[PATCH 1/2] dt-bindings: media: Add macros for video interface bus types
Sakari Ailus
sakari.ailus at linux.intel.com
Sun Feb 27 13:07:23 PST 2022
Hi Laurent,
Thanks for the set.
On Sun, Feb 27, 2022 at 10:33:51PM +0200, Laurent Pinchart wrote:
> Add a new dt-bindings/media/video-interfaces.h header that defines
> macros corresponding to the bus types from media/video-interfaces.yaml.
> This allows avoiding hardcoded constants in device tree sources.
>
> Signed-off-by: Laurent Pinchart <laurent.pinchart at ideasonboard.com>
> ---
> include/dt-bindings/media/video-interfaces.h | 16 ++++++++++++++++
> 1 file changed, 16 insertions(+)
> create mode 100644 include/dt-bindings/media/video-interfaces.h
>
> diff --git a/include/dt-bindings/media/video-interfaces.h b/include/dt-bindings/media/video-interfaces.h
> new file mode 100644
> index 000000000000..e38058e1cca7
> --- /dev/null
> +++ b/include/dt-bindings/media/video-interfaces.h
> @@ -0,0 +1,16 @@
> +/* SPDX-License-Identifier: GPL-2.0-only */
> +/*
> + * Copyright (C) 2022 Laurent Pinchart <laurent.pinchart at ideasonboard.com>
> + */
> +
> +#ifndef __DT_BINDINGS_MEDIA_VIDEO_INTERFACES_H__
> +#define __DT_BINDINGS_MEDIA_VIDEO_INTERFACES_H__
> +
> +#define MEDIA_BUS_TYPE_CSI2_CPHY 1
> +#define MEDIA_BUS_TYPE_CSI1 2
> +#define MEDIA_BUS_TYPE_CCP2 3
> +#define MEDIA_BUS_TYPE_CSI2_DPHY 4
> +#define MEDIA_BUS_TYPE_PARALLEL 5
I've been long thinkin of renaming "PARALLEL" as "BT.601" which it really
is. I don't mind postponing that, but I think you could as well start here.
Up to you.
Should this be somehow visible in video-interfaces.yaml?
> +#define MEDIA_BUS_TYPE_BT656 6
> +
> +#endif /* __DT_BINDINGS_MEDIA_VIDEO_INTERFACES_H__ */
--
Kind regards,
Sakari Ailus
More information about the linux-arm-kernel
mailing list