[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <5B8DA87D05A7694D9FA63FD143655C1B01E9DED6@HASMSX106.ger.corp.intel.com>
Date: Tue, 4 Dec 2012 15:28:23 +0000
From: "Winkler, Tomas" <tomas.winkler@...el.com>
To: Alan Cox <alan@...rguk.ukuu.org.uk>
CC: "gregkh@...uxfoundation.org" <gregkh@...uxfoundation.org>,
"arnd@...db.de" <arnd@...db.de>,
"alan@...ux.intel.com" <alan@...ux.intel.com>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
Stanislaw Gruszka <sgruszka@...hat.com>
Subject: RE: [char-misc-next 07/15] mei: use wrietl/readl instead of io
wrappers
> >
> > /**
> > @@ -451,7 +451,7 @@ static inline u32 mei_reg_read(const struct
> > mei_device *dev, static inline void mei_reg_write(const struct mei_device
> *dev,
> > unsigned long offset, u32 value) {
> > - iowrite32(value, dev->mem_addr + offset);
> > + writel(value, dev->mem_addr + offset);
>
> ioremap should match readl/writel
> iomap iowrite32/ioread32
Thanks, I can replace pci_iomap with pci_ioremap_bar although in low level it is doing just the same.
> so you need to tweak the map/unmap if you do this.
>
> As to overhead. I'd love to see a measurement that can detect the
> difference. Do you have a benchmark that shows it ?
Don't have any numbers but it seems reasonable to me.
I did following this example
commit 05f5b97ee0013fefbd9139cf8c3eda5f2a88c04a
Author: Stanislaw Gruszka <sgruszka@...hat.com>
Date: Wed Mar 7 09:52:26 2012 -0800
iwlwifi: use writeb,writel,readl directly
That change will save us some CPU cycles at run time. Having port-based
I/O seems to be not possible for PCIe devices.
Signed-off-by: Stanislaw Gruszka <sgruszka@...hat.com>
Thanks
Tomas
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists