Commit 2e353c0
video: Kbuild: detect x1p42100-videocc.h at build time
The dt-bindings header <dt-bindings/clock/qcom,x1p42100-videocc.h>
is present in qcom-specific kernel trees (qcom-6.18, qcom-next) but
is not yet available in linux-yocto based trees (yocto-6.18,
yocto-next). A file-existence check cannot be replaced by a version
number because both kernel families share the same version.
Add a build-time probe in video/Kbuild that tests for the header
and, when found, passes -DMSM_VIDC_HAS_X1P42100_VIDEOCC=1 to compiler.
Guard the include of that header and the three clock-table entries
whose initialiser values (VIDEO_CC_MVS0C_CLK, VIDEO_CC_MVS0_CLK,
VIDEO_CC_MVS0_BSE_CLK) are defined exclusively by it with the same
macro.
Also guard the qcom,x1p42100-iris entry in msm_vidc_dt_match[] so
that the kernel does not associate the driver with the purwa device
at all on kernels where the header is absent.
Signed-off-by: Gourav Kumar <gouravk@qti.qualcomm.com>1 parent 19d02d4 commit 2e353c0
3 files changed
Lines changed: 16 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
4 | 4 | | |
5 | 5 | | |
6 | 6 | | |
| 7 | + | |
7 | 8 | | |
| 9 | + | |
8 | 10 | | |
9 | 11 | | |
10 | 12 | | |
| |||
1809 | 1811 | | |
1810 | 1812 | | |
1811 | 1813 | | |
| 1814 | + | |
1812 | 1815 | | |
1813 | 1816 | | |
1814 | 1817 | | |
1815 | 1818 | | |
1816 | 1819 | | |
| 1820 | + | |
1817 | 1821 | | |
1818 | 1822 | | |
1819 | 1823 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
172 | 172 | | |
173 | 173 | | |
174 | 174 | | |
| 175 | + | |
175 | 176 | | |
| 177 | + | |
176 | 178 | | |
177 | 179 | | |
178 | 180 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
3 | 7 | | |
4 | 8 | | |
5 | 9 | | |
| |||
9 | 13 | | |
10 | 14 | | |
11 | 15 | | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
12 | 22 | | |
13 | 23 | | |
14 | 24 | | |
| |||
0 commit comments