[PATCH 09/13] ARM: imx: Remove unused IO_ADDRESS() macros

Arnd Bergmann arnd at arndb.de
Tue Sep 29 09:21:43 EDT 2020


On Tue, Sep 29, 2020 at 3:11 PM Linus Walleij <linus.walleij at linaro.org> wrote:
> On Thu, Sep 17, 2020 at 9:16 AM Arnd Bergmann <arnd at arndb.de> wrote:
>
> > If all of the devices in here are now also mapped using of_iomap() or
> > ioremap(), then the iotables are not strictly needed any more, but most
> > of them are 1MB section sized, which helps slightly reduce TLB usage
> > compared to non-section ioremap() mappings, so we might want to
> > keep them anyway, possibly with the constants moved from the header
> > into the mm-imx??.c files.
> >
> > Adding Linus to Cc for further thoughts, as he was looking at the early
> > io mappings recently.
>
> There is early fixmap which I think should replace the iotables
> completely if we can, since it is generic kernel code. I was meaning
> to look into this "at some point".
>
> The early fixmap seems to be page (0x1000) based so the iotables
> might be more efficient if using 1MB sections but I doubt that it is
> worth it.

As far as I can tell, the 1MB section maps are the only reason
this exists, as all of them are actually ioremap()ed later on before
use.

I don't know if it makes a difference to real-world performance.
Note that there are only 64 TLB entries on ARM926, or 128 on
ARM1136, so avoiding the lookup/eviction at least theoretically
should be measurably faster.

       Arnd



More information about the linux-arm-kernel mailing list