[PATCH] powerpc: Add support to access the flash on SLOF based systems

Adrian Reber adrian at lisas.de
Thu Jan 15 02:56:02 EST 2009


On Mon, Jan 12, 2009 at 09:51:23AM -0600, Milton Miller wrote:
> Is SLOF just exposing the user image part of the flash device?  Or is it 
> the raw flash device?

SLOF is exposing the raw flash device.

> I need to keep this quick, but am intrested in a few more details.  My  
> first reaction is its yet another random misc-device, but I confess to  
> having written one for internal consumption.  But as a misc device it  
> will need to go through lkml review to be merged.

I had a look at mtd and it was pretty easy to get it to do the same
thing as my misc-device was doing with only 5 lines changed in
drivers/mtd/maps/physmap_of.c

So thanks for pointing me in that direction. What would be now the best
way to include the SLOF flash properly into the mtd driver?

Should I add additional code to physmap_of.c to detect the flash and
then use a hardcoded layout for the partition? Because SLOF is missing
all the necessary properties in the flash device node. Or should I add
the missing properties in prom_init.c in a fixup_device_tree_slof()
function? Both versions would lead to the same result but I am unsure
about which approach is the better one.

		Adrian



More information about the Linuxppc-dev mailing list