porting and run the linux kernel on beaglebone black development board - linux

i have already compile the linux kernel with arm compiler for beaglebone black.comile the uboot. and also filesystem debian. Now i want to run my compiled linux kernel on beaglebone. how can i do it?which image file has to be port? and how? using sd card or using usb to serial ttl connector? please help me descriptively.thank you

This excellent page created by Robert C. Nelson, who also maintains the official images for Beagleboard, covers it in great descriptive detail, #exactsteps even.

Related

How are platform drivers managed in linux

Helo All,
I am trying to learn embedded linux.
Please provide clarity on below:
As DTB provides Board and SOC related information will it be sufficient to make sure correct drivers will be enabled?
How a correct driver will get selected and will it happen during build time or kernel runtime based on the DTB?
How are drivers for platform devices(UART, SPI, I2C etc) handled in Linux? I mean as different SOC's have different implementations(register and bit fields will be different) of these peripherals how a single driver will be able to handle both SOC's?
Is it sufficient to have well defined DTB about board and kernel to make Linux up and running on any platform.
Thanks,
Suraj

Picking ARM or x86 to boot from

I currently have a raspberry pi, and am using my sd card to boot into linux for on-the-go access. However, the sd card boots into an ubuntu x86 version, not ARM. I saw the tutorial on how to flash the sd card for a raspberry pi, but I was curious if there is a way to pick which OS with specific architecture to boot off of. Is there a way to choose whichever system you would like to boot from?
Your SD card currently allow you to boot on ubuntu x86. You just want to add the ability to boot on your RPi. This totally depends on the ability of the RPi. I can't find complete documentation on RPi processor (this is why I don't like RPi (and Broadcom)), but, according to some online documentation, the RPi boots on FAT32. Your PC is probably also able to boot on a FAT32-formated SD card.
So, if your SD card format fits RPi requirements, you may put your bootable ubuntu x86 and a RPi bootloader on the same SD card partition. RPi is baremetal ARM, so you may put anything you want in your bootloader, including looking for your kernel on FAT32 on SD card with any name you want. It is therefore possible to add your ARM bootloader, your ARM kernel, and an ARM ramfs on your SD card without interfering with the x86 related files. You may then add a partition on your SD card to put your ARM binaries (some will use the same name as the x86, such as bash or startx, and should not be put on the same location than x86 ones, to avoid conflicts), and share data partitions between x86 and ARM OS.

porting linux on bare board

Yesterday I faced with an interview. In interview he asked me for steps to porting Linux on new board.
My answer was,
cross-compile u-boot for board architecture.
cross-compile kernel, with selecting driver for peripherals connected to board.
cross-compile filesystem, and port all on board.
But Interviewer is not happy with this answer.
Can you please suggest me which point were I missed out?
Thanks in advance.
Porting steps -
Install a cross-development environment.
Setup the board and ensure that the serial port is working so we can print data through the serial port.
Download and install the Linux kernel, most of the porting work will be done at this level.
Add board specific code into the kernel tree.
Build a kernel image to run on the board
Test that early kernel printk is working
Get the real printk working with the serial console.
For a new board, a new board-specific directory should be added as well as support for interrupt handling, kernel timer services and mapping for memory areas.
Ethernet drivers are usually the next drivers to focus on as they enable setup of NFS root file system to get access to user utilities and applications.
Filesystem can be provided in different forms which are listed on LinuxFilesystem

Embedded Linux and device driver development

I plan to learn embedded linux and writing linux device drivers.
I need a dev board where I can,
Build and boot it with a linux distribution.
Write drivers for peripherals in the board.
(In future) Possible port Android to it
Can you suggest a dev kit to help me with this? Cost is not a bar - I am already familiar with linux at user space, I am willingly to spend to get better at the other side.
Thanks
James
How about a BeagleBoard (TI OMAP)? The Beagleboard has an active community and a lot of example projects, including an Android porting project. They're a few versions of Android behind the present day, but that should provide a starting point.
There is a new 25$ and 35$ option called Raspberry PI.
check this http://elinux.org/Android_on_OMAP
Google's Android on TI's ARM based OMAP SoCs / 2.6.23 Linux kernel
I think Armadeus project is for you. It is an open source project, that started in France and that is now expanding. The community is great and the number of peripherals is growing fast. Of course it is based on Linux.
A small company is building the boards. They are based on ARM9 and now ARM11. In the boards you also have a Xilinx FPGA, that open the doors for exciting experiments.
Hope this helps.
JCLL
Some cheap mini2440 linux board sounds like a good start. It can also run Android.
maybe you can have a Virtual Development Board, that is interesting.
Check also the OK6410 at http://www.arm9board.net, it is provided with Linux - 2.6.28 (2.6.36 in a quit near future) with all peripheral drivers and a basic Android system. You'll find it interesting and quit useful.

How to compile and install a Linux kernel into an ARM kit

I have an ARM kit beside me and a Linux kernel source code patched with Xenomai on my machine. I understand I can send data to the kit through an USB cable and a (windows-based, of course) software, but I'm stumped as to exactly what I should be sending that would make the kit run Linux.
(clarifications from comments: It is an Atmel AT91SAM9260-EK kit. It uses SAM-BA and SAM-PROG for the loading and unloading of data through either a serial or USB cable.)
I'd start with the ATM91SAM9 Linux software package from Atmel and follow the instructions.
Linky:
http://www.atmel.com/dyn/products/tools_card.asp?tool_id=4335
Otherwise, you need to get GCC setup with an ARM back end on a Linux box, build a Linux binary and then figure out how to load it on the devt board.
You might want to check out some cross compiler like OpenEmbedded which will help you compile the kernel for the ARM architecture.
i would suggest jtag and openOCD, then you just use the JTAG to place your filesystem and kernal image in the flash memory, in a place wear our bootloader can find it. you might have to change your bootloader.
another option is you might start up your micro, then insert a bootloading program into the RAM of the program then change the program counter to point at it.
that bootloading program can init the UART/USB then you have a host side program that transers the files. this method is very complicated and generally only good if you don't want to spend 100$ on a jtag (hint, buy a jtag they are useful)

Resources