need to which version of linux code need to compile

Hi,

I am using BeagleBone Beagleboard Black (ARM Cortex A8, DDR3 Speicher, HDMI, USB 2.0) from amazon.

i flashed the image through image utitlity.

From the board i got below information.

cat /proc/version
Linux version 6.18.32-bone35 (voodoo@rpi4b4g-10) (gcc (Debian 14.2.0-19) 14.2.0, GNU ld (GNU Binutils for Debian) 2.44) #1 SMP PREEMPT Mon May 18 22:16:45 UTC 2026
manoj@beagle:~$
manoj@beagle:~$
manoj@beagle:~$
manoj@beagle:~$ grep uname_r /boot/uEnv.tx
grep: /boot/uEnv.tx: No such file or directory
manoj@beagle:~$
manoj@beagle:~$ grep uname_r /boot/uEnv.txt
uname_r=6.18.32-bone35
manoj@beagle:~$
manoj@beagle:~$
manoj@beagle:~$ ls /lib/modules
6.18.32-bone35

my main aim want to flash compiled linux kernal image. So i tried to checkout the below

But i am not able to find exact version.

I taken the below version

uname_r=6.12.34-g9e419b26243b

but system is not booting.

may i know what exact version i should take. can you please help me.

thanks,

6.18.32-bone35 is tagged here: Release 6.18.32-bone35 Ā· RobertCNelson/linux-stable-rcn-ee Ā· GitHub

Regards,

Hi robertCNelson,

thanks for your reply.

For compilation do we have any documentation like how to compile the code.

can i use the below commands to compile the code.

previous time i worked for autosar etc stuff. So now i want to learn linux.

please help me,

make ARCH=arm CROSS_COMPILE=arm-linux-gnueabihf- omap2plus_defconfig

make ARCH=arm CROSS_COMPILE=arm-linux-gnueabihf- LOADADDR=0x80000000 -j$(nproc) modules

Drop the loadaddr, add zImage target along with dtbs

1 Like

Hi Robert,

Thanks,

make ARCH=arm CROSS_COMPILE=arm-linux-gnueabihf- -j$(nproc) zImage dtbs modules

able to see beagleblack/linux-stable-rcn-ee-6.18.32-bone35/arch/arm/boot/ in this folder Image and zImage.

for checking purpose i used bb imager to flash 6.18 deb package from bb image utility. Board boots.

my sd card looks like this.

sda                         8:0    1 119.1G  0 disk
ā”œā”€sda1                      8:1    1    36M  0 part /media/msudagoni/BOOT
ā”œā”€sda2                      8:2    1   512M  0 part
└─sda3                      8:3    1 118.6G  0 part /mnt/beaglebonerootfs
/media/msudagoni/rootfs

mnt/beaglebonerootfs$ ls -la
total 88
drwxr-xr-x 19 root root  4096 May 19 16:49 .
drwxr-xr-x  9 root root  4096 Jul  9 13:42 ..
lrwxrwxrwx  1 root root     7 May 19 16:15 bin → usr/bin
drwxr-xr-x  4 root root  4096 Jul  9 13:51 boot
drwxr-xr-x  4 root root  4096 May 19 16:15 dev
drwxr-xr-x 86 root root  4096 May 19 16:50 etc
drwxr-xr-x  3 root root  4096 May 19 16:49 functions
drwxr-xr-x  3 root root  4096 May 19 16:50 home
lrwxrwxrwx  1 root root     7 May 19 16:15 lib → usr/lib
drwx------  2 root root 16384 May 19 16:49 lost+found
drwxr-xr-x  2 root root  4096 May 19 16:15 media
drwxr-xr-x  2 root root  4096 May 19 16:15 mnt
drwxr-xr-x  4 root root  4096 May 19 16:48 opt
drwxr-xr-x  2 root root  4096 May  8 16:15 proc
drwx------  3 root root  4096 May 19 16:19 root
drwxr-xr-x  2 root root  4096 May  8 16:15 run
lrwxrwxrwx  1 root root     8 May 19 16:15 sbin → usr/sbin
drwxr-xr-x  2 root root  4096 May 19 16:15 srv
drwxr-xr-x  2 root root  4096 May  8 16:15 sys
drwxrwxrwt 10 root root  4096 May 19 16:49 tmp
drwxr-xr-x 11 root root  4096 May 19 16:15 usr
drwxr-xr-x 12 root root  4096 Aug  7  2024 var

went to boot folder

ls -la
total 39728
drwxr-xr-x  4 root    root       4096 Jul  9 13:51 .
drwxr-xr-x 19 root    root       4096 May 19 16:49 ..
-rw-r–r--  1 root    root     216977 May 18 20:37 config-6.18.32-bone35
drwxr-xr-x  3 root    root       4096 Jul  9 13:58 dtbs
drwxr-xr-x  2 root    root       4096 May 19 16:49 firmware
-rwxr-xr-x  1 root    root   18992048 Jul  9 13:49 Image
-rw-r–r--  1 root    root    9271180 May 19 16:47 initrd.img-6.18.32-bone35
-rw-r–r--  1 root    root        549 May 19 16:50 SOC.sh
-rw-r–r--  1 root    root    5767195 May 18 20:37 System.map-6.18.32-bone35
-rw-r–r--  1 ridvith ubuntu     2078 Jul  9 13:51 uEnv.txt
-rwxr-xr-x  1 root    root    9101824 May 18 20:37 vmlinuz-6.18.32-bone35

copied Image to boot folder.

/mnt/beaglebonerootfs/boot$ ls -la
total 39728
drwxr-xr-x  4 root    root       4096 Jul  9 13:51 .
drwxr-xr-x 19 root    root       4096 May 19 16:49 ..
-rw-r–r--  1 root    root     216977 May 18 20:37 config-6.18.32-bone35
drwxr-xr-x  3 root    root       4096 Jul  9 13:58 dtbs
drwxr-xr-x  2 root    root       4096 May 19 16:49 firmware
-rwxr-xr-x  1 root    root   18992048 Jul  9 13:49 Image
-rw-r–r--  1 root    root    9271180 May 19 16:47 initrd.img-6.18.32-bone35
-rw-r–r--  1 root    root        549 May 19 16:50 SOC.sh
-rw-r–r--  1 root    root    5767195 May 18 20:37 System.map-6.18.32-bone35
-rw-r–r--  1 ridvith ubuntu     2078 Jul  9 13:51 uEnv.txt
-rwxr-xr-x  1 root    root    9101824 May 18 20:37 vmlinuz-6.18.32-bone35
msudagoni@BB3443585839:/mnt/beaglebonerootfs/boot$

My UEnv.txt file looks like below:

#Docs: http://elinux.org/Beagleboard:U-boot_partitioning_layout_2.0

#uname_r=6.18.32-bone35
uname_r=Image
#uuid=
#dtb=

###U-Boot Overlays###
###Documentation: http://elinux.org/Beagleboard:BeagleBoneBlack_Debian#U-Boot_Overlays
###Master Enable
enable_uboot_overlays=1

### 

###Overide capes with eeprom
#uboot_overlay_addr0=.dtbo
#uboot_overlay_addr1=.dtbo
#uboot_overlay_addr2=.dtbo
#uboot_overlay_addr3=.dtbo

### 

###Additional custom capes
#uboot_overlay_addr4=.dtbo
#uboot_overlay_addr5=.dtbo
#uboot_overlay_addr6=.dtbo
#uboot_overlay_addr7=.dtbo

### 

###Custom Cape
#dtb_overlay=.dtbo

### 

###Disable auto loading of virtual capes (emmc/video/wireless/adc)
#disable_uboot_overlay_emmc=1
#disable_uboot_overlay_video=1
#disable_uboot_overlay_audio=1
#disable_uboot_overlay_wireless=1
#disable_uboot_overlay_adc=1

### 

###PRUSS OPTIONS
###pru_rproc (4.14.x-ti kernel)
#uboot_overlay_pru=AM335X-PRU-RPROC-4-14-TI-00A0.dtbo
###pru_rproc (4.19.x-ti kernel)
#uboot_overlay_pru=AM335X-PRU-RPROC-4-19-TI-00A0.dtbo
###pru_uio (4.14.x-ti, 4.19.x-ti & mainline/bone kernel)
uboot_overlay_pru=AM335X-PRU-UIO-00A0.dtbo

### 

\###Cape Universal Enable
#enable_uboot_cape_universal=1

### 

###Debug: disable uboot autoload of Cape
#disable_uboot_overlay_addr0=1
#disable_uboot_overlay_addr1=1
#disable_uboot_overlay_addr2=1
#disable_uboot_overlay_addr3=1

### 

###U-Boot fdt tweaks… (60000 = 384KB)
#uboot_fdt_buffer=0x60000
###U-Boot Overlays###

console=ttyS0,115200n8
cmdline=fsck.repair=yes earlycon coherent_pool=1M net.ifnames=0 lpj=1990656 rng_core.default_quality=100

#In the event of edid real failures, uncomment this next line:
#cmdline=fsck.repair=yes earlycon coherent_pool=1M net.ifnames=0 lpj=1990656 rng_core.default_quality=100 video=HDMI-A-1:1024x768@60e

#Use an overlayfs on top of a read-only root filesystem:
#cmdline=fsck.repair=yes earlycon coherent_pool=1M net.ifnames=0 lpj=1990656 rng_core.default_quality=100 overlayroot=tmpfs

##enable Generic eMMC Flasher:
#cmdline=init=/usr/sbin/init-beagle-flasher

But still board is not booting. can you please help here.

please share the usb serial boot log over j6 header..

Regards,

Hi, please find the serial log.

U-Boot SPL 2022.04-gc6f4cf7d (Apr 24 2025 - 03:22:59 +0000)
Trying to boot from MMC2

U-Boot 2022.04-gc6f4cf7d (Apr 24 2025 - 03:22:59 +0000)

CPU  : AM335X-GP rev 2.1
Model: TI AM335x BeagleBone Black
DRAM:  512 MiB
Reset Source: Global external warm reset has occurred.
Reset Source: Power-on reset has occurred.
RTC 32KCLK Source: External.
Core:  150 devices, 14 uclasses, devicetree: separate
WDT:   Started wdt@44e35000 with servicing (60s timeout)
MMC:   OMAP SD/MMC: 0, OMAP SD/MMC: 1
Loading Environment from EXT4…
\*\* Unable to use mmc 0:1 for loading the env \*\*
Board: BeagleBone Black
 not set. Validating first E-fuse MAC
BeagleBone Black:
BeagleBone Cape EEPROM: no EEPROM at address: 0x54
BeagleBone Cape EEPROM: no EEPROM at address: 0x55
BeagleBone Cape EEPROM: no EEPROM at address: 0x56
BeagleBone Cape EEPROM: no EEPROM at address: 0x57
Net:   eth2: ethernet@4a100000, eth3: usb_ether
Press SPACE to abort autoboot in 0 seconds
board_name=\[A335BNLT\] …
board_rev=\[00D0\] …
switch to partitions #0, OK
mmc0 is current device
SD/MMC found on device 0
Couldn’t find partition 0:2 0x82000000
Can’t set block device
Couldn’t find partition 0:2 0x82000000
Can’t set block device
switch to partitions #0, OK
mmc0 is current device
Scanning mmc 0:1…
libfdt fdt_check_header(): FDT_ERR_BADMAGIC
Scanning disk mmc@48060000.blk…
Scanning disk mmc@481d8000.blk…
Found 8 disks
No EFI system partition
BootOrder not defined
EFI boot manager: Cannot load any image
gpio: pin 56 (gpio 56) value is 0
gpio: pin 55 (gpio 55) value is 0
gpio: pin 54 (gpio 54) value is 0
gpio: pin 53 (gpio 53) value is 1
switch to partitions #0, OK
mmc0 is current device
gpio: pin 54 (gpio 54) value is 1
Checking for: /uEnv.txt …
Checking for: /boot/uEnv.txt …
gpio: pin 55 (gpio 55) value is 1
2078 bytes read in 3 ms (675.8 KiB/s)
Loaded environment from /boot/uEnv.txt
Checking if uname_r is set in /boot/uEnv.txt…
gpio: pin 56 (gpio 56) value is 1
Running uname_boot …
\*\* Invalid partition 4 \*\*
Couldn’t find partition mmc 0:4
\*\* Invalid partition 5 \*\*
Couldn’t find partition mmc 0:5
\*\* Invalid partition 6 \*\*
Couldn’t find partition mmc 0:6
\*\* Invalid partition 7 \*\*
Couldn’t find partition mmc 0:7
switch to partitions #0, OK
mmc1(part 0) is current device
Scanning mmc 1:1…
libfdt fdt_check_header(): FDT_ERR_BADMAGIC
BootOrder not defined
EFI boot manager: Cannot load any image
gpio: pin 56 (gpio 56) value is 0
gpio: pin 55 (gpio 55) value is 0
gpio: pin 54 (gpio 54) value is 0
gpio: pin 53 (gpio 53) value is 1
switch to partitions #0, OK
mmc1(part 0) is current device
gpio: pin 54 (gpio 54) value is 1
Checking for: /uEnv.txt …
Checking for: /boot/uEnv.txt …
gpio: pin 55 (gpio 55) value is 1
2038 bytes read in 2 ms (995.1 KiB/s)
Loaded environment from /boot/uEnv.txt
Checking if uname_r is set in /boot/uEnv.txt…
gpio: pin 56 (gpio 56) value is 1
Running uname_boot …                                                                    ±----------------------------+
loading /boot/vmlinuz-6.12.34-g9e419b26243b …                                           |                             |
5370384 bytes read in 341 ms (15 MiB/s)                                                   |  Cannot open /dev/ttyUSB0!  |
debug: \[enable_uboot_overlays=1\] …                                                      |                             |
debug: \[enable_uboot_cape_universal=\] …                                                 ±----------------------------+
debug: \[uboot_base_dtb_univ=am335x-boneblack-uboot.dtb\] …
uboot_overlays: \[uboot_base_dtb=am335x-boneblack-uboot.dtb\] …

unable to find \[dtb=am335x-boneblack-revd.dtb\] did you name it correctly? …

## Error: ā€œfailumsbootā€ not defined

Found 0 extension board(s).
uboot_overlays: \[fdt_buffer=0x60000\] …
uboot_overlays: unable to find \[mmc 1:3 BB-ADC-00A0.dtbo\]…
uboot_overlays: unable to find \[mmc 1:3 BB-BONE-eMMC1-01-00A0.dtbo\]…
uboot_overlays: unable to find \[mmc 1:3 BB-HDMI-TDA998x-00A0.dtbo\]…
uboot_overlays: unable to find \[mmc 1:3 AM335X-PRU-UIO-00A0.dtbo\]…
debug: \[console=ttyS0,115200n8 root=/dev/mmcblk1p3 ro rootfstype=ext4 rootwait coherent_pool=1M net.ifnames=0 lpj=1990656 rng_core.default_quality=100 quiet\] …
debug: \[bootz 0x82000000 - 0x88000000\] …
Kernel image @ 0x82000000 \[ 0x000000 - 0x51f210 \]
ERROR: Did not find a cmdline Flattened Device Tree
Could not find a valid device tree
\*\* Invalid partition 4 \*\*
Couldn’t find partition mmc 1:4
\*\* Invalid partition 5 \*\*
Couldn’t find partition mmc 1:5
\*\* Invalid partition 6 \*\*
Couldn’t find partition mmc 1:6
\*\* Invalid partition 7 \*\*
Couldn’t find partition mmc 1:7
starting USB…

USB is stopped. Please issue ā€˜usb start’ first.
starting USB…
Bus usb@47401800: Port not available.
ethernet@4a100000 Waiting for PHY auto negotiation to complete… TIMEOUT !
using musb-hdrc, OUT ep1out IN ep1in STATUS ep2in
MAC de:ad:be:ef:00:01
HOST MAC de:ad:be:ef:00:00
RNDIS ready
musb-hdrc: peripheral reset irq lost!
high speed config #2: 2 mA, Ethernet Gadget, using RNDIS
USB RNDIS network up!
BOOTP broadcast 1
BOOTP broadcast 2

This variable will fail when set like this..

Here’s the logic it understands.. Making sure you're not a bot!

These are the names it looks for:

rootfs: / (ext2/ext3/ext4) (btrfs supported in u-boot v2018.03+ (with both compression options))
/boot/uEnv.txt (priority 4)
/boot/vmlinuz-$(uname -r)
/boot/initrd.img-$(uname -r) (optional, but needed for uuid cases)
/boot/dtbs/$(uname -r)/*.dtb (or one of the 7 locations below)

and disable:

#enable_uboot_overlays=1

till you get everything in the correct spot and booting..

Regards

Hi robert,

It works fine. thanks for your help.