xref: /netbsd-src/sys/external/gpl2/dts/dist/include/dt-bindings/display/sdtv-standards.h (revision 58c3e048f5c2f43ee7e820013e37079f2e0b6ae5)
1 /*	$NetBSD: sdtv-standards.h,v 1.1.1.1 2021/11/07 16:49:57 jmcneill Exp $	*/
2 
3 /* SPDX-License-Identifier: GPL-2.0-only or X11 */
4 /*
5  * Copyright 2019 Pengutronix, Marco Felsch <kernel@pengutronix.de>
6  */
7 
8 #ifndef _DT_BINDINGS_DISPLAY_SDTV_STDS_H
9 #define _DT_BINDINGS_DISPLAY_SDTV_STDS_H
10 
11 /*
12  * Attention: Keep the SDTV_STD_* bit definitions in sync with
13  * include/uapi/linux/videodev2.h V4L2_STD_* bit definitions.
14  */
15 /* One bit for each standard */
16 #define SDTV_STD_PAL_B		0x00000001
17 #define SDTV_STD_PAL_B1		0x00000002
18 #define SDTV_STD_PAL_G		0x00000004
19 #define SDTV_STD_PAL_H		0x00000008
20 #define SDTV_STD_PAL_I		0x00000010
21 #define SDTV_STD_PAL_D		0x00000020
22 #define SDTV_STD_PAL_D1		0x00000040
23 #define SDTV_STD_PAL_K		0x00000080
24 
25 #define SDTV_STD_PAL		(SDTV_STD_PAL_B		| \
26 				 SDTV_STD_PAL_B1	| \
27 				 SDTV_STD_PAL_G		| \
28 				 SDTV_STD_PAL_H		| \
29 				 SDTV_STD_PAL_I		| \
30 				 SDTV_STD_PAL_D		| \
31 				 SDTV_STD_PAL_D1	| \
32 				 SDTV_STD_PAL_K)
33 
34 #define SDTV_STD_PAL_M		0x00000100
35 #define SDTV_STD_PAL_N		0x00000200
36 #define SDTV_STD_PAL_Nc		0x00000400
37 #define SDTV_STD_PAL_60		0x00000800
38 
39 #define SDTV_STD_NTSC_M		0x00001000	/* BTSC */
40 #define SDTV_STD_NTSC_M_JP	0x00002000	/* EIA-J */
41 #define SDTV_STD_NTSC_443	0x00004000
42 #define SDTV_STD_NTSC_M_KR	0x00008000	/* FM A2 */
43 
44 #define SDTV_STD_NTSC		(SDTV_STD_NTSC_M	| \
45 				 SDTV_STD_NTSC_M_JP	| \
46 				 SDTV_STD_NTSC_M_KR)
47 
48 #define SDTV_STD_SECAM_B	0x00010000
49 #define SDTV_STD_SECAM_D	0x00020000
50 #define SDTV_STD_SECAM_G	0x00040000
51 #define SDTV_STD_SECAM_H	0x00080000
52 #define SDTV_STD_SECAM_K	0x00100000
53 #define SDTV_STD_SECAM_K1	0x00200000
54 #define SDTV_STD_SECAM_L	0x00400000
55 #define SDTV_STD_SECAM_LC	0x00800000
56 
57 #define SDTV_STD_SECAM		(SDTV_STD_SECAM_B	| \
58 				 SDTV_STD_SECAM_D	| \
59 				 SDTV_STD_SECAM_G	| \
60 				 SDTV_STD_SECAM_H	| \
61 				 SDTV_STD_SECAM_K	| \
62 				 SDTV_STD_SECAM_K1	| \
63 				 SDTV_STD_SECAM_L	| \
64 				 SDTV_STD_SECAM_LC)
65 
66 /* Standards for Countries with 60Hz Line frequency */
67 #define SDTV_STD_525_60		(SDTV_STD_PAL_M		| \
68 				 SDTV_STD_PAL_60	| \
69 				 SDTV_STD_NTSC		| \
70 				 SDTV_STD_NTSC_443)
71 
72 /* Standards for Countries with 50Hz Line frequency */
73 #define SDTV_STD_625_50		(SDTV_STD_PAL		| \
74 				 SDTV_STD_PAL_N		| \
75 				 SDTV_STD_PAL_Nc	| \
76 				 SDTV_STD_SECAM)
77 
78 #endif /* _DT_BINDINGS_DISPLAY_SDTV_STDS_H */
79