On 9/17/07, Jiri Slaby <jirislaby@xxxxxxxxx> wrote: > On 09/17/2007 10:34 PM, Luis R. Rodriguez wrote: > > Based on advise from Jeff, as described in the e-mail: > > > > [PATCH] Clarify pci_iomap() usage for MMIO-only devices > > > > we shouldn't use ioread32()/iowrite32() unless we really have a need > > to otherwise we're creating an unnecessary branch on read/write. Lets > > revert this back to readl()/writel() as our devices so far have been > > MMIO-only. This reverts 9202ec15da36ca060722c363575e0e390d85fb71 on > > ath5k. This patch is intended for the ath5k branch of wireless-dev. > > > > Changes-licensed-under: ISC > > Singed-off-by: Luis R. Rodriguez <mcgrof@xxxxxxxxx> > > > > --- > > > > drivers/net/wireless/ath5k_hw.c | 4 ++-- > > 1 files changed, 2 insertions(+), 2 deletions(-) > > > > diff --git a/drivers/net/wireless/ath5k_hw.c b/drivers/net/wireless/ath5k_hw.c > > index 07ad127..3501b4c 100644 > > --- a/drivers/net/wireless/ath5k_hw.c > > +++ b/drivers/net/wireless/ath5k_hw.c > > @@ -219,7 +219,7 @@ static inline unsigned int > > ath5k_hw_clocktoh(unsigned int clock, bool turbo) > > */ > > static inline u32 ath5k_hw_reg_read(struct ath_hw *hal, u16 reg) > > { > > - return ioread32(hal->ah_sh + reg); > > + return readl(hal->ah_sh + reg); > > } > > > > /* > > @@ -227,7 +227,7 @@ static inline u32 ath5k_hw_reg_read(struct ath_hw > > *hal, u16 reg) > > */ > > static inline void ath5k_hw_reg_write(struct ath_hw *hal, u32 val, u16 reg) > > { > > - iowrite32(val, hal->ah_sh + reg); > > + writel(val, hal->ah_sh + reg); > > } > > > > /* > > > > NACK, this is wrong. iomap returns platform dependant return value, which may or > may not correspond to what is accepted by readX/writeX. (but is 100% accepted by > ioreadXX/iowriteXX). Actually it does work 100% of the times if all we have is MMIO-only devices and hence the change. I've asked around and checked some of my really old Atheros cards and can't find any using PIO. Are you aware of any Atheros card using PIO? Luis - To unsubscribe from this list: send the line "unsubscribe linux-wireless" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html