提交 960d665c 编写于 作者: J John Ferlan

nodedev: Privatize _virNodeDeviceObj and _virNodeDeviceObjList

Move the structures to withing virnodedeviceobj.c

Move the typedefs from node_device_conf to virnodedeviceobj.h
Signed-off-by: NJohn Ferlan <jferlan@redhat.com>
上级 1c7bc64e
......@@ -328,23 +328,6 @@ struct _virNodeDeviceDef {
virNodeDevCapsDefPtr caps; /* optional device capabilities */
};
typedef struct _virNodeDeviceObj virNodeDeviceObj;
typedef virNodeDeviceObj *virNodeDeviceObjPtr;
struct _virNodeDeviceObj {
virMutex lock;
virNodeDeviceDefPtr def; /* device definition */
};
typedef struct _virNodeDeviceObjList virNodeDeviceObjList;
typedef virNodeDeviceObjList *virNodeDeviceObjListPtr;
struct _virNodeDeviceObjList {
size_t count;
virNodeDeviceObjPtr *objs;
};
char *
virNodeDeviceDefFormat(const virNodeDeviceDef *def);
......
......@@ -32,6 +32,17 @@
VIR_LOG_INIT("conf.virnodedeviceobj");
struct _virNodeDeviceObj {
virMutex lock;
virNodeDeviceDefPtr def; /* device definition */
};
struct _virNodeDeviceObjList {
size_t count;
virNodeDeviceObjPtr *objs;
};
static virNodeDeviceObjPtr
virNodeDeviceObjNew(void)
......
......@@ -27,6 +27,12 @@
# include "object_event.h"
typedef struct _virNodeDeviceObj virNodeDeviceObj;
typedef virNodeDeviceObj *virNodeDeviceObjPtr;
typedef struct _virNodeDeviceObjList virNodeDeviceObjList;
typedef virNodeDeviceObjList *virNodeDeviceObjListPtr;
typedef struct _virNodeDeviceDriverState virNodeDeviceDriverState;
typedef virNodeDeviceDriverState *virNodeDeviceDriverStatePtr;
struct _virNodeDeviceDriverState {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册