[PATCH v6 27/33] nvdimm acpi: support function 0

2015-10-30 Thread Xiao Guangrong
__DSM is defined in ACPI 6.0: 9.14.1 _DSM (Device Specific Method) Function 0 is a query function. We do not support any function on root device and only 3 functions are support for NVDIMM device, Get Namespace Label Size, Get Namespace Label Data and Set Namespace Label Data, that means we

Re: [PATCH v6 27/33] nvdimm acpi: support function 0

2015-10-30 Thread Stefan Hajnoczi
On Fri, Oct 30, 2015 at 01:56:21PM +0800, Xiao Guangrong wrote: > static uint64_t > nvdimm_dsm_read(void *opaque, hwaddr addr, unsigned size) > { > -return 0; > +AcpiNVDIMMState *state = opaque; > +MemoryRegion *dsm_ram_mr = >ram_mr; > +NvdimmDsmIn *in; > +GArray *out; > +

Re: [PATCH v6 27/33] nvdimm acpi: support function 0

2015-10-30 Thread Xiao Guangrong
On 10/30/2015 06:14 PM, Stefan Hajnoczi wrote: On Fri, Oct 30, 2015 at 01:56:21PM +0800, Xiao Guangrong wrote: static uint64_t nvdimm_dsm_read(void *opaque, hwaddr addr, unsigned size) { -return 0; +AcpiNVDIMMState *state = opaque; +MemoryRegion *dsm_ram_mr = >ram_mr; +