[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20210325095529.GA5775@alpha.franken.de>
Date: Thu, 25 Mar 2021 10:55:29 +0100
From: Thomas Bogendoerfer <tsbogend@...ha.franken.de>
To: Ilya Lipnitskiy <ilya.lipnitskiy@...il.com>
Cc: Matthias Brugger <matthias.bgg@...il.com>,
John Crispin <john@...ozen.org>,
Chuanhong Guo <gch981213@...il.com>,
Jiaxun Yang <jiaxun.yang@...goat.com>,
linux-mips@...r.kernel.org, linux-arm-kernel@...ts.infradead.org,
linux-mediatek@...ts.infradead.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH] MIPS: ralink: mt7621: add memory detection support
On Tue, Mar 16, 2021 at 10:59:02PM -0700, Ilya Lipnitskiy wrote:
> From: Chuanhong Guo <gch981213@...il.com>
>
> mt7621 has the following memory map:
> 0x0-0x1c000000: lower 448m memory
> 0x1c000000-0x2000000: peripheral registers
> 0x20000000-0x2400000: higher 64m memory
>
> detect_memory_region in arch/mips/kernel/setup.c only adds the first
> memory region and isn't suitable for 512m memory detection because
> it may accidentally read the memory area for peripheral registers.
>
> This commit adds memory detection capability for mt7621:
> 1. Add the highmem area when 512m is detected.
> 2. Guard memcmp from accessing peripheral registers:
> This only happens when a user decided to change kernel load address
> to 256m or higher address. Since this is a quite unusual case, we
> just skip 512m testing and return 256m as memory size.
>
> [...]
I get
WARNING: modpost: vmlinux.o(.text+0x132c): Section mismatch in reference from the function prom_soc_init() to the function .init.text:mt7621_memory_detect()
The function prom_soc_init() references
the function __init mt7621_memory_detect().
This is often because prom_soc_init lacks a __init
annotation or the annotation of mt7621_memory_detect is wrong.
Can you please fix this ?
Thomas.
--
Crap can work. Given enough thrust pigs will fly, but it's not necessarily a
good idea. [ RFC1925, 2.3 ]
Powered by blists - more mailing lists