public inbox for linux-mtd@lists.infradead.org
 help / color / mirror / Atom feed
* [Question] m25p80 driver versus spi clock rate
@ 2009-06-22 20:50 Steven A. Falco
  2009-06-22 21:04 ` Mike Frysinger
  0 siblings, 1 reply; 15+ messages in thread
From: Steven A. Falco @ 2009-06-22 20:50 UTC (permalink / raw)
  To: linux-mtd

I am trying to figure out how the mtd/devices/m25p80.c driver is supposed
to set the spi clock speed.  (Perhaps I'm making a bad assuption even to
think that it _should_ set the clock speed.  If so, please say so.)

I have three spi devices on a ppc400epx: two m25p16 chips and one Atmel
AVR uP.  The Atmel is handled from user-space, via spidev.  I am setting
the spi_ioc_transfer "speed_hz" parameter, and I see spidev change the
clock rate as I would expect.

However, m25p80.c doesn't seem to touch the clock rate.  Perhaps this is
because the PPC440epx uses "open firmware" device trees to specify the
speed and the m25p80 driver is not an OF driver.  Or as I said above,
perhaps the m25p80 driver isn't even supposed to set the clock rate.

The Atmel we are using cannot have its spi bus run faster than 250 KHz,
while the m25p16 devices can run up to 75 MHz (although the PPC440epx
tops out at 16.6 MHz).  So it is essential that I flip the clock rate
back and forth to maximize performance of the m25p16's while allowing
the Atmel to work.

So, if someone could comment on how the clock speed should be set, I
would appreciate it.  Clearly, I can put in a hack, but I'd rather
follow the existing intent.

	Thanks,
	Steve

^ permalink raw reply	[flat|nested] 15+ messages in thread

end of thread, other threads:[~2009-06-24 16:15 UTC | newest]

Thread overview: 15+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-06-22 20:50 [Question] m25p80 driver versus spi clock rate Steven A. Falco
2009-06-22 21:04 ` Mike Frysinger
2009-06-23 18:41   ` Steven A. Falco
2009-06-23 18:46     ` Mike Frysinger
2009-06-23 19:56       ` David Brownell
2009-06-23 20:31         ` Steven A. Falco
2009-06-23 21:08           ` David Brownell
2009-06-23 21:49             ` Steven A. Falco
2009-06-23 22:38               ` David Brownell
2009-06-24 14:25                 ` Steven A. Falco
2009-06-24 14:33                   ` Stefan Roese
2009-06-24 14:36                     ` Steven A. Falco
2009-06-24 14:50                       ` Stefan Roese
2009-06-24 15:13                   ` David Brownell
2009-06-24 16:14                     ` Steven A. Falco

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox