]>
git.ipfire.org Git - thirdparty/systemd.git/blob - udev_sysfs.h
4 * Copyright (C) 2004 Kay Sievers <kay.sievers@vrfy.org>
5 * Copyright (C) 2004 Greg Kroah-Hartman <greg@kroah.com>
7 * This program is free software; you can redistribute it and/or modify it
8 * under the terms of the GNU General Public License as published by the
9 * Free Software Foundation version 2 of the License.
11 * This program is distributed in the hope that it will be useful, but
12 * WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 * General Public License for more details.
16 * You should have received a copy of the GNU General Public License along
17 * with this program; if not, write to the Free Software Foundation, Inc.,
18 * 675 Mass Ave, Cambridge, MA 02139, USA.
22 #ifndef _UDEV_SYSFS_H_
23 #define _UDEV_SYSFS_H_
25 #include "libsysfs/sysfs/libsysfs.h"
27 #define WAIT_MAX_SECONDS 5
28 #define WAIT_LOOP_PER_SECOND 20
30 extern int subsystem_expect_no_dev(const char *subsystem
);
32 /* /sys/class /sys/block devices */
33 extern struct sysfs_class_device
*wait_class_device_open(const char *path
);
34 extern int wait_for_class_device(struct sysfs_class_device
*class_dev
, const char **error
);
36 /* /sys/devices devices */
37 extern struct sysfs_device
*wait_devices_device_open(const char *path
);
38 extern int wait_for_devices_device(struct sysfs_device
*devices_dev
, const char **error
);
40 #endif /* _UDEV_SYSFS_H_ */