All of lore.kernel.org
 help / color / mirror / Atom feed
* Re: [PATCH v4 1/2] media: add new mediabus format enums for dm365
       [not found] ` <1333102154-24657-2-git-send-email-manjunath.hadli@ti.com>
@ 2012-07-17 10:56   ` Laurent Pinchart
  2012-07-17 11:41     ` Hadli, Manjunath
  0 siblings, 1 reply; 12+ messages in thread
From: Laurent Pinchart @ 2012-07-17 10:56 UTC (permalink / raw)
  To: Hadli, Manjunath; +Cc: dlos, LMML, Sakari Ailus, Hans Verkuil

Hi Manjunath,

Thank you for the patch.

Just some nitpicking, please see below.

On Friday 30 March 2012 10:09:13 Hadli, Manjunath wrote:
> add new enum entries for supporting the media-bus formats on dm365.
> These include some bayer and some non-bayer formats.
> V4L2_MBUS_FMT_YDYC8_1X16 and V4L2_MBUS_FMT_UV8_1X8 are used
> internal to the hardware by the resizer.
> V4L2_MBUS_FMT_SBGGR10_ALAW8_1X8 represents the bayer ALAW format
> that is supported by dm365 hardware.
> 
> Signed-off-by: Manjunath Hadli <manjunath.hadli@ti.com>
> Cc: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
> Cc: Sakari Ailus <sakari.ailus@iki.fi>
> Cc: Hans Verkuil <hans.verkuil@cisco.com>
> ---
>  Documentation/DocBook/media/v4l/subdev-formats.xml |  171 +++++++++++++++++
>  include/linux/v4l2-mediabus.h                      |   10 +-
>  2 files changed, 179 insertions(+), 2 deletions(-)
> 
> diff --git a/Documentation/DocBook/media/v4l/subdev-formats.xml
> b/Documentation/DocBook/media/v4l/subdev-formats.xml index 49c532e..48d92bb
> 100644
> --- a/Documentation/DocBook/media/v4l/subdev-formats.xml
> +++ b/Documentation/DocBook/media/v4l/subdev-formats.xml
> @@ -356,6 +356,9 @@
>  	<listitem><para>If the pixel components are DPCM-compressed, a mention of
> the DPCM compression and the number of bits per compressed pixel
> component.</para> </listitem>
> +	<listitem><para>If the pixel components are ALAW-compressed, a mention of
> the
> +	ALAW compression and the number of bits per compressed pixel
> component.</para>
> +	</listitem>

I would group ALAW and DPCM compression, as they're mutally exclusive. 
Something like

    transferred on the same number of bits. Common values are 8, 10 and 12.
    </para>
    </listitem>
-   <listitem><para>If the pixel components are DPCM-compressed, a mention of
-   the DPCM compression and the number of bits per compressed pixel
-   component.</para>
-   </listitem>
+   <listitem><para>The compression (optional). If the pixel components are
+   ALAW- or DPCM-compressed, a mention of the compression scheme and the
+   number of bits per compressed pixel component.</para></listitem>
    <listitem><para>The number of bus samples per pixel. Pixels that are wider
    than the bus width must be transferred in multiple samples. Common values
    are 1 and 2.</para></listitem>


>  	<listitem><para>The number of bus samples per pixel. Pixels that are 
wider
> than the bus width must be transferred in multiple samples. Common values
> are 1 and 2.</para></listitem>
> @@ -572,6 +575,74 @@
>  	      <entry>r<subscript>1</subscript></entry>
>  	      <entry>r<subscript>0</subscript></entry>
>  	    </row>
> +	    <row id="V4L2-MBUS-FMT-SBGGR10-ALAW8-1X8">
> +	      <entry>V4L2_MBUS_FMT_SBGGR10_ALAW8_1X8</entry>
> +	      <entry>0x3015</entry>
> +	      <entry></entry>
> +	      <entry>-</entry>
> +	      <entry>-</entry>
> +	      <entry>-</entry>
> +	      <entry>-</entry>
> +	      <entry>b<subscript>7</subscript></entry>
> +	      <entry>b<subscript>6</subscript></entry>
> +	      <entry>b<subscript>5</subscript></entry>
> +	      <entry>b<subscript>4</subscript></entry>
> +	      <entry>b<subscript>3</subscript></entry>
> +	      <entry>b<subscript>2</subscript></entry>
> +	      <entry>b<subscript>1</subscript></entry>
> +	      <entry>b<subscript>0</subscript></entry>
> +	    </row>
> +	    <row id="V4L2-MBUS-FMT-SGBRG10-ALAW8-1X8">
> +	      <entry>V4L2_MBUS_FMT_SGBRG10_ALAW8_1X8</entry>
> +	      <entry>0x3016</entry>
> +	      <entry></entry>
> +	      <entry>-</entry>
> +	      <entry>-</entry>
> +	      <entry>-</entry>
> +	      <entry>-</entry>
> +	      <entry>g<subscript>7</subscript></entry>
> +	      <entry>g<subscript>6</subscript></entry>
> +	      <entry>g<subscript>5</subscript></entry>
> +	      <entry>g<subscript>4</subscript></entry>
> +	      <entry>g<subscript>3</subscript></entry>
> +	      <entry>g<subscript>2</subscript></entry>
> +	      <entry>g<subscript>1</subscript></entry>
> +	      <entry>g<subscript>0</subscript></entry>
> +	    </row>
> +	    <row id="V4L2-MBUS-FMT-SGRBG10-ALAW8-1X8">
> +	      <entry>V4L2_MBUS_FMT_SGRBG10_ALAW8_1X8</entry>
> +	      <entry>0x3017</entry>
> +	      <entry></entry>
> +	      <entry>-</entry>
> +	      <entry>-</entry>
> +	      <entry>-</entry>
> +	      <entry>-</entry>
> +	      <entry>g<subscript>7</subscript></entry>
> +	      <entry>g<subscript>6</subscript></entry>
> +	      <entry>g<subscript>5</subscript></entry>
> +	      <entry>g<subscript>4</subscript></entry>
> +	      <entry>g<subscript>3</subscript></entry>
> +	      <entry>g<subscript>2</subscript></entry>
> +	      <entry>g<subscript>1</subscript></entry>
> +	      <entry>g<subscript>0</subscript></entry>
> +	    </row>
> +	    <row id="V4L2-MBUS-FMT-SRGGB10-ALAW8-1X8">
> +	      <entry>V4L2_MBUS_FMT_SRGGB10_ALAW8_1X8</entry>
> +	      <entry>0x3018</entry>
> +	      <entry></entry>
> +	      <entry>-</entry>
> +	      <entry>-</entry>
> +	      <entry>-</entry>
> +	      <entry>-</entry>
> +	      <entry>r<subscript>7</subscript></entry>
> +	      <entry>r<subscript>6</subscript></entry>
> +	      <entry>r<subscript>5</subscript></entry>
> +	      <entry>r<subscript>4</subscript></entry>
> +	      <entry>r<subscript>3</subscript></entry>
> +	      <entry>r<subscript>2</subscript></entry>
> +	      <entry>r<subscript>1</subscript></entry>
> +	      <entry>r<subscript>0</subscript></entry>
> +	    </row>

Please move the ALAW formats above the DPCM formats to keep them 
alphabetically sorted.

>  	    <row id="V4L2-MBUS-FMT-SBGGR10-2X8-PADHI-BE">
>  	      <entry>V4L2_MBUS_FMT_SBGGR10_2X8_PADHI_BE</entry>
>  	      <entry>0x3003</entry>
> @@ -965,6 +1036,56 @@
>  	      <entry>y<subscript>1</subscript></entry>
>  	      <entry>y<subscript>0</subscript></entry>
>  	    </row>
> +	    <row id="V4L2-MBUS-FMT-UV8-1X8">

That's a weird one. Just out of curiosity, what's the point of transferring 
chroma information without luma ?

> +	      <entry>V4L2_MBUS_FMT_UV8_1X8</entry>
> +	      <entry>0x2015</entry>
> +	      <entry></entry>
> +	      <entry>-</entry>
> +	      <entry>-</entry>
> +	      <entry>-</entry>
> +	      <entry>-</entry>
> +	      <entry>-</entry>
> +	      <entry>-</entry>
> +	      <entry>-</entry>
> +	      <entry>-</entry>
> +	      <entry>-</entry>
> +	      <entry>-</entry>
> +	      <entry>-</entry>
> +	      <entry>-</entry>
> +	      <entry>u<subscript>7</subscript></entry>
> +	      <entry>u<subscript>6</subscript></entry>
> +	      <entry>u<subscript>5</subscript></entry>
> +	      <entry>u<subscript>4</subscript></entry>
> +	      <entry>u<subscript>3</subscript></entry>
> +	      <entry>u<subscript>2</subscript></entry>
> +	      <entry>u<subscript>1</subscript></entry>
> +	      <entry>u<subscript>0</subscript></entry>
> +	    </row>
> +	    <row>
> +	      <entry></entry>
> +	      <entry></entry>
> +	      <entry></entry>
> +	      <entry>-</entry>
> +	      <entry>-</entry>
> +	      <entry>-</entry>
> +	      <entry>-</entry>
> +	      <entry>-</entry>
> +	      <entry>-</entry>
> +	      <entry>-</entry>
> +	      <entry>-</entry>
> +	      <entry>-</entry>
> +	      <entry>-</entry>
> +	      <entry>-</entry>
> +	      <entry>-</entry>
> +	      <entry>v<subscript>7</subscript></entry>
> +	      <entry>v<subscript>6</subscript></entry>
> +	      <entry>v<subscript>5</subscript></entry>
> +	      <entry>v<subscript>4</subscript></entry>
> +	      <entry>v<subscript>3</subscript></entry>
> +	      <entry>v<subscript>2</subscript></entry>
> +	      <entry>v<subscript>1</subscript></entry>
> +	      <entry>v<subscript>0</subscript></entry>
> +	    </row>
>  	    <row id="V4L2-MBUS-FMT-UYVY8-1_5X8">
>  	      <entry>V4L2_MBUS_FMT_UYVY8_1_5X8</entry>
>  	      <entry>0x2002</entry>
> @@ -2415,6 +2536,56 @@
>  	      <entry>u<subscript>1</subscript></entry>
>  	      <entry>u<subscript>0</subscript></entry>
>  	    </row>
> +	    <row id="V4L2-MBUS-FMT-YDYC8-1X16">

What is this beast ? We at least need a textual description, as I have no idea 
what the format corresponds to.

> +	      <entry>V4L2_MBUS_FMT_YDYC8_1X16</entry>
> +	      <entry>0x2014</entry>
> +	      <entry></entry>
> +	      <entry>-</entry>
> +	      <entry>-</entry>
> +	      <entry>-</entry>
> +	      <entry>-</entry>
> +	      <entry>y<subscript>7</subscript></entry>
> +	      <entry>y<subscript>6</subscript></entry>
> +	      <entry>y<subscript>5</subscript></entry>
> +	      <entry>y<subscript>4</subscript></entry>
> +	      <entry>y<subscript>3</subscript></entry>
> +	      <entry>y<subscript>2</subscript></entry>
> +	      <entry>y<subscript>1</subscript></entry>
> +	      <entry>y<subscript>0</subscript></entry>
> +	      <entry>d<subscript>7</subscript></entry>
> +	      <entry>d<subscript>6</subscript></entry>
> +	      <entry>d<subscript>5</subscript></entry>
> +	      <entry>d<subscript>4</subscript></entry>
> +	      <entry>d<subscript>3</subscript></entry>
> +	      <entry>d<subscript>2</subscript></entry>
> +	      <entry>d<subscript>1</subscript></entry>
> +	      <entry>d<subscript>0</subscript></entry>
> +	    </row>
> +	    <row>
> +	      <entry></entry>
> +	      <entry></entry>
> +	      <entry></entry>
> +	      <entry>-</entry>
> +	      <entry>-</entry>
> +	      <entry>-</entry>
> +	      <entry>-</entry>
> +	      <entry>y<subscript>7</subscript></entry>
> +	      <entry>y<subscript>6</subscript></entry>
> +	      <entry>y<subscript>5</subscript></entry>
> +	      <entry>y<subscript>4</subscript></entry>
> +	      <entry>y<subscript>3</subscript></entry>
> +	      <entry>y<subscript>2</subscript></entry>
> +	      <entry>y<subscript>1</subscript></entry>
> +	      <entry>y<subscript>0</subscript></entry>
> +	      <entry>c<subscript>7</subscript></entry>
> +	      <entry>c<subscript>6</subscript></entry>
> +	      <entry>c<subscript>5</subscript></entry>
> +	      <entry>c<subscript>4</subscript></entry>
> +	      <entry>c<subscript>3</subscript></entry>
> +	      <entry>c<subscript>2</subscript></entry>
> +	      <entry>c<subscript>1</subscript></entry>
> +	      <entry>c<subscript>0</subscript></entry>
> +	    </row>
>  	    <row id="V4L2-MBUS-FMT-YUYV10-1X20">
>  	      <entry>V4L2_MBUS_FMT_YUYV10_1X20</entry>
>  	      <entry>0x200d</entry>
> diff --git a/include/linux/v4l2-mediabus.h b/include/linux/v4l2-mediabus.h
> index 5ea7f75..8d68fa1 100644
> --- a/include/linux/v4l2-mediabus.h
> +++ b/include/linux/v4l2-mediabus.h
> @@ -47,8 +47,9 @@ enum v4l2_mbus_pixelcode {
>  	V4L2_MBUS_FMT_RGB565_2X8_BE = 0x1007,
>  	V4L2_MBUS_FMT_RGB565_2X8_LE = 0x1008,
> 
> -	/* YUV (including grey) - next is 0x2014 */
> +	/* YUV (including grey) - next is 0x2016 */
>  	V4L2_MBUS_FMT_Y8_1X8 = 0x2001,
> +	V4L2_MBUS_FMT_UV8_1X8 = 0x2015,
>  	V4L2_MBUS_FMT_UYVY8_1_5X8 = 0x2002,
>  	V4L2_MBUS_FMT_VYUY8_1_5X8 = 0x2003,
>  	V4L2_MBUS_FMT_YUYV8_1_5X8 = 0x2004,
> @@ -65,10 +66,11 @@ enum v4l2_mbus_pixelcode {
>  	V4L2_MBUS_FMT_VYUY8_1X16 = 0x2010,
>  	V4L2_MBUS_FMT_YUYV8_1X16 = 0x2011,
>  	V4L2_MBUS_FMT_YVYU8_1X16 = 0x2012,
> +	V4L2_MBUS_FMT_YDYC8_1X16 = 0x2014,
>  	V4L2_MBUS_FMT_YUYV10_1X20 = 0x200d,
>  	V4L2_MBUS_FMT_YVYU10_1X20 = 0x200e,
> 
> -	/* Bayer - next is 0x3015 */
> +	/* Bayer - next is 0x3019 */
>  	V4L2_MBUS_FMT_SBGGR8_1X8 = 0x3001,
>  	V4L2_MBUS_FMT_SGBRG8_1X8 = 0x3013,
>  	V4L2_MBUS_FMT_SGRBG8_1X8 = 0x3002,
> @@ -77,6 +79,10 @@ enum v4l2_mbus_pixelcode {
>  	V4L2_MBUS_FMT_SGBRG10_DPCM8_1X8 = 0x300c,
>  	V4L2_MBUS_FMT_SGRBG10_DPCM8_1X8 = 0x3009,
>  	V4L2_MBUS_FMT_SRGGB10_DPCM8_1X8 = 0x300d,
> +	V4L2_MBUS_FMT_SBGGR10_ALAW8_1X8 = 0x3015,
> +	V4L2_MBUS_FMT_SGBRG10_ALAW8_1X8 = 0x3016,
> +	V4L2_MBUS_FMT_SGRBG10_ALAW8_1X8 = 0x3017,
> +	V4L2_MBUS_FMT_SRGGB10_ALAW8_1X8 = 0x3018,

Please move the ALAW formats above the DPCM formats to keep them 
alphabetically sorted.

>  	V4L2_MBUS_FMT_SBGGR10_2X8_PADHI_BE = 0x3003,
>  	V4L2_MBUS_FMT_SBGGR10_2X8_PADHI_LE = 0x3004,
>  	V4L2_MBUS_FMT_SBGGR10_2X8_PADLO_BE = 0x3005,
-- 
Regards,

Laurent Pinchart


^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [PATCH v4 2/2] v4l2: add new pixel formats supported on dm365
       [not found] ` <1333102154-24657-3-git-send-email-manjunath.hadli@ti.com>
@ 2012-07-17 10:59   ` Laurent Pinchart
  2012-07-17 11:43     ` Hadli, Manjunath
  0 siblings, 1 reply; 12+ messages in thread
From: Laurent Pinchart @ 2012-07-17 10:59 UTC (permalink / raw)
  To: Hadli, Manjunath; +Cc: dlos, LMML, Sakari Ailus, Hans Verkuil

Hi Manjunath,

Thank you for the patch.

A couple of comments below.

On Friday 30 March 2012 10:09:14 Hadli, Manjunath wrote:
> add new macro V4L2_PIX_FMT_SGRBG10ALAW8 and associated formats
> to represent Bayer format frames compressed by A-LAW algorithm,
> add V4L2_PIX_FMT_UV8 to represent storage of CbCr data (UV interleaved)
> only.
> 
> Signed-off-by: Manjunath Hadli <manjunath.hadli@ti.com>
> Cc: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
> Cc: Sakari Ailus <sakari.ailus@iki.fi>
> Cc: Hans Verkuil <hans.verkuil@cisco.com>
> ---
>  .../DocBook/media/v4l/pixfmt-srggb10alaw8.xml      |   34 +++++++++++
>  Documentation/DocBook/media/v4l/pixfmt-uv8.xml     |   62
> ++++++++++++++++++++ Documentation/DocBook/media/v4l/pixfmt.xml         |  
>  2 +
>  include/linux/videodev2.h                          |    8 +++
>  4 files changed, 106 insertions(+), 0 deletions(-)
>  create mode 100644 Documentation/DocBook/media/v4l/pixfmt-srggb10alaw8.xml
>  create mode 100644 Documentation/DocBook/media/v4l/pixfmt-uv8.xml
> 
> diff --git a/Documentation/DocBook/media/v4l/pixfmt-srggb10alaw8.xml
> b/Documentation/DocBook/media/v4l/pixfmt-srggb10alaw8.xml new file mode
> 100644
> index 0000000..9b5c80d
> --- /dev/null
> +++ b/Documentation/DocBook/media/v4l/pixfmt-srggb10alaw8.xml
> @@ -0,0 +1,34 @@
> +	<refentry>
> +	  <refmeta>
> +	    <refentrytitle>
> +	      V4L2_PIX_FMT_SRGGB10ALAW8 ('aRA8'),
> +	      V4L2_PIX_FMT_SGRBG10ALAW8 ('agA8'),
> +	      V4L2_PIX_FMT_SGBRG10ALAW8 ('aGA8'),
> +	      V4L2_PIX_FMT_SBGGR10ALAW8 ('aBA8'),
> +	    </refentrytitle>
> +	    &manvol;
> +	  </refmeta>
> +	  <refnamediv>
> +	    <refname id="V4L2-PIX-FMT-SRGGB10ALAW8">
> +	      <constant>V4L2_PIX_FMT_SRGGB10ALAW8</constant>
> +	    </refname>
> +	    <refname id="V4L2-PIX-FMT-SGRBG10ALAW8">
> +	      <constant>V4L2_PIX_FMT_SGRBG10ALAW8</constant>
> +	    </refname>
> +	    <refname id="V4L2-PIX-FMT-SGBRG10ALAW8">
> +	      <constant>V4L2_PIX_FMT_SGBRG10ALAW8</constant>
> +	    </refname>
> +	    <refname id="V4L2-PIX-FMT-SBGGR10ALAW8">
> +	      <constant>V4L2_PIX_FMT_SBGGR10ALAW8</constant>
> +	    </refname>
> +	    <refpurpose>10-bit Bayer formats compressed to 8 bits</refpurpose>
> +	  </refnamediv>
> +	  <refsect1>
> +	    <title>Description</title>
> +	    <para>The following four pixel formats are raw sRGB / Bayer
> +	    formats with 10 bits per colour compressed to 8 bits each,
> +	    using the A-LAW algorithm. Each colour component consumes 8
> +	    bits of memory. In other respects this format is similar to
> +	    <xref linkend="V4L2-PIX-FMT-SRGGB8">.</xref></para>
> +	  </refsect1>
> +	</refentry>
> diff --git a/Documentation/DocBook/media/v4l/pixfmt-uv8.xml
> b/Documentation/DocBook/media/v4l/pixfmt-uv8.xml new file mode 100644
> index 0000000..c507c1f
> --- /dev/null
> +++ b/Documentation/DocBook/media/v4l/pixfmt-uv8.xml
> @@ -0,0 +1,62 @@
> +	<refentry id="V4L2-PIX-FMT-UV8">
> +	  <refmeta>
> +	    <refentrytitle>V4L2_PIX_FMT_UV8  ('UV8')</refentrytitle>
> +	    &manvol;
> +	  </refmeta>
> +	  <refnamediv>
> +	    <refname><constant>V4L2_PIX_FMT_UV8</constant></refname>
> +	    <refpurpose>UV plane interleaved</refpurpose>
> +	  </refnamediv>
> +	  <refsect1>
> +	    <title>Description</title>
> +	    <para>In this format there is no Y plane, Only CbCr plane. ie
> +	    (UV interleaved)</para>
> +	    <example>
> +	    <title>
> +	      <constant>V4L2_PIX_FMT_UV8</constant>
> +	       pixel image
> +	    </title>
> +
> +	    <formalpara>
> +	      <title>Byte Order.</title>
> +	      <para>Each cell is one byte.
> +	        <informaltable frame="none">
> +	        <tgroup cols="5" align="center">
> +		  <colspec align="left" colwidth="2*" />
> +		  <tbody valign="top">
> +		    <row>
> +		      <entry>start&nbsp;+&nbsp;0:</entry>
> +		      <entry>Cb<subscript>00</subscript></entry>
> +		      <entry>Cr<subscript>00</subscript></entry>
> +		      <entry>Cb<subscript>01</subscript></entry>
> +		      <entry>Cr<subscript>01</subscript></entry>
> +		    </row>
> +		    <row>
> +		      <entry>start&nbsp;+&nbsp;4:</entry>
> +		      <entry>Cb<subscript>10</subscript></entry>
> +		      <entry>Cr<subscript>10</subscript></entry>
> +		      <entry>Cb<subscript>11</subscript></entry>
> +		      <entry>Cr<subscript>11</subscript></entry>
> +		    </row>
> +		    <row>
> +		      <entry>start&nbsp;+&nbsp;8:</entry>
> +		      <entry>Cb<subscript>20</subscript></entry>
> +		      <entry>Cr<subscript>20</subscript></entry>
> +		      <entry>Cb<subscript>21</subscript></entry>
> +		      <entry>Cr<subscript>21</subscript></entry>
> +		    </row>
> +		    <row>
> +		      <entry>start&nbsp;+&nbsp;12:</entry>
> +		      <entry>Cb<subscript>30</subscript></entry>
> +		      <entry>Cr<subscript>30</subscript></entry>
> +		      <entry>Cb<subscript>31</subscript></entry>
> +		      <entry>Cr<subscript>31</subscript></entry>
> +		    </row>
> +		  </tbody>
> +		</tgroup>
> +		</informaltable>
> +	      </para>
> +	      </formalpara>
> +	    </example>
> +	  </refsect1>
> +	</refentry>
> diff --git a/Documentation/DocBook/media/v4l/pixfmt.xml
> b/Documentation/DocBook/media/v4l/pixfmt.xml index 74d4fcd..9dc3024 100644
> --- a/Documentation/DocBook/media/v4l/pixfmt.xml
> +++ b/Documentation/DocBook/media/v4l/pixfmt.xml
> @@ -674,6 +674,7 @@ access the palette, this must be done with ioctls of the
> Linux framebuffer API.< &sub-sbggr16;
>      &sub-srggb10;
>      &sub-srggb10dpcm8;
> +    &sub-srggb10alaw8;

Please move the ALAW formats above the DPCM formats to keep them 
alphabetically sorted.

>      &sub-srggb12;
>    </section>
> 
> @@ -701,6 +702,7 @@ information.</para>
>      &sub-y12;
>      &sub-y10b;
>      &sub-y16;
> +    &sub-uv8;
>      &sub-yuyv;
>      &sub-uyvy;
>      &sub-yvyu;
> diff --git a/include/linux/videodev2.h b/include/linux/videodev2.h
> index dbc0d77..71f9f94 100644
> --- a/include/linux/videodev2.h
> +++ b/include/linux/videodev2.h
> @@ -328,6 +328,9 @@ struct v4l2_pix_format {
>  /* Palette formats */
>  #define V4L2_PIX_FMT_PAL8    v4l2_fourcc('P', 'A', 'L', '8') /*  8  8-bit
> palette */
> 
> +/* Chrominance formats */
> +#define V4L2_PIX_FMT_UV8      v4l2_fourcc('U', 'V', '8', ' ') /*  8  UV 4:4
> */ +
>  /* Luminance+Chrominance formats */
>  #define V4L2_PIX_FMT_YVU410  v4l2_fourcc('Y', 'V', 'U', '9') /*  9  YVU
> 4:1:0     */ #define V4L2_PIX_FMT_YVU420  v4l2_fourcc('Y', 'V', '1', '2')
> /* 12  YVU 4:2:0     */ @@ -382,6 +385,11 @@ struct v4l2_pix_format {
>  #define V4L2_PIX_FMT_SGBRG10DPCM8 v4l2_fourcc('b', 'G', 'A', '8')
>  #define V4L2_PIX_FMT_SGRBG10DPCM8 v4l2_fourcc('B', 'D', '1', '0')
>  #define V4L2_PIX_FMT_SRGGB10DPCM8 v4l2_fourcc('b', 'R', 'A', '8')
> +	/* 10bit raw bayer a-law compressed to 8 bits */
> +#define V4L2_PIX_FMT_SBGGR10ALAW8 v4l2_fourcc('a', 'B', 'A', '8')
> +#define V4L2_PIX_FMT_SGBRG10ALAW8 v4l2_fourcc('a', 'G', 'A', '8')
> +#define V4L2_PIX_FMT_SGRBG10ALAW8 v4l2_fourcc('a', 'g', 'A', '8')
> +#define V4L2_PIX_FMT_SRGGB10ALAW8 v4l2_fourcc('a', 'R', 'A', '8')

Please move the ALAW formats above the DPCM formats to keep them 
alphabetically sorted.

We still have no clear fourcc allocation scheme for Bayer formats, but I 
suppose I'll need to give up on that.

>  	/*
>  	 * 10bit raw bayer, expanded to 16 bits
>  	 * xxxxrrrrrrrrrrxxxxgggggggggg xxxxggggggggggxxxxbbbbbbbbbb...
-- 
Regards,

Laurent Pinchart


^ permalink raw reply	[flat|nested] 12+ messages in thread

* RE: [PATCH v4 1/2] media: add new mediabus format enums for dm365
  2012-07-17 10:56   ` [PATCH v4 1/2] media: add new mediabus format enums for dm365 Laurent Pinchart
@ 2012-07-17 11:41     ` Hadli, Manjunath
  2012-07-17 11:55       ` Laurent Pinchart
  0 siblings, 1 reply; 12+ messages in thread
From: Hadli, Manjunath @ 2012-07-17 11:41 UTC (permalink / raw)
  To: Laurent Pinchart; +Cc: dlos, LMML, Sakari Ailus, Hans Verkuil

Hi Laurent,

Thanks for the review.

On Tue, Jul 17, 2012 at 16:26:24, Laurent Pinchart wrote:
> Hi Manjunath,
> 
> Thank you for the patch.
> 
> Just some nitpicking, please see below.
> 
> On Friday 30 March 2012 10:09:13 Hadli, Manjunath wrote:
> > add new enum entries for supporting the media-bus formats on dm365.
> > These include some bayer and some non-bayer formats.
> > V4L2_MBUS_FMT_YDYC8_1X16 and V4L2_MBUS_FMT_UV8_1X8 are used
> > internal to the hardware by the resizer.
> > V4L2_MBUS_FMT_SBGGR10_ALAW8_1X8 represents the bayer ALAW format
> > that is supported by dm365 hardware.
> > 
> > Signed-off-by: Manjunath Hadli <manjunath.hadli@ti.com>
> > Cc: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
> > Cc: Sakari Ailus <sakari.ailus@iki.fi>
> > Cc: Hans Verkuil <hans.verkuil@cisco.com>
> > ---
> >  Documentation/DocBook/media/v4l/subdev-formats.xml |  171 +++++++++++++++++
> >  include/linux/v4l2-mediabus.h                      |   10 +-
> >  2 files changed, 179 insertions(+), 2 deletions(-)
> > 
> > diff --git a/Documentation/DocBook/media/v4l/subdev-formats.xml
> > b/Documentation/DocBook/media/v4l/subdev-formats.xml index 49c532e..48d92bb
> > 100644
> > --- a/Documentation/DocBook/media/v4l/subdev-formats.xml
> > +++ b/Documentation/DocBook/media/v4l/subdev-formats.xml
> > @@ -356,6 +356,9 @@
> >  	<listitem><para>If the pixel components are DPCM-compressed, a mention of
> > the DPCM compression and the number of bits per compressed pixel
> > component.</para> </listitem>
> > +	<listitem><para>If the pixel components are ALAW-compressed, a mention of
> > the
> > +	ALAW compression and the number of bits per compressed pixel
> > component.</para>
> > +	</listitem>
> 
> I would group ALAW and DPCM compression, as they're mutally exclusive. 
> Something like
> 
>     transferred on the same number of bits. Common values are 8, 10 and 12.
>     </para>
>     </listitem>
> -   <listitem><para>If the pixel components are DPCM-compressed, a mention of
> -   the DPCM compression and the number of bits per compressed pixel
> -   component.</para>
> -   </listitem>
> +   <listitem><para>The compression (optional). If the pixel components are
> +   ALAW- or DPCM-compressed, a mention of the compression scheme and the
> +   number of bits per compressed pixel component.</para></listitem>
>     <listitem><para>The number of bus samples per pixel. Pixels that are wider
>     than the bus width must be transferred in multiple samples. Common values
>     are 1 and 2.</para></listitem>
> 
     Ok.
> 
> >  	<listitem><para>The number of bus samples per pixel. Pixels that are 
> wider
> > than the bus width must be transferred in multiple samples. Common values
> > are 1 and 2.</para></listitem>
> > @@ -572,6 +575,74 @@
> >  	      <entry>r<subscript>1</subscript></entry>
> >  	      <entry>r<subscript>0</subscript></entry>
> >  	    </row>
> > +	    <row id="V4L2-MBUS-FMT-SBGGR10-ALAW8-1X8">
> > +	      <entry>V4L2_MBUS_FMT_SBGGR10_ALAW8_1X8</entry>
> > +	      <entry>0x3015</entry>
> > +	      <entry></entry>
> > +	      <entry>-</entry>
> > +	      <entry>-</entry>
> > +	      <entry>-</entry>
> > +	      <entry>-</entry>
> > +	      <entry>b<subscript>7</subscript></entry>
> > +	      <entry>b<subscript>6</subscript></entry>
> > +	      <entry>b<subscript>5</subscript></entry>
> > +	      <entry>b<subscript>4</subscript></entry>
> > +	      <entry>b<subscript>3</subscript></entry>
> > +	      <entry>b<subscript>2</subscript></entry>
> > +	      <entry>b<subscript>1</subscript></entry>
> > +	      <entry>b<subscript>0</subscript></entry>
> > +	    </row>
> > +	    <row id="V4L2-MBUS-FMT-SGBRG10-ALAW8-1X8">
> > +	      <entry>V4L2_MBUS_FMT_SGBRG10_ALAW8_1X8</entry>
> > +	      <entry>0x3016</entry>
> > +	      <entry></entry>
> > +	      <entry>-</entry>
> > +	      <entry>-</entry>
> > +	      <entry>-</entry>
> > +	      <entry>-</entry>
> > +	      <entry>g<subscript>7</subscript></entry>
> > +	      <entry>g<subscript>6</subscript></entry>
> > +	      <entry>g<subscript>5</subscript></entry>
> > +	      <entry>g<subscript>4</subscript></entry>
> > +	      <entry>g<subscript>3</subscript></entry>
> > +	      <entry>g<subscript>2</subscript></entry>
> > +	      <entry>g<subscript>1</subscript></entry>
> > +	      <entry>g<subscript>0</subscript></entry>
> > +	    </row>
> > +	    <row id="V4L2-MBUS-FMT-SGRBG10-ALAW8-1X8">
> > +	      <entry>V4L2_MBUS_FMT_SGRBG10_ALAW8_1X8</entry>
> > +	      <entry>0x3017</entry>
> > +	      <entry></entry>
> > +	      <entry>-</entry>
> > +	      <entry>-</entry>
> > +	      <entry>-</entry>
> > +	      <entry>-</entry>
> > +	      <entry>g<subscript>7</subscript></entry>
> > +	      <entry>g<subscript>6</subscript></entry>
> > +	      <entry>g<subscript>5</subscript></entry>
> > +	      <entry>g<subscript>4</subscript></entry>
> > +	      <entry>g<subscript>3</subscript></entry>
> > +	      <entry>g<subscript>2</subscript></entry>
> > +	      <entry>g<subscript>1</subscript></entry>
> > +	      <entry>g<subscript>0</subscript></entry>
> > +	    </row>
> > +	    <row id="V4L2-MBUS-FMT-SRGGB10-ALAW8-1X8">
> > +	      <entry>V4L2_MBUS_FMT_SRGGB10_ALAW8_1X8</entry>
> > +	      <entry>0x3018</entry>
> > +	      <entry></entry>
> > +	      <entry>-</entry>
> > +	      <entry>-</entry>
> > +	      <entry>-</entry>
> > +	      <entry>-</entry>
> > +	      <entry>r<subscript>7</subscript></entry>
> > +	      <entry>r<subscript>6</subscript></entry>
> > +	      <entry>r<subscript>5</subscript></entry>
> > +	      <entry>r<subscript>4</subscript></entry>
> > +	      <entry>r<subscript>3</subscript></entry>
> > +	      <entry>r<subscript>2</subscript></entry>
> > +	      <entry>r<subscript>1</subscript></entry>
> > +	      <entry>r<subscript>0</subscript></entry>
> > +	    </row>
> 
> Please move the ALAW formats above the DPCM formats to keep them 
> alphabetically sorted.
> 
  Ok.

> >  	    <row id="V4L2-MBUS-FMT-SBGGR10-2X8-PADHI-BE">
> >  	      <entry>V4L2_MBUS_FMT_SBGGR10_2X8_PADHI_BE</entry>
> >  	      <entry>0x3003</entry>
> > @@ -965,6 +1036,56 @@
> >  	      <entry>y<subscript>1</subscript></entry>
> >  	      <entry>y<subscript>0</subscript></entry>
> >  	    </row>
> > +	    <row id="V4L2-MBUS-FMT-UV8-1X8">
> 
> That's a weird one. Just out of curiosity, what's the point of transferring 
> chroma information without luma ?
> 
  DM365 supports this format.

> > +	      <entry>V4L2_MBUS_FMT_UV8_1X8</entry>
> > +	      <entry>0x2015</entry>
> > +	      <entry></entry>
> > +	      <entry>-</entry>
> > +	      <entry>-</entry>
> > +	      <entry>-</entry>
> > +	      <entry>-</entry>
> > +	      <entry>-</entry>
> > +	      <entry>-</entry>
> > +	      <entry>-</entry>
> > +	      <entry>-</entry>
> > +	      <entry>-</entry>
> > +	      <entry>-</entry>
> > +	      <entry>-</entry>
> > +	      <entry>-</entry>
> > +	      <entry>u<subscript>7</subscript></entry>
> > +	      <entry>u<subscript>6</subscript></entry>
> > +	      <entry>u<subscript>5</subscript></entry>
> > +	      <entry>u<subscript>4</subscript></entry>
> > +	      <entry>u<subscript>3</subscript></entry>
> > +	      <entry>u<subscript>2</subscript></entry>
> > +	      <entry>u<subscript>1</subscript></entry>
> > +	      <entry>u<subscript>0</subscript></entry>
> > +	    </row>
> > +	    <row>
> > +	      <entry></entry>
> > +	      <entry></entry>
> > +	      <entry></entry>
> > +	      <entry>-</entry>
> > +	      <entry>-</entry>
> > +	      <entry>-</entry>
> > +	      <entry>-</entry>
> > +	      <entry>-</entry>
> > +	      <entry>-</entry>
> > +	      <entry>-</entry>
> > +	      <entry>-</entry>
> > +	      <entry>-</entry>
> > +	      <entry>-</entry>
> > +	      <entry>-</entry>
> > +	      <entry>-</entry>
> > +	      <entry>v<subscript>7</subscript></entry>
> > +	      <entry>v<subscript>6</subscript></entry>
> > +	      <entry>v<subscript>5</subscript></entry>
> > +	      <entry>v<subscript>4</subscript></entry>
> > +	      <entry>v<subscript>3</subscript></entry>
> > +	      <entry>v<subscript>2</subscript></entry>
> > +	      <entry>v<subscript>1</subscript></entry>
> > +	      <entry>v<subscript>0</subscript></entry>
> > +	    </row>
> >  	    <row id="V4L2-MBUS-FMT-UYVY8-1_5X8">
> >  	      <entry>V4L2_MBUS_FMT_UYVY8_1_5X8</entry>
> >  	      <entry>0x2002</entry>
> > @@ -2415,6 +2536,56 @@
> >  	      <entry>u<subscript>1</subscript></entry>
> >  	      <entry>u<subscript>0</subscript></entry>
> >  	    </row>
> > +	    <row id="V4L2-MBUS-FMT-YDYC8-1X16">
> 
> What is this beast ? We at least need a textual description, as I have no idea 
> what the format corresponds to.
> 
  This was discussed earlier over here http://patchwork.linuxtv.org/patch/8843/ 

> > +	      <entry>V4L2_MBUS_FMT_YDYC8_1X16</entry>
> > +	      <entry>0x2014</entry>
> > +	      <entry></entry>
> > +	      <entry>-</entry>
> > +	      <entry>-</entry>
> > +	      <entry>-</entry>
> > +	      <entry>-</entry>
> > +	      <entry>y<subscript>7</subscript></entry>
> > +	      <entry>y<subscript>6</subscript></entry>
> > +	      <entry>y<subscript>5</subscript></entry>
> > +	      <entry>y<subscript>4</subscript></entry>
> > +	      <entry>y<subscript>3</subscript></entry>
> > +	      <entry>y<subscript>2</subscript></entry>
> > +	      <entry>y<subscript>1</subscript></entry>
> > +	      <entry>y<subscript>0</subscript></entry>
> > +	      <entry>d<subscript>7</subscript></entry>
> > +	      <entry>d<subscript>6</subscript></entry>
> > +	      <entry>d<subscript>5</subscript></entry>
> > +	      <entry>d<subscript>4</subscript></entry>
> > +	      <entry>d<subscript>3</subscript></entry>
> > +	      <entry>d<subscript>2</subscript></entry>
> > +	      <entry>d<subscript>1</subscript></entry>
> > +	      <entry>d<subscript>0</subscript></entry>
> > +	    </row>
> > +	    <row>
> > +	      <entry></entry>
> > +	      <entry></entry>
> > +	      <entry></entry>
> > +	      <entry>-</entry>
> > +	      <entry>-</entry>
> > +	      <entry>-</entry>
> > +	      <entry>-</entry>
> > +	      <entry>y<subscript>7</subscript></entry>
> > +	      <entry>y<subscript>6</subscript></entry>
> > +	      <entry>y<subscript>5</subscript></entry>
> > +	      <entry>y<subscript>4</subscript></entry>
> > +	      <entry>y<subscript>3</subscript></entry>
> > +	      <entry>y<subscript>2</subscript></entry>
> > +	      <entry>y<subscript>1</subscript></entry>
> > +	      <entry>y<subscript>0</subscript></entry>
> > +	      <entry>c<subscript>7</subscript></entry>
> > +	      <entry>c<subscript>6</subscript></entry>
> > +	      <entry>c<subscript>5</subscript></entry>
> > +	      <entry>c<subscript>4</subscript></entry>
> > +	      <entry>c<subscript>3</subscript></entry>
> > +	      <entry>c<subscript>2</subscript></entry>
> > +	      <entry>c<subscript>1</subscript></entry>
> > +	      <entry>c<subscript>0</subscript></entry>
> > +	    </row>
> >  	    <row id="V4L2-MBUS-FMT-YUYV10-1X20">
> >  	      <entry>V4L2_MBUS_FMT_YUYV10_1X20</entry>
> >  	      <entry>0x200d</entry>
> > diff --git a/include/linux/v4l2-mediabus.h b/include/linux/v4l2-mediabus.h
> > index 5ea7f75..8d68fa1 100644
> > --- a/include/linux/v4l2-mediabus.h
> > +++ b/include/linux/v4l2-mediabus.h
> > @@ -47,8 +47,9 @@ enum v4l2_mbus_pixelcode {
> >  	V4L2_MBUS_FMT_RGB565_2X8_BE = 0x1007,
> >  	V4L2_MBUS_FMT_RGB565_2X8_LE = 0x1008,
> > 
> > -	/* YUV (including grey) - next is 0x2014 */
> > +	/* YUV (including grey) - next is 0x2016 */
> >  	V4L2_MBUS_FMT_Y8_1X8 = 0x2001,
> > +	V4L2_MBUS_FMT_UV8_1X8 = 0x2015,
> >  	V4L2_MBUS_FMT_UYVY8_1_5X8 = 0x2002,
> >  	V4L2_MBUS_FMT_VYUY8_1_5X8 = 0x2003,
> >  	V4L2_MBUS_FMT_YUYV8_1_5X8 = 0x2004,
> > @@ -65,10 +66,11 @@ enum v4l2_mbus_pixelcode {
> >  	V4L2_MBUS_FMT_VYUY8_1X16 = 0x2010,
> >  	V4L2_MBUS_FMT_YUYV8_1X16 = 0x2011,
> >  	V4L2_MBUS_FMT_YVYU8_1X16 = 0x2012,
> > +	V4L2_MBUS_FMT_YDYC8_1X16 = 0x2014,
> >  	V4L2_MBUS_FMT_YUYV10_1X20 = 0x200d,
> >  	V4L2_MBUS_FMT_YVYU10_1X20 = 0x200e,
> > 
> > -	/* Bayer - next is 0x3015 */
> > +	/* Bayer - next is 0x3019 */
> >  	V4L2_MBUS_FMT_SBGGR8_1X8 = 0x3001,
> >  	V4L2_MBUS_FMT_SGBRG8_1X8 = 0x3013,
> >  	V4L2_MBUS_FMT_SGRBG8_1X8 = 0x3002,
> > @@ -77,6 +79,10 @@ enum v4l2_mbus_pixelcode {
> >  	V4L2_MBUS_FMT_SGBRG10_DPCM8_1X8 = 0x300c,
> >  	V4L2_MBUS_FMT_SGRBG10_DPCM8_1X8 = 0x3009,
> >  	V4L2_MBUS_FMT_SRGGB10_DPCM8_1X8 = 0x300d,
> > +	V4L2_MBUS_FMT_SBGGR10_ALAW8_1X8 = 0x3015,
> > +	V4L2_MBUS_FMT_SGBRG10_ALAW8_1X8 = 0x3016,
> > +	V4L2_MBUS_FMT_SGRBG10_ALAW8_1X8 = 0x3017,
> > +	V4L2_MBUS_FMT_SRGGB10_ALAW8_1X8 = 0x3018,
> 
> Please move the ALAW formats above the DPCM formats to keep them 
> alphabetically sorted.
> 
  Ok.

Thx,
--Manju

> >  	V4L2_MBUS_FMT_SBGGR10_2X8_PADHI_BE = 0x3003,
> >  	V4L2_MBUS_FMT_SBGGR10_2X8_PADHI_LE = 0x3004,
> >  	V4L2_MBUS_FMT_SBGGR10_2X8_PADLO_BE = 0x3005,
> -- 
> Regards,
> 
> Laurent Pinchart
> 
> 


^ permalink raw reply	[flat|nested] 12+ messages in thread

* RE: [PATCH v4 2/2] v4l2: add new pixel formats supported on dm365
  2012-07-17 10:59   ` [PATCH v4 2/2] v4l2: add new pixel formats supported on dm365 Laurent Pinchart
@ 2012-07-17 11:43     ` Hadli, Manjunath
  0 siblings, 0 replies; 12+ messages in thread
From: Hadli, Manjunath @ 2012-07-17 11:43 UTC (permalink / raw)
  To: Laurent Pinchart; +Cc: dlos, LMML, Sakari Ailus, Hans Verkuil

Hi Laurent,

On Tue, Jul 17, 2012 at 16:29:44, Laurent Pinchart wrote:
> Hi Manjunath,
> 
> Thank you for the patch.
> 
> A couple of comments below.
> 
> On Friday 30 March 2012 10:09:14 Hadli, Manjunath wrote:
> > add new macro V4L2_PIX_FMT_SGRBG10ALAW8 and associated formats
> > to represent Bayer format frames compressed by A-LAW algorithm,
> > add V4L2_PIX_FMT_UV8 to represent storage of CbCr data (UV interleaved)
> > only.
> > 
> > Signed-off-by: Manjunath Hadli <manjunath.hadli@ti.com>
> > Cc: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
> > Cc: Sakari Ailus <sakari.ailus@iki.fi>
> > Cc: Hans Verkuil <hans.verkuil@cisco.com>
> > ---
> >  .../DocBook/media/v4l/pixfmt-srggb10alaw8.xml      |   34 +++++++++++
> >  Documentation/DocBook/media/v4l/pixfmt-uv8.xml     |   62
> > ++++++++++++++++++++ Documentation/DocBook/media/v4l/pixfmt.xml         |  
> >  2 +
> >  include/linux/videodev2.h                          |    8 +++
> >  4 files changed, 106 insertions(+), 0 deletions(-)
> >  create mode 100644 Documentation/DocBook/media/v4l/pixfmt-srggb10alaw8.xml
> >  create mode 100644 Documentation/DocBook/media/v4l/pixfmt-uv8.xml
> > 
> > diff --git a/Documentation/DocBook/media/v4l/pixfmt-srggb10alaw8.xml
> > b/Documentation/DocBook/media/v4l/pixfmt-srggb10alaw8.xml new file mode
> > 100644
> > index 0000000..9b5c80d
> > --- /dev/null
> > +++ b/Documentation/DocBook/media/v4l/pixfmt-srggb10alaw8.xml
> > @@ -0,0 +1,34 @@
> > +	<refentry>
> > +	  <refmeta>
> > +	    <refentrytitle>
> > +	      V4L2_PIX_FMT_SRGGB10ALAW8 ('aRA8'),
> > +	      V4L2_PIX_FMT_SGRBG10ALAW8 ('agA8'),
> > +	      V4L2_PIX_FMT_SGBRG10ALAW8 ('aGA8'),
> > +	      V4L2_PIX_FMT_SBGGR10ALAW8 ('aBA8'),
> > +	    </refentrytitle>
> > +	    &manvol;
> > +	  </refmeta>
> > +	  <refnamediv>
> > +	    <refname id="V4L2-PIX-FMT-SRGGB10ALAW8">
> > +	      <constant>V4L2_PIX_FMT_SRGGB10ALAW8</constant>
> > +	    </refname>
> > +	    <refname id="V4L2-PIX-FMT-SGRBG10ALAW8">
> > +	      <constant>V4L2_PIX_FMT_SGRBG10ALAW8</constant>
> > +	    </refname>
> > +	    <refname id="V4L2-PIX-FMT-SGBRG10ALAW8">
> > +	      <constant>V4L2_PIX_FMT_SGBRG10ALAW8</constant>
> > +	    </refname>
> > +	    <refname id="V4L2-PIX-FMT-SBGGR10ALAW8">
> > +	      <constant>V4L2_PIX_FMT_SBGGR10ALAW8</constant>
> > +	    </refname>
> > +	    <refpurpose>10-bit Bayer formats compressed to 8 bits</refpurpose>
> > +	  </refnamediv>
> > +	  <refsect1>
> > +	    <title>Description</title>
> > +	    <para>The following four pixel formats are raw sRGB / Bayer
> > +	    formats with 10 bits per colour compressed to 8 bits each,
> > +	    using the A-LAW algorithm. Each colour component consumes 8
> > +	    bits of memory. In other respects this format is similar to
> > +	    <xref linkend="V4L2-PIX-FMT-SRGGB8">.</xref></para>
> > +	  </refsect1>
> > +	</refentry>
> > diff --git a/Documentation/DocBook/media/v4l/pixfmt-uv8.xml
> > b/Documentation/DocBook/media/v4l/pixfmt-uv8.xml new file mode 100644
> > index 0000000..c507c1f
> > --- /dev/null
> > +++ b/Documentation/DocBook/media/v4l/pixfmt-uv8.xml
> > @@ -0,0 +1,62 @@
> > +	<refentry id="V4L2-PIX-FMT-UV8">
> > +	  <refmeta>
> > +	    <refentrytitle>V4L2_PIX_FMT_UV8  ('UV8')</refentrytitle>
> > +	    &manvol;
> > +	  </refmeta>
> > +	  <refnamediv>
> > +	    <refname><constant>V4L2_PIX_FMT_UV8</constant></refname>
> > +	    <refpurpose>UV plane interleaved</refpurpose>
> > +	  </refnamediv>
> > +	  <refsect1>
> > +	    <title>Description</title>
> > +	    <para>In this format there is no Y plane, Only CbCr plane. ie
> > +	    (UV interleaved)</para>
> > +	    <example>
> > +	    <title>
> > +	      <constant>V4L2_PIX_FMT_UV8</constant>
> > +	       pixel image
> > +	    </title>
> > +
> > +	    <formalpara>
> > +	      <title>Byte Order.</title>
> > +	      <para>Each cell is one byte.
> > +	        <informaltable frame="none">
> > +	        <tgroup cols="5" align="center">
> > +		  <colspec align="left" colwidth="2*" />
> > +		  <tbody valign="top">
> > +		    <row>
> > +		      <entry>start&nbsp;+&nbsp;0:</entry>
> > +		      <entry>Cb<subscript>00</subscript></entry>
> > +		      <entry>Cr<subscript>00</subscript></entry>
> > +		      <entry>Cb<subscript>01</subscript></entry>
> > +		      <entry>Cr<subscript>01</subscript></entry>
> > +		    </row>
> > +		    <row>
> > +		      <entry>start&nbsp;+&nbsp;4:</entry>
> > +		      <entry>Cb<subscript>10</subscript></entry>
> > +		      <entry>Cr<subscript>10</subscript></entry>
> > +		      <entry>Cb<subscript>11</subscript></entry>
> > +		      <entry>Cr<subscript>11</subscript></entry>
> > +		    </row>
> > +		    <row>
> > +		      <entry>start&nbsp;+&nbsp;8:</entry>
> > +		      <entry>Cb<subscript>20</subscript></entry>
> > +		      <entry>Cr<subscript>20</subscript></entry>
> > +		      <entry>Cb<subscript>21</subscript></entry>
> > +		      <entry>Cr<subscript>21</subscript></entry>
> > +		    </row>
> > +		    <row>
> > +		      <entry>start&nbsp;+&nbsp;12:</entry>
> > +		      <entry>Cb<subscript>30</subscript></entry>
> > +		      <entry>Cr<subscript>30</subscript></entry>
> > +		      <entry>Cb<subscript>31</subscript></entry>
> > +		      <entry>Cr<subscript>31</subscript></entry>
> > +		    </row>
> > +		  </tbody>
> > +		</tgroup>
> > +		</informaltable>
> > +	      </para>
> > +	      </formalpara>
> > +	    </example>
> > +	  </refsect1>
> > +	</refentry>
> > diff --git a/Documentation/DocBook/media/v4l/pixfmt.xml
> > b/Documentation/DocBook/media/v4l/pixfmt.xml index 74d4fcd..9dc3024 100644
> > --- a/Documentation/DocBook/media/v4l/pixfmt.xml
> > +++ b/Documentation/DocBook/media/v4l/pixfmt.xml
> > @@ -674,6 +674,7 @@ access the palette, this must be done with ioctls of the
> > Linux framebuffer API.< &sub-sbggr16;
> >      &sub-srggb10;
> >      &sub-srggb10dpcm8;
> > +    &sub-srggb10alaw8;
> 
> Please move the ALAW formats above the DPCM formats to keep them 
> alphabetically sorted.
> 
  Ok.

> >      &sub-srggb12;
> >    </section>
> > 
> > @@ -701,6 +702,7 @@ information.</para>
> >      &sub-y12;
> >      &sub-y10b;
> >      &sub-y16;
> > +    &sub-uv8;
> >      &sub-yuyv;
> >      &sub-uyvy;
> >      &sub-yvyu;
> > diff --git a/include/linux/videodev2.h b/include/linux/videodev2.h
> > index dbc0d77..71f9f94 100644
> > --- a/include/linux/videodev2.h
> > +++ b/include/linux/videodev2.h
> > @@ -328,6 +328,9 @@ struct v4l2_pix_format {
> >  /* Palette formats */
> >  #define V4L2_PIX_FMT_PAL8    v4l2_fourcc('P', 'A', 'L', '8') /*  8  8-bit
> > palette */
> > 
> > +/* Chrominance formats */
> > +#define V4L2_PIX_FMT_UV8      v4l2_fourcc('U', 'V', '8', ' ') /*  8  UV 4:4
> > */ +
> >  /* Luminance+Chrominance formats */
> >  #define V4L2_PIX_FMT_YVU410  v4l2_fourcc('Y', 'V', 'U', '9') /*  9  YVU
> > 4:1:0     */ #define V4L2_PIX_FMT_YVU420  v4l2_fourcc('Y', 'V', '1', '2')
> > /* 12  YVU 4:2:0     */ @@ -382,6 +385,11 @@ struct v4l2_pix_format {
> >  #define V4L2_PIX_FMT_SGBRG10DPCM8 v4l2_fourcc('b', 'G', 'A', '8')
> >  #define V4L2_PIX_FMT_SGRBG10DPCM8 v4l2_fourcc('B', 'D', '1', '0')
> >  #define V4L2_PIX_FMT_SRGGB10DPCM8 v4l2_fourcc('b', 'R', 'A', '8')
> > +	/* 10bit raw bayer a-law compressed to 8 bits */
> > +#define V4L2_PIX_FMT_SBGGR10ALAW8 v4l2_fourcc('a', 'B', 'A', '8')
> > +#define V4L2_PIX_FMT_SGBRG10ALAW8 v4l2_fourcc('a', 'G', 'A', '8')
> > +#define V4L2_PIX_FMT_SGRBG10ALAW8 v4l2_fourcc('a', 'g', 'A', '8')
> > +#define V4L2_PIX_FMT_SRGGB10ALAW8 v4l2_fourcc('a', 'R', 'A', '8')
> 
> Please move the ALAW formats above the DPCM formats to keep them 
> alphabetically sorted.
> 
  Ok.

Thx,
--Manju

> We still have no clear fourcc allocation scheme for Bayer formats, but I 
> suppose I'll need to give up on that.
> 
> >  	/*
> >  	 * 10bit raw bayer, expanded to 16 bits
> >  	 * xxxxrrrrrrrrrrxxxxgggggggggg xxxxggggggggggxxxxbbbbbbbbbb...
> -- 
> Regards,
> 
> Laurent Pinchart
> 
> 


^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [PATCH v4 1/2] media: add new mediabus format enums for dm365
  2012-07-17 11:41     ` Hadli, Manjunath
@ 2012-07-17 11:55       ` Laurent Pinchart
  2012-07-17 12:22         ` Hadli, Manjunath
  0 siblings, 1 reply; 12+ messages in thread
From: Laurent Pinchart @ 2012-07-17 11:55 UTC (permalink / raw)
  To: Hadli, Manjunath; +Cc: dlos, LMML, Sakari Ailus, Hans Verkuil

Hi Manjunath,

On Tuesday 17 July 2012 11:41:11 Hadli, Manjunath wrote:
> On Tue, Jul 17, 2012 at 16:26:24, Laurent Pinchart wrote:
> > On Friday 30 March 2012 10:09:13 Hadli, Manjunath wrote:
> > > add new enum entries for supporting the media-bus formats on dm365.
> > > These include some bayer and some non-bayer formats.
> > > V4L2_MBUS_FMT_YDYC8_1X16 and V4L2_MBUS_FMT_UV8_1X8 are used
> > > internal to the hardware by the resizer.
> > > V4L2_MBUS_FMT_SBGGR10_ALAW8_1X8 represents the bayer ALAW format
> > > that is supported by dm365 hardware.
> > > 
> > > Signed-off-by: Manjunath Hadli <manjunath.hadli@ti.com>
> > > Cc: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
> > > Cc: Sakari Ailus <sakari.ailus@iki.fi>
> > > Cc: Hans Verkuil <hans.verkuil@cisco.com>
> > > ---
> > > 
> > >  Documentation/DocBook/media/v4l/subdev-formats.xml |  171  ++++++++++++
> > >  include/linux/v4l2-mediabus.h                      |   10 +-
> > >  2 files changed, 179 insertions(+), 2 deletions(-)
> > > 
> > > diff --git a/Documentation/DocBook/media/v4l/subdev-formats.xml
> > > b/Documentation/DocBook/media/v4l/subdev-formats.xml index
> > > 49c532e..48d92bb
> > > 100644
> > > --- a/Documentation/DocBook/media/v4l/subdev-formats.xml
> > > +++ b/Documentation/DocBook/media/v4l/subdev-formats.xml

[snip]

> > > @@ -965,6 +1036,56 @@
> > >  	      <entry>y<subscript>1</subscript></entry>
> > >  	      <entry>y<subscript>0</subscript></entry>
> > >  	    </row>
> > > +	    <row id="V4L2-MBUS-FMT-UV8-1X8">
> > 
> > That's a weird one. Just out of curiosity, what's the point of
> > transferring chroma information without luma ?
> 
> DM365 supports this format.

Right, but what is it used for ?

[snip]

> > > @@ -2415,6 +2536,56 @@
> > >  	      <entry>u<subscript>1</subscript></entry>
> > >  	      <entry>u<subscript>0</subscript></entry>
> > >  	    </row>
> > > +	    <row id="V4L2-MBUS-FMT-YDYC8-1X16">
> > 
> > What is this beast ? We at least need a textual description, as I have no
> > idea what the format corresponds to.
> 
> This was discussed earlier over here
> http://patchwork.linuxtv.org/patch/8843/

My bad, I should have remembered that. Please add a textual description of the 
format, it's not clear from the name what D and C are.

-- 
Regards,

Laurent Pinchart


^ permalink raw reply	[flat|nested] 12+ messages in thread

* RE: [PATCH v4 1/2] media: add new mediabus format enums for dm365
  2012-07-17 11:55       ` Laurent Pinchart
@ 2012-07-17 12:22         ` Hadli, Manjunath
  2012-07-18 11:05           ` Laurent Pinchart
  0 siblings, 1 reply; 12+ messages in thread
From: Hadli, Manjunath @ 2012-07-17 12:22 UTC (permalink / raw)
  To: Laurent Pinchart; +Cc: dlos, LMML, Sakari Ailus, Hans Verkuil

Hi Laurent,

On Tue, Jul 17, 2012 at 17:25:42, Laurent Pinchart wrote:
> Hi Manjunath,
> 
> On Tuesday 17 July 2012 11:41:11 Hadli, Manjunath wrote:
> > On Tue, Jul 17, 2012 at 16:26:24, Laurent Pinchart wrote:
> > > On Friday 30 March 2012 10:09:13 Hadli, Manjunath wrote:
> > > > add new enum entries for supporting the media-bus formats on dm365.
> > > > These include some bayer and some non-bayer formats.
> > > > V4L2_MBUS_FMT_YDYC8_1X16 and V4L2_MBUS_FMT_UV8_1X8 are used
> > > > internal to the hardware by the resizer.
> > > > V4L2_MBUS_FMT_SBGGR10_ALAW8_1X8 represents the bayer ALAW format
> > > > that is supported by dm365 hardware.
> > > > 
> > > > Signed-off-by: Manjunath Hadli <manjunath.hadli@ti.com>
> > > > Cc: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
> > > > Cc: Sakari Ailus <sakari.ailus@iki.fi>
> > > > Cc: Hans Verkuil <hans.verkuil@cisco.com>
> > > > ---
> > > > 
> > > >  Documentation/DocBook/media/v4l/subdev-formats.xml |  171  ++++++++++++
> > > >  include/linux/v4l2-mediabus.h                      |   10 +-
> > > >  2 files changed, 179 insertions(+), 2 deletions(-)
> > > > 
> > > > diff --git a/Documentation/DocBook/media/v4l/subdev-formats.xml
> > > > b/Documentation/DocBook/media/v4l/subdev-formats.xml index
> > > > 49c532e..48d92bb
> > > > 100644
> > > > --- a/Documentation/DocBook/media/v4l/subdev-formats.xml
> > > > +++ b/Documentation/DocBook/media/v4l/subdev-formats.xml
> 
> [snip]
> 
> > > > @@ -965,6 +1036,56 @@
> > > >  	      <entry>y<subscript>1</subscript></entry>
> > > >  	      <entry>y<subscript>0</subscript></entry>
> > > >  	    </row>
> > > > +	    <row id="V4L2-MBUS-FMT-UV8-1X8">
> > > 
> > > That's a weird one. Just out of curiosity, what's the point of
> > > transferring chroma information without luma ?
> > 
> > DM365 supports this format.
> 
> Right, but what is it used for ?
> 
Sorry about that. The Resizer in Dm365 can take only chroma and resize the buffer. It can also take luma of course.In general it can take UV8, Y8 and also UYVY.  
> [snip]
> 
> > > > @@ -2415,6 +2536,56 @@
> > > >  	      <entry>u<subscript>1</subscript></entry>
> > > >  	      <entry>u<subscript>0</subscript></entry>
> > > >  	    </row>
> > > > +	    <row id="V4L2-MBUS-FMT-YDYC8-1X16">
> > > 
> > > What is this beast ? We at least need a textual description, as I have no
> > > idea what the format corresponds to.
> > 
> > This was discussed earlier over here
> > http://patchwork.linuxtv.org/patch/8843/
> 
> My bad, I should have remembered that. Please add a textual description of the 
> format, it's not clear from the name what D and C are.
> 
I see no description for individual MBUS formats but a collective para on everything together.
Would you like me to add in the same or otherwise can you point to me where I can add this description?
 
Thx,
--Manju
> -- 
> Regards,
> 
> Laurent Pinchart
> 
> 


^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [PATCH v4 1/2] media: add new mediabus format enums for dm365
  2012-07-17 12:22         ` Hadli, Manjunath
@ 2012-07-18 11:05           ` Laurent Pinchart
  2012-07-19 11:33             ` Hadli, Manjunath
  0 siblings, 1 reply; 12+ messages in thread
From: Laurent Pinchart @ 2012-07-18 11:05 UTC (permalink / raw)
  To: Hadli, Manjunath; +Cc: dlos, LMML, Sakari Ailus, Hans Verkuil

Hi Manjunath,

On Tuesday 17 July 2012 12:22:42 Hadli, Manjunath wrote:
> On Tue, Jul 17, 2012 at 17:25:42, Laurent Pinchart wrote:
> > On Tuesday 17 July 2012 11:41:11 Hadli, Manjunath wrote:
> > > On Tue, Jul 17, 2012 at 16:26:24, Laurent Pinchart wrote:
> > > > On Friday 30 March 2012 10:09:13 Hadli, Manjunath wrote:
> > > > > add new enum entries for supporting the media-bus formats on dm365.
> > > > > These include some bayer and some non-bayer formats.
> > > > > V4L2_MBUS_FMT_YDYC8_1X16 and V4L2_MBUS_FMT_UV8_1X8 are used
> > > > > internal to the hardware by the resizer.
> > > > > V4L2_MBUS_FMT_SBGGR10_ALAW8_1X8 represents the bayer ALAW format
> > > > > that is supported by dm365 hardware.
> > > > > 
> > > > > Signed-off-by: Manjunath Hadli <manjunath.hadli@ti.com>
> > > > > Cc: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
> > > > > Cc: Sakari Ailus <sakari.ailus@iki.fi>
> > > > > Cc: Hans Verkuil <hans.verkuil@cisco.com>
> > > > > ---
> > > > > 
> > > > >  Documentation/DocBook/media/v4l/subdev-formats.xml |  171 
> > > > >  ++++++++++++
> > > > >  include/linux/v4l2-mediabus.h                      |   10 +-
> > > > >  2 files changed, 179 insertions(+), 2 deletions(-)
> > > > > 
> > > > > diff --git a/Documentation/DocBook/media/v4l/subdev-formats.xml
> > > > > b/Documentation/DocBook/media/v4l/subdev-formats.xml index
> > > > > 49c532e..48d92bb
> > > > > 100644
> > > > > --- a/Documentation/DocBook/media/v4l/subdev-formats.xml
> > > > > +++ b/Documentation/DocBook/media/v4l/subdev-formats.xml
> > 
> > [snip]
> > 
> > > > > @@ -965,6 +1036,56 @@
> > > > > 
> > > > >  	      <entry>y<subscript>1</subscript></entry>
> > > > >  	      <entry>y<subscript>0</subscript></entry>
> > > > >  	    
> > > > >  	    </row>
> > > > > 
> > > > > +	    <row id="V4L2-MBUS-FMT-UV8-1X8">
> > > > 
> > > > That's a weird one. Just out of curiosity, what's the point of
> > > > transferring chroma information without luma ?
> > > 
> > > DM365 supports this format.
> > 
> > Right, but what is it used for ?
> 
> Sorry about that. The Resizer in Dm365 can take only chroma and resize the
> buffer. It can also take luma of course. In general it can take UV8, Y8 and
> also UYVY.

So UV8 is used to resize an NV buffer in two passes (first Y8 then UV8) ?

> > [snip]
> > 
> > > > > @@ -2415,6 +2536,56 @@
> > > > > 
> > > > >  	      <entry>u<subscript>1</subscript></entry>
> > > > >  	      <entry>u<subscript>0</subscript></entry>
> > > > >  	    
> > > > >  	    </row>
> > > > > 
> > > > > +	    <row id="V4L2-MBUS-FMT-YDYC8-1X16">
> > > > 
> > > > What is this beast ? We at least need a textual description, as I have
> > > > no
> > > > idea what the format corresponds to.
> > > 
> > > This was discussed earlier over here
> > > http://patchwork.linuxtv.org/patch/8843/
> > 
> > My bad, I should have remembered that. Please add a textual description of
> > the format, it's not clear from the name what D and C are.
> 
> I see no description for individual MBUS formats but a collective para on
> everything together. Would you like me to add in the same or otherwise can
> you point to me where I can add this description?

What about the following patch ? Note that I've renamed YDYC to YDYU, as we
might later need a YDYV format.

(Hans, Sakari, any opinion ?)

diff --git a/Documentation/DocBook/media/v4l/subdev-formats.xml b/Documentation/DocBook/media/v4l/subdev-formats.xml
index 49c532e..47a485e 100644
--- a/Documentation/DocBook/media/v4l/subdev-formats.xml
+++ b/Documentation/DocBook/media/v4l/subdev-formats.xml
@@ -853,10 +853,15 @@
       <title>Packed YUV Formats</title>
 
       <para>Those data formats transfer pixel data as (possibly downsampled) Y, U
-      and V components. The format code is made of the following information.
+      and V components. Some formats include dummy bits in some of their samples
+      and are collectively referred to as "YDYC" (Y-Dummy-Y-Chroma) formats.
+      </para>
+
+      <para>The format code is made of the following information.
       <itemizedlist>
 	<listitem><para>The Y, U and V components order code, as transferred on the
-	bus. Possible values are YUYV, UYVY, YVYU and VYUY.</para></listitem>
+	bus. Possible values are YUYV, UYVY, YVYU and VYUY for formats with no
+	dummy bit, and YDYU, YDYV, YUYD and YVYD for YDYC formats.</para></listitem>
 	<listitem><para>The number of bits per pixel component. All components are
 	transferred on the same number of bits. Common values are 8, 10 and 12.</para>
 	</listitem>
@@ -877,7 +882,21 @@
       U, Y, V, Y order will be named <constant>V4L2_MBUS_FMT_UYVY8_2X8</constant>.
       </para>
 
-      <para>The following table lisst existing packet YUV formats.</para>
+      <para><xref linkend="v4l2-mbus-pixelcode-yuv8"/> list existing packet YUV
+      formats and describes the organization of each pixel data in each sample.
+      When a format pattern is split across multiple samples each of the samples
+      in the pattern is described.</para>
+
+      <para>The role of each bit transferred over the bus is identified by one
+      of the following codes.</para>
+
+      <itemizedlist>
+        <listitem><para>y<subscript>x</subscript> for luma component bit number x</para></listitem>
+        <listitem><para>u<subscript>x</subscript> for blue chroma component bit number x</para></listitem>
+        <listitem><para>v<subscript>x</subscript> for red chroma component bit number x</para></listitem>
+        <listitem><para>- for non-available bits (for positions higher than the bus width)</para></listitem>
+        <listitem><para>/ for dummy bits</para></listitem>
+      </itemizedlist>
 
       <table pgwide="0" frame="none" id="v4l2-mbus-pixelcode-yuv8">
 	<title>YUV Formats</title>
@@ -2415,6 +2434,106 @@
 	      <entry>u<subscript>1</subscript></entry>
 	      <entry>u<subscript>0</subscript></entry>
 	    </row>
+	    <row id="V4L2-MBUS-FMT-YDYU8-1X16">
+	      <entry>V4L2_MBUS_FMT_YDYU8_1X16</entry>
+	      <entry>0x2014</entry>
+	      <entry></entry>
+	      <entry>-</entry>
+	      <entry>-</entry>
+	      <entry>-</entry>
+	      <entry>-</entry>
+	      <entry>y<subscript>7</subscript></entry>
+	      <entry>y<subscript>6</subscript></entry>
+	      <entry>y<subscript>5</subscript></entry>
+	      <entry>y<subscript>4</subscript></entry>
+	      <entry>y<subscript>3</subscript></entry>
+	      <entry>y<subscript>2</subscript></entry>
+	      <entry>y<subscript>1</subscript></entry>
+	      <entry>y<subscript>0</subscript></entry>
+	      <entry>/</entry>
+	      <entry>/</entry>
+	      <entry>/</entry>
+	      <entry>/</entry>
+	      <entry>/</entry>
+	      <entry>/</entry>
+	      <entry>/</entry>
+	      <entry>/</entry>
+	    </row>
+	    <row>
+	      <entry></entry>
+	      <entry></entry>
+	      <entry></entry>
+	      <entry>-</entry>
+	      <entry>-</entry>
+	      <entry>-</entry>
+	      <entry>-</entry>
+	      <entry>y<subscript>7</subscript></entry>
+	      <entry>y<subscript>6</subscript></entry>
+	      <entry>y<subscript>5</subscript></entry>
+	      <entry>y<subscript>4</subscript></entry>
+	      <entry>y<subscript>3</subscript></entry>
+	      <entry>y<subscript>2</subscript></entry>
+	      <entry>y<subscript>1</subscript></entry>
+	      <entry>y<subscript>0</subscript></entry>
+	      <entry>u<subscript>7</subscript></entry>
+	      <entry>u<subscript>6</subscript></entry>
+	      <entry>u<subscript>5</subscript></entry>
+	      <entry>u<subscript>4</subscript></entry>
+	      <entry>u<subscript>3</subscript></entry>
+	      <entry>u<subscript>2</subscript></entry>
+	      <entry>u<subscript>1</subscript></entry>
+	      <entry>u<subscript>0</subscript></entry>
+	    </row>
+	    <row>
+	      <entry></entry>
+	      <entry></entry>
+	      <entry></entry>
+	      <entry>-</entry>
+	      <entry>-</entry>
+	      <entry>-</entry>
+	      <entry>-</entry>
+	      <entry>y<subscript>7</subscript></entry>
+	      <entry>y<subscript>6</subscript></entry>
+	      <entry>y<subscript>5</subscript></entry>
+	      <entry>y<subscript>4</subscript></entry>
+	      <entry>y<subscript>3</subscript></entry>
+	      <entry>y<subscript>2</subscript></entry>
+	      <entry>y<subscript>1</subscript></entry>
+	      <entry>y<subscript>0</subscript></entry>
+	      <entry>/</entry>
+	      <entry>/</entry>
+	      <entry>/</entry>
+	      <entry>/</entry>
+	      <entry>/</entry>
+	      <entry>/</entry>
+	      <entry>/</entry>
+	      <entry>/</entry>
+	    </row>
+	    <row>
+	      <entry></entry>
+	      <entry></entry>
+	      <entry></entry>
+	      <entry>-</entry>
+	      <entry>-</entry>
+	      <entry>-</entry>
+	      <entry>-</entry>
+	      <entry>y<subscript>7</subscript></entry>
+	      <entry>y<subscript>6</subscript></entry>
+	      <entry>y<subscript>5</subscript></entry>
+	      <entry>y<subscript>4</subscript></entry>
+	      <entry>y<subscript>3</subscript></entry>
+	      <entry>y<subscript>2</subscript></entry>
+	      <entry>y<subscript>1</subscript></entry>
+	      <entry>y<subscript>0</subscript></entry>
+	      <entry>v<subscript>7</subscript></entry>
+	      <entry>v<subscript>6</subscript></entry>
+	      <entry>v<subscript>5</subscript></entry>
+	      <entry>v<subscript>4</subscript></entry>
+	      <entry>v<subscript>3</subscript></entry>
+	      <entry>v<subscript>2</subscript></entry>
+	      <entry>v<subscript>1</subscript></entry>
+	      <entry>v<subscript>0</subscript></entry>
+	    </row>
 	    <row id="V4L2-MBUS-FMT-YUYV10-1X20">
 	      <entry>V4L2_MBUS_FMT_YUYV10_1X20</entry>
 	      <entry>0x200d</entry>

-- 
Regards,

Laurent Pinchart


^ permalink raw reply related	[flat|nested] 12+ messages in thread

* RE: [PATCH v4 1/2] media: add new mediabus format enums for dm365
  2012-07-18 11:05           ` Laurent Pinchart
@ 2012-07-19 11:33             ` Hadli, Manjunath
  2012-07-19 11:39               ` Laurent Pinchart
                                 ` (2 more replies)
  0 siblings, 3 replies; 12+ messages in thread
From: Hadli, Manjunath @ 2012-07-19 11:33 UTC (permalink / raw)
  To: Laurent Pinchart
  Cc: dlos, LMML, Sakari Ailus, Hans Verkuil, g.liakhovetski, Lad, Prabhakar

Hi Laurent,

On Wed, Jul 18, 2012 at 16:35:18, Laurent Pinchart wrote:
> Hi Manjunath,
> 
> On Tuesday 17 July 2012 12:22:42 Hadli, Manjunath wrote:
> > On Tue, Jul 17, 2012 at 17:25:42, Laurent Pinchart wrote:
> > > On Tuesday 17 July 2012 11:41:11 Hadli, Manjunath wrote:
> > > > On Tue, Jul 17, 2012 at 16:26:24, Laurent Pinchart wrote:
> > > > > On Friday 30 March 2012 10:09:13 Hadli, Manjunath wrote:
> > > > > > add new enum entries for supporting the media-bus formats on dm365.
> > > > > > These include some bayer and some non-bayer formats.
> > > > > > V4L2_MBUS_FMT_YDYC8_1X16 and V4L2_MBUS_FMT_UV8_1X8 are used
> > > > > > internal to the hardware by the resizer.
> > > > > > V4L2_MBUS_FMT_SBGGR10_ALAW8_1X8 represents the bayer ALAW format
> > > > > > that is supported by dm365 hardware.
> > > > > > 
> > > > > > Signed-off-by: Manjunath Hadli <manjunath.hadli@ti.com>
> > > > > > Cc: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
> > > > > > Cc: Sakari Ailus <sakari.ailus@iki.fi>
> > > > > > Cc: Hans Verkuil <hans.verkuil@cisco.com>
> > > > > > ---
> > > > > > 
> > > > > >  Documentation/DocBook/media/v4l/subdev-formats.xml |  171 
> > > > > >  ++++++++++++
> > > > > >  include/linux/v4l2-mediabus.h                      |   10 +-
> > > > > >  2 files changed, 179 insertions(+), 2 deletions(-)
> > > > > > 
> > > > > > diff --git a/Documentation/DocBook/media/v4l/subdev-formats.xml
> > > > > > b/Documentation/DocBook/media/v4l/subdev-formats.xml index
> > > > > > 49c532e..48d92bb
> > > > > > 100644
> > > > > > --- a/Documentation/DocBook/media/v4l/subdev-formats.xml
> > > > > > +++ b/Documentation/DocBook/media/v4l/subdev-formats.xml
> > > 
> > > [snip]
> > > 
> > > > > > @@ -965,6 +1036,56 @@
> > > > > > 
> > > > > >  	      <entry>y<subscript>1</subscript></entry>
> > > > > >  	      <entry>y<subscript>0</subscript></entry>
> > > > > >  	    
> > > > > >  	    </row>
> > > > > > 
> > > > > > +	    <row id="V4L2-MBUS-FMT-UV8-1X8">
> > > > > 
> > > > > That's a weird one. Just out of curiosity, what's the point of
> > > > > transferring chroma information without luma ?
> > > > 
> > > > DM365 supports this format.
> > > 
> > > Right, but what is it used for ?
> > 
> > Sorry about that. The Resizer in Dm365 can take only chroma and resize the
> > buffer. It can also take luma of course. In general it can take UV8, Y8 and
> > also UYVY.
> 
> So UV8 is used to resize an NV buffer in two passes (first Y8 then UV8) ?
> 
  No. The resizer can take has a capability to resize UV8 alone. Apart from 
  this I don't see any use case for UV8.

(Hans, Sakari, Guennadi, any opinion on exposing UV8 to user?)

> > > [snip]
> > > 
> > > > > > @@ -2415,6 +2536,56 @@
> > > > > > 
> > > > > >  	      <entry>u<subscript>1</subscript></entry>
> > > > > >  	      <entry>u<subscript>0</subscript></entry>
> > > > > >  	    
> > > > > >  	    </row>
> > > > > > 
> > > > > > +	    <row id="V4L2-MBUS-FMT-YDYC8-1X16">
> > > > > 
> > > > > What is this beast ? We at least need a textual description, as I have
> > > > > no
> > > > > idea what the format corresponds to.
> > > > 
> > > > This was discussed earlier over here
> > > > http://patchwork.linuxtv.org/patch/8843/
> > > 
> > > My bad, I should have remembered that. Please add a textual description of
> > > the format, it's not clear from the name what D and C are.
> > 
> > I see no description for individual MBUS formats but a collective para on
> > everything together. Would you like me to add in the same or otherwise can
> > you point to me where I can add this description?
> 
> What about the following patch ? Note that I've renamed YDYC to YDYU, as we
> might later need a YDYV format.
> 
> (Hans, Sakari, any opinion ?)
> 
> diff --git a/Documentation/DocBook/media/v4l/subdev-formats.xml b/Documentation/DocBook/media/v4l/subdev-formats.xml
> index 49c532e..47a485e 100644
> --- a/Documentation/DocBook/media/v4l/subdev-formats.xml
> +++ b/Documentation/DocBook/media/v4l/subdev-formats.xml
> @@ -853,10 +853,15 @@
>        <title>Packed YUV Formats</title>
>  
>        <para>Those data formats transfer pixel data as (possibly downsampled) Y, U
> -      and V components. The format code is made of the following information.
> +      and V components. Some formats include dummy bits in some of their samples
> +      and are collectively referred to as "YDYC" (Y-Dummy-Y-Chroma) formats.
> +      </para>
> +
> +      <para>The format code is made of the following information.
>        <itemizedlist>
>  	<listitem><para>The Y, U and V components order code, as transferred on the
> -	bus. Possible values are YUYV, UYVY, YVYU and VYUY.</para></listitem>
> +	bus. Possible values are YUYV, UYVY, YVYU and VYUY for formats with no
> +	dummy bit, and YDYU, YDYV, YUYD and YVYD for YDYC formats.</para></listitem>
>  	<listitem><para>The number of bits per pixel component. All components are
>  	transferred on the same number of bits. Common values are 8, 10 and 12.</para>
>  	</listitem>
> @@ -877,7 +882,21 @@
>        U, Y, V, Y order will be named <constant>V4L2_MBUS_FMT_UYVY8_2X8</constant>.
>        </para>
>  
> -      <para>The following table lisst existing packet YUV formats.</para>
> +      <para><xref linkend="v4l2-mbus-pixelcode-yuv8"/> list existing packet YUV
> +      formats and describes the organization of each pixel data in each sample.
> +      When a format pattern is split across multiple samples each of the samples
> +      in the pattern is described.</para>
> +
> +      <para>The role of each bit transferred over the bus is identified by one
> +      of the following codes.</para>
> +
> +      <itemizedlist>
> +        <listitem><para>y<subscript>x</subscript> for luma component bit number x</para></listitem>
> +        <listitem><para>u<subscript>x</subscript> for blue chroma component bit number x</para></listitem>
> +        <listitem><para>v<subscript>x</subscript> for red chroma component bit number x</para></listitem>
> +        <listitem><para>- for non-available bits (for positions higher than the bus width)</para></listitem>
> +        <listitem><para>/ for dummy bits</para></listitem>
 As discussed with Hans, Ill use 'd' for dummy bits which would make more sense.

> +      </itemizedlist>
>  
>        <table pgwide="0" frame="none" id="v4l2-mbus-pixelcode-yuv8">
>  	<title>YUV Formats</title>
> @@ -2415,6 +2434,106 @@
>  	      <entry>u<subscript>1</subscript></entry>
>  	      <entry>u<subscript>0</subscript></entry>
>  	    </row>
> +	    <row id="V4L2-MBUS-FMT-YDYU8-1X16">
> +	      <entry>V4L2_MBUS_FMT_YDYU8_1X16</entry>
As discussed over the IRC chat ill change it to V4L2_MBUS_FMT_YDYUYDYV8_1X16

Thx,
--Manju

> +	      <entry>0x2014</entry>
> +	      <entry></entry>
> +	      <entry>-</entry>
> +	      <entry>-</entry>
> +	      <entry>-</entry>
> +	      <entry>-</entry>
> +	      <entry>y<subscript>7</subscript></entry>
> +	      <entry>y<subscript>6</subscript></entry>
> +	      <entry>y<subscript>5</subscript></entry>
> +	      <entry>y<subscript>4</subscript></entry>
> +	      <entry>y<subscript>3</subscript></entry>
> +	      <entry>y<subscript>2</subscript></entry>
> +	      <entry>y<subscript>1</subscript></entry>
> +	      <entry>y<subscript>0</subscript></entry>
> +	      <entry>/</entry>
> +	      <entry>/</entry>
> +	      <entry>/</entry>
> +	      <entry>/</entry>
> +	      <entry>/</entry>
> +	      <entry>/</entry>
> +	      <entry>/</entry>
> +	      <entry>/</entry>
> +	    </row>
> +	    <row>
> +	      <entry></entry>
> +	      <entry></entry>
> +	      <entry></entry>
> +	      <entry>-</entry>
> +	      <entry>-</entry>
> +	      <entry>-</entry>
> +	      <entry>-</entry>
> +	      <entry>y<subscript>7</subscript></entry>
> +	      <entry>y<subscript>6</subscript></entry>
> +	      <entry>y<subscript>5</subscript></entry>
> +	      <entry>y<subscript>4</subscript></entry>
> +	      <entry>y<subscript>3</subscript></entry>
> +	      <entry>y<subscript>2</subscript></entry>
> +	      <entry>y<subscript>1</subscript></entry>
> +	      <entry>y<subscript>0</subscript></entry>
> +	      <entry>u<subscript>7</subscript></entry>
> +	      <entry>u<subscript>6</subscript></entry>
> +	      <entry>u<subscript>5</subscript></entry>
> +	      <entry>u<subscript>4</subscript></entry>
> +	      <entry>u<subscript>3</subscript></entry>
> +	      <entry>u<subscript>2</subscript></entry>
> +	      <entry>u<subscript>1</subscript></entry>
> +	      <entry>u<subscript>0</subscript></entry>
> +	    </row>
> +	    <row>
> +	      <entry></entry>
> +	      <entry></entry>
> +	      <entry></entry>
> +	      <entry>-</entry>
> +	      <entry>-</entry>
> +	      <entry>-</entry>
> +	      <entry>-</entry>
> +	      <entry>y<subscript>7</subscript></entry>
> +	      <entry>y<subscript>6</subscript></entry>
> +	      <entry>y<subscript>5</subscript></entry>
> +	      <entry>y<subscript>4</subscript></entry>
> +	      <entry>y<subscript>3</subscript></entry>
> +	      <entry>y<subscript>2</subscript></entry>
> +	      <entry>y<subscript>1</subscript></entry>
> +	      <entry>y<subscript>0</subscript></entry>
> +	      <entry>/</entry>
> +	      <entry>/</entry>
> +	      <entry>/</entry>
> +	      <entry>/</entry>
> +	      <entry>/</entry>
> +	      <entry>/</entry>
> +	      <entry>/</entry>
> +	      <entry>/</entry>
> +	    </row>
> +	    <row>
> +	      <entry></entry>
> +	      <entry></entry>
> +	      <entry></entry>
> +	      <entry>-</entry>
> +	      <entry>-</entry>
> +	      <entry>-</entry>
> +	      <entry>-</entry>
> +	      <entry>y<subscript>7</subscript></entry>
> +	      <entry>y<subscript>6</subscript></entry>
> +	      <entry>y<subscript>5</subscript></entry>
> +	      <entry>y<subscript>4</subscript></entry>
> +	      <entry>y<subscript>3</subscript></entry>
> +	      <entry>y<subscript>2</subscript></entry>
> +	      <entry>y<subscript>1</subscript></entry>
> +	      <entry>y<subscript>0</subscript></entry>
> +	      <entry>v<subscript>7</subscript></entry>
> +	      <entry>v<subscript>6</subscript></entry>
> +	      <entry>v<subscript>5</subscript></entry>
> +	      <entry>v<subscript>4</subscript></entry>
> +	      <entry>v<subscript>3</subscript></entry>
> +	      <entry>v<subscript>2</subscript></entry>
> +	      <entry>v<subscript>1</subscript></entry>
> +	      <entry>v<subscript>0</subscript></entry>
> +	    </row>
>  	    <row id="V4L2-MBUS-FMT-YUYV10-1X20">
>  	      <entry>V4L2_MBUS_FMT_YUYV10_1X20</entry>
>  	      <entry>0x200d</entry>
> 
> -- 
> Regards,
> 
> Laurent Pinchart
> 
> 


^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [PATCH v4 1/2] media: add new mediabus format enums for dm365
  2012-07-19 11:33             ` Hadli, Manjunath
@ 2012-07-19 11:39               ` Laurent Pinchart
  2012-07-19 11:43               ` Guennadi Liakhovetski
  2012-07-19 12:58               ` Hans Verkuil
  2 siblings, 0 replies; 12+ messages in thread
From: Laurent Pinchart @ 2012-07-19 11:39 UTC (permalink / raw)
  To: Hadli, Manjunath
  Cc: dlos, LMML, Sakari Ailus, Hans Verkuil, g.liakhovetski, Lad, Prabhakar

Hi Manjunath,

On Thursday 19 July 2012 11:33:56 Hadli, Manjunath wrote:
> On Wed, Jul 18, 2012 at 16:35:18, Laurent Pinchart wrote:
> > On Tuesday 17 July 2012 12:22:42 Hadli, Manjunath wrote:
> > > On Tue, Jul 17, 2012 at 17:25:42, Laurent Pinchart wrote:
> > > > On Tuesday 17 July 2012 11:41:11 Hadli, Manjunath wrote:
> > > > > On Tue, Jul 17, 2012 at 16:26:24, Laurent Pinchart wrote:
> > > > > > On Friday 30 March 2012 10:09:13 Hadli, Manjunath wrote:
> > > > > > > add new enum entries for supporting the media-bus formats on
> > > > > > > dm365.
> > > > > > > These include some bayer and some non-bayer formats.
> > > > > > > V4L2_MBUS_FMT_YDYC8_1X16 and V4L2_MBUS_FMT_UV8_1X8 are used
> > > > > > > internal to the hardware by the resizer.
> > > > > > > V4L2_MBUS_FMT_SBGGR10_ALAW8_1X8 represents the bayer ALAW format
> > > > > > > that is supported by dm365 hardware.
> > > > > > > 
> > > > > > > Signed-off-by: Manjunath Hadli <manjunath.hadli@ti.com>
> > > > > > > Cc: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
> > > > > > > Cc: Sakari Ailus <sakari.ailus@iki.fi>
> > > > > > > Cc: Hans Verkuil <hans.verkuil@cisco.com>
> > > > > > > ---
> > > > > > > 
> > > > > > >  Documentation/DocBook/media/v4l/subdev-formats.xml |  171
> > > > > > >  ++++++++++++
> > > > > > >  include/linux/v4l2-mediabus.h                      |   10 +-
> > > > > > >  2 files changed, 179 insertions(+), 2 deletions(-)
> > > > > > > 
> > > > > > > diff --git a/Documentation/DocBook/media/v4l/subdev-formats.xml
> > > > > > > b/Documentation/DocBook/media/v4l/subdev-formats.xml index
> > > > > > > 49c532e..48d92bb
> > > > > > > 100644
> > > > > > > --- a/Documentation/DocBook/media/v4l/subdev-formats.xml
> > > > > > > +++ b/Documentation/DocBook/media/v4l/subdev-formats.xml
> > > > 
> > > > [snip]
> > > > 
> > > > > > > @@ -965,6 +1036,56 @@
> > > > > > > 
> > > > > > >  	      <entry>y<subscript>1</subscript></entry>
> > > > > > >  	      <entry>y<subscript>0</subscript></entry>
> > > > > > >  	    
> > > > > > >  	    </row>
> > > > > > > 
> > > > > > > +	    <row id="V4L2-MBUS-FMT-UV8-1X8">
> > > > > > 
> > > > > > That's a weird one. Just out of curiosity, what's the point of
> > > > > > transferring chroma information without luma ?
> > > > > 
> > > > > DM365 supports this format.
> > > > 
> > > > Right, but what is it used for ?
> > > 
> > > Sorry about that. The Resizer in Dm365 can take only chroma and resize
> > > the buffer. It can also take luma of course. In general it can take UV8,
> > > Y8 and also UYVY.
> > 
> > So UV8 is used to resize an NV buffer in two passes (first Y8 then UV8) ?
> 
> No. The resizer can take has a capability to resize UV8 alone. Apart from
> this I don't see any use case for UV8.

Right, but what is standalone UV8 useful for ? Y8 images make sense, but an 
image made of UV8 data only doesn't sound very useful to me.

NV formats are made of a Y8 plane and a UV8 plane, so UV8 resizing could be 
used to resize an NV image in two passes (resizing the Y8 plane first, then 
the UV8 plane). That's the only use case I see, and in that case I wonder 
whether the driver shouldn't expose NV resizing capabilities to userspace and 
run the two passes internally.

> (Hans, Sakari, Guennadi, any opinion on exposing UV8 to user?)

-- 
Regards,

Laurent Pinchart


^ permalink raw reply	[flat|nested] 12+ messages in thread

* RE: [PATCH v4 1/2] media: add new mediabus format enums for dm365
  2012-07-19 11:33             ` Hadli, Manjunath
  2012-07-19 11:39               ` Laurent Pinchart
@ 2012-07-19 11:43               ` Guennadi Liakhovetski
  2012-07-19 12:58               ` Hans Verkuil
  2 siblings, 0 replies; 12+ messages in thread
From: Guennadi Liakhovetski @ 2012-07-19 11:43 UTC (permalink / raw)
  To: Hadli, Manjunath
  Cc: Laurent Pinchart, dlos, LMML, Sakari Ailus, Hans Verkuil, Lad, Prabhakar

On Thu, 19 Jul 2012, Hadli, Manjunath wrote:

> Hi Laurent,
> 
> On Wed, Jul 18, 2012 at 16:35:18, Laurent Pinchart wrote:
> > Hi Manjunath,
> > 
> > On Tuesday 17 July 2012 12:22:42 Hadli, Manjunath wrote:
> > > On Tue, Jul 17, 2012 at 17:25:42, Laurent Pinchart wrote:
> > > > On Tuesday 17 July 2012 11:41:11 Hadli, Manjunath wrote:
> > > > > On Tue, Jul 17, 2012 at 16:26:24, Laurent Pinchart wrote:
> > > > > > On Friday 30 March 2012 10:09:13 Hadli, Manjunath wrote:
> > > > > > > add new enum entries for supporting the media-bus formats on dm365.
> > > > > > > These include some bayer and some non-bayer formats.
> > > > > > > V4L2_MBUS_FMT_YDYC8_1X16 and V4L2_MBUS_FMT_UV8_1X8 are used
> > > > > > > internal to the hardware by the resizer.
> > > > > > > V4L2_MBUS_FMT_SBGGR10_ALAW8_1X8 represents the bayer ALAW format
> > > > > > > that is supported by dm365 hardware.
> > > > > > > 
> > > > > > > Signed-off-by: Manjunath Hadli <manjunath.hadli@ti.com>
> > > > > > > Cc: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
> > > > > > > Cc: Sakari Ailus <sakari.ailus@iki.fi>
> > > > > > > Cc: Hans Verkuil <hans.verkuil@cisco.com>
> > > > > > > ---
> > > > > > > 
> > > > > > >  Documentation/DocBook/media/v4l/subdev-formats.xml |  171 
> > > > > > >  ++++++++++++
> > > > > > >  include/linux/v4l2-mediabus.h                      |   10 +-
> > > > > > >  2 files changed, 179 insertions(+), 2 deletions(-)
> > > > > > > 
> > > > > > > diff --git a/Documentation/DocBook/media/v4l/subdev-formats.xml
> > > > > > > b/Documentation/DocBook/media/v4l/subdev-formats.xml index
> > > > > > > 49c532e..48d92bb
> > > > > > > 100644
> > > > > > > --- a/Documentation/DocBook/media/v4l/subdev-formats.xml
> > > > > > > +++ b/Documentation/DocBook/media/v4l/subdev-formats.xml
> > > > 
> > > > [snip]
> > > > 
> > > > > > > @@ -965,6 +1036,56 @@
> > > > > > > 
> > > > > > >  	      <entry>y<subscript>1</subscript></entry>
> > > > > > >  	      <entry>y<subscript>0</subscript></entry>
> > > > > > >  	    
> > > > > > >  	    </row>
> > > > > > > 
> > > > > > > +	    <row id="V4L2-MBUS-FMT-UV8-1X8">
> > > > > > 
> > > > > > That's a weird one. Just out of curiosity, what's the point of
> > > > > > transferring chroma information without luma ?
> > > > > 
> > > > > DM365 supports this format.
> > > > 
> > > > Right, but what is it used for ?
> > > 
> > > Sorry about that. The Resizer in Dm365 can take only chroma and resize the
> > > buffer. It can also take luma of course. In general it can take UV8, Y8 and
> > > also UYVY.
> > 
> > So UV8 is used to resize an NV buffer in two passes (first Y8 then UV8) ?
> > 
>   No. The resizer can take has a capability to resize UV8 alone. Apart from 
>   this I don't see any use case for UV8.
> 
> (Hans, Sakari, Guennadi, any opinion on exposing UV8 to user?)

No particular objections from me. Just curious - what could this be used 
for... :-)

Thanks
Guennadi

> > > > [snip]
> > > > 
> > > > > > > @@ -2415,6 +2536,56 @@
> > > > > > > 
> > > > > > >  	      <entry>u<subscript>1</subscript></entry>
> > > > > > >  	      <entry>u<subscript>0</subscript></entry>
> > > > > > >  	    
> > > > > > >  	    </row>
> > > > > > > 
> > > > > > > +	    <row id="V4L2-MBUS-FMT-YDYC8-1X16">
> > > > > > 
> > > > > > What is this beast ? We at least need a textual description, as I have
> > > > > > no
> > > > > > idea what the format corresponds to.
> > > > > 
> > > > > This was discussed earlier over here
> > > > > http://patchwork.linuxtv.org/patch/8843/
> > > > 
> > > > My bad, I should have remembered that. Please add a textual description of
> > > > the format, it's not clear from the name what D and C are.
> > > 
> > > I see no description for individual MBUS formats but a collective para on
> > > everything together. Would you like me to add in the same or otherwise can
> > > you point to me where I can add this description?
> > 
> > What about the following patch ? Note that I've renamed YDYC to YDYU, as we
> > might later need a YDYV format.
> > 
> > (Hans, Sakari, any opinion ?)
> > 
> > diff --git a/Documentation/DocBook/media/v4l/subdev-formats.xml b/Documentation/DocBook/media/v4l/subdev-formats.xml
> > index 49c532e..47a485e 100644
> > --- a/Documentation/DocBook/media/v4l/subdev-formats.xml
> > +++ b/Documentation/DocBook/media/v4l/subdev-formats.xml
> > @@ -853,10 +853,15 @@
> >        <title>Packed YUV Formats</title>
> >  
> >        <para>Those data formats transfer pixel data as (possibly downsampled) Y, U
> > -      and V components. The format code is made of the following information.
> > +      and V components. Some formats include dummy bits in some of their samples
> > +      and are collectively referred to as "YDYC" (Y-Dummy-Y-Chroma) formats.
> > +      </para>
> > +
> > +      <para>The format code is made of the following information.
> >        <itemizedlist>
> >  	<listitem><para>The Y, U and V components order code, as transferred on the
> > -	bus. Possible values are YUYV, UYVY, YVYU and VYUY.</para></listitem>
> > +	bus. Possible values are YUYV, UYVY, YVYU and VYUY for formats with no
> > +	dummy bit, and YDYU, YDYV, YUYD and YVYD for YDYC formats.</para></listitem>
> >  	<listitem><para>The number of bits per pixel component. All components are
> >  	transferred on the same number of bits. Common values are 8, 10 and 12.</para>
> >  	</listitem>
> > @@ -877,7 +882,21 @@
> >        U, Y, V, Y order will be named <constant>V4L2_MBUS_FMT_UYVY8_2X8</constant>.
> >        </para>
> >  
> > -      <para>The following table lisst existing packet YUV formats.</para>
> > +      <para><xref linkend="v4l2-mbus-pixelcode-yuv8"/> list existing packet YUV
> > +      formats and describes the organization of each pixel data in each sample.
> > +      When a format pattern is split across multiple samples each of the samples
> > +      in the pattern is described.</para>
> > +
> > +      <para>The role of each bit transferred over the bus is identified by one
> > +      of the following codes.</para>
> > +
> > +      <itemizedlist>
> > +        <listitem><para>y<subscript>x</subscript> for luma component bit number x</para></listitem>
> > +        <listitem><para>u<subscript>x</subscript> for blue chroma component bit number x</para></listitem>
> > +        <listitem><para>v<subscript>x</subscript> for red chroma component bit number x</para></listitem>
> > +        <listitem><para>- for non-available bits (for positions higher than the bus width)</para></listitem>
> > +        <listitem><para>/ for dummy bits</para></listitem>
>  As discussed with Hans, Ill use 'd' for dummy bits which would make more sense.
> 
> > +      </itemizedlist>
> >  
> >        <table pgwide="0" frame="none" id="v4l2-mbus-pixelcode-yuv8">
> >  	<title>YUV Formats</title>
> > @@ -2415,6 +2434,106 @@
> >  	      <entry>u<subscript>1</subscript></entry>
> >  	      <entry>u<subscript>0</subscript></entry>
> >  	    </row>
> > +	    <row id="V4L2-MBUS-FMT-YDYU8-1X16">
> > +	      <entry>V4L2_MBUS_FMT_YDYU8_1X16</entry>
> As discussed over the IRC chat ill change it to V4L2_MBUS_FMT_YDYUYDYV8_1X16
> 
> Thx,
> --Manju
> 
> > +	      <entry>0x2014</entry>
> > +	      <entry></entry>
> > +	      <entry>-</entry>
> > +	      <entry>-</entry>
> > +	      <entry>-</entry>
> > +	      <entry>-</entry>
> > +	      <entry>y<subscript>7</subscript></entry>
> > +	      <entry>y<subscript>6</subscript></entry>
> > +	      <entry>y<subscript>5</subscript></entry>
> > +	      <entry>y<subscript>4</subscript></entry>
> > +	      <entry>y<subscript>3</subscript></entry>
> > +	      <entry>y<subscript>2</subscript></entry>
> > +	      <entry>y<subscript>1</subscript></entry>
> > +	      <entry>y<subscript>0</subscript></entry>
> > +	      <entry>/</entry>
> > +	      <entry>/</entry>
> > +	      <entry>/</entry>
> > +	      <entry>/</entry>
> > +	      <entry>/</entry>
> > +	      <entry>/</entry>
> > +	      <entry>/</entry>
> > +	      <entry>/</entry>
> > +	    </row>
> > +	    <row>
> > +	      <entry></entry>
> > +	      <entry></entry>
> > +	      <entry></entry>
> > +	      <entry>-</entry>
> > +	      <entry>-</entry>
> > +	      <entry>-</entry>
> > +	      <entry>-</entry>
> > +	      <entry>y<subscript>7</subscript></entry>
> > +	      <entry>y<subscript>6</subscript></entry>
> > +	      <entry>y<subscript>5</subscript></entry>
> > +	      <entry>y<subscript>4</subscript></entry>
> > +	      <entry>y<subscript>3</subscript></entry>
> > +	      <entry>y<subscript>2</subscript></entry>
> > +	      <entry>y<subscript>1</subscript></entry>
> > +	      <entry>y<subscript>0</subscript></entry>
> > +	      <entry>u<subscript>7</subscript></entry>
> > +	      <entry>u<subscript>6</subscript></entry>
> > +	      <entry>u<subscript>5</subscript></entry>
> > +	      <entry>u<subscript>4</subscript></entry>
> > +	      <entry>u<subscript>3</subscript></entry>
> > +	      <entry>u<subscript>2</subscript></entry>
> > +	      <entry>u<subscript>1</subscript></entry>
> > +	      <entry>u<subscript>0</subscript></entry>
> > +	    </row>
> > +	    <row>
> > +	      <entry></entry>
> > +	      <entry></entry>
> > +	      <entry></entry>
> > +	      <entry>-</entry>
> > +	      <entry>-</entry>
> > +	      <entry>-</entry>
> > +	      <entry>-</entry>
> > +	      <entry>y<subscript>7</subscript></entry>
> > +	      <entry>y<subscript>6</subscript></entry>
> > +	      <entry>y<subscript>5</subscript></entry>
> > +	      <entry>y<subscript>4</subscript></entry>
> > +	      <entry>y<subscript>3</subscript></entry>
> > +	      <entry>y<subscript>2</subscript></entry>
> > +	      <entry>y<subscript>1</subscript></entry>
> > +	      <entry>y<subscript>0</subscript></entry>
> > +	      <entry>/</entry>
> > +	      <entry>/</entry>
> > +	      <entry>/</entry>
> > +	      <entry>/</entry>
> > +	      <entry>/</entry>
> > +	      <entry>/</entry>
> > +	      <entry>/</entry>
> > +	      <entry>/</entry>
> > +	    </row>
> > +	    <row>
> > +	      <entry></entry>
> > +	      <entry></entry>
> > +	      <entry></entry>
> > +	      <entry>-</entry>
> > +	      <entry>-</entry>
> > +	      <entry>-</entry>
> > +	      <entry>-</entry>
> > +	      <entry>y<subscript>7</subscript></entry>
> > +	      <entry>y<subscript>6</subscript></entry>
> > +	      <entry>y<subscript>5</subscript></entry>
> > +	      <entry>y<subscript>4</subscript></entry>
> > +	      <entry>y<subscript>3</subscript></entry>
> > +	      <entry>y<subscript>2</subscript></entry>
> > +	      <entry>y<subscript>1</subscript></entry>
> > +	      <entry>y<subscript>0</subscript></entry>
> > +	      <entry>v<subscript>7</subscript></entry>
> > +	      <entry>v<subscript>6</subscript></entry>
> > +	      <entry>v<subscript>5</subscript></entry>
> > +	      <entry>v<subscript>4</subscript></entry>
> > +	      <entry>v<subscript>3</subscript></entry>
> > +	      <entry>v<subscript>2</subscript></entry>
> > +	      <entry>v<subscript>1</subscript></entry>
> > +	      <entry>v<subscript>0</subscript></entry>
> > +	    </row>
> >  	    <row id="V4L2-MBUS-FMT-YUYV10-1X20">
> >  	      <entry>V4L2_MBUS_FMT_YUYV10_1X20</entry>
> >  	      <entry>0x200d</entry>
> > 
> > -- 
> > Regards,
> > 
> > Laurent Pinchart
> > 
> > 
> 

---
Guennadi Liakhovetski, Ph.D.
Freelance Open-Source Software Developer
http://www.open-technology.de/

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [PATCH v4 1/2] media: add new mediabus format enums for dm365
  2012-07-19 11:33             ` Hadli, Manjunath
  2012-07-19 11:39               ` Laurent Pinchart
  2012-07-19 11:43               ` Guennadi Liakhovetski
@ 2012-07-19 12:58               ` Hans Verkuil
  2012-07-19 13:41                 ` Laurent Pinchart
  2 siblings, 1 reply; 12+ messages in thread
From: Hans Verkuil @ 2012-07-19 12:58 UTC (permalink / raw)
  To: Hadli, Manjunath
  Cc: Laurent Pinchart, dlos, LMML, Sakari Ailus, Hans Verkuil,
	g.liakhovetski, Lad, Prabhakar

On Thu 19 July 2012 13:33:56 Hadli, Manjunath wrote:
> Hi Laurent,
> 
> On Wed, Jul 18, 2012 at 16:35:18, Laurent Pinchart wrote:
> > Hi Manjunath,
> > 
> > On Tuesday 17 July 2012 12:22:42 Hadli, Manjunath wrote:
> > > On Tue, Jul 17, 2012 at 17:25:42, Laurent Pinchart wrote:
> > > > On Tuesday 17 July 2012 11:41:11 Hadli, Manjunath wrote:
> > > > > On Tue, Jul 17, 2012 at 16:26:24, Laurent Pinchart wrote:
> > > > > > On Friday 30 March 2012 10:09:13 Hadli, Manjunath wrote:
> > > > > > > add new enum entries for supporting the media-bus formats on dm365.
> > > > > > > These include some bayer and some non-bayer formats.
> > > > > > > V4L2_MBUS_FMT_YDYC8_1X16 and V4L2_MBUS_FMT_UV8_1X8 are used
> > > > > > > internal to the hardware by the resizer.
> > > > > > > V4L2_MBUS_FMT_SBGGR10_ALAW8_1X8 represents the bayer ALAW format
> > > > > > > that is supported by dm365 hardware.
> > > > > > > 
> > > > > > > Signed-off-by: Manjunath Hadli <manjunath.hadli@ti.com>
> > > > > > > Cc: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
> > > > > > > Cc: Sakari Ailus <sakari.ailus@iki.fi>
> > > > > > > Cc: Hans Verkuil <hans.verkuil@cisco.com>
> > > > > > > ---
> > > > > > > 
> > > > > > >  Documentation/DocBook/media/v4l/subdev-formats.xml |  171 
> > > > > > >  ++++++++++++
> > > > > > >  include/linux/v4l2-mediabus.h                      |   10 +-
> > > > > > >  2 files changed, 179 insertions(+), 2 deletions(-)
> > > > > > > 
> > > > > > > diff --git a/Documentation/DocBook/media/v4l/subdev-formats.xml
> > > > > > > b/Documentation/DocBook/media/v4l/subdev-formats.xml index
> > > > > > > 49c532e..48d92bb
> > > > > > > 100644
> > > > > > > --- a/Documentation/DocBook/media/v4l/subdev-formats.xml
> > > > > > > +++ b/Documentation/DocBook/media/v4l/subdev-formats.xml
> > > > 
> > > > [snip]
> > > > 
> > > > > > > @@ -965,6 +1036,56 @@
> > > > > > > 
> > > > > > >  	      <entry>y<subscript>1</subscript></entry>
> > > > > > >  	      <entry>y<subscript>0</subscript></entry>
> > > > > > >  	    
> > > > > > >  	    </row>
> > > > > > > 
> > > > > > > +	    <row id="V4L2-MBUS-FMT-UV8-1X8">
> > > > > > 
> > > > > > That's a weird one. Just out of curiosity, what's the point of
> > > > > > transferring chroma information without luma ?
> > > > > 
> > > > > DM365 supports this format.
> > > > 
> > > > Right, but what is it used for ?
> > > 
> > > Sorry about that. The Resizer in Dm365 can take only chroma and resize the
> > > buffer. It can also take luma of course. In general it can take UV8, Y8 and
> > > also UYVY.
> > 
> > So UV8 is used to resize an NV buffer in two passes (first Y8 then UV8) ?
> > 
>   No. The resizer can take has a capability to resize UV8 alone. Apart from 
>   this I don't see any use case for UV8.
> 
> (Hans, Sakari, Guennadi, any opinion on exposing UV8 to user?)

I have no problem with that. As far as I can tell they should be useful for
conversions between 4:2:0, 4:2:2 and 4:4:4 formats where you just want to resize
the chroma plane.

Regards,

	Hans

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [PATCH v4 1/2] media: add new mediabus format enums for dm365
  2012-07-19 12:58               ` Hans Verkuil
@ 2012-07-19 13:41                 ` Laurent Pinchart
  0 siblings, 0 replies; 12+ messages in thread
From: Laurent Pinchart @ 2012-07-19 13:41 UTC (permalink / raw)
  To: Hans Verkuil
  Cc: Hadli, Manjunath, dlos, LMML, Sakari Ailus, Hans Verkuil,
	g.liakhovetski, Lad, Prabhakar

Hi Hans,

On Thursday 19 July 2012 14:58:12 Hans Verkuil wrote:
> On Thu 19 July 2012 13:33:56 Hadli, Manjunath wrote:
> > On Wed, Jul 18, 2012 at 16:35:18, Laurent Pinchart wrote:
> > > On Tuesday 17 July 2012 12:22:42 Hadli, Manjunath wrote:
> > > > On Tue, Jul 17, 2012 at 17:25:42, Laurent Pinchart wrote:
> > > > > On Tuesday 17 July 2012 11:41:11 Hadli, Manjunath wrote:
> > > > > > On Tue, Jul 17, 2012 at 16:26:24, Laurent Pinchart wrote:
> > > > > > > On Friday 30 March 2012 10:09:13 Hadli, Manjunath wrote:
> > > > > > > > add new enum entries for supporting the media-bus formats on
> > > > > > > > dm365.
> > > > > > > > These include some bayer and some non-bayer formats.
> > > > > > > > V4L2_MBUS_FMT_YDYC8_1X16 and V4L2_MBUS_FMT_UV8_1X8 are used
> > > > > > > > internal to the hardware by the resizer.
> > > > > > > > V4L2_MBUS_FMT_SBGGR10_ALAW8_1X8 represents the bayer ALAW
> > > > > > > > format
> > > > > > > > that is supported by dm365 hardware.
> > > > > > > > 
> > > > > > > > Signed-off-by: Manjunath Hadli <manjunath.hadli@ti.com>
> > > > > > > > Cc: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
> > > > > > > > Cc: Sakari Ailus <sakari.ailus@iki.fi>
> > > > > > > > Cc: Hans Verkuil <hans.verkuil@cisco.com>
> > > > > > > > ---
> > > > > > > > 
> > > > > > > >  Documentation/DocBook/media/v4l/subdev-formats.xml |  171
> > > > > > > >  ++++++++++++
> > > > > > > >  include/linux/v4l2-mediabus.h                      |   10 +-
> > > > > > > >  2 files changed, 179 insertions(+), 2 deletions(-)
> > > > > > > > 
> > > > > > > > diff --git
> > > > > > > > a/Documentation/DocBook/media/v4l/subdev-formats.xml
> > > > > > > > b/Documentation/DocBook/media/v4l/subdev-formats.xml index
> > > > > > > > 49c532e..48d92bb
> > > > > > > > 100644
> > > > > > > > --- a/Documentation/DocBook/media/v4l/subdev-formats.xml
> > > > > > > > +++ b/Documentation/DocBook/media/v4l/subdev-formats.xml
> > > > > 
> > > > > [snip]
> > > > > 
> > > > > > > > @@ -965,6 +1036,56 @@
> > > > > > > > 
> > > > > > > >  	      <entry>y<subscript>1</subscript></entry>
> > > > > > > >  	      <entry>y<subscript>0</subscript></entry>
> > > > > > > >  	    
> > > > > > > >  	    </row>
> > > > > > > > 
> > > > > > > > +	    <row id="V4L2-MBUS-FMT-UV8-1X8">
> > > > > > > 
> > > > > > > That's a weird one. Just out of curiosity, what's the point of
> > > > > > > transferring chroma information without luma ?
> > > > > > 
> > > > > > DM365 supports this format.
> > > > > 
> > > > > Right, but what is it used for ?
> > > > 
> > > > Sorry about that. The Resizer in Dm365 can take only chroma and resize
> > > > the buffer. It can also take luma of course. In general it can take
> > > > UV8, Y8 and also UYVY.
> > > 
> > > So UV8 is used to resize an NV buffer in two passes (first Y8 then UV8)
> > > ?
> > > 
> > No. The resizer can take has a capability to resize UV8 alone. Apart from
> > this I don't see any use case for UV8.
> > 
> > (Hans, Sakari, Guennadi, any opinion on exposing UV8 to user?)
> 
> I have no problem with that. As far as I can tell they should be useful for
> conversions between 4:2:0, 4:2:2 and 4:4:4 formats where you just want to
> resize the chroma plane.

Good point. I'm fine with adding explicit support for UV8 then.

-- 
Regards,

Laurent Pinchart


^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2012-07-19 13:41 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <1333102154-24657-1-git-send-email-manjunath.hadli@ti.com>
     [not found] ` <1333102154-24657-2-git-send-email-manjunath.hadli@ti.com>
2012-07-17 10:56   ` [PATCH v4 1/2] media: add new mediabus format enums for dm365 Laurent Pinchart
2012-07-17 11:41     ` Hadli, Manjunath
2012-07-17 11:55       ` Laurent Pinchart
2012-07-17 12:22         ` Hadli, Manjunath
2012-07-18 11:05           ` Laurent Pinchart
2012-07-19 11:33             ` Hadli, Manjunath
2012-07-19 11:39               ` Laurent Pinchart
2012-07-19 11:43               ` Guennadi Liakhovetski
2012-07-19 12:58               ` Hans Verkuil
2012-07-19 13:41                 ` Laurent Pinchart
     [not found] ` <1333102154-24657-3-git-send-email-manjunath.hadli@ti.com>
2012-07-17 10:59   ` [PATCH v4 2/2] v4l2: add new pixel formats supported on dm365 Laurent Pinchart
2012-07-17 11:43     ` Hadli, Manjunath

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.