Searched refs:devpath (Results 1 - 25 of 54) sorted by relevance

123

/netgear-WNDR4500v2-V1.0.0.60_1.0.38/src/router/busybox-1.x/libbb/
H A Dfind_root_device.c20 char devpath[DEVNAME_MAX]; member in struct:arena
30 dir = opendir(ap->devpath);
34 len = strlen(ap->devpath);
38 ap->devpath[len++] = '/';
41 safe_strncpy(ap->devpath + len, entry->d_name, rem);
43 if (lstat(ap->devpath, &ap->st) != 0)
46 retpath = xstrdup(ap->devpath);
70 strcpy(a.devpath, "/dev");
/netgear-WNDR4500v2-V1.0.0.60_1.0.38/src/router/udev/test/
H A Dudev-test.pl38 devpath => "/block/sda",
48 devpath => "/block/sda",
58 devpath => "/block/sda",
68 devpath => "/block/sda/sda1",
77 devpath => "/block/sda/sda1",
89 devpath => "/block/sda/sda1",
99 devpath => "/block/sda/sda1",
109 devpath => "/class/tty/ttyUSB0",
118 devpath => "/class/tty/ttyUSB0",
128 devpath
[all...]
/netgear-WNDR4500v2-V1.0.0.60_1.0.38/src/router/udev/
H A Dudevtest.c51 static int import_uevent_var(const char *devpath) argument
63 strlcat(path, devpath, sizeof(path));
95 char *devpath = NULL; local
139 printf("Usage: udevtest OPTIONS <devpath>\n"
149 devpath = argv[optind];
151 if (devpath == NULL) {
152 fprintf(stderr, "devpath parameter missing\n");
166 if (strncmp(devpath, sysfs_path, strlen(sysfs_path)) == 0)
167 devpath = &devpath[strle
[all...]
H A Dudev_sysfs.c80 void sysfs_device_set_values(struct sysfs_device *dev, const char *devpath, argument
85 strlcpy(dev->devpath, devpath, sizeof(dev->devpath));
92 pos = strrchr(dev->devpath, '/');
114 int sysfs_resolve_link(char *devpath, size_t size) argument
123 strlcat(link_path, devpath, sizeof(link_path));
128 dbg("path link '%s' points to '%s'", devpath, link_target);
132 dbg("base '%s', tail '%s', back %i", devpath, &link_target[back * 3], back);
134 char *pos = strrchr(devpath, '/');
146 sysfs_device_get(const char *devpath) argument
344 sysfs_attr_get_value(const char *devpath, const char *attr_name) argument
[all...]
H A Dudev_device.c73 attr = sysfs_attr_get_value(udev->dev->devpath, "dev");
152 dbg("device node add '%s'", udev->dev->devpath);
168 if (udev_db_get_device(udev_old, udev->dev->devpath) == 0) {
169 info("device '%s' already in database, cleanup", udev->dev->devpath);
195 dbg("netif add '%s'", udev->dev->devpath);
208 char devpath[PATH_MAX]; local
219 /* now change the devpath, because the kernel device name has changed */
220 strlcpy(devpath, udev->dev->devpath, sizeof(devpath));
[all...]
H A Dudev.h58 char devpath[PATH_SIZE]; member in struct:sysfs_device
115 extern void sysfs_device_set_values(struct sysfs_device *dev, const char *devpath,
117 extern struct sysfs_device *sysfs_device_get(const char *devpath);
120 extern char *sysfs_attr_get_value(const char *devpath, const char *attr_name);
122 extern int sysfs_lookup_devpath_by_subsys_id(char *devpath, size_t len, const char *subsystem, const char *id);
133 extern int udev_db_get_device(struct udevice *udev, const char *devpath);
168 extern int pass_env_to_socket(const char *name, const char *devpath, const char *action);
H A Dudev_db.c36 static size_t devpath_to_db_path(const char *devpath, char *filename, size_t len) argument
43 strlcat(filename, devpath, len);
47 /* reverse mapping from the device file name to the devpath */
48 static int name_index(const char *devpath, const char *name, int add) argument
60 /* entry with the devpath */
61 strlcpy(device, devpath, sizeof(device));
127 devpath_to_db_path(udev->dev->devpath, filename, sizeof(filename));
151 dbg("storing data for device '%s' in '%s'", udev->dev->devpath, filename);
157 name_index(udev->dev->devpath, name_loop->name, 1);
172 name_index(udev->dev->devpath, ude
177 udev_db_get_device(struct udevice *udev, const char *devpath) argument
[all...]
H A Dtest-udev.c67 const char *devpath; local
111 devpath = getenv("DEVPATH");
117 if (action == NULL || subsystem == NULL || devpath == NULL) {
118 err("action, subsystem or devpath missing");
133 dev = sysfs_device_get(devpath);
135 info("unable to open '%s'", devpath);
163 pass_env_to_socket(&name_loop->name[strlen("socket:")], devpath, action);
H A Dudevinfo.c49 static void print_all_attributes(const char *devpath, const char *key) argument
56 strlcat(path, devpath, sizeof(path));
78 attr_value = sysfs_attr_get_value(devpath, dent->d_name);
103 static int print_device_chain(const char *devpath) argument
107 dev = sysfs_device_get(devpath);
112 "Udevinfo starts with the device specified by the devpath and then\n"
119 printf(" looking at device '%s':\n", dev->devpath);
123 print_all_attributes(dev->devpath, "ATTR");
130 printf(" looking at parent device '%s':\n", dev->devpath);
135 print_all_attributes(dev->devpath, "ATTR
[all...]
H A Dudevd.h64 char *devpath; member in struct:udevd_uevent_msg
H A Dudevstart.c69 const char *devpath = &path[strlen(sysfs_path)]; local
71 dbg("insert: '%s'", devpath);
74 if (strcmp(loop_device->path, devpath) > 0) {
85 strlcpy(new_device->path, devpath, sizeof(new_device->path));
104 static int add_device(const char *devpath) argument
119 dev = sysfs_device_get(devpath);
137 dbg("add '%s'", udev->dev->devpath);
138 setenv("DEVPATH", udev->dev->devpath, 1);
157 pass_env_to_socket(&name_loop->name[strlen("socket:")], udev->dev->devpath, "add");
H A Dudevtrigger.c60 static int delay_device(const char *devpath) argument
70 if (fnmatch(delay_device_list[i], devpath, 0) == 0)
78 char devpath[PATH_SIZE]; local
91 strlcpy(devpath, &path[strlen(sysfs_path)], sizeof(devpath));
97 if (sysfs_resolve_link(devpath, sizeof(devpath)) != 0)
100 name_list_add(&device_list, devpath, 1);
104 static void trigger_uevent(const char *devpath) argument
110 strlcat(filename, devpath, sizeo
[all...]
H A Dudevd.c132 sysfs_device_set_values(udev->dev, msg->devpath, msg->subsystem, msg->driver);
144 pass_env_to_socket(&name_loop->name[strlen("socket:")], udev->dev->devpath, udev->action);
179 strlcat(filename, msg->devpath, sizeof(filename));
186 strlcat(filename_failed, msg->devpath, sizeof(filename_failed));
205 if (loop_msg->devpath && strcmp(loop_msg->devpath, msg->devpath) == 0)
209 if (loop_msg->devpath && strcmp(loop_msg->devpath, msg->devpath)
[all...]
H A Dudev_node.c216 if (strcmp(udev->dev->devpath, device->name) == 0) {
218 udev->dev->devpath, udev->link_priority, priority);
232 udev_db->dev->devpath, udev_db->link_priority, priority);
267 info("update symlink '%s' of '%s'", name_loop->name, udev->dev->devpath);
298 link_old_loop->name, udev->dev->devpath);
369 attr = sysfs_attr_get_value(udev->dev->devpath, "range");
H A Dudev_rules.c162 info("updating devpath from '%s' to '%s'", udev->dev->devpath, value);
208 dbg("found parent '%s', get the node name", dev_parent->devpath);
213 if (udev_db_get_device(udev_parent, dev_parent->devpath) == 0) {
250 strlcat(devicepath, udev->dev->devpath, sizeof(devicepath));
275 static int attr_get_by_subsys_id(const char *attrstr, char *devpath, size_t len, char **attr) argument
299 if (sysfs_lookup_devpath_by_subsys_id(devpath, len, subsys, id)) {
341 { .name = "devpath", .fmt = 'p', .type = SUBST_DEVPATH },
419 strlcat(string, udev->dev->devpath, maxsize);
420 dbg("substitute devpath '
484 char devpath[PATH_SIZE]; local
693 char devpath[PATH_SIZE]; local
741 char devpath[PATH_SIZE]; local
930 char devpath[PATH_SIZE]; local
[all...]
H A Dudev_rules.h68 struct key devpath; member in struct:udev_rule
H A Dudevmonitor.c217 const char *devpath, *action, *subsys; local
261 devpath = search_key("DEVPATH", &buf[keys], buflen);
264 printf("%s[%s] %-8s %s (%s)\n", source, timestr, action, devpath, subsys);
/netgear-WNDR4500v2-V1.0.0.60_1.0.38/src/router/udev/extras/usb_id/
H A Dusb_id.c222 static int usb_id(const char *devpath) argument
233 dbg("devpath %s\n", devpath);
236 dev = sysfs_device_get(devpath);
238 err("unable to access '%s'", devpath);
245 info("unable to access usb_interface device of '%s'", devpath);
249 if_class = sysfs_attr_get_value(dev_interface->devpath, "bInterfaceClass");
256 if_subclass = sysfs_attr_get_value(dev_interface->devpath, "bInterfaceSubClass");
262 info("%s: if_class %d protocol %d\n", dev_interface->devpath, if_class_num, protocol);
267 info("unable to find parent 'usb' device of '%s'", devpath);
369 char devpath[MAX_PATH_LEN]; local
[all...]
/netgear-WNDR4500v2-V1.0.0.60_1.0.38/src/router/udev/extras/scsi_id/
H A Dscsi_id.c42 { "devpath", 1, NULL, 's' },
172 static int create_tmp_dev(const char *devpath, char *tmpdev, int dev_type) argument
177 dbg("%s", devpath);
178 attr = sysfs_attr_get_value(devpath, "dev");
180 dbg("%s: could not get dev attribute: %s", devpath, strerror(errno));
186 err("%s: invalid dev major/minor", devpath);
468 " --devpath sysfs devpath\n"
597 vendor = sysfs_attr_get_value(dev_scsi->devpath, "vendor");
599 info("%s: cannot get vendor attribute", dev_scsi->devpath);
677 scsi_id(const char *devpath, char *maj_min_dev) argument
768 char devpath[MAX_PATH_LEN]; local
[all...]
/netgear-WNDR4500v2-V1.0.0.60_1.0.38/src/linux/linux-2.6/drivers/parisc/
H A Dpdc_stable.c104 struct device_path devpath; /* device path in parisc representation */ member in struct:pdcspath_entry
154 struct device_path *devpath; local
159 devpath = &entry->devpath;
162 entry, devpath, entry->addr);
164 /* addr, devpath and count must be word aligned */
165 if (pdc_stable_read(entry->addr, devpath, sizeof(*devpath)) != PDC_OK)
171 entry->dev = hwpath_to_device((struct hardware_path *)devpath);
184 * It can be used in two ways: either by passing it a preset devpath struc
195 struct device_path *devpath; local
239 struct device_path *devpath; local
341 struct device_path *devpath; local
[all...]
/netgear-WNDR4500v2-V1.0.0.60_1.0.38/src/linux/linux-2.6/lib/
H A Dkobject_uevent.c73 const char *devpath = NULL; local
135 devpath = kobject_get_path(kobj, GFP_KERNEL);
136 if (!devpath) {
150 scratch += sprintf (scratch, "DEVPATH=%s", devpath) + 1;
184 len = strlen(action_string) + strlen(devpath) + 2;
189 sprintf(scratch, "%s@%s", action_string, devpath);
215 kfree(devpath);
H A Dkobject.c315 const char *devpath = NULL; local
325 devpath = kobject_get_path(kobj, GFP_KERNEL);
326 if (!devpath) {
330 devpath_string = kmalloc(strlen(devpath) + 15, GFP_KERNEL);
335 sprintf(devpath_string, "DEVPATH_OLD=%s", devpath);
351 kfree(devpath);
388 const char *devpath = NULL; local
401 devpath = kobject_get_path(kobj, GFP_KERNEL);
402 if (!devpath) {
406 devpath_string = kmalloc(strlen(devpath)
[all...]
/netgear-WNDR4500v2-V1.0.0.60_1.0.38/src/router/busybox-1.x/examples/
H A Ddevfsd.conf53 REGISTER .* COPY /lib/dev-state/$devname $devpath
54 CREATE .* COPY $devpath /lib/dev-state/$devname
55 CHANGE .* COPY $devpath /lib/dev-state/$devname
85 #REGISTER .* CFUNCTION /lib/security/pam_console_apply_devfsd.so pam_console_apply_single $devpath
/netgear-WNDR4500v2-V1.0.0.60_1.0.38/src/linux/linux-2.6/drivers/usb/core/
H A Dusb.c287 * dev->devpath will be stable until USB is re-cabled, and hubs
293 dev->devpath[0] = '0';
299 if (parent->devpath[0] == '0')
300 snprintf(dev->devpath, sizeof dev->devpath,
303 snprintf(dev->devpath, sizeof dev->devpath,
304 "%s.%d", parent->devpath, port1);
308 bus->busnum, dev->devpath);
/netgear-WNDR4500v2-V1.0.0.60_1.0.38/src/router/rc/
H A Dusb_hotplug.c839 char *devpath = NULL; local
856 !(devpath = getenv("PHYSDEVPATH")) ||
890 devpath = getenv("PHYSDEVPATH");
893 get_usb_port(devpath, usb_port);
1168 static char devpath[128] = {0}; variable
1177 memset(devpath, 0, sizeof(devpath));
1182 sscanf(buf, "%s %s", devpath, mntpath);
1310 if (strlen(mntpath) == 0 || strlen(devpath) == 0)
1333 dump_disk_type(devpath);
1364 char *devpath; local
[all...]

Completed in 93 milliseconds

123