diff mbox series

[PATCH/RFC] media: Add ISP entity function

Message ID 20210206230616.20403-1-laurent.pinchart@ideasonboard.com
State New
Headers show
Series [PATCH/RFC] media: Add ISP entity function | expand

Commit Message

Laurent Pinchart Feb. 6, 2021, 11:06 p.m. UTC
Add a media entity function to describe ISPs. ISPs overlap with existing
functions such as MEDIA_ENT_F_PROC_VIDEO_SCALER (when they include a
scaler). The new function should be used when the whole ISP is exposed
as a single entity, or for the central "catch all" entity of an ISP that
exposes additional entities for the scaler or other specific processing
blocks.

Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
---
 Documentation/media/uapi/mediactl/media-types.rst | 11 +++++++++++
 include/uapi/linux/media.h                        |  1 +
 2 files changed, 12 insertions(+)

Comments

Laurent Pinchart Feb. 7, 2021, 10 p.m. UTC | #1
Hello,

Please ignore this patch, I've just noticed we already have
MEDIA_ENT_F_PROC_VIDEO_ISP in the linux-media master branch :-S Sorry
for the noise.

On Sun, Feb 07, 2021 at 01:06:16AM +0200, Laurent Pinchart wrote:
> Add a media entity function to describe ISPs. ISPs overlap with existing

> functions such as MEDIA_ENT_F_PROC_VIDEO_SCALER (when they include a

> scaler). The new function should be used when the whole ISP is exposed

> as a single entity, or for the central "catch all" entity of an ISP that

> exposes additional entities for the scaler or other specific processing

> blocks.

> 

> Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>

> ---

>  Documentation/media/uapi/mediactl/media-types.rst | 11 +++++++++++

>  include/uapi/linux/media.h                        |  1 +

>  2 files changed, 12 insertions(+)

> 

> diff --git a/Documentation/media/uapi/mediactl/media-types.rst b/Documentation/media/uapi/mediactl/media-types.rst

> index 3af6a414b501..bbf1b7745d23 100644

> --- a/Documentation/media/uapi/mediactl/media-types.rst

> +++ b/Documentation/media/uapi/mediactl/media-types.rst

> @@ -208,6 +208,17 @@ Types and flags used to represent the media graph elements

>            decompressing a compressed video stream into uncompressed video

>  	  frames. Must have one sink pad and at least one source pad.

>  

> +    *  -  ``MEDIA_ENT_F_PROC_ISP``

> +       -  Image Signal Processor. An entity capable processing images from a

> +          raw sensor to apply demosaicing, a wide range of color correction

> +          algorithms, and optional processing such as scaling or noise

> +          reduction to produce images suitable for consumption by general

> +          purpose applications (often in YUV format). This function should be

> +          used when the whole ISP is exposed as a single entity, or for the

> +          central "catch all" entity of an ISP that exposes additional entities

> +          for the scaler or other specific processing blocks. Must have at

> +          least one sink pad and at least one source pad.

> +

>      *  -  ``MEDIA_ENT_F_VID_MUX``

>         - Video multiplexer. An entity capable of multiplexing must have at

>           least two sink pads and one source pad, and must pass the video

> diff --git a/include/uapi/linux/media.h b/include/uapi/linux/media.h

> index 383ac7b7d8f0..a5977f7a729a 100644

> --- a/include/uapi/linux/media.h

> +++ b/include/uapi/linux/media.h

> @@ -127,6 +127,7 @@ struct media_device_info {

>  #define MEDIA_ENT_F_PROC_VIDEO_STATISTICS	(MEDIA_ENT_F_BASE + 0x4006)

>  #define MEDIA_ENT_F_PROC_VIDEO_ENCODER		(MEDIA_ENT_F_BASE + 0x4007)

>  #define MEDIA_ENT_F_PROC_VIDEO_DECODER		(MEDIA_ENT_F_BASE + 0x4008)

> +#define MEDIA_ENT_F_PROC_ISP			(MEDIA_ENT_F_BASE + 0x4009)

>  

>  /*

>   * Switch and bridge entity functions


-- 
Regards,

Laurent Pinchart
diff mbox series

Patch

diff --git a/Documentation/media/uapi/mediactl/media-types.rst b/Documentation/media/uapi/mediactl/media-types.rst
index 3af6a414b501..bbf1b7745d23 100644
--- a/Documentation/media/uapi/mediactl/media-types.rst
+++ b/Documentation/media/uapi/mediactl/media-types.rst
@@ -208,6 +208,17 @@  Types and flags used to represent the media graph elements
           decompressing a compressed video stream into uncompressed video
 	  frames. Must have one sink pad and at least one source pad.
 
+    *  -  ``MEDIA_ENT_F_PROC_ISP``
+       -  Image Signal Processor. An entity capable processing images from a
+          raw sensor to apply demosaicing, a wide range of color correction
+          algorithms, and optional processing such as scaling or noise
+          reduction to produce images suitable for consumption by general
+          purpose applications (often in YUV format). This function should be
+          used when the whole ISP is exposed as a single entity, or for the
+          central "catch all" entity of an ISP that exposes additional entities
+          for the scaler or other specific processing blocks. Must have at
+          least one sink pad and at least one source pad.
+
     *  -  ``MEDIA_ENT_F_VID_MUX``
        - Video multiplexer. An entity capable of multiplexing must have at
          least two sink pads and one source pad, and must pass the video
diff --git a/include/uapi/linux/media.h b/include/uapi/linux/media.h
index 383ac7b7d8f0..a5977f7a729a 100644
--- a/include/uapi/linux/media.h
+++ b/include/uapi/linux/media.h
@@ -127,6 +127,7 @@  struct media_device_info {
 #define MEDIA_ENT_F_PROC_VIDEO_STATISTICS	(MEDIA_ENT_F_BASE + 0x4006)
 #define MEDIA_ENT_F_PROC_VIDEO_ENCODER		(MEDIA_ENT_F_BASE + 0x4007)
 #define MEDIA_ENT_F_PROC_VIDEO_DECODER		(MEDIA_ENT_F_BASE + 0x4008)
+#define MEDIA_ENT_F_PROC_ISP			(MEDIA_ENT_F_BASE + 0x4009)
 
 /*
  * Switch and bridge entity functions