• Z
    arm64: Add memmap parameter and register pmem · 94dc364f
    ZhuLing 提交于
    hulk inclusion
    category: feature
    bugzilla: 48159
    CVE: NA
    
    ------------------------------
    
    Register pmem in arm64:
    Use memmap(memmap=nn[KMG]!ss[KMG]) reserve memory and
    e820(driver/nvdimm/e820.c) function to register persistent
    memory in arm64. when the kernel restart or update, the data
    in PMEM will not be lost and can be loaded faster. this is a
    general features.
    
    driver/nvdimm/e820.c:
    The function of this file is scan "iomem_resource" and take
    advantage of nvdimm resource discovery mechanism by registering
    a resource named "Persistent Memory (legacy)", this function
    doesn't depend on architecture.
    
    We will push the feature to linux kernel community and discuss to
    modify the file name. because people have a mistaken notion that
    the e820.c is depend on x86.
    
    If you want use this features, you need do as follows:
    1.Reserve memory: add memmap to reserve memory in grub.cfg
      memmap=nn[KMG]!ss[KMG] exp:memmap=100K!0x1a0000000.
    2.Insmod nd_e820.ko: modprobe nd_e820.
    3.Check pmem device in /dev exp: /dev/pmem0
    Signed-off-by: NZhuLing <zhuling8@huawei.com>
    Signed-off-by: NSang Yan <sangyan@huawei.com>
    Reviewed-by: NChen Wandun <chenwandun@huawei.com>
    Signed-off-by: NZheng Zengkai <zhengzengkai@huawei.com>
    94dc364f
Kconfig 68.0 KB