- udevice = udev_device_init(udev);
- if (udevice == NULL)
- goto fail;
-
- /* override built-in sysfs device */
- udevice->dev = dev;
- strlcpy(udevice->action, action, sizeof(udevice->action));
-
- /* get dev_t from environment, which is needed for "remove" to work, "add" works also from sysfs */
- maj = getenv("MAJOR");
- min = getenv("MINOR");
- if (maj != NULL && min != NULL)
- udevice->devt = makedev(atoi(maj), atoi(min));
- else
- udevice->devt = udev_device_get_devt(udevice);
+ /* skip reading of db, but read kernel parameters */
+ udev_device_set_info_loaded(dev);
+ udev_device_read_uevent_file(dev);