On Fri, 19 Jun 2015, Dan Williams wrote: > On Fri, Jun 19, 2015 at 9:33 AM, Mikulas Patocka <mpatocka@xxxxxxxxxx> wrote: > > Hi > > > > I looked at the new the persistent memory block device driver > > (drivers/block/pmem.c and arch/x86/kernel/pmem.c) and it seems that the > > interface between them is incorrect. > > > > If I want to use persistent memory in another driver, for a different > > purpose, how can I make sure that that drivers/block/pmem.c doesn't attach > > to this piece of memory and export it? It seems not possible. > > drivers/block/pmem.c attaches to everything without regard that there may > > be other users of persistent memory. > > Simply partition the pmem device however you see fit and then > blkdev_get_by_path(<dev>, FMODE_EXCL, <holder>) the resulting > partition(s). But that still means accessing it through the block layer. I need to access persistent memory directly - map it into the kernel space and access it as mapped memory - and if I do it, it will fight with drivers/block/pmem.c over ownership of the memory :-( Mikulas -- dm-devel mailing list dm-devel@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/dm-devel