无法在Jetson Nano上构建内核4.9

时间:2020-03-21 20:54:47

标签: kernel nvidia-jetson-nano

我正在尝试在Jetson Nano上构建Kernel 4.9,但是出现以下错误消息:

在包含的文件中 ...... / kernel-4.9 / include / asm-generic / bug.h:13:0, 来自...... / kernel-4.9 / arch / arm64 / include / asm / bug.h:67, 来自...... / kernel-4.9 / include / linux / bug.h:4, 来自...... / kernel-4.9 / arch / arm64 / include / asm / cmpxchg.h:21, 来自...... / kernel-4.9 / arch / arm64 / include / asm / atomic.h:41, 来自...... / kernel-4.9 / include / linux / atomic.h:4, 来自...... / nvidia / drivers / media / platform / tegra / camera / vi / channel.c:13: ...... / nvidia / drivers / media / platform / tegra / camera / vi / channel.c:在 函数“ tegra_channel_s_parm”: ...... / kernel-4.9 / include / linux / kernel.h:838:48:错误:初始化 来自不兼容的指针类型[-Werror = incompatible-pointer-types]
const typeof((((type *)0)-> member)* __ mptr =(ptr); \ ^ ...... / nvidia / include / media / mc_common.h:265:2:注意:在扩展 宏“ container_of” container_of(vdev,struct tegra_channel,视频) ^ ~~~~~~~~~~~~ ...... / nvidia / drivers / media / platform / tegra / camera / vi / channel.c:2029:37: 注意:扩展宏“ to_tegra_channel” struct tegra_channel * chan = to_tegra_channel(vfh-> vdev); ^ ~~~~~~~~~~~~~~~ ...... / kernel-4.9 / include / linux / kernel.h:838:48:注意:(附近 初始化“ chan”)const typeof((((type *)0)-> member) * __ mptr =(ptr); \ ^ ...... / nvidia / include / media / mc_common.h:265:2:注意:在扩展 宏“ container_of” container_of(vdev,struct tegra_channel,视频) ^ ~~~~~~~~~~~~ ...... / nvidia / drivers / media / platform / tegra / camera / vi / channel.c:2029:37: 注意:扩展宏“ to_tegra_channel” struct tegra_channel * chan = to_tegra_channel(vfh-> vdev); ^ ~~~~~~~~~~~~~~~ ...... / nvidia / drivers / media / platform / tegra / camera / vi / channel.c:在 函数“ tegra_channel_g_parm”: ...... / kernel-4.9 / include / linux / kernel.h:838:48:错误:初始化 来自不兼容的指针类型[-Werror = incompatible-pointer-types]
const typeof((((type *)0)-> member)* __ mptr =(ptr); \ ^ ...... / nvidia / include / media / mc_common.h:265:2:注意:在扩展 宏“ container_of” container_of(vdev,struct tegra_channel,视频) ^ ~~~~~~~~~~~~ ...... / nvidia / drivers / media / platform / tegra / camera / vi / channel.c:2039:37: 注意:扩展宏“ to_tegra_channel” struct tegra_channel * chan = to_tegra_channel(vfh-> vdev); ^ ~~~~~~~~~~~~~~~ ...... / kernel-4.9 / include / linux / kernel.h:838:48:注意:(附近 初始化“ chan”)const typeof((((type *)0)-> member) * __ mptr =(ptr); \ ^ ...... / nvidia / include / media / mc_common.h:265:2:注意:在扩展 宏“ container_of” container_of(vdev,struct tegra_channel,视频) ^ ~~~~~~~~~~~~ ...... / nvidia / drivers / media / platform / tegra / camera / vi / channel.c:2039:37: 注意:扩展宏“ to_tegra_channel” struct tegra_channel chan = to_tegra_channel(vfh-> vdev); ^ ~~~~~~~~~~~~~~~ LD驱动程序/媒体/平台/tegra-vivid/built-in.o CC
驱动程序/媒体/平台/积分/相机/camera_gpio.o cc1:所有警告 被视为错误...... / kernel-4.9 / scripts / Makefile.build:335: 目标“驱动程序/媒体/平台/集成/相机/vi/channel.o”的配方 失败的制作[7]:
[drivers / media / platform / tegra / camera / vi / channel.o] 错误1 ...... / kernel-4.9 / scripts / Makefile.build:649:配方 目标'drivers / media / platform / tegra / camera / vi'失败[6]: [drivers / media / platform / tegra / camera / vi]错误2使[6]: 等待中 用于未完成的工作.... CC
驱动程序/媒体/平台/积分/音乐/mipi_cal.o ...... / kernel-4.9 / scripts / Makefile.build:649:目标配方 '驱动程序/媒体/平台/积分/相机'失败[5]:
[drivers / media / platform / tegra / camera]错误2出现[5]: 未完成的工作...... CC
驱动程序/媒体/平台/积分/音乐/vmipi/vmipi.o LD
驱动程序/媒体/平台/集成/mipical/built-in.o ...... / kernel-4.9 / scripts / Makefile.build:649:目标配方 'drivers / media / platform / tegra'失败的make [4]:
[驱动程序/媒体/平台/集成]错误2 ...... / kernel-4.9 / scripts / Makefile.build:649:目标配方 '驱动程序/媒体/平台'失败[3]: [驱动程序/媒体/平台] 错误2 ...... / kernel-4.9 / scripts / Makefile.build:649:配方 目标'驱动程序/媒体'失败make [2]: [驱动程序/媒体]错误2 ...... // kernel-4.9 / Makefile:1104:目标'驱动程序'的配方失败 make [1]: [驱动程序]错误2 make [1]:* 等待未完成 jobs .... make [1]:离开目录'.......... / kernel_out' Makefile:171:目标“ Sub-make”的配方失败:*** [sub-make] 错误2

文件 ...... / kernel-4.9 / include / linux / kernel.h 中的第838行是:

 837 #define container_of(ptr, type, member) ({          \
 838     const typeof( ((type *)0)->member ) *__mptr = (ptr);    \
 839     (type *)( (char *)__mptr - offsetof(type,member) );})

我的编译器是gcc / g ++ 7.5.0。

➜  kernel-4.9 gcc --version
gcc (Ubuntu/Linaro 7.5.0-3ubuntu1~18.04) 7.5.0
Copyright (C) 2017 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

➜  kernel-4.9 g++ --version
g++ (Ubuntu/Linaro 7.5.0-3ubuntu1~18.04) 7.5.0
Copyright (C) 2017 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

有人可以帮我吗?

欢呼 裴

0 个答案:

没有答案