• Aneesh Kumar K.V's avatar
    libnvdimm/region: Initialize bad block for volatile namespaces · c42adf87
    Aneesh Kumar K.V authored
    We do check for a bad block during namespace init and that use
    region bad block list. We need to initialize the bad block
    for volatile regions for this to work. We also observe a lockdep
    warning as below because the lock is not initialized correctly
    since we skip bad block init for volatile regions.
    
     INFO: trying to register non-static key.
     the code is fine but needs lockdep annotation.
     turning off the locking correctness validator.
     CPU: 2 PID: 1 Comm: swapper/0 Not tainted 5.3.0-rc1-15699-g3dee241c937e #149
     Call Trace:
     [c0000000f95cb250] [c00000000147dd84] dump_stack+0xe8/0x164 (unreliable)
     [c0000000f95cb2a0] [c00000000022ccd8] register_lock_class+0x308/0xa60
     [c0000000f95cb3a0] [c000000000229cc0] __lock_acquire+0x170/0x1ff0
     [c0000000f95cb4c0] [c00000000022c740] lock_acquire+0x220/0x270
     [c0000000f95cb580] [c000000000a93230] badblocks_check+0xc0/0x290
     [c0000000f95cb5f0] [c000000000d97540] nd_pfn_validate+0x5c0/0x7f0
     [c0000000f95cb6d...
    c42adf87
region.c 4.07 KB