diff mbox series

[02/14] media: dt-bindings: media: rockchip-cif: add port definitions

Message ID 20240220-v6-8-topic-rk3568-vicap-v1-2-2680a1fa640b@wolfvision.net
State New
Headers show
Series media: rockchip: cif: add support for rk3568 vicap | expand

Commit Message

Michael Riesch Feb. 20, 2024, 9:39 a.m. UTC
The different variants of the Rockchip Camera Interface may feature
various ports. Add a new header file with port definitions to avoid
hardcoded constants in device tree sources.

Signed-off-by: Michael Riesch <michael.riesch@wolfvision.net>
---
 include/dt-bindings/media/rockchip-cif.h | 12 ++++++++++++
 1 file changed, 12 insertions(+)

Comments

Rob Herring Feb. 23, 2024, 12:28 a.m. UTC | #1
On Tue, Feb 20, 2024 at 10:39:12AM +0100, Michael Riesch wrote:
> The different variants of the Rockchip Camera Interface may feature
> various ports. Add a new header file with port definitions to avoid
> hardcoded constants in device tree sources.

We generally don't do defines for 'port' numbering. I don't see a reason 
to start.

> 
> Signed-off-by: Michael Riesch <michael.riesch@wolfvision.net>
> ---
>  include/dt-bindings/media/rockchip-cif.h | 12 ++++++++++++
>  1 file changed, 12 insertions(+)
> 
> diff --git a/include/dt-bindings/media/rockchip-cif.h b/include/dt-bindings/media/rockchip-cif.h
> new file mode 100644
> index 000000000000..37364ee1f7bc
> --- /dev/null
> +++ b/include/dt-bindings/media/rockchip-cif.h
> @@ -0,0 +1,12 @@
> +/* SPDX-License-Identifier: (GPL-2.0-only OR MIT) */
> +/*
> + * Copyright (C) 2023 Michael Riesch <michael.riesch@wolfvision.net>
> + */
> +
> +#ifndef __DT_BINDINGS_MEDIA_ROCKCHIP_CIF_H__
> +#define __DT_BINDINGS_MEDIA_ROCKCHIP_CIF_H__
> +
> +#define MEDIA_ROCKCHIP_CIF_DVP		0
> +#define MEDIA_ROCKCHIP_CIF_MIPI		1
> +
> +#endif /* __DT_BINDINGS_MEDIA_ROCKCHIP_CIF_H__ */
> 
> -- 
> 2.30.2
>
Michael Riesch Feb. 23, 2024, 6:53 a.m. UTC | #2
Hi Rob,

On 2/23/24 01:28, Rob Herring wrote:
> On Tue, Feb 20, 2024 at 10:39:12AM +0100, Michael Riesch wrote:
>> The different variants of the Rockchip Camera Interface may feature
>> various ports. Add a new header file with port definitions to avoid
>> hardcoded constants in device tree sources.
> 
> We generally don't do defines for 'port' numbering. I don't see a reason 
> to start.

OK. I'll drop patches 2 and 8, then.

Best regards,
Michael

>> Signed-off-by: Michael Riesch <michael.riesch@wolfvision.net>
>> ---
>>  include/dt-bindings/media/rockchip-cif.h | 12 ++++++++++++
>>  1 file changed, 12 insertions(+)
>>
>> diff --git a/include/dt-bindings/media/rockchip-cif.h b/include/dt-bindings/media/rockchip-cif.h
>> new file mode 100644
>> index 000000000000..37364ee1f7bc
>> --- /dev/null
>> +++ b/include/dt-bindings/media/rockchip-cif.h
>> @@ -0,0 +1,12 @@
>> +/* SPDX-License-Identifier: (GPL-2.0-only OR MIT) */
>> +/*
>> + * Copyright (C) 2023 Michael Riesch <michael.riesch@wolfvision.net>
>> + */
>> +
>> +#ifndef __DT_BINDINGS_MEDIA_ROCKCHIP_CIF_H__
>> +#define __DT_BINDINGS_MEDIA_ROCKCHIP_CIF_H__
>> +
>> +#define MEDIA_ROCKCHIP_CIF_DVP		0
>> +#define MEDIA_ROCKCHIP_CIF_MIPI		1
>> +
>> +#endif /* __DT_BINDINGS_MEDIA_ROCKCHIP_CIF_H__ */
>>
>> -- 
>> 2.30.2
>>
diff mbox series

Patch

diff --git a/include/dt-bindings/media/rockchip-cif.h b/include/dt-bindings/media/rockchip-cif.h
new file mode 100644
index 000000000000..37364ee1f7bc
--- /dev/null
+++ b/include/dt-bindings/media/rockchip-cif.h
@@ -0,0 +1,12 @@ 
+/* SPDX-License-Identifier: (GPL-2.0-only OR MIT) */
+/*
+ * Copyright (C) 2023 Michael Riesch <michael.riesch@wolfvision.net>
+ */
+
+#ifndef __DT_BINDINGS_MEDIA_ROCKCHIP_CIF_H__
+#define __DT_BINDINGS_MEDIA_ROCKCHIP_CIF_H__
+
+#define MEDIA_ROCKCHIP_CIF_DVP		0
+#define MEDIA_ROCKCHIP_CIF_MIPI		1
+
+#endif /* __DT_BINDINGS_MEDIA_ROCKCHIP_CIF_H__ */