lkml.org 
[lkml]   [2022]   [Aug]   [28]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH v2 07/11] openrisc: mm: Convert to GENERIC_IOREMAP
On 08/21/22 at 12:03am, Christoph Hellwig wrote:
> > + if (unlikely(!mem_init_done)) {
> > if ((fixmaps_used + (size >> PAGE_SHIFT)) > FIX_N_IOREMAPS)
> > + return IOMEM_ERR_PTR(ret);
> > v = fix_to_virt(FIX_IOREMAP_BEGIN + fixmaps_used);
> > fixmaps_used += (size >> PAGE_SHIFT);
> >
> > + if (ioremap_page_range(v, v + size, p, __pgprot(*prot_val))) {
> > fixmaps_used -= (size >> PAGE_SHIFT);
> > + return IOMEM_ERR_PTR(ret);
> > + }
> > +
> > + return (void __iomem *)(offset + (char *)v);
> > }
>
> This code needs to go away, and all very early boot uses of ioremap
> need to switch to use early_ioremap insted.

Makes sense. On openrisc, the thing is I didn't find one place where
ioremap() is called in arch code. I can cut the early ioremap out and
wrap into a separate early_ioremap() function, however I don't know
where to put it. Not sure if I miss anything or openrisc doesn't really
need early ioremap.

\
 
 \ /
  Last update: 2022-08-29 03:41    [W:0.139 / U:1.816 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site