summaryrefslogtreecommitdiff
path: root/libudev/libudev-private.h
diff options
context:
space:
mode:
authorKay Sievers <kay.sievers@vrfy.org>2009-08-19 20:49:49 +0200
committerKay Sievers <kay.sievers@vrfy.org>2009-08-19 20:49:49 +0200
commit2ffc9cc1917b1bb6fe86881a94a47dce9aa15168 (patch)
tree842ba77f43018179ce42e5433ce1c6cd63559c60 /libudev/libudev-private.h
parent24d1fea8bd609f9eb7901efd7cba7f2dee05f557 (diff)
change database file names
With very deeply nested devices, We can not use a single file name to carry an entire DEVPATH. Use <subsystem>:<sysname> as the database filename, which should also simplify the handling of devices moving around, as these values will not change but still be unique. For the name stack we use the <maj>:<min> now as the filename. > On Tue, Aug 18, 2009 at 09:59:56AM -0400, Ric Wheeler wrote: > The first is that udev grumbles during boot about "file name too long" > like the following: > > Aug 17 06:49:58 megadeth udevd-event[20447]: unable to create db file > '/dev/.udev/db/\x2fdevices\x2fpci0000:00\x2f0000:00:04.0\x2f0000:17:00.0\x2f0000:18:0a.0\x2f0000:1f:00.0\x2fhost11\x2fport-11:0\x2fexpander-11:0\x2fport-11:0:0\x2fexpander-11:1\x2fport-11:1:0\x2fexpander-11:2\x2fport-11:2:17\x2fexpander-11:3\x2fport-11:3:1\x2fend_device-11:3:1\x2fbsg\x2fend_device-11:3:1': > File name too long
Diffstat (limited to 'libudev/libudev-private.h')
-rw-r--r--libudev/libudev-private.h5
1 files changed, 3 insertions, 2 deletions
diff --git a/libudev/libudev-private.h b/libudev/libudev-private.h
index 16f9f2e1c1..b735298c67 100644
--- a/libudev/libudev-private.h
+++ b/libudev/libudev-private.h
@@ -79,6 +79,7 @@ int udev_device_read_uevent_file(struct udev_device *udev_device);
int udev_device_set_action(struct udev_device *udev_device, const char *action);
int udev_device_set_driver(struct udev_device *udev_device, const char *driver);
const char *udev_device_get_devpath_old(struct udev_device *udev_device);
+const char *udev_device_get_sysname_old(struct udev_device *udev_device);
int udev_device_set_devpath_old(struct udev_device *udev_device, const char *devpath_old);
const char *udev_device_get_knodename(struct udev_device *udev_device);
int udev_device_set_knodename(struct udev_device *udev_device, const char *knodename);
@@ -101,7 +102,7 @@ void udev_device_set_info_loaded(struct udev_device *device);
/* libudev-device-private.c */
int udev_device_update_db(struct udev_device *udev_device);
int udev_device_delete_db(struct udev_device *udev_device);
-int udev_device_rename_db(struct udev_device *udev_device, const char *devpath);
+int udev_device_rename_db(struct udev_device *udev_device);
/* libudev-monitor.c - netlink/unix socket communication */
int udev_monitor_disconnect(struct udev_monitor *udev_monitor);
@@ -186,8 +187,8 @@ int udev_queue_export_device_failed(struct udev_queue_export *udev_queue_export,
/* libudev-util.c */
#define UTIL_PATH_SIZE 1024
-#define UTIL_LINE_SIZE 2048
#define UTIL_NAME_SIZE 512
+#define UTIL_LINE_SIZE 2048
#define UDEV_ALLOWED_CHARS_INPUT "/ $%?,"
ssize_t util_get_sys_subsystem(struct udev *udev, const char *syspath, char *subsystem, size_t size);
ssize_t util_get_sys_driver(struct udev *udev, const char *syspath, char *driver, size_t size);