nd.h (1f7df6f88b9245a7f2d0f8ecbc97dc88c8d0d8e1) | nd.h (3d88002e4a7bd40f355550284c6cd140e6fe29dc) |
---|---|
1/* 2 * Copyright(c) 2013-2015 Intel Corporation. All rights reserved. 3 * 4 * This program is free software; you can redistribute it and/or modify 5 * it under the terms of version 2 of the GNU General Public License as 6 * published by the Free Software Foundation. 7 * 8 * This program is distributed in the hope that it will be useful, but --- 9 unchanged lines hidden (view full) --- 18#include <linux/ndctl.h> 19 20struct nvdimm_drvdata { 21 struct device *dev; 22 struct nd_cmd_get_config_size nsarea; 23 void *data; 24}; 25 | 1/* 2 * Copyright(c) 2013-2015 Intel Corporation. All rights reserved. 3 * 4 * This program is free software; you can redistribute it and/or modify 5 * it under the terms of version 2 of the GNU General Public License as 6 * published by the Free Software Foundation. 7 * 8 * This program is distributed in the hope that it will be useful, but --- 9 unchanged lines hidden (view full) --- 18#include <linux/ndctl.h> 19 20struct nvdimm_drvdata { 21 struct device *dev; 22 struct nd_cmd_get_config_size nsarea; 23 void *data; 24}; 25 |
26struct nd_region_namespaces { 27 int count; 28 int active; 29}; 30 |
|
26struct nd_region { 27 struct device dev; 28 u16 ndr_mappings; 29 u64 ndr_size; 30 u64 ndr_start; 31 int id; 32 void *provider_data; 33 struct nd_mapping mapping[0]; 34}; 35 36enum nd_async_mode { 37 ND_SYNC, 38 ND_ASYNC, 39}; 40 41void nd_device_register(struct device *dev); 42void nd_device_unregister(struct device *dev, enum nd_async_mode mode); 43int __init nvdimm_init(void); | 31struct nd_region { 32 struct device dev; 33 u16 ndr_mappings; 34 u64 ndr_size; 35 u64 ndr_start; 36 int id; 37 void *provider_data; 38 struct nd_mapping mapping[0]; 39}; 40 41enum nd_async_mode { 42 ND_SYNC, 43 ND_ASYNC, 44}; 45 46void nd_device_register(struct device *dev); 47void nd_device_unregister(struct device *dev, enum nd_async_mode mode); 48int __init nvdimm_init(void); |
49int __init nd_region_init(void); |
|
44void nvdimm_exit(void); | 50void nvdimm_exit(void); |
51void nd_region_exit(void); |
|
45int nvdimm_init_nsarea(struct nvdimm_drvdata *ndd); 46int nvdimm_init_config_data(struct nvdimm_drvdata *ndd); | 52int nvdimm_init_nsarea(struct nvdimm_drvdata *ndd); 53int nvdimm_init_config_data(struct nvdimm_drvdata *ndd); |
54struct nd_region *to_nd_region(struct device *dev); 55int nd_region_to_nstype(struct nd_region *nd_region); 56int nd_region_register_namespaces(struct nd_region *nd_region, int *err); 57void nvdimm_bus_lock(struct device *dev); 58void nvdimm_bus_unlock(struct device *dev); 59bool is_nvdimm_bus_locked(struct device *dev); |
|
47#endif /* __ND_H__ */ | 60#endif /* __ND_H__ */ |