libnvdimm, nfit: initial libnvdimm infrastructure and NFIT support
[deliverable/linux.git] / include / linux / libnvdimm.h
CommitLineData
b94d5230
DW
1/*
2 * libnvdimm - Non-volatile-memory Devices Subsystem
3 *
4 * Copyright(c) 2013-2015 Intel Corporation. All rights reserved.
5 *
6 * This program is free software; you can redistribute it and/or modify
7 * it under the terms of version 2 of the GNU General Public License as
8 * published by the Free Software Foundation.
9 *
10 * This program is distributed in the hope that it will be useful, but
11 * WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 * General Public License for more details.
14 */
15#ifndef __LIBNVDIMM_H__
16#define __LIBNVDIMM_H__
17struct nvdimm;
18struct nvdimm_bus_descriptor;
19typedef int (*ndctl_fn)(struct nvdimm_bus_descriptor *nd_desc,
20 struct nvdimm *nvdimm, unsigned int cmd, void *buf,
21 unsigned int buf_len);
22
23struct nvdimm_bus_descriptor {
24 unsigned long dsm_mask;
25 char *provider_name;
26 ndctl_fn ndctl;
27};
28
29struct device;
30struct nvdimm_bus;
31struct nvdimm_bus *nvdimm_bus_register(struct device *parent,
32 struct nvdimm_bus_descriptor *nfit_desc);
33void nvdimm_bus_unregister(struct nvdimm_bus *nvdimm_bus);
34#endif /* __LIBNVDIMM_H__ */
This page took 0.026682 seconds and 5 git commands to generate.