Linus Torvalds wrote:
The old situation with SATA drivers that had if (iomem) writel(..) else outl(..)in the cases that needed it (and used hardcoded writel/outl in the cases that didn't) was an example of code that "in theory" is faster. But dammit, in practice that mattered not one whit, and what iomap() tries to do is to attack the _real_ problem we had in that area.Which had nothing what-so-ever to do with any branches.
And none of those issues are a factor at all in ath5k (which spawned this sub-discussion), or indeed many other drivers. The above code you cite is -generic-, hardware agnostic code.
Most new hardware is MMIO-only, making ioread32() only for drivers that care about legacy IO support, something that is being slowly phased out. e.g. legacy IDE, legacy 10/100 mbps ethernet NICs with the dual MMIO/PIO register spaces.
Jeff - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
- Follow-Ups:
- Re: [PATCH] Clarify pci_iomap() usage for MMIO-only devices
- From: Linus Torvalds <[email protected]>
- Re: [PATCH] Clarify pci_iomap() usage for MMIO-only devices
- References:
- [PATCH] Clarify pci_iomap() usage for MMIO-only devices
- From: "Luis R. Rodriguez" <[email protected]>
- Re: [PATCH] Clarify pci_iomap() usage for MMIO-only devices
- From: Alan Cox <[email protected]>
- Re: [PATCH] Clarify pci_iomap() usage for MMIO-only devices
- From: "Luis R. Rodriguez" <[email protected]>
- Re: [PATCH] Clarify pci_iomap() usage for MMIO-only devices
- From: Linus Torvalds <[email protected]>
- Re: [PATCH] Clarify pci_iomap() usage for MMIO-only devices
- From: "Luis R. Rodriguez" <[email protected]>
- Re: [PATCH] Clarify pci_iomap() usage for MMIO-only devices
- From: Linus Torvalds <[email protected]>
- Re: [PATCH] Clarify pci_iomap() usage for MMIO-only devices
- From: "Luis R. Rodriguez" <[email protected]>
- Re: [PATCH] Clarify pci_iomap() usage for MMIO-only devices
- From: Linus Torvalds <[email protected]>
- Re: [PATCH] Clarify pci_iomap() usage for MMIO-only devices
- From: "Luis R. Rodriguez" <[email protected]>
- Re: [PATCH] Clarify pci_iomap() usage for MMIO-only devices
- From: Linus Torvalds <[email protected]>
- [PATCH] Clarify pci_iomap() usage for MMIO-only devices
- Prev by Date: Re: bnx2 dirver's firmware images
- Next by Date: Re: [PATCH 3/3] Time to make CONFIG_PARAVIRT non-experimental.
- Previous by thread: Re: [PATCH] Clarify pci_iomap() usage for MMIO-only devices
- Next by thread: Re: [PATCH] Clarify pci_iomap() usage for MMIO-only devices
- Index(es):