[PATCH 3/4] ARM: change vmalloc_min to vmalloc_start

Russell King (Oracle) linux at armlinux.org.uk
Thu May 20 02:00:24 PDT 2021


On Wed, May 19, 2021 at 12:41:10PM +0800, Xu, Yanfei wrote:
> On 5/18/21 8:15 PM, Russell King (Oracle) wrote:
> > -static unsigned long __initdata vmalloc_min =
> > -       VMALLOC_END - (240 << 20) - VMALLOC_OFFSET;
> > +static unsigned long __initdata vmalloc_start = VMALLOC_END - (240 << 20);
> > 
> >   /*
> >    * vmalloc=size forces the vmalloc area to be exactly 'size'
> > @@ -1169,7 +1168,8 @@ void __init adjust_lowmem_bounds(void)
> >           * and may itself be outside the valid range for which phys_addr_t
> >           * and therefore __pa() is defined.
> >           */
> > -       vmalloc_limit = (u64)vmalloc_min - PAGE_OFFSET + PHYS_OFFSET;
> > +       vmalloc_limit = (u64)vmalloc_start -
> > +                       (PAGE_OFFSET + PHYS_OFFSET + VMALLOC_OFFSET);
> > 
> Here is bug, it should be
> 
>        vmalloc_limit = (u64)vmalloc_start -
>                        (PAGE_OFFSET + VMALLOC_OFFSET) + PHYS_OFFSET;

Yes, you're absolutely right, thanks for catching that!

-- 
RMK's Patch system: https://www.armlinux.org.uk/developer/patches/
FTTP is here! 40Mbps down 10Mbps up. Decent connectivity at last!



More information about the linux-arm-kernel mailing list