I followed the Kernel customization guide to build a custom kernel with GadgetFS enabled in Menuconfig. Although I successfully built the kernel, I noticed that the changes I made are not reflected in the .config files. Below are the build logs:
The default path needs root permission, so yo may not build it with correct toolchain. May try to create another non-root-permission path to build it, and then copy to Linux_for_Tegra folder. And please build nvidia-oot along with upstream kernel.
I’m fairly new to this, so I hope I don’t say anything wrong. Are you suggesting that I should extract the BSP source code to a directory where I don’t need root permissions? Or do I need to move my cross-compiler, which I currently have located at:
I have attempted the first procedure you suggested, running it with sudo, but unfortunately, it did not resolve the issue, as I am still seeing the default settings in the configuration file. I will now try your other suggestion of placing the build in a non-root directory and building it there.
In the meantime, I have a few questions:
After building the kernel with custom menuconfig settings, is it necessary to flash the entire system, or is there an alternative way to avoid reflashing? In the future, if we need to enable additional options in menuconfig, reflashing might become a cumbersome process, especially considering the built environment would already be configured.
If reflashing is the only option, are there any additional steps beyond what’s mentioned in the documentation that we should be aware of when building and flashing the kernel?
I believe these questions would be helpful for beginners like myself.
Hi,
It is supposed to take effect by overwriting kernel image. Since you mention it doesn’t take effect, we suggest re-flash the whole system for a try.
Hello! As you suggested, I extracted the source code in the Downloads directory, specifically in the kernel_src folder, using the command:
tar xf kernel_src.tbz2
After that, I navigated to the source directory and ran:
./generic_rt_build.sh "enable"
Next, I entered the kernel_jammy_source directory and executed the make menuconfig command. I enabled gadgetfs as built-in and saved it to the .config file. Then, I returned to the source directory and set the CROSS_COMPILE environment variable as follows:
Hi,
As you suggested, I navigated to the ‘kernel_jammy_source’ directory and ran the ‘make defconfig’ command. After that, I enabled ‘gadgetfs’ in the ‘menuconfig’ and saved the changes to the ‘.config’ file.
Next, I executed the ‘savedefconfig’ command. I then built the kernel using the command: ‘make -j$(nproc)’.
After building, I replaced the kernel image in the ‘boot’ directory of the Orin Nano. However, upon rebooting the device, it did not reflect the updated configurations
Hi,
I just wanted to confirm my understanding. Are you saying that the GadgetFS config could have been deprecated in K5.15? and if that is the case why is the option available in the menuconfig?
Hi,
Yes, we suspect the config may b deprecated. Other customizations in the elinux page work by following the developer guide. A bit strange this config does not work as expected.
Hi,
After booting the kernel image with default configuration, we enabled gadgetfs and rebuilt the kernel. The device booted up with new custom kernel image and gadgetfs has been installed as a module and then loaded it to the kernel using modprobe, As you can see in the images below. however we were unable to mount it. could you please suggest me how to mount gadgetfs?
I am using jetson orin nano(jetpack 6)