drivers/video/Kconfig:27: can’t open file “drivers/video/tegra/Kconfig”
Did you follow the document to compile the kernel?
https://docs.nvidia.com/jetson/archives/r35.1/DeveloperGuide/text/SD/Kernel/KernelCustomization.html
Hello,
I am facing a similar issue in compiling kernel with my own set of commands:
I populated the sources with the below command:
./source_sync.sh -k jetson_35.1
Compiling:
$ make ARCH=arm64 CROSS_COMPILE=<toolchain>/bin/aarch64-buildroot-linux-gnu- -C sources/kernel/kernel-5.10/ -o $PWD/kernel_out/ tegra_defconfig
make: Entering directory '<PATH>/Linux_for_Tegra/sources/kernel/kernel-5.10'
HOSTCC scripts/basic/fixdep
HOSTCC scripts/kconfig/conf.o
HOSTCC scripts/kconfig/confdata.o
HOSTCC scripts/kconfig/expr.o
LEX scripts/kconfig/lexer.lex.c
YACC scripts/kconfig/parser.tab.[ch]
HOSTCC scripts/kconfig/lexer.lex.o
HOSTCC scripts/kconfig/parser.tab.o
HOSTCC scripts/kconfig/preprocess.o
HOSTCC scripts/kconfig/symbol.o
HOSTCC scripts/kconfig/util.o
HOSTLD scripts/kconfig/conf
drivers/video/Kconfig:27: can't open file "drivers/video/tegra/Kconfig"
make[1]: *** [scripts/kconfig/Makefile:89: tegra_defconfig] Error 1
make: *** [Makefile:633: tegra_defconfig] Error 2
make: Leaving directory '<PATH>/Linux_for_Tegra/sources/kernel/kernel-5.10'
The problem comes from:
$ grep -rn “drivers/video/tegra/Kconfig” sources/kernel/
sources/kernel/kernel-5.10/drivers/video/Kconfig:27:source “drivers/video/tegra/Kconfig”
But there is no directory named ‘tegra’
$ ls -l sources/kernel/kernel-5.10/drivers/video/tegra
ls: cannot access ‘sources/kernel/kernel-5.10/drivers/video/tegra’: No such file or directory
Please follow the document to compile the kernel. I just verify without problem.
Thanks
We are encountering a similar issue. It seems what is being pulled by source_sync.sh
is missing the aforementioned files. They are however included in the public_sources.tbz2
kernel sources (kernel_src.tbz2
archive). Manually copying the contents of kernel/nvidia/
to the matching directory pulled by source_sync.sh
is our workaround.
Upon looking into it further, this just seems to be an issue with the ordering of SOURCE_INFO
elements in source_sync.sh
.
Specifically, since nv-tegra.nvidia.com/kernel/nvethernetrm.git
is cloned prior to nv-tegra.nvidia.com/linux-nvidia.git
, git obviously refuses to clone linux-nvidia
into a non-empty directory. The easiest solution is to just patch source_sync.sh
such that linux-nvidia.git
is cloned prior to the other repositories that will be entailed within it:
@@ -59,9 +59,9 @@ SCRIPT_NAME=`basename $0`
# NOTE: *Add only kernel repos here. Add new repos separately below. Keep related repos together*
SOURCE_INFO="
k:kernel/kernel-5.10:nv-tegra.nvidia.com/linux-5.10.git:
-k:kernel/nvidia/drivers/net/ethernet/nvidia/nvethernet/nvethernetrm:nv-tegra.nvidia.com/kernel/nvethernetrm.git:
k:kernel/nvgpu:nv-tegra.nvidia.com/linux-nvgpu.git:
k:kernel/nvidia:nv-tegra.nvidia.com/linux-nvidia.git:
+k:kernel/nvidia/drivers/net/ethernet/nvidia/nvethernet/nvethernetrm:nv-tegra.nvidia.com/kernel/nvethernetrm.git:
k:hardware/nvidia/platform/tegra/common:nv-tegra.nvidia.com/device/hardware/nvidia/platform/tegra/common.git:
k:hardware/nvidia/soc/t19x:nv-tegra.nvidia.com/device/hardware/nvidia/soc/t19x.git:
k:hardware/nvidia/platform/t19x/common:nv-tegra.nvidia.com/device/hardware/nvidia/platform/t19x/common.git:
Alternatively, cd into nvidia
directory, then:
git init
git remote add origin git://nv-tegra.nvidia.com/linux-nvidia.git
git fetch --depth=1 origin jetson_35.1
git checkout FETCH_HEAD
Have a try this file to sync the source or download the public.tbz2 from download center.
source_sync.sh (11.0 KB)
nvbuild.sh (3.7 KB)
This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.