OSDN Git Service

[media] s5p-mfc: Fix sparse errors in the MFC driver
authorKamil Debski <k.debski@samsung.com>
Thu, 11 Sep 2014 13:27:20 +0000 (10:27 -0300)
committerMauro Carvalho Chehab <mchehab@osg.samsung.com>
Fri, 26 Sep 2014 09:47:46 +0000 (06:47 -0300)
commite2c3be2aff3358e485ed307cc3ad11a9c58c086f
tree346851ef1bce754b1a632462ad8e5cd39c03673c
parent9aee8b80a8facefb29ad0077fdbcca116f25f6e6
[media] s5p-mfc: Fix sparse errors in the MFC driver

The following error: "error: incompatible types in conditional expression
(different base types)" was reported multiple times for the s5p-mfc
driver. This error was caused by two macro definitions - s5p_mfc_hw_call
(in s5p_mfc_common.h) and WRITEL (in s5p_mfc_opr_v6.c).

In the former case the macro assumed that all ops return a value, but some
ops return void. The solution to this problem was the addition of a
s5p_mfc_hw_call_void macro.

In the latter case the macro used the ?: construction to check whether
the address is non zero. This is not necessary after the driver left the
development and debugging cycle, so the READL and WRITEL macros were
removed.

Signed-off-by: Kamil Debski <k.debski@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
drivers/media/platform/s5p-mfc/s5p_mfc.c
drivers/media/platform/s5p-mfc/s5p_mfc_common.h
drivers/media/platform/s5p-mfc/s5p_mfc_ctrl.c
drivers/media/platform/s5p-mfc/s5p_mfc_dec.c
drivers/media/platform/s5p-mfc/s5p_mfc_enc.c
drivers/media/platform/s5p-mfc/s5p_mfc_opr_v6.c