SAMA5D3 Xplained buildroot-at91 console support

Go To Last Post
3 posts / 0 new
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

I need to do a 3.10 kernel build for this board to test some SDIO hardware for our own variant.  We use buildroot and I'm hoping to continue to do that for the tests I need to run.


It took a little twisting to find the right versions of tools and git commits needed, but I got the build working, using 


  • linux-at91: make ARCH=arm sama5d3_xplained_defconfig
  • buildroot-at91: make ARCH=arm atmel_sama5d3_xplained_defconfig


buildroot created a rootfs.ubi file and a zImage kernel, which seems to be what sam-ba wants.  I created the .dtb file in the linux-at91 directory with


  • make ARCH=arm dtbs


which made at91-sama5d3_xplained.dtb.


All of that looked good, but after programming it with sam-ba and rebooting, the blue light stayed on for a couple seconds and went dark.  I didn't get a Linux prompt from my connection to USB-A.


I have a debug port serial cable on order and I'm hoping that gives me some clues on what might be going on, but shouldn't those defconfig files have just worked?  Did I need to do something extra to get the same USB-A console that I get with the yocto-poky binaries?  I tried the latest master sources without changing any defaults and got the same results.  


Thanks for reading.

Last Edited: Fri. Apr 6, 2018 - 02:25 PM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

The debug port made a huge difference.  My rootfs format / placement is way off:



NET: Registered protocol family 17                                             
can: controller area network core (rev 20120528 abi 9)                         
NET: Registered protocol family 29                                             
can: raw protocol (rev 20120528)                                               
can: broadcast manager protocol (rev 20120528 t)                               
can: netlink gateway (rev 20130117) max_hops=1                                 
ubi0: attaching mtd7                                                           
ubi0: scanning is finished                                                     
ubi0 error: ubi_read_volume_table: the layout volume was not found             
ubi0 error: ubi_attach_mtd_dev: failed to attach mtd7, error -22               
UBI error: cannot attach mtd7                                                  
input: gpio_keys as /devices/soc0/gpio_keys/input/input0                       
at91_rtc fffffeb0.rtc: setting system clock to 2007-01-01 01:19:50 UTC (1167614)
ALSA device list:                                                              
  No soundcards found.                                                         
UBIFS error (pid: 1): cannot open "ubi0:rootfs", error -19VFS: Cannot open root9
Please append a correct "root=" boot option; here are the available partitions:
0100            8192 ram0  (driver?)                                           
0101            8192 ram1  (driver?)                                           
0102            8192 ram2  (driver?)                                           
0103            8192 ram3  (driver?)                                           
1f00             256 mtdblock0  (driver?)                                      
1f01             512 mtdblock1  (driver?)                                      
1f02             256 mtdblock2  (driver?)                                      
1f03             256 mtdblock3  (driver?)                                      
1f04             256 mtdblock4  (driver?)                                      
1f05             512 mtdblock5  (driver?)                                      
1f06            6144 mtdblock6  (driver?)                                      
1f07          253952 mtdblock7  (driver?)                                      
Kernel panic - not syncing: VFS: Unable to mount root fs on unknown-block(0,0) 
CPU: 0 PID: 1 Comm: swapper Not tainted 4.1.0-linux4sam_5.3 #1                 
Hardware name: Atmel SAMA5                                                     
[<c0013e84>] (unwind_backtrace) from [<c0011da8>] (show_stack+0x10/0x14)       
[<c0011da8>] (show_stack) from [<c04b9cec>] (panic+0x88/0x1dc)                 
[<c04b9cec>] (panic) from [<c067914c>] (mount_block_root+0x1c0/0x25c)          
[<c067914c>] (mount_block_root) from [<c067948c>] (prepare_namespace+0xa8/0x1d8)
[<c067948c>] (prepare_namespace) from [<c0678de8>] (kernel_init_freeable+0x1b0/)
[<c0678de8>] (kernel_init_freeable) from [<c04b8d0c>] (kernel_init+0x8/0xe8)   
[<c04b8d0c>] (kernel_init) from [<c000f2c8>] (ret_from_fork+0x14/0x2c)         
---[ end Kernel panic - not syncing: VFS: Unable to mount root fs on unknown-bl)
random: nonblocking pool is initialized                        


I was hoping I would find the right CONFIGs to change in the buildroot .config file (through menuconfig).  My builds finish, and I'm updating all of the files used by the sam-ba scripts (at91boot, u-boot, .dtb, kernel, and rootfs). But all of my many attempts end up looking like the run shown above. 


So I still have the same issue, but with more insight.  What's missing from my config that's keeping this from working, and are there instructions out there somewhere that work?

Last Edited: Sat. Apr 7, 2018 - 02:41 PM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

... ah, mark the UBI file option and use the .ubi file instead of the .ubifs file.  I hope that helps someone.