diff options
author | Boris BREZILLON <boris.brezillon@free-electrons.com> | 2014-11-10 20:28:33 +0300 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@osg.samsung.com> | 2014-11-14 22:55:08 +0300 |
commit | 3336f07aa6bccf86d59b16f91b8ecb95bf8c1910 (patch) | |
tree | 134200b62540efda754d74d8e6167fb04458357b /drivers/staging/media/omap4iss/iss_ipipeif.c | |
parent | 18cb5ec38f427f4552b4435ce2021f6fb21743f4 (diff) | |
download | linux-3336f07aa6bccf86d59b16f91b8ecb95bf8c1910.tar.xz |
[media] staging: media: Make use of MEDIA_BUS_FMT_ definitions
In order to have subsytem agnostic media bus format definitions we've
moved media bus definition to include/uapi/linux/media-bus-format.h and
prefixed values with MEDIA_BUS_FMT instead of V4L2_MBUS_FMT.
Reference new definitions in all media drivers residing in staging.
Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com>
Acked-by: Hans Verkuil <hans.verkuil@cisco.com>
Acked-by: Sakari Ailus <sakari.ailus@linux.intel.com>
Acked-by: Lad, Prabhakar <prabhakar.csengg@gmail.com>
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
Diffstat (limited to 'drivers/staging/media/omap4iss/iss_ipipeif.c')
-rw-r--r-- | drivers/staging/media/omap4iss/iss_ipipeif.c | 28 |
1 files changed, 14 insertions, 14 deletions
diff --git a/drivers/staging/media/omap4iss/iss_ipipeif.c b/drivers/staging/media/omap4iss/iss_ipipeif.c index 75f6a15ad202..32a748398ced 100644 --- a/drivers/staging/media/omap4iss/iss_ipipeif.c +++ b/drivers/staging/media/omap4iss/iss_ipipeif.c @@ -24,12 +24,12 @@ #include "iss_ipipeif.h" static const unsigned int ipipeif_fmts[] = { - V4L2_MBUS_FMT_SGRBG10_1X10, - V4L2_MBUS_FMT_SRGGB10_1X10, - V4L2_MBUS_FMT_SBGGR10_1X10, - V4L2_MBUS_FMT_SGBRG10_1X10, - V4L2_MBUS_FMT_UYVY8_1X16, - V4L2_MBUS_FMT_YUYV8_1X16, + MEDIA_BUS_FMT_SGRBG10_1X10, + MEDIA_BUS_FMT_SRGGB10_1X10, + MEDIA_BUS_FMT_SBGGR10_1X10, + MEDIA_BUS_FMT_SGBRG10_1X10, + MEDIA_BUS_FMT_UYVY8_1X16, + MEDIA_BUS_FMT_YUYV8_1X16, }; /* @@ -140,8 +140,8 @@ static void ipipeif_configure(struct iss_ipipeif_device *ipipeif) /* Select ISIF/IPIPEIF input format */ switch (format->code) { - case V4L2_MBUS_FMT_UYVY8_1X16: - case V4L2_MBUS_FMT_YUYV8_1X16: + case MEDIA_BUS_FMT_UYVY8_1X16: + case MEDIA_BUS_FMT_YUYV8_1X16: iss_reg_update(iss, OMAP4_ISS_MEM_ISP_ISIF, ISIF_MODESET, ISIF_MODESET_CCDMD | ISIF_MODESET_INPMOD_MASK | ISIF_MODESET_CCDW_MASK, @@ -151,25 +151,25 @@ static void ipipeif_configure(struct iss_ipipeif_device *ipipeif) IPIPEIF_CFG2_YUV8, IPIPEIF_CFG2_YUV16); break; - case V4L2_MBUS_FMT_SGRBG10_1X10: + case MEDIA_BUS_FMT_SGRBG10_1X10: isif_ccolp = ISIF_CCOLP_CP0_F0_GR | ISIF_CCOLP_CP1_F0_R | ISIF_CCOLP_CP2_F0_B | ISIF_CCOLP_CP3_F0_GB; goto cont_raw; - case V4L2_MBUS_FMT_SRGGB10_1X10: + case MEDIA_BUS_FMT_SRGGB10_1X10: isif_ccolp = ISIF_CCOLP_CP0_F0_R | ISIF_CCOLP_CP1_F0_GR | ISIF_CCOLP_CP2_F0_GB | ISIF_CCOLP_CP3_F0_B; goto cont_raw; - case V4L2_MBUS_FMT_SBGGR10_1X10: + case MEDIA_BUS_FMT_SBGGR10_1X10: isif_ccolp = ISIF_CCOLP_CP0_F0_B | ISIF_CCOLP_CP1_F0_GB | ISIF_CCOLP_CP2_F0_GR | ISIF_CCOLP_CP3_F0_R; goto cont_raw; - case V4L2_MBUS_FMT_SGBRG10_1X10: + case MEDIA_BUS_FMT_SGBRG10_1X10: isif_ccolp = ISIF_CCOLP_CP0_F0_GB | ISIF_CCOLP_CP1_F0_B | ISIF_CCOLP_CP2_F0_R | @@ -415,7 +415,7 @@ ipipeif_try_format(struct iss_ipipeif_device *ipipeif, /* If not found, use SGRBG10 as default */ if (i >= ARRAY_SIZE(ipipeif_fmts)) - fmt->code = V4L2_MBUS_FMT_SGRBG10_1X10; + fmt->code = MEDIA_BUS_FMT_SGRBG10_1X10; /* Clamp the input size. */ fmt->width = clamp_t(u32, width, 1, 8192); @@ -625,7 +625,7 @@ static int ipipeif_init_formats(struct v4l2_subdev *sd, memset(&format, 0, sizeof(format)); format.pad = IPIPEIF_PAD_SINK; format.which = fh ? V4L2_SUBDEV_FORMAT_TRY : V4L2_SUBDEV_FORMAT_ACTIVE; - format.format.code = V4L2_MBUS_FMT_SGRBG10_1X10; + format.format.code = MEDIA_BUS_FMT_SGRBG10_1X10; format.format.width = 4096; format.format.height = 4096; ipipeif_set_format(sd, fh, &format); |