[LinuxBIOS] [RFC] Use Linux MTD framework for SPI flash?

Peter Stuge peter at stuge.se
Fri Jul 27 01:43:12 CEST 2007

On Fri, Jul 27, 2007 at 12:49:10AM +0200, Carl-Daniel Hailfinger wrote:
> While thinking about adding SPI support to flashrom, I came across the
> directory linux/drivers/mtd/maps/ in a recent kernel tree and found
> drivers for flash on
> * Nvidia CK804
> * AMD 76X
> * Intel ICHx

These are at best generic, ie. there's no specific support for SPI in
them. Now, MTD does have a driver for some SST SPI chips, in

> Should we try to use the Linux MTD framework before hacking
> flashrom?

Worth a shot, but..

> If so, can somebody test? My machines either run too old kernels
> (production router) or the chipset doesn't appear in the list.

..there is only support for a few SPI masters in Linux.

An SPI driver for each chipset needs to be written before MTD
can talk to the flash. The same code has to be written for
flashrom anyway so it could just as well go to both places.

But, trouble comes if some of the chipsets aren't really generic
SPI masters but rather specialized for SPI flash. I seem to remember
reading some PDF (ICH7/8?) where the southbridge SPI interface wasn't
completely generic. :\


More information about the coreboot mailing list