aboutsummaryrefslogtreecommitdiff
path: root/cddl/compat/opensolaris/include/devid.h
diff options
context:
space:
mode:
Diffstat (limited to 'cddl/compat/opensolaris/include/devid.h')
-rw-r--r--cddl/compat/opensolaris/include/devid.h27
1 files changed, 16 insertions, 11 deletions
diff --git a/cddl/compat/opensolaris/include/devid.h b/cddl/compat/opensolaris/include/devid.h
index 06839ddfe2f5..6718ce2b9fbc 100644
--- a/cddl/compat/opensolaris/include/devid.h
+++ b/cddl/compat/opensolaris/include/devid.h
@@ -27,23 +27,28 @@
#ifndef _OPENSOLARIS_DEVID_H_
#define _OPENSOLARIS_DEVID_H_
-#include <sys/types.h>
+#include <sys/param.h>
+#include <sys/disk.h>
#include <stdlib.h>
-typedef int ddi_devid_t;
+typedef struct ddi_devid {
+ char devid[DISK_IDENT_SIZE];
+} ddi_devid_t;
typedef struct devid_nmlist {
- char *devname;
+ char devname[MAXPATHLEN];
dev_t dev;
} devid_nmlist_t;
-static inline int devid_str_decode(char *devidstr, ddi_devid_t *retdevid, char **retminor_name) { abort(); }
-static inline int devid_deviceid_to_nmlist(char *search_path, ddi_devid_t devid, char *minor_name, devid_nmlist_t **retlist) { abort(); }
-static inline void devid_str_free(char *str) { abort(); }
-static inline void devid_free(ddi_devid_t devid) { abort(); }
-static inline void devid_free_nmlist(devid_nmlist_t *list) { abort(); }
-static inline int devid_get(int fd, ddi_devid_t *retdevid) { return -1; }
-static inline int devid_get_minor_name(int fd, char **retminor_name) { abort(); }
-static inline char *devid_str_encode(ddi_devid_t devid, char *minor_name) { abort(); }
+int devid_str_decode(char *devidstr, ddi_devid_t *retdevid,
+ char **retminor_name);
+int devid_deviceid_to_nmlist(char *search_path, ddi_devid_t devid,
+ char *minor_name, devid_nmlist_t **retlist);
+void devid_str_free(char *str);
+void devid_free(ddi_devid_t devid);
+void devid_free_nmlist(devid_nmlist_t *list);
+int devid_get(int fd, ddi_devid_t *retdevid);
+int devid_get_minor_name(int fd, char **retminor_name);
+char *devid_str_encode(ddi_devid_t devid, char *minor_name);
#endif /* !_OPENSOLARIS_DEVID_H_ */