Re: [Patch v2 19/21] media: v4l2-common: add pixel encoding support

2019-10-07 Thread Benoit Parrot
Hans Verkuil  wrote on Mon [2019-Oct-07 10:06:39 +0200]:
> On 10/4/19 6:29 PM, Benoit Parrot wrote:
> > It is often useful to figure out if a pixel_format is either YUV or RGB
> > especially for driver who can perform the pixel encoding conversion.
> > 
> > Instead of having each driver implement its own "is_this_yuv/rgb"
> > function based on a restricted set of pixel value, it is better to do
> > this in centralized manner.
> > 
> > We therefore add a pix_enc member to the v4l2_format_info structure to
> > quickly identify the related pixel encoding.
> > And add helper function to find/check pixel encoding.
> > 
> > Signed-off-by: Benoit Parrot 
> > ---
> >  drivers/media/v4l2-core/v4l2-common.c | 162 --
> >  include/media/v4l2-common.h   |  20 
> >  2 files changed, 119 insertions(+), 63 deletions(-)
> > 
> > diff --git a/drivers/media/v4l2-core/v4l2-common.c 
> > b/drivers/media/v4l2-core/v4l2-common.c
> > index 62f7aa92ac29..474cdb5863f4 100644
> > --- a/drivers/media/v4l2-core/v4l2-common.c
> > +++ b/drivers/media/v4l2-core/v4l2-common.c
> > @@ -236,77 +236,77 @@ const struct v4l2_format_info *v4l2_format_info(u32 
> > format)
> >  {
> > static const struct v4l2_format_info formats[] = {
> > /* RGB formats */
> > -   { .format = V4L2_PIX_FMT_BGR24,   .mem_planes = 1, .comp_planes 
> > = 1, .bpp = { 3, 0, 0, 0 }, .hdiv = 1, .vdiv = 1 },
> > -   { .format = V4L2_PIX_FMT_RGB24,   .mem_planes = 1, .comp_planes 
> > = 1, .bpp = { 3, 0, 0, 0 }, .hdiv = 1, .vdiv = 1 },
> > -   { .format = V4L2_PIX_FMT_HSV24,   .mem_planes = 1, .comp_planes 
> > = 1, .bpp = { 3, 0, 0, 0 }, .hdiv = 1, .vdiv = 1 },
> > -   { .format = V4L2_PIX_FMT_BGR32,   .mem_planes = 1, .comp_planes 
> > = 1, .bpp = { 4, 0, 0, 0 }, .hdiv = 1, .vdiv = 1 },
> > -   { .format = V4L2_PIX_FMT_XBGR32,  .mem_planes = 1, .comp_planes 
> > = 1, .bpp = { 4, 0, 0, 0 }, .hdiv = 1, .vdiv = 1 },
> > -   { .format = V4L2_PIX_FMT_BGRX32,  .mem_planes = 1, .comp_planes 
> > = 1, .bpp = { 4, 0, 0, 0 }, .hdiv = 1, .vdiv = 1 },
> > -   { .format = V4L2_PIX_FMT_RGB32,   .mem_planes = 1, .comp_planes 
> > = 1, .bpp = { 4, 0, 0, 0 }, .hdiv = 1, .vdiv = 1 },
> > -   { .format = V4L2_PIX_FMT_XRGB32,  .mem_planes = 1, .comp_planes 
> > = 1, .bpp = { 4, 0, 0, 0 }, .hdiv = 1, .vdiv = 1 },
> > -   { .format = V4L2_PIX_FMT_RGBX32,  .mem_planes = 1, .comp_planes 
> > = 1, .bpp = { 4, 0, 0, 0 }, .hdiv = 1, .vdiv = 1 },
> > -   { .format = V4L2_PIX_FMT_HSV32,   .mem_planes = 1, .comp_planes 
> > = 1, .bpp = { 4, 0, 0, 0 }, .hdiv = 1, .vdiv = 1 },
> > -   { .format = V4L2_PIX_FMT_ARGB32,  .mem_planes = 1, .comp_planes 
> > = 1, .bpp = { 4, 0, 0, 0 }, .hdiv = 1, .vdiv = 1 },
> > -   { .format = V4L2_PIX_FMT_RGBA32,  .mem_planes = 1, .comp_planes 
> > = 1, .bpp = { 4, 0, 0, 0 }, .hdiv = 1, .vdiv = 1 },
> > -   { .format = V4L2_PIX_FMT_ABGR32,  .mem_planes = 1, .comp_planes 
> > = 1, .bpp = { 4, 0, 0, 0 }, .hdiv = 1, .vdiv = 1 },
> > -   { .format = V4L2_PIX_FMT_BGRA32,  .mem_planes = 1, .comp_planes 
> > = 1, .bpp = { 4, 0, 0, 0 }, .hdiv = 1, .vdiv = 1 },
> > -   { .format = V4L2_PIX_FMT_GREY,.mem_planes = 1, .comp_planes 
> > = 1, .bpp = { 1, 0, 0, 0 }, .hdiv = 1, .vdiv = 1 },
> > +   { .format = V4L2_PIX_FMT_BGR24,   .pix_enc = V4L2_ENC_RGB, 
> > .mem_planes = 1, .comp_planes = 1, .bpp = { 3, 0, 0, 0 }, .hdiv = 1, .vdiv 
> > = 1 },
> > +   { .format = V4L2_PIX_FMT_RGB24,   .pix_enc = V4L2_ENC_RGB, 
> > .mem_planes = 1, .comp_planes = 1, .bpp = { 3, 0, 0, 0 }, .hdiv = 1, .vdiv 
> > = 1 },
> > +   { .format = V4L2_PIX_FMT_HSV24,   .pix_enc = V4L2_ENC_RGB, 
> > .mem_planes = 1, .comp_planes = 1, .bpp = { 3, 0, 0, 0 }, .hdiv = 1, .vdiv 
> > = 1 },
> > +   { .format = V4L2_PIX_FMT_BGR32,   .pix_enc = V4L2_ENC_RGB, 
> > .mem_planes = 1, .comp_planes = 1, .bpp = { 4, 0, 0, 0 }, .hdiv = 1, .vdiv 
> > = 1 },
> > +   { .format = V4L2_PIX_FMT_XBGR32,  .pix_enc = V4L2_ENC_RGB, 
> > .mem_planes = 1, .comp_planes = 1, .bpp = { 4, 0, 0, 0 }, .hdiv = 1, .vdiv 
> > = 1 },
> > +   { .format = V4L2_PIX_FMT_BGRX32,  .pix_enc = V4L2_ENC_RGB, 
> > .mem_planes = 1, .comp_planes = 1, .bpp = { 4, 0, 0, 0 }, .hdiv = 1, .vdiv 
> > = 1 },
> > +   { .format = V4L2_PIX_FMT_RGB32,   .pix_enc = V4L2_ENC_RGB, 
> > .mem_planes = 1, .comp_planes = 1, .bpp = { 4, 0, 0, 0 }, .hdiv = 1, .vdiv 
> > = 1 },
> > +   { .format = V4L2_PIX_FMT_XRGB32,  .pix_enc = V4L2_ENC_RGB, 
> > .mem_planes = 1, .comp_planes = 1, .bpp = { 4, 0, 0, 0 }, .hdiv = 1, .vdiv 
> > = 1 },
> > +   { .format = V4L2_PIX_FMT_RGBX32,  .pix_enc = V4L2_ENC_RGB, 
> > .mem_planes = 1, .comp_planes = 1, .bpp = { 4, 0, 0, 0 }, .hdiv = 1, .vdiv 
> > = 1 },
> > +   { .format = V4L2_PIX_FMT_HSV32,   .pix_enc = V4L2_ENC_RGB, 
> > .mem_planes = 1, .comp_planes = 1, .bpp = { 4, 0, 0, 0 }, .hdiv = 1, .vdiv

Re: [Patch v2 19/21] media: v4l2-common: add pixel encoding support

2019-10-07 Thread Hans Verkuil
On 10/4/19 6:29 PM, Benoit Parrot wrote:
> It is often useful to figure out if a pixel_format is either YUV or RGB
> especially for driver who can perform the pixel encoding conversion.
> 
> Instead of having each driver implement its own "is_this_yuv/rgb"
> function based on a restricted set of pixel value, it is better to do
> this in centralized manner.
> 
> We therefore add a pix_enc member to the v4l2_format_info structure to
> quickly identify the related pixel encoding.
> And add helper function to find/check pixel encoding.
> 
> Signed-off-by: Benoit Parrot 
> ---
>  drivers/media/v4l2-core/v4l2-common.c | 162 --
>  include/media/v4l2-common.h   |  20 
>  2 files changed, 119 insertions(+), 63 deletions(-)
> 
> diff --git a/drivers/media/v4l2-core/v4l2-common.c 
> b/drivers/media/v4l2-core/v4l2-common.c
> index 62f7aa92ac29..474cdb5863f4 100644
> --- a/drivers/media/v4l2-core/v4l2-common.c
> +++ b/drivers/media/v4l2-core/v4l2-common.c
> @@ -236,77 +236,77 @@ const struct v4l2_format_info *v4l2_format_info(u32 
> format)
>  {
>   static const struct v4l2_format_info formats[] = {
>   /* RGB formats */
> - { .format = V4L2_PIX_FMT_BGR24,   .mem_planes = 1, .comp_planes 
> = 1, .bpp = { 3, 0, 0, 0 }, .hdiv = 1, .vdiv = 1 },
> - { .format = V4L2_PIX_FMT_RGB24,   .mem_planes = 1, .comp_planes 
> = 1, .bpp = { 3, 0, 0, 0 }, .hdiv = 1, .vdiv = 1 },
> - { .format = V4L2_PIX_FMT_HSV24,   .mem_planes = 1, .comp_planes 
> = 1, .bpp = { 3, 0, 0, 0 }, .hdiv = 1, .vdiv = 1 },
> - { .format = V4L2_PIX_FMT_BGR32,   .mem_planes = 1, .comp_planes 
> = 1, .bpp = { 4, 0, 0, 0 }, .hdiv = 1, .vdiv = 1 },
> - { .format = V4L2_PIX_FMT_XBGR32,  .mem_planes = 1, .comp_planes 
> = 1, .bpp = { 4, 0, 0, 0 }, .hdiv = 1, .vdiv = 1 },
> - { .format = V4L2_PIX_FMT_BGRX32,  .mem_planes = 1, .comp_planes 
> = 1, .bpp = { 4, 0, 0, 0 }, .hdiv = 1, .vdiv = 1 },
> - { .format = V4L2_PIX_FMT_RGB32,   .mem_planes = 1, .comp_planes 
> = 1, .bpp = { 4, 0, 0, 0 }, .hdiv = 1, .vdiv = 1 },
> - { .format = V4L2_PIX_FMT_XRGB32,  .mem_planes = 1, .comp_planes 
> = 1, .bpp = { 4, 0, 0, 0 }, .hdiv = 1, .vdiv = 1 },
> - { .format = V4L2_PIX_FMT_RGBX32,  .mem_planes = 1, .comp_planes 
> = 1, .bpp = { 4, 0, 0, 0 }, .hdiv = 1, .vdiv = 1 },
> - { .format = V4L2_PIX_FMT_HSV32,   .mem_planes = 1, .comp_planes 
> = 1, .bpp = { 4, 0, 0, 0 }, .hdiv = 1, .vdiv = 1 },
> - { .format = V4L2_PIX_FMT_ARGB32,  .mem_planes = 1, .comp_planes 
> = 1, .bpp = { 4, 0, 0, 0 }, .hdiv = 1, .vdiv = 1 },
> - { .format = V4L2_PIX_FMT_RGBA32,  .mem_planes = 1, .comp_planes 
> = 1, .bpp = { 4, 0, 0, 0 }, .hdiv = 1, .vdiv = 1 },
> - { .format = V4L2_PIX_FMT_ABGR32,  .mem_planes = 1, .comp_planes 
> = 1, .bpp = { 4, 0, 0, 0 }, .hdiv = 1, .vdiv = 1 },
> - { .format = V4L2_PIX_FMT_BGRA32,  .mem_planes = 1, .comp_planes 
> = 1, .bpp = { 4, 0, 0, 0 }, .hdiv = 1, .vdiv = 1 },
> - { .format = V4L2_PIX_FMT_GREY,.mem_planes = 1, .comp_planes 
> = 1, .bpp = { 1, 0, 0, 0 }, .hdiv = 1, .vdiv = 1 },
> + { .format = V4L2_PIX_FMT_BGR24,   .pix_enc = V4L2_ENC_RGB, 
> .mem_planes = 1, .comp_planes = 1, .bpp = { 3, 0, 0, 0 }, .hdiv = 1, .vdiv = 
> 1 },
> + { .format = V4L2_PIX_FMT_RGB24,   .pix_enc = V4L2_ENC_RGB, 
> .mem_planes = 1, .comp_planes = 1, .bpp = { 3, 0, 0, 0 }, .hdiv = 1, .vdiv = 
> 1 },
> + { .format = V4L2_PIX_FMT_HSV24,   .pix_enc = V4L2_ENC_RGB, 
> .mem_planes = 1, .comp_planes = 1, .bpp = { 3, 0, 0, 0 }, .hdiv = 1, .vdiv = 
> 1 },
> + { .format = V4L2_PIX_FMT_BGR32,   .pix_enc = V4L2_ENC_RGB, 
> .mem_planes = 1, .comp_planes = 1, .bpp = { 4, 0, 0, 0 }, .hdiv = 1, .vdiv = 
> 1 },
> + { .format = V4L2_PIX_FMT_XBGR32,  .pix_enc = V4L2_ENC_RGB, 
> .mem_planes = 1, .comp_planes = 1, .bpp = { 4, 0, 0, 0 }, .hdiv = 1, .vdiv = 
> 1 },
> + { .format = V4L2_PIX_FMT_BGRX32,  .pix_enc = V4L2_ENC_RGB, 
> .mem_planes = 1, .comp_planes = 1, .bpp = { 4, 0, 0, 0 }, .hdiv = 1, .vdiv = 
> 1 },
> + { .format = V4L2_PIX_FMT_RGB32,   .pix_enc = V4L2_ENC_RGB, 
> .mem_planes = 1, .comp_planes = 1, .bpp = { 4, 0, 0, 0 }, .hdiv = 1, .vdiv = 
> 1 },
> + { .format = V4L2_PIX_FMT_XRGB32,  .pix_enc = V4L2_ENC_RGB, 
> .mem_planes = 1, .comp_planes = 1, .bpp = { 4, 0, 0, 0 }, .hdiv = 1, .vdiv = 
> 1 },
> + { .format = V4L2_PIX_FMT_RGBX32,  .pix_enc = V4L2_ENC_RGB, 
> .mem_planes = 1, .comp_planes = 1, .bpp = { 4, 0, 0, 0 }, .hdiv = 1, .vdiv = 
> 1 },
> + { .format = V4L2_PIX_FMT_HSV32,   .pix_enc = V4L2_ENC_RGB, 
> .mem_planes = 1, .comp_planes = 1, .bpp = { 4, 0, 0, 0 }, .hdiv = 1, .vdiv = 
> 1 },
> + { .format = V4L2_PIX_FMT_ARGB32,  .pix_enc = V4L2_ENC_RGB, 
> .mem_planes = 1, .comp_planes = 1, .bpp = { 4, 0, 0, 0 }, .hdiv = 1, .vdiv = 
> 1 },
> +

Re: [Patch v2 19/21] media: v4l2-common: add pixel encoding support

2019-10-04 Thread kbuild test robot
Hi Benoit,

I love your patch! Yet something to improve:

[auto build test ERROR on linuxtv-media/master]
[cannot apply to v5.4-rc1 next-20191004]
[if your patch is applied to the wrong git tree, please drop us a note to help
improve the system. BTW, we also suggest to use '--base' option to specify the
base tree in git format-patch, please see https://stackoverflow.com/a/37406982]

url:
https://github.com/0day-ci/linux/commits/Benoit-Parrot/media-vpe-maintenance/20191005-061051
base:   git://linuxtv.org/media_tree.git master
config: x86_64-rhel (attached as .config)
compiler: gcc-7 (Debian 7.4.0-13) 7.4.0
reproduce:
# save the attached .config to linux build tree
make ARCH=x86_64 

If you fix the issue, kindly add following tag
Reported-by: kbuild test robot 

All errors (new ones prefixed by >>):

   In file included from drivers/media//usb/zr364xx/zr364xx.c:25:0:
>> include/media/v4l2-common.h:468:2: error: stray '@' in program
 @V4L2_ENC_UNKNOWN = 0,
 ^

vim +468 include/media/v4l2-common.h

   458  
   459  /**
   460   * enum v4l2_pixel_encoding - specifies the pixel encoding value
   461   *
   462   * @V4L2_ENC_UNKNOWN:   Pixel encoding is unknown/un-initialized
   463   * @V4L2_ENC_YUV:   Pixel encoding is YUV
   464   * @V4L2_ENC_RGB:   Pixel encoding is RGB
   465   * @V4L2_ENC_BAYER: Pixel encoding is Bayer
   466   */
   467  enum v4l2_pixel_encoding {
 > 468  @V4L2_ENC_UNKNOWN = 0,
   469  V4L2_ENC_YUV = 1,
   470  V4L2_ENC_RGB = 2,
   471  V4L2_ENC_BAYER = 3,
   472  };
   473  

---
0-DAY kernel test infrastructureOpen Source Technology Center
https://lists.01.org/pipermail/kbuild-all   Intel Corporation


.config.gz
Description: application/gzip


Re: [Patch v2 19/21] media: v4l2-common: add pixel encoding support

2019-10-04 Thread kbuild test robot
Hi Benoit,

I love your patch! Perhaps something to improve:

[auto build test WARNING on linuxtv-media/master]
[cannot apply to v5.4-rc1 next-20191004]
[if your patch is applied to the wrong git tree, please drop us a note to help
improve the system. BTW, we also suggest to use '--base' option to specify the
base tree in git format-patch, please see https://stackoverflow.com/a/37406982]

url:
https://github.com/0day-ci/linux/commits/Benoit-Parrot/media-vpe-maintenance/20191005-061051
base:   git://linuxtv.org/media_tree.git master
reproduce: make htmldocs

If you fix the issue, kindly add following tag
Reported-by: kbuild test robot 

All warnings (new ones prefixed by >>):

   Warning: The Sphinx 'sphinx_rtd_theme' HTML theme was not found. Make sure 
you have the theme installed to produce pretty HTML output. Falling back to the 
default theme.
   WARNING: dot(1) not found, for better output quality install graphviz from 
http://www.graphviz.org
   WARNING: convert(1) not found, for SVG to PDF conversion install ImageMagick 
(https://www.imagemagick.org)
   include/linux/regulator/machine.h:196: warning: Function parameter or member 
'max_uV_step' not described in 'regulation_constraints'
   include/linux/regulator/driver.h:223: warning: Function parameter or member 
'resume' not described in 'regulator_ops'
   Error: Cannot open file drivers/dma-buf/reservation.c
   Error: Cannot open file drivers/dma-buf/reservation.c
   Error: Cannot open file drivers/dma-buf/reservation.c
   Error: Cannot open file include/linux/reservation.h
   Error: Cannot open file include/linux/reservation.h
   include/linux/spi/spi.h:190: warning: Function parameter or member 
'driver_override' not described in 'spi_device'
   drivers/gpu/drm/amd/amdgpu/amdgpu_dma_buf.c:335: warning: Excess function 
parameter 'dev' description in 'amdgpu_gem_prime_export'
   drivers/gpu/drm/amd/amdgpu/amdgpu_dma_buf.c:336: warning: Excess function 
parameter 'dev' description in 'amdgpu_gem_prime_export'
   drivers/gpu/drm/amd/amdgpu/amdgpu_mn.c:142: warning: Function parameter or 
member 'blockable' not described in 'amdgpu_mn_read_lock'
   drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c:347: warning: cannot understand 
function prototype: 'struct amdgpu_vm_pt_cursor '
   drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c:348: warning: cannot understand 
function prototype: 'struct amdgpu_vm_pt_cursor '
   drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c:494: warning: Function parameter or 
member 'start' not described in 'amdgpu_vm_pt_first_dfs'
   drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c:546: warning: Function parameter or 
member 'adev' not described in 'for_each_amdgpu_vm_pt_dfs_safe'
   drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c:546: warning: Function parameter or 
member 'vm' not described in 'for_each_amdgpu_vm_pt_dfs_safe'
   drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c:546: warning: Function parameter or 
member 'start' not described in 'for_each_amdgpu_vm_pt_dfs_safe'
   drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c:546: warning: Function parameter or 
member 'cursor' not described in 'for_each_amdgpu_vm_pt_dfs_safe'
   drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c:546: warning: Function parameter or 
member 'entry' not described in 'for_each_amdgpu_vm_pt_dfs_safe'
   drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c:823: warning: Function parameter or 
member 'level' not described in 'amdgpu_vm_bo_param'
   drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c:1285: warning: Function parameter or 
member 'params' not described in 'amdgpu_vm_update_flags'
   drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c:1285: warning: Function parameter or 
member 'bo' not described in 'amdgpu_vm_update_flags'
   drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c:1285: warning: Function parameter or 
member 'level' not described in 'amdgpu_vm_update_flags'
   drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c:1285: warning: Function parameter or 
member 'pe' not described in 'amdgpu_vm_update_flags'
   drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c:1285: warning: Function parameter or 
member 'addr' not described in 'amdgpu_vm_update_flags'
   drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c:1285: warning: Function parameter or 
member 'count' not described in 'amdgpu_vm_update_flags'
   drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c:1285: warning: Function parameter or 
member 'incr' not described in 'amdgpu_vm_update_flags'
   drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c:1285: warning: Function parameter or 
member 'flags' not described in 'amdgpu_vm_update_flags'
   drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c:2823: warning: Function parameter or 
member 'pasid' not described in 'amdgpu_vm_make_compute'
   drivers/gpu/drm/amd/amdgpu/amdgpu_irq.c:378: warning: Excess function 
parameter 'entry' description in 'amdgpu_irq_dispatch'
   drivers/gpu/drm/amd/amdgpu/amdgpu_irq.c:379: warning: Function parameter or 
member 'ih' not described in 'amdgpu_irq_dispatch'
   drivers/gpu/drm/amd/amdgpu/amdgpu_irq.c:379: warning: Excess function 
parameter 'entry' description in 'amdgpu_irq_dispatch'
   dr

[Patch v2 19/21] media: v4l2-common: add pixel encoding support

2019-10-04 Thread Benoit Parrot
It is often useful to figure out if a pixel_format is either YUV or RGB
especially for driver who can perform the pixel encoding conversion.

Instead of having each driver implement its own "is_this_yuv/rgb"
function based on a restricted set of pixel value, it is better to do
this in centralized manner.

We therefore add a pix_enc member to the v4l2_format_info structure to
quickly identify the related pixel encoding.
And add helper function to find/check pixel encoding.

Signed-off-by: Benoit Parrot 
---
 drivers/media/v4l2-core/v4l2-common.c | 162 --
 include/media/v4l2-common.h   |  20 
 2 files changed, 119 insertions(+), 63 deletions(-)

diff --git a/drivers/media/v4l2-core/v4l2-common.c 
b/drivers/media/v4l2-core/v4l2-common.c
index 62f7aa92ac29..474cdb5863f4 100644
--- a/drivers/media/v4l2-core/v4l2-common.c
+++ b/drivers/media/v4l2-core/v4l2-common.c
@@ -236,77 +236,77 @@ const struct v4l2_format_info *v4l2_format_info(u32 
format)
 {
static const struct v4l2_format_info formats[] = {
/* RGB formats */
-   { .format = V4L2_PIX_FMT_BGR24,   .mem_planes = 1, .comp_planes 
= 1, .bpp = { 3, 0, 0, 0 }, .hdiv = 1, .vdiv = 1 },
-   { .format = V4L2_PIX_FMT_RGB24,   .mem_planes = 1, .comp_planes 
= 1, .bpp = { 3, 0, 0, 0 }, .hdiv = 1, .vdiv = 1 },
-   { .format = V4L2_PIX_FMT_HSV24,   .mem_planes = 1, .comp_planes 
= 1, .bpp = { 3, 0, 0, 0 }, .hdiv = 1, .vdiv = 1 },
-   { .format = V4L2_PIX_FMT_BGR32,   .mem_planes = 1, .comp_planes 
= 1, .bpp = { 4, 0, 0, 0 }, .hdiv = 1, .vdiv = 1 },
-   { .format = V4L2_PIX_FMT_XBGR32,  .mem_planes = 1, .comp_planes 
= 1, .bpp = { 4, 0, 0, 0 }, .hdiv = 1, .vdiv = 1 },
-   { .format = V4L2_PIX_FMT_BGRX32,  .mem_planes = 1, .comp_planes 
= 1, .bpp = { 4, 0, 0, 0 }, .hdiv = 1, .vdiv = 1 },
-   { .format = V4L2_PIX_FMT_RGB32,   .mem_planes = 1, .comp_planes 
= 1, .bpp = { 4, 0, 0, 0 }, .hdiv = 1, .vdiv = 1 },
-   { .format = V4L2_PIX_FMT_XRGB32,  .mem_planes = 1, .comp_planes 
= 1, .bpp = { 4, 0, 0, 0 }, .hdiv = 1, .vdiv = 1 },
-   { .format = V4L2_PIX_FMT_RGBX32,  .mem_planes = 1, .comp_planes 
= 1, .bpp = { 4, 0, 0, 0 }, .hdiv = 1, .vdiv = 1 },
-   { .format = V4L2_PIX_FMT_HSV32,   .mem_planes = 1, .comp_planes 
= 1, .bpp = { 4, 0, 0, 0 }, .hdiv = 1, .vdiv = 1 },
-   { .format = V4L2_PIX_FMT_ARGB32,  .mem_planes = 1, .comp_planes 
= 1, .bpp = { 4, 0, 0, 0 }, .hdiv = 1, .vdiv = 1 },
-   { .format = V4L2_PIX_FMT_RGBA32,  .mem_planes = 1, .comp_planes 
= 1, .bpp = { 4, 0, 0, 0 }, .hdiv = 1, .vdiv = 1 },
-   { .format = V4L2_PIX_FMT_ABGR32,  .mem_planes = 1, .comp_planes 
= 1, .bpp = { 4, 0, 0, 0 }, .hdiv = 1, .vdiv = 1 },
-   { .format = V4L2_PIX_FMT_BGRA32,  .mem_planes = 1, .comp_planes 
= 1, .bpp = { 4, 0, 0, 0 }, .hdiv = 1, .vdiv = 1 },
-   { .format = V4L2_PIX_FMT_GREY,.mem_planes = 1, .comp_planes 
= 1, .bpp = { 1, 0, 0, 0 }, .hdiv = 1, .vdiv = 1 },
+   { .format = V4L2_PIX_FMT_BGR24,   .pix_enc = V4L2_ENC_RGB, 
.mem_planes = 1, .comp_planes = 1, .bpp = { 3, 0, 0, 0 }, .hdiv = 1, .vdiv = 1 
},
+   { .format = V4L2_PIX_FMT_RGB24,   .pix_enc = V4L2_ENC_RGB, 
.mem_planes = 1, .comp_planes = 1, .bpp = { 3, 0, 0, 0 }, .hdiv = 1, .vdiv = 1 
},
+   { .format = V4L2_PIX_FMT_HSV24,   .pix_enc = V4L2_ENC_RGB, 
.mem_planes = 1, .comp_planes = 1, .bpp = { 3, 0, 0, 0 }, .hdiv = 1, .vdiv = 1 
},
+   { .format = V4L2_PIX_FMT_BGR32,   .pix_enc = V4L2_ENC_RGB, 
.mem_planes = 1, .comp_planes = 1, .bpp = { 4, 0, 0, 0 }, .hdiv = 1, .vdiv = 1 
},
+   { .format = V4L2_PIX_FMT_XBGR32,  .pix_enc = V4L2_ENC_RGB, 
.mem_planes = 1, .comp_planes = 1, .bpp = { 4, 0, 0, 0 }, .hdiv = 1, .vdiv = 1 
},
+   { .format = V4L2_PIX_FMT_BGRX32,  .pix_enc = V4L2_ENC_RGB, 
.mem_planes = 1, .comp_planes = 1, .bpp = { 4, 0, 0, 0 }, .hdiv = 1, .vdiv = 1 
},
+   { .format = V4L2_PIX_FMT_RGB32,   .pix_enc = V4L2_ENC_RGB, 
.mem_planes = 1, .comp_planes = 1, .bpp = { 4, 0, 0, 0 }, .hdiv = 1, .vdiv = 1 
},
+   { .format = V4L2_PIX_FMT_XRGB32,  .pix_enc = V4L2_ENC_RGB, 
.mem_planes = 1, .comp_planes = 1, .bpp = { 4, 0, 0, 0 }, .hdiv = 1, .vdiv = 1 
},
+   { .format = V4L2_PIX_FMT_RGBX32,  .pix_enc = V4L2_ENC_RGB, 
.mem_planes = 1, .comp_planes = 1, .bpp = { 4, 0, 0, 0 }, .hdiv = 1, .vdiv = 1 
},
+   { .format = V4L2_PIX_FMT_HSV32,   .pix_enc = V4L2_ENC_RGB, 
.mem_planes = 1, .comp_planes = 1, .bpp = { 4, 0, 0, 0 }, .hdiv = 1, .vdiv = 1 
},
+   { .format = V4L2_PIX_FMT_ARGB32,  .pix_enc = V4L2_ENC_RGB, 
.mem_planes = 1, .comp_planes = 1, .bpp = { 4, 0, 0, 0 }, .hdiv = 1, .vdiv = 1 
},
+   { .format = V4L2_PIX_FMT_RGBA32,  .pix_enc = V4L2_ENC_RGB, 
.mem_planes = 1, .comp_planes = 1, .bpp = { 4, 0, 0, 0 }, .hdiv = 1, .vdiv = 1 
},
+