Hello all,

Not entirely sure if this is the "right" place to post this, but here
goes...

I want to take in kernel command arguments from a bootloader made by
logicpd on the M5329 called Lolo.  This kernel command arguments would
configure the video frame buffer characteristics (i.e. hsync, vsync,
pixel clock, etc.). The problem is that when I specify the command line
arguments in Lolo they don't get passed to the kernel. I have found the
documentation for the exec command and here is what it says: 

                                 Quote:
                          The ‘exec’ Command 
The ‘exec’ command is an assembly-level jump to the starting instruction
 of a program that will pass in three arguments. If ‘exec’ is executed
without a parameter, LogicLoader will jump to the program start address
of the last program loaded to system RAM (if any) and pass in a pointer
 to an empty string. If both an address and command line are specified,
the ‘exec’ command will jump to the specified address and pass a pointer
     to the command line provided. The ‘exec’ command will disable
 interrupts, the cache, and the MMU (if present) prior to executing the
jump. The ‘exec’ command passes the command line argument via a pointer
     to memory that has been allocated from LogicLoader’s heap. Any
 application or OS code must preserve the command line, or finish using
the command line arguments, before reclaiming LogicLoader’s memory space
for its own use. Because the ‘exec’ command shuts off the MMU, the image
 must have a virtual address that maps directly to its physical address
 since the entry address that ‘exec’ jumps to will always be a physical
     address. This example may be used when writing a function that
                       LogicLoader will exec to: 
                                    
    int my_exec_function(unsigned int arg1, unsigned int arg2, char
                             *cmd_string); 
                                    
The first two arguments have fixed values for legacy reasons: arg1 = 0,
and arg2 = 997. The third argument will be a pointer to the command line
                          as described above. 
                                    

So what I thought I would have to do is change the function that gets
called on kernel start to have the signature called out by this exec
command. After digging through the kernel, I thought that asm_linkage
void __init start_kernel(void) in /init/main.c is the function that I
need to change. So I changed it and my image will no longer boot. Where
is good place to start if I want to change to entry point of the kernel?
I really have little experience doing assembly (only assembly I have
done was in college like four years ago) and I am rather confused on how
to get parameters in an assembly routine.  Is there some code in
the /arch/m68knommu/kernel/entry.S that calls the start_kernel function?
Has anyone had any luck dealing with something like this?  
_______________________________________________
uClinux-dev mailing list
[email protected]
http://mailman.uclinux.org/mailman/listinfo/uclinux-dev
This message was resent by [email protected]
To unsubscribe see:
http://mailman.uclinux.org/mailman/options/uclinux-dev

Reply via email to