upstream: [media] smiapp: Fix determining the need for 8-bit read access
authorSakari Ailus <sakari.ailus@linux.intel.com>
Sat, 12 Apr 2014 19:41:12 +0000 (16:41 -0300)
committerChanho Park <chanho61.park@samsung.com>
Tue, 18 Nov 2014 02:55:13 +0000 (11:55 +0900)
commit7ef95fb803a0a36f54470fb1adb35fb836e2a076
tree70d516904959d2a8fbb5d3c2e5b294be5ab7a23d
parentbba19cfaffc9dcc5272d64bb623d40fe2529d54a
upstream: [media] smiapp: Fix determining the need for 8-bit read access

8-bit reads are needed in some cases; however the condition used was wrong.
Regular access (register width) was used if:

len == SMIAPP_REG_8BIT && !only8

This causes 8-bit read access to be used always. The operator should be ||
instead: regular access can be used for 8-bit reads OR if allowed otherwise.

Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
drivers/media/i2c/smiapp/smiapp-regs.c