xref: /qemu/hw/mem/nvdimm.c (revision 7a4e543d)
1 /*
2  * Non-Volatile Dual In-line Memory Module Virtualization Implementation
3  *
4  * Copyright(C) 2015 Intel Corporation.
5  *
6  * Author:
7  *  Xiao Guangrong <guangrong.xiao@linux.intel.com>
8  *
9  * Currently, it only supports PMEM Virtualization.
10  *
11  * This library is free software; you can redistribute it and/or
12  * modify it under the terms of the GNU Lesser General Public
13  * License as published by the Free Software Foundation; either
14  * version 2 of the License, or (at your option) any later version.
15  *
16  * This library is distributed in the hope that it will be useful,
17  * but WITHOUT ANY WARRANTY; without even the implied warranty of
18  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
19  * Lesser General Public License for more details.
20  *
21  * You should have received a copy of the GNU Lesser General Public
22  * License along with this library; if not, see <http://www.gnu.org/licenses/>
23  */
24 
25 #include "qemu/osdep.h"
26 #include "hw/mem/nvdimm.h"
27 
28 static void nvdimm_class_init(ObjectClass *oc, void *data)
29 {
30     DeviceClass *dc = DEVICE_CLASS(oc);
31 
32     /* nvdimm hotplug has not been supported yet. */
33     dc->hotpluggable = false;
34 }
35 
36 static TypeInfo nvdimm_info = {
37     .name          = TYPE_NVDIMM,
38     .parent        = TYPE_PC_DIMM,
39     .class_init    = nvdimm_class_init,
40 };
41 
42 static void nvdimm_register_types(void)
43 {
44     type_register_static(&nvdimm_info);
45 }
46 
47 type_init(nvdimm_register_types)
48