This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

DM816x

Hi guys, i'm using the dm816x development board. I try to allocate a memory region in ddr3 at location 0xC0000000 and ioremap it. After i insmod the driver, i can get the result but it show some warning here.It seen like related to the ioremap... Can anyone help me?Thank you.

Done allocated Logram Memory
Done allocated Buffer Memory
BUG: Your driver calls ioremap() on system memory. This leads
to architecturally unpredictable behaviour on ARMv6+, and ioremap()
will fail in the next kernel release. Please fix your driver.
------------[ cut here ]------------
WARNING: at arch/arm/mm/ioremap.c:211 __arm_ioremap_pfn_caller+0x58/0x190()
Modules linked in: mem_region(+) bufferclass_ti pvrsrvkm TI81xx_hdmi ti81xxfb vpss syslink ipv6 [last unloaded: mem_region]
Backtrace:
[<c0043b44>] (dump_backtrace+0x0/0x110) from [<c0353b74>] (dump_stack+0x18/0x1c)
r7:00000000 r6:c00474e4 r5:c04084fb r4:000000d3
[<c0353b5c>] (dump_stack+0x0/0x1c) from [<c00608f4>] (warn_slowpath_common+0x54/0x6c)
[<c00608a0>] (warn_slowpath_common+0x0/0x6c) from [<c0060930>] (warn_slowpath_null+0x24/0x2c)
r9:c6276000 r8:bf039000 r7:bf039140 r6:000800f0 r5:00000010
r4:00000000
[<c006090c>] (warn_slowpath_null+0x0/0x2c) from [<c00474e4>] (__arm_ioremap_pfn_caller+0x58/0x190)
[<c004748c>] (__arm_ioremap_pfn_caller+0x0/0x190) from [<c00476a0>] (__arm_ioremap_caller+0x64/0x6c)
[<c004763c>] (__arm_ioremap_caller+0x0/0x6c) from [<c00571f8>] (omap_ioremap+0x60/0x64)
r6:00000000 r5:00000010 r4:800f0000
[<c0057198>] (omap_ioremap+0x0/0x64) from [<bf039140>] (install_reserved_memory+0x140/0x240 [mem_region])
r7:00012018 r6:00000000 r5:bf036510 r4:bf0366c8
[<bf039000>] (install_reserved_memory+0x0/0x240 [mem_region]) from [<c00353d8>] (do_one_initcall+0xd0/0x1a4)
r6:00012008 r5:bf0365a0 r4:00000000
[<c0035308>] (do_one_initcall+0x0/0x1a4) from [<c008b704>] (sys_init_module+0x9c/0x1bc)
[<c008b668>] (sys_init_module+0x0/0x1bc) from [<c003fda0>] (ret_fast_syscall+0x0/0x30)
r7:00000080 r6:00000003 r5:00004000 r4:00000000
---[ end trace 99b1af0f66ba275b ]---
  • Hi,

    You should be doing ioremap to the I/O area or the memory which Linux is not aware of. You are trying to do ioremap of the memroy given to Linux as its system memory. Thats why you are seeing this dump. Why you want to ioremap Linux memory>

    Regards,

    Hardik Shah

  • Hi, i'm new to linux...What is linux memory?I look at AM389x Sitara ARM datasheet, there is 2 memory region for DDR memory:0x80000000-0xBFFFFFFF and 0xC0000000- 0xFFFFFFFF.So i decide to use the memory region from 0x80000000 for my custom memory buffer region.After that, i found that in the /proc/iomem , there are some portion of memory are being used.

    For example: 80000000-87ffffff : System RAM

                             80035000-80477fff : Kernel text

                             80478000-804efa57 : Kernel data

                             80000000-ffffffff : pcie-inbound0

    What is kernel text, kernel data,pcie-inbound0 and what is their function? How can i know where is linux memory so that i won't do any ioremap at that region? From where can i find the operating system and ramdisk is occupying which memory region and how big the size?Thank you.