[LEDE-DEV] cavium: Ignore MEM boot param when too small
John Crispin
john at phrozen.org
Thu Jun 9 06:03:35 PDT 2016
On 08/06/2016 15:49, Michał Osowiecki wrote:
> Cisco RV0XX u-boot sets MEM=2048 as boot param. We assume that at least
> 4MB (mem_alloc_size) of ram is needed to run linux on cavium boards, so
> if mem < 4M - ignore it and set default value
>
>
> Signed-off-by: Michał Osowiecki <michal.osowiecki at gmail.com>
>
Hi Michał,
how much memory does the board have ? maybe they just forgot the "<< 20"
part ?
John
> --- a/arch/mips/cavium-octeon/setup.c 2016-06-06 18:15:32.000000000 +0200
> +++ b/arch/mips/cavium-octeon/setup.c 2016-06-08 15:28:56.642919151 +0200
> @@ -941,6 +941,11 @@
> * to consistently work.
> */
> mem_alloc_size = 4 << 20;
> +
> + /* Ignore bootarg MEM <= 4MB */
> + if (MAX_MEMORY <= mem_alloc_size)
> + MAX_MEMORY = 512ull << 20;
> +
> if (mem_alloc_size > MAX_MEMORY)
> mem_alloc_size = MAX_MEMORY;
>
>
> _______________________________________________
> Lede-dev mailing list
> Lede-dev at lists.infradead.org
> http://lists.infradead.org/mailman/listinfo/lede-dev
More information about the Lede-dev
mailing list