Linux Media Controller development
 help / color / mirror / Atom feed
From: "Niklas Söderlund" <niklas.soderlund@ragnatech.se>
To: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
Cc: linux-media@vger.kernel.org, linux-renesas-soc@vger.kernel.org,
	Sakari Ailus <sakari.ailus@iki.fi>,
	Kieran Bingham <kieran.bingham@ideasonboard.com>,
	Jacopo Mondi <jacopo@jmondi.org>,
	Maxime Ripard <mripard@kernel.org>,
	Dafna Hirschfeld <dafna.hirschfeld@collabora.com>,
	Pratyush Yadav <p.yadav@ti.com>
Subject: Re: [PATCH 1/6] media: Define MIPI CSI-2 data types in a shared header file
Date: Mon, 24 Jan 2022 10:06:16 +0100	[thread overview]
Message-ID: <Ye5sCDwX1e9UwqAN@oden.dyn.berto.se> (raw)
In-Reply-To: <20220123160857.24161-2-laurent.pinchart+renesas@ideasonboard.com>

Hi Laurent,

Thanks for your work.

On 2022-01-23 18:08:52 +0200, Laurent Pinchart wrote:
> There are many CSI-2-related drivers in the media subsystem that come
> with their own macros to handle the CSI-2 data types (or just hardcode
> the numerical values). Provide a shared header with definitions for
> those data types that driver can use.
> 
> Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>

I like this effort. I have not double checked each DT code with the spec 
but choose to trust you on those.

Reviewed-by: Niklas Söderlund <niklas.soderlund+renesas@ragnatech.se>

> ---
>  include/media/mipi-csi2.h | 45 +++++++++++++++++++++++++++++++++++++++
>  1 file changed, 45 insertions(+)
>  create mode 100644 include/media/mipi-csi2.h
> 
> diff --git a/include/media/mipi-csi2.h b/include/media/mipi-csi2.h
> new file mode 100644
> index 000000000000..392794e5badd
> --- /dev/null
> +++ b/include/media/mipi-csi2.h
> @@ -0,0 +1,45 @@
> +/* SPDX-License-Identifier: GPL-2.0-only */
> +/*
> + * MIPI CSI-2 Data Types
> + *
> + * Copyright (C) 2022 Laurent Pinchart <laurent.pinchart@ideasonboard.com>
> + */
> +
> +#ifndef _MEDIA_MIPI_CSI2_H
> +#define _MEDIA_MIPI_CSI2_H
> +
> +/* Short packet data types */
> +#define MIPI_CSI2_DT_FS			0x00
> +#define MIPI_CSI2_DT_FE			0x01
> +#define MIPI_CSI2_DT_LS			0x02
> +#define MIPI_CSI2_DT_LE			0x03
> +#define MIPI_CSI2_DT_GENERIC_SHORT(n)	(0x08 + (n))	/* 0..7 */
> +
> +/* Long packet data types */
> +#define MIPI_CSI2_DT_NULL		0x10
> +#define MIPI_CSI2_DT_BLANKING		0x11
> +#define MIPI_CSI2_DT_EMBEDDED_8B	0x12
> +#define MIPI_CSI2_DT_YUV420_8B		0x18
> +#define MIPI_CSI2_DT_YUV420_10B		0x19
> +#define MIPI_CSI2_DT_YUV420_8B_LEGACY	0x1a
> +#define MIPI_CSI2_DT_YUV420_8B_CS	0x1c
> +#define MIPI_CSI2_DT_YUV420_10B_CS	0x1d
> +#define MIPI_CSI2_DT_YUV422_8B		0x1e
> +#define MIPI_CSI2_DT_YUV422_10B		0x1f
> +#define MIPI_CSI2_DT_RGB444		0x20
> +#define MIPI_CSI2_DT_RGB555		0x21
> +#define MIPI_CSI2_DT_RGB565		0x22
> +#define MIPI_CSI2_DT_RGB666		0x23
> +#define MIPI_CSI2_DT_RGB888		0x24
> +#define MIPI_CSI2_DT_RAW24		0x27
> +#define MIPI_CSI2_DT_RAW6		0x28
> +#define MIPI_CSI2_DT_RAW7		0x29
> +#define MIPI_CSI2_DT_RAW8		0x2a
> +#define MIPI_CSI2_DT_RAW10		0x2b
> +#define MIPI_CSI2_DT_RAW12		0x2c
> +#define MIPI_CSI2_DT_RAW14		0x2d
> +#define MIPI_CSI2_DT_RAW16		0x2e
> +#define MIPI_CSI2_DT_RAW20		0x2f
> +#define MIPI_CSI2_DT_USER_DEFINED(n)	(0x30 + (n))	/* 0..7 */
> +
> +#endif /* _MEDIA_MIPI_CSI2_H */
> -- 
> Regards,
> 
> Laurent Pinchart
> 

-- 
Kind Regards,
Niklas Söderlund

  reply	other threads:[~2022-01-24  9:06 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-01-23 16:08 [PATCH 0/6] media: Centralize MIPI CSI-2 data types in shared header Laurent Pinchart
2022-01-23 16:08 ` [PATCH 1/6] media: Define MIPI CSI-2 data types in a shared header file Laurent Pinchart
2022-01-24  9:06   ` Niklas Söderlund [this message]
2022-01-24 15:22   ` Pratyush Yadav
2022-01-26 11:50     ` Dave Stevenson
2022-01-26 11:59       ` Laurent Pinchart
2022-01-26  9:47   ` Kieran Bingham
2022-01-26 11:57     ` Laurent Pinchart
2022-01-23 16:08 ` [PATCH 2/6] media: cadence: cdns-csi2tx: Use mipi-csi2.h Laurent Pinchart
2022-04-14 14:42   ` Laurent Pinchart
2022-01-23 16:08 ` [PATCH 3/6] media: rcar-isp: " Laurent Pinchart
2022-01-24  9:07   ` Niklas Söderlund
2022-01-23 16:08 ` [PATCH 4/6] media: rcar-csi2: " Laurent Pinchart
2022-01-24  9:10   ` Niklas Söderlund
2022-01-23 16:08 ` [PATCH 5/6] media: rockchip: rkisp1: " Laurent Pinchart
2022-02-03  9:11   ` Dafna Hirschfeld
2022-01-23 16:08 ` [PATCH 6/6] media: xilinx: csi2rxss: " Laurent Pinchart

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=Ye5sCDwX1e9UwqAN@oden.dyn.berto.se \
    --to=niklas.soderlund@ragnatech.se \
    --cc=dafna.hirschfeld@collabora.com \
    --cc=jacopo@jmondi.org \
    --cc=kieran.bingham@ideasonboard.com \
    --cc=laurent.pinchart+renesas@ideasonboard.com \
    --cc=linux-media@vger.kernel.org \
    --cc=linux-renesas-soc@vger.kernel.org \
    --cc=mripard@kernel.org \
    --cc=p.yadav@ti.com \
    --cc=sakari.ailus@iki.fi \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox