Take the 2-minute tour ×
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems.. It's 100% free, no registration required.

I placed the uBoot loader and the kernel into the raw flash image. This does not contain any root file system. (I copied uBoot and kernel image using dd command to a flash image).

Now i have to change my kernel as to start my application at a particular address which was located in my flash image.

How can I change the kernel to start my application on its own?

share|improve this question

migrated from stackoverflow.com Mar 23 '11 at 12:51

This question came from our site for professional and enthusiast programmers.

    
Your question is a bit unclear. Are you asking how to load an executable from the raw flash after the kernel has booted, or how to boot the kernel from the raw flash? –  ultrasawblade Mar 23 '11 at 15:34
add comment

1 Answer 1

I think you're going to need to have a filesystem on that flash, or else modify the kernel. You'll need to mount that as your root fs, and then pass the path to your program as a kernel parameter — init=/bin/yourbinary.

share|improve this answer
    
The problem is i don't have file system in my flash. I have to invoke the application directly from the kernel –  user5998 Mar 24 '11 at 3:22
1  
Unless you are trying to execute your application from the flash (ie, not copy it into ram) it may be simplest to use a file system rather than try to figure out how to go without. If you are planning to execute from flash, realize this will be substantially slower than ram unless you can stay in the processor cache almost all of the time. –  Chris Stratton Mar 26 '11 at 14:54
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.