X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=drivers%2Fbase%2Fclass_simple.c;h=682e73bd3f498eb0f705f51a265477ce0eb2081f;hb=6a77f38946aaee1cd85eeec6cf4229b204c15071;hp=3410636de0a500c42b0d12d083fc83a2a3d5db05;hpb=87fc8d1bb10cd459024a742c6a10961fefcef18f;p=linux-2.6.git diff --git a/drivers/base/class_simple.c b/drivers/base/class_simple.c index 3410636de..682e73bd3 100644 --- a/drivers/base/class_simple.c +++ b/drivers/base/class_simple.c @@ -27,7 +27,7 @@ struct simple_dev { #define to_simple_dev(d) container_of(d, struct simple_dev, class_dev) static LIST_HEAD(simple_dev_list); -static spinlock_t simple_dev_list_lock = SPIN_LOCK_UNLOCKED; +static DEFINE_SPINLOCK(simple_dev_list_lock); static void release_simple_dev(struct class_device *class_dev) { @@ -122,7 +122,7 @@ EXPORT_SYMBOL(class_simple_destroy); * be created, showing the dev_t for the device. The pointer to the struct * class_device will be returned from the call. Any further sysfs files that * might be required can be created using this pointer. - * Note: the struct class_device passed to this function must have previously been + * Note: the struct class_simple passed to this function must have previously been * created with a call to class_simple_create(). */ struct class_device *class_simple_device_add(struct class_simple *cs, dev_t dev, struct device *device, const char *fmt, ...)