gentoo-sources kernel not seeing 4G ram

classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

gentoo-sources kernel not seeing 4G ram

William Kenworthy
Hi, not sure anyone can help with this as its a bit off the reservation :)

I have a Odroid N2 with 4G ram that is only seeing 1G. (even from right
at boot looking at dmesg).  Its part of the board so its not a connector
issue.

Kernel is gentoo-sources-5.4.8 with the AMLOGIC armv8 relevant bits
copied from the 4.9 series original hardkernel sources.  OS is gentoo
AARCH64.  This all built and runs quite nicely, but cant see the full 4G
ram that should be there.

Ive attached my latest kernel config in the hope that someone can see
something Ive missed (presuming it isn't an inherent problem in the way
I have gone about this) - looking at the config, diffing it against the
hardkernel source etc. hasn't helped.  Below is the start of dmesg up to
the memory statement.

My next move will be to go back to the 4.9 supplied kernel and make sure
it isn't hardware failure (unlikely, but ...)

BillK

[    0.000000] Booting Linux on physical CPU 0x0000000000 [0x410fd034]
[    0.000000] Linux version 5.4.8-gentoo (root@n2) (gcc version 9.2.0
(Gentoo 9.2.0-r2 p3)) #1 SMP PREEMPT Thu Jan 9 08:36:20 AWST 2020
[    0.000000] Machine model: Hardkernel ODROID-N2
[    0.000000] efi: Getting EFI parameters from FDT:
[    0.000000] efi: UEFI not found.
[    0.000000] Reserved memory: created CMA memory pool at
0x0000000030000000, size 256 MiB
[    0.000000] OF: reserved mem: initialized node linux,cma, compatible
id shared-dma-pool
[    0.000000] NUMA: No NUMA configuration found
[    0.000000] NUMA: Faking a node at [mem
0x0000000000000000-0x000000003fffffff]
[    0.000000] NUMA: NODE_DATA [mem 0x2fdb6800-0x2fdb7fff]
[    0.000000] Zone ranges:
[    0.000000]   DMA32    [mem 0x0000000000000000-0x000000003fffffff]
[    0.000000]   Normal   empty
[    0.000000] Movable zone start for each node
[    0.000000] Early memory node ranges
[    0.000000]   node   0: [mem 0x0000000000000000-0x0000000004ffffff]
[    0.000000]   node   0: [mem 0x0000000005300000-0x000000003fffffff]
[    0.000000] Initmem setup node 0 [mem
0x0000000000000000-0x000000003fffffff]
[    0.000000] On node 0 totalpages: 261376
[    0.000000]   DMA32 zone: 4096 pages used for memmap
[    0.000000]   DMA32 zone: 0 pages reserved
[    0.000000]   DMA32 zone: 261376 pages, LIFO batch:63
[    0.000000] psci: probing for conduit method from DT.
[    0.000000] psci: PSCIv1.0 detected in firmware.
[    0.000000] psci: Using standard PSCI v0.2 function IDs
[    0.000000] psci: MIGRATE_INFO_TYPE not supported.
[    0.000000] psci: SMC Calling Convention v1.1
[    0.000000] percpu: Embedded 22 pages/cpu s52632 r8192 d29288 u90112
[    0.000000] pcpu-alloc: s52632 r8192 d29288 u90112 alloc=22*4096
[    0.000000] pcpu-alloc: [0] 0 [0] 1 [0] 2 [0] 3 [0] 4 [0] 5
[    0.000000] Detected VIPT I-cache on CPU0
[    0.000000] CPU features: detected: ARM erratum 845719
[    0.000000] Built 1 zonelists, mobility grouping on.  Total pages: 257280
[    0.000000] Policy zone: DMA32
[    0.000000] Kernel command line: root=/dev/mmcblk0p2 rootwait rw
console=ttyAML0,115200n8  no_console_suspend fsck.repair=yes
net.ifnames=0 elevator=noop hdmimode=1080p60hz cvbsmode=576cvbs
max_freq_a53=1896 max_freq_a73=1800 maxcpus=6 voutmode=hdmi 
disablehpd=false cvbscable=0 overscan=100  monitor_onoff=false
usb-xhci.tablesize=2 logo=osd0,loaded
[    0.000000] Dentry cache hash table entries: 131072 (order: 8,
1048576 bytes, linear)
[    0.000000] Inode-cache hash table entries: 65536 (order: 7, 524288
bytes, linear)
[    0.000000] mem auto-init: stack:off, heap alloc:off, heap free:off
[    0.000000] Memory: 748756K/1045504K available (7932K kernel code,
728K rwdata, 2784K rodata, 1856K init, 403K bss, 34604K reserved,
262144K cma-reserved)
[    0.000000] SLUB: HWalign=64, Order=0-3, MinObjects=0, CPUs=6, Nodes=1
[    0.000000] rcu: Preemptible hierarchical RCU implementation.
[    0.000000] rcu:     RCU restricting CPUs from NR_CPUS=256 to
nr_cpu_ids=6.


config (171K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

RE: gentoo-sources kernel not seeing 4G ram

Raffaele BELARDI
No experience on this, but looks like it can be done with the patched mainline kernel:
https://forum.odroid.com/viewtopic.php?t=33993

Just for my understanding, gentoo-sources does not contain all the drivers needed by this board so you are trying to copy those from the 'hardkernel' sources, correct?

Raffaele

> -----Original Message-----
> From: Bill Kenworthy <[hidden email]>
> Sent: Thursday, January 9, 2020 02:50
> To: [hidden email]
> Subject: [gentoo-user] gentoo-sources kernel not seeing 4G ram
>
> Hi, not sure anyone can help with this as its a bit off the reservation :)
>
> I have a Odroid N2 with 4G ram that is only seeing 1G. (even from right at
> boot looking at dmesg).  Its part of the board so its not a connector issue.
>
> Kernel is gentoo-sources-5.4.8 with the AMLOGIC armv8 relevant bits copied
> from the 4.9 series original hardkernel sources.  OS is gentoo AARCH64.  This
> all built and runs quite nicely, but cant see the full 4G ram that should be
> there.
>
> Ive attached my latest kernel config in the hope that someone can see
> something Ive missed (presuming it isn't an inherent problem in the way I
> have gone about this) - looking at the config, diffing it against the hardkernel
> source etc. hasn't helped.  Below is the start of dmesg up to the memory
> statement.
>
> My next move will be to go back to the 4.9 supplied kernel and make sure it
> isn't hardware failure (unlikely, but ...)
>
> BillK
>
> [    0.000000] Booting Linux on physical CPU 0x0000000000 [0x410fd034]
> [    0.000000] Linux version 5.4.8-gentoo (root@n2) (gcc version 9.2.0 (Gentoo
> 9.2.0-r2 p3)) #1 SMP PREEMPT Thu Jan 9 08:36:20 AWST 2020 [    0.000000]
> Machine model: Hardkernel ODROID-N2 [    0.000000] efi: Getting EFI
> parameters from FDT:
> [    0.000000] efi: UEFI not found.
> [    0.000000] Reserved memory: created CMA memory pool at
> 0x0000000030000000, size 256 MiB [    0.000000] OF: reserved mem: initialized
> node linux,cma, compatible id shared-dma-pool [    0.000000] NUMA: No
> NUMA configuration found [    0.000000] NUMA: Faking a node at [mem
> 0x0000000000000000-0x000000003fffffff]
> [    0.000000] NUMA: NODE_DATA [mem 0x2fdb6800-0x2fdb7fff] [    0.000000]
> Zone ranges:
> [    0.000000]   DMA32    [mem 0x0000000000000000-0x000000003fffffff]
> [    0.000000]   Normal   empty
> [    0.000000] Movable zone start for each node [    0.000000] Early memory
> node ranges [    0.000000]   node   0: [mem 0x0000000000000000-
> 0x0000000004ffffff]
> [    0.000000]   node   0: [mem 0x0000000005300000-0x000000003fffffff]
> [    0.000000] Initmem setup node 0 [mem 0x0000000000000000-
> 0x000000003fffffff]
> [    0.000000] On node 0 totalpages: 261376 [    0.000000]   DMA32 zone: 4096
> pages used for memmap [    0.000000]   DMA32 zone: 0 pages reserved
> [    0.000000]   DMA32 zone: 261376 pages, LIFO batch:63 [    0.000000] psci:
> probing for conduit method from DT.
> [    0.000000] psci: PSCIv1.0 detected in firmware.
> [    0.000000] psci: Using standard PSCI v0.2 function IDs [    0.000000] psci:
> MIGRATE_INFO_TYPE not supported.
> [    0.000000] psci: SMC Calling Convention v1.1 [    0.000000] percpu:
> Embedded 22 pages/cpu s52632 r8192 d29288 u90112 [    0.000000] pcpu-alloc:
> s52632 r8192 d29288 u90112 alloc=22*4096 [    0.000000] pcpu-alloc: [0] 0 [0] 1
> [0] 2 [0] 3 [0] 4 [0] 5 [    0.000000] Detected VIPT I-cache on CPU0 [    0.000000]
> CPU features: detected: ARM erratum 845719 [    0.000000] Built 1 zonelists,
> mobility grouping on.  Total pages: 257280 [    0.000000] Policy zone: DMA32
> [    0.000000] Kernel command line: root=/dev/mmcblk0p2 rootwait rw
> console=ttyAML0,115200n8  no_console_suspend fsck.repair=yes
> net.ifnames=0 elevator=noop hdmimode=1080p60hz cvbsmode=576cvbs
> max_freq_a53=1896 max_freq_a73=1800 maxcpus=6 voutmode=hdmi
> disablehpd=false cvbscable=0 overscan=100  monitor_onoff=false
> usb-xhci.tablesize=2 logo=osd0,loaded
> [    0.000000] Dentry cache hash table entries: 131072 (order: 8,
> 1048576 bytes, linear)
> [    0.000000] Inode-cache hash table entries: 65536 (order: 7, 524288 bytes,
> linear) [    0.000000] mem auto-init: stack:off, heap alloc:off, heap free:off
> [    0.000000] Memory: 748756K/1045504K available (7932K kernel code, 728K
> rwdata, 2784K rodata, 1856K init, 403K bss, 34604K reserved, 262144K cma-
> reserved) [    0.000000] SLUB: HWalign=64, Order=0-3, MinObjects=0,
> CPUs=6, Nodes=1 [    0.000000] rcu: Preemptible hierarchical RCU
> implementation.
> [    0.000000] rcu:     RCU restricting CPUs from NR_CPUS=256 to
> nr_cpu_ids=6.

Reply | Threaded
Open this post in threaded view
|

Re: gentoo-sources kernel not seeing 4G ram

William Kenworthy
Hi Rafael, fixed thanks to the link you gave - needed  apatch to a dts
file that limited thge memory available.

So I now have a heavily patched mainline based (gentoo-sources) kernel
with gentoo aarch64/openrc userland running on the n2 as a headless
server for 6 x lxc containers for network infrastructure!

Nice,
BillK

On 9/1/20 3:34 pm, Raffaele BELARDI wrote:

> No experience on this, but looks like it can be done with the patched mainline kernel:
> https://forum.odroid.com/viewtopic.php?t=33993
>
> Just for my understanding, gentoo-sources does not contain all the drivers needed by this board so you are trying to copy those from the 'hardkernel' sources, correct?
>
> Raffaele
>
>> -----Original Message-----
>> From: Bill Kenworthy <[hidden email]>
>> Sent: Thursday, January 9, 2020 02:50
>> To: [hidden email]
>> Subject: [gentoo-user] gentoo-sources kernel not seeing 4G ram
>>
>> Hi, not sure anyone can help with this as its a bit off the reservation :)
>>
>> I have a Odroid N2 with 4G ram that is only seeing 1G. (even from right at
>> boot looking at dmesg).  Its part of the board so its not a connector issue.
>>
>> Kernel is gentoo-sources-5.4.8 with the AMLOGIC armv8 relevant bits copied
>> from the 4.9 series original hardkernel sources.  OS is gentoo AARCH64.  This
>> all built and runs quite nicely, but cant see the full 4G ram that should be
>> there.
>>
>> Ive attached my latest kernel config in the hope that someone can see
>> something Ive missed (presuming it isn't an inherent problem in the way I
>> have gone about this) - looking at the config, diffing it against the hardkernel
>> source etc. hasn't helped.  Below is the start of dmesg up to the memory
>> statement.
>>
>> My next move will be to go back to the 4.9 supplied kernel and make sure it
>> isn't hardware failure (unlikely, but ...)
>>
>> BillK
>>
>> [    0.000000] Booting Linux on physical CPU 0x0000000000 [0x410fd034]
>> [    0.000000] Linux version 5.4.8-gentoo (root@n2) (gcc version 9.2.0 (Gentoo
>> 9.2.0-r2 p3)) #1 SMP PREEMPT Thu Jan 9 08:36:20 AWST 2020 [    0.000000]
>> Machine model: Hardkernel ODROID-N2 [    0.000000] efi: Getting EFI
>> parameters from FDT:
>> [    0.000000] efi: UEFI not found.
>> [    0.000000] Reserved memory: created CMA memory pool at
>> 0x0000000030000000, size 256 MiB [    0.000000] OF: reserved mem: initialized
>> node linux,cma, compatible id shared-dma-pool [    0.000000] NUMA: No
>> NUMA configuration found [    0.000000] NUMA: Faking a node at [mem
>> 0x0000000000000000-0x000000003fffffff]
>> [    0.000000] NUMA: NODE_DATA [mem 0x2fdb6800-0x2fdb7fff] [    0.000000]
>> Zone ranges:
>> [    0.000000]   DMA32    [mem 0x0000000000000000-0x000000003fffffff]
>> [    0.000000]   Normal   empty
>> [    0.000000] Movable zone start for each node [    0.000000] Early memory
>> node ranges [    0.000000]   node   0: [mem 0x0000000000000000-
>> 0x0000000004ffffff]
>> [    0.000000]   node   0: [mem 0x0000000005300000-0x000000003fffffff]
>> [    0.000000] Initmem setup node 0 [mem 0x0000000000000000-
>> 0x000000003fffffff]
>> [    0.000000] On node 0 totalpages: 261376 [    0.000000]   DMA32 zone: 4096
>> pages used for memmap [    0.000000]   DMA32 zone: 0 pages reserved
>> [    0.000000]   DMA32 zone: 261376 pages, LIFO batch:63 [    0.000000] psci:
>> probing for conduit method from DT.
>> [    0.000000] psci: PSCIv1.0 detected in firmware.
>> [    0.000000] psci: Using standard PSCI v0.2 function IDs [    0.000000] psci:
>> MIGRATE_INFO_TYPE not supported.
>> [    0.000000] psci: SMC Calling Convention v1.1 [    0.000000] percpu:
>> Embedded 22 pages/cpu s52632 r8192 d29288 u90112 [    0.000000] pcpu-alloc:
>> s52632 r8192 d29288 u90112 alloc=22*4096 [    0.000000] pcpu-alloc: [0] 0 [0] 1
>> [0] 2 [0] 3 [0] 4 [0] 5 [    0.000000] Detected VIPT I-cache on CPU0 [    0.000000]
>> CPU features: detected: ARM erratum 845719 [    0.000000] Built 1 zonelists,
>> mobility grouping on.  Total pages: 257280 [    0.000000] Policy zone: DMA32
>> [    0.000000] Kernel command line: root=/dev/mmcblk0p2 rootwait rw
>> console=ttyAML0,115200n8  no_console_suspend fsck.repair=yes
>> net.ifnames=0 elevator=noop hdmimode=1080p60hz cvbsmode=576cvbs
>> max_freq_a53=1896 max_freq_a73=1800 maxcpus=6 voutmode=hdmi
>> disablehpd=false cvbscable=0 overscan=100  monitor_onoff=false
>> usb-xhci.tablesize=2 logo=osd0,loaded
>> [    0.000000] Dentry cache hash table entries: 131072 (order: 8,
>> 1048576 bytes, linear)
>> [    0.000000] Inode-cache hash table entries: 65536 (order: 7, 524288 bytes,
>> linear) [    0.000000] mem auto-init: stack:off, heap alloc:off, heap free:off
>> [    0.000000] Memory: 748756K/1045504K available (7932K kernel code, 728K
>> rwdata, 2784K rodata, 1856K init, 403K bss, 34604K reserved, 262144K cma-
>> reserved) [    0.000000] SLUB: HWalign=64, Order=0-3, MinObjects=0,
>> CPUs=6, Nodes=1 [    0.000000] rcu: Preemptible hierarchical RCU
>> implementation.
>> [    0.000000] rcu:     RCU restricting CPUs from NR_CPUS=256 to
>> nr_cpu_ids=6.



Reply | Threaded
Open this post in threaded view
|

Re: gentoo-sources kernel not seeing 4G ram

james-3
On 1/11/20 7:38 PM, Bill Kenworthy wrote:
> Hi Rafael, fixed thanks to the link you gave - needed� apatch to a dts
> file that limited thge memory available.
>
> So I now have a heavily patched mainline based (gentoo-sources) kernel
> with gentoo aarch64/openrc userland running on the n2 as a headless
> server for 6 x lxc containers for network infrastructure!
>
> Nice,
> BillK

Hello Bill,

Very, very cool. Take a look at this page and see if you want to
contribute, so others may follow your (gentoo) footsteps::

https://wiki.gentoo.org/wiki/Odroid_N2

and

https://wiki.gentoo.org/wiki/Embedded_systems/ARM_hardware_list


ODROID-N2 Georgy Yakovlev (GYakovlev)
        ARMv8 Amlogic S922X - 4xA73@1.8GHz, 2xA53@1.9GHz, GPU: Mali G52@846MHz
        2G or 4G @DDR4@1320MHz


Any more specific input on that link would be greatly appreciated and
encourage others to be companion gentoo users.....

I know it's on my short list, once I get my new/expanded lab cleaned up
a bit more.... The coolest thing is 36" x 18" open-wire racks on
wheels...... just for such projects.

hth,


James




>
> On 9/1/20 3:34 pm, Raffaele BELARDI wrote:
>> No experience on this, but looks like it can be done with the patched
>> mainline kernel:
>> https://forum.odroid.com/viewtopic.php?t=33993
>>
>> Just for my understanding, gentoo-sources does not contain all the
>> drivers needed by this board so you are trying to copy those from the
>> 'hardkernel' sources, correct?
>>
>> Raffaele
>>
>>> -----Original Message-----
>>> From: Bill Kenworthy <[hidden email]>
>>> Sent: Thursday, January 9, 2020 02:50
>>> To: [hidden email]
>>> Subject: [gentoo-user] gentoo-sources kernel not seeing 4G ram
>>>
>>> Hi, not sure anyone can help with this as its a bit off the
>>> reservation :)
>>>
>>> I have a Odroid N2 with 4G ram that is only seeing 1G. (even from
>>> right at
>>> boot looking at dmesg).� Its part of the board so its not a connector
>>> issue.
>>>
>>> Kernel is gentoo-sources-5.4.8 with the AMLOGIC armv8 relevant bits
>>> copied
>>> from the 4.9 series original hardkernel sources.� OS is gentoo
>>> AARCH64.� This
>>> all built and runs quite nicely, but cant see the full 4G ram that
>>> should be
>>> there.
>>>
>>> Ive attached my latest kernel config in the hope that someone can see
>>> something Ive missed (presuming it isn't an inherent problem in the
>>> way I
>>> have gone about this) - looking at the config, diffing it against the
>>> hardkernel
>>> source etc. hasn't helped.� Below is the start of dmesg up to the memory
>>> statement.
>>>
>>> My next move will be to go back to the 4.9 supplied kernel and make
>>> sure it
>>> isn't hardware failure (unlikely, but ...)
>>>
>>> BillK
>>>
>>> [��� 0.000000] Booting Linux on physical CPU 0x0000000000 [0x410fd034]
>>> [��� 0.000000] Linux version 5.4.8-gentoo (root@n2) (gcc version
>>> 9.2.0 (Gentoo
>>> 9.2.0-r2 p3)) #1 SMP PREEMPT Thu Jan 9 08:36:20 AWST 2020 [��� 0.000000]
>>> Machine model: Hardkernel ODROID-N2 [��� 0.000000] efi: Getting EFI
>>> parameters from FDT:
>>> [��� 0.000000] efi: UEFI not found.
>>> [��� 0.000000] Reserved memory: created CMA memory pool at
>>> 0x0000000030000000, size 256 MiB [��� 0.000000] OF: reserved mem:
>>> initialized
>>> node linux,cma, compatible id shared-dma-pool [��� 0.000000] NUMA: No
>>> NUMA configuration found [��� 0.000000] NUMA: Faking a node at [mem
>>> 0x0000000000000000-0x000000003fffffff]
>>> [��� 0.000000] NUMA: NODE_DATA [mem 0x2fdb6800-0x2fdb7fff] [    
>>> 0.000000]
>>> Zone ranges:
>>> [��� 0.000000]�� DMA32��� [mem 0x0000000000000000-0x000000003fffffff]
>>> [��� 0.000000]�� Normal�� empty
>>> [��� 0.000000] Movable zone start for each node [��� 0.000000] Early
>>> memory
>>> node ranges [��� 0.000000]�� node�� 0: [mem 0x0000000000000000-
>>> 0x0000000004ffffff]
>>> [��� 0.000000]�� node�� 0: [mem 0x0000000005300000-0x000000003fffffff]
>>> [��� 0.000000] Initmem setup node 0 [mem 0x0000000000000000-
>>> 0x000000003fffffff]
>>> [��� 0.000000] On node 0 totalpages: 261376 [��� 0.000000]�� DMA32
>>> zone: 4096
>>> pages used for memmap [��� 0.000000]�� DMA32 zone: 0 pages reserved
>>> [��� 0.000000]�� DMA32 zone: 261376 pages, LIFO batch:63 [    
>>> 0.000000] psci:
>>> probing for conduit method from DT.
>>> [��� 0.000000] psci: PSCIv1.0 detected in firmware.
>>> [��� 0.000000] psci: Using standard PSCI v0.2 function IDs [    
>>> 0.000000] psci:
>>> MIGRATE_INFO_TYPE not supported.
>>> [��� 0.000000] psci: SMC Calling Convention v1.1 [��� 0.000000] percpu:
>>> Embedded 22 pages/cpu s52632 r8192 d29288 u90112 [��� 0.000000]
>>> pcpu-alloc:
>>> s52632 r8192 d29288 u90112 alloc=22*4096 [��� 0.000000] pcpu-alloc:
>>> [0] 0 [0] 1
>>> [0] 2 [0] 3 [0] 4 [0] 5 [��� 0.000000] Detected VIPT I-cache on CPU0
>>> [��� 0.000000]
>>> CPU features: detected: ARM erratum 845719 [��� 0.000000] Built 1
>>> zonelists,
>>> mobility grouping on.� Total pages: 257280 [��� 0.000000] Policy
>>> zone: DMA32
>>> [��� 0.000000] Kernel command line: root=/dev/mmcblk0p2 rootwait rw
>>> console=ttyAML0,115200n8� no_console_suspend fsck.repair=yes
>>> net.ifnames=0 elevator=noop hdmimode=1080p60hz cvbsmode=576cvbs
>>> max_freq_a53=1896 max_freq_a73=1800 maxcpus=6 voutmode=hdmi
>>> disablehpd=false cvbscable=0 overscan=100� monitor_onoff=false
>>> usb-xhci.tablesize=2 logo=osd0,loaded
>>> [��� 0.000000] Dentry cache hash table entries: 131072 (order: 8,
>>> 1048576 bytes, linear)
>>> [��� 0.000000] Inode-cache hash table entries: 65536 (order: 7,
>>> 524288 bytes,
>>> linear) [��� 0.000000] mem auto-init: stack:off, heap alloc:off, heap
>>> free:off
>>> [��� 0.000000] Memory: 748756K/1045504K available (7932K kernel code,
>>> 728K
>>> rwdata, 2784K rodata, 1856K init, 403K bss, 34604K reserved, 262144K
>>> cma-
>>> reserved) [��� 0.000000] SLUB: HWalign=64, Order=0-3, MinObjects=0,
>>> CPUs=6, Nodes=1 [��� 0.000000] rcu: Preemptible hierarchical RCU
>>> implementation.
>>> [��� 0.000000] rcu:���� RCU restricting CPUs from NR_CPUS=256 to
>>> nr_cpu_ids=6.
>
>
>