/*
- * udev.h
- *
* Copyright (C) 2003 Greg Kroah-Hartman <greg@kroah.com>
- * Copyright (C) 2003-2005 Kay Sievers <kay.sievers@vrfy.org>
+ * Copyright (C) 2003-2006 Kay Sievers <kay.sievers@vrfy.org>
*
* This program is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License as published by the
*
* You should have received a copy of the GNU General Public License along
* with this program; if not, write to the Free Software Foundation, Inc.,
- * 675 Mass Ave, Cambridge, MA 02139, USA.
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
*
*/
#include "udev_version.h"
#define COMMENT_CHARACTER '#'
-#define PATH_TO_NAME_CHAR '@'
#define LINE_SIZE 512
#define PATH_SIZE 512
#define NAME_SIZE 128
#define WRITE_END 1
#define DB_DIR ".udev/db"
+#define DB_NAME_INDEX_DIR ".udev/names"
struct udev_rules;
/* udev_config.c */
extern char udev_root[PATH_SIZE];
extern char udev_config_filename[PATH_SIZE];
-extern char udev_rules_filename[PATH_SIZE];
+extern char udev_rules_dir[PATH_SIZE];
extern int udev_log_priority;
extern int udev_run;
extern void udev_config_init(void);
extern struct sysfs_device *sysfs_device_get_parent(struct sysfs_device *dev);
extern struct sysfs_device *sysfs_device_get_parent_with_subsystem(struct sysfs_device *dev, const char *subsystem);
extern char *sysfs_attr_get_value(const char *devpath, const char *attr_name);
+extern int sysfs_resolve_link(char *path, size_t size);
/* udev_node.c */
extern int udev_node_mknod(struct udevice *udev, const char *file, dev_t devt, mode_t mode, uid_t uid, gid_t gid);
extern gid_t lookup_group(const char *group);
/* udev_utils_string.c */
-extern int strcmp_pattern(const char *p, const char *s);
extern int string_is_true(const char *str);
extern void remove_trailing_chars(char *path, char c);
+extern size_t path_encode(char *s, size_t len);
+extern size_t path_decode(char *s);
extern int utf8_encoded_valid_unichar(const char *str);
extern int replace_untrusted_chars(char *str);