X-Git-Url: https://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?a=blobdiff_plain;f=src%2Fdevice.h;h=5757c9139d9470e7ec1a74ed5d7e88b45477a409;hb=47342320a097523d93040cdd627e237a420572c5;hp=a5c5f745b81f712dfea4e582e7205269c0a54b8c;hpb=e99e38bbdcca3fe5956823bdb3d38544ccf93221;p=elogind.git diff --git a/src/device.h b/src/device.h index a5c5f745b..5757c9139 100644 --- a/src/device.h +++ b/src/device.h @@ -30,7 +30,7 @@ typedef struct Device Device; * simplifies the state engine greatly */ typedef enum DeviceState { DEVICE_DEAD, - DEVICE_AVAILABLE, + DEVICE_PLUGGED, _DEVICE_STATE_MAX, _DEVICE_STATE_INVALID = -1 } DeviceState; @@ -41,6 +41,12 @@ struct Device { DeviceState state; char *sysfs; + + /* In order to be able to distuingish dependencies on + different device nodes we might end up creating multiple + devices for the same sysfs path. We chain them up here. */ + + LIST_FIELDS(struct Device, same_sysfs); }; extern const UnitVTable device_vtable;