diff options
author | Tejun Heo <htejun@gmail.com> | 2007-06-13 14:45:17 -0400 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2007-07-11 19:09:06 -0400 |
commit | 7b595756ec1f49e0049a9e01a1298d53a7faaa15 (patch) | |
tree | cd06687ab3e5c7a5a4ef91903dff207a18c4db76 /drivers/s390 | |
parent | dbde0fcf9f8f6d477af3c32d9979e789ee680cde (diff) |
sysfs: kill unnecessary attribute->owner
sysfs is now completely out of driver/module lifetime game. After
deletion, a sysfs node doesn't access anything outside sysfs proper,
so there's no reason to hold onto the attribute owners. Note that
often the wrong modules were accounted for as owners leading to
accessing removed modules.
This patch kills now unnecessary attribute->owner. Note that with
this change, userland holding a sysfs node does not prevent the
backing module from being unloaded.
For more info regarding lifetime rule cleanup, please read the
following message.
http://article.gmane.org/gmane.linux.kernel/510293
(tweaked by Greg to not delete the field just yet, to make it easier to
merge things properly.)
Signed-off-by: Tejun Heo <htejun@gmail.com>
Cc: Cornelia Huck <cornelia.huck@de.ibm.com>
Cc: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/s390')
-rw-r--r-- | drivers/s390/cio/chp.c | 2 | ||||
-rw-r--r-- | drivers/s390/net/qeth_sys.c | 2 |
2 files changed, 1 insertions, 3 deletions
diff --git a/drivers/s390/cio/chp.c b/drivers/s390/cio/chp.c index ac289e6eadfe..96a8a72a6083 100644 --- a/drivers/s390/cio/chp.c +++ b/drivers/s390/cio/chp.c | |||
@@ -165,7 +165,6 @@ static struct bin_attribute chp_measurement_chars_attr = { | |||
165 | .attr = { | 165 | .attr = { |
166 | .name = "measurement_chars", | 166 | .name = "measurement_chars", |
167 | .mode = S_IRUSR, | 167 | .mode = S_IRUSR, |
168 | .owner = THIS_MODULE, | ||
169 | }, | 168 | }, |
170 | .size = sizeof(struct cmg_chars), | 169 | .size = sizeof(struct cmg_chars), |
171 | .read = chp_measurement_chars_read, | 170 | .read = chp_measurement_chars_read, |
@@ -217,7 +216,6 @@ static struct bin_attribute chp_measurement_attr = { | |||
217 | .attr = { | 216 | .attr = { |
218 | .name = "measurement", | 217 | .name = "measurement", |
219 | .mode = S_IRUSR, | 218 | .mode = S_IRUSR, |
220 | .owner = THIS_MODULE, | ||
221 | }, | 219 | }, |
222 | .size = sizeof(struct cmg_entry), | 220 | .size = sizeof(struct cmg_entry), |
223 | .read = chp_measurement_read, | 221 | .read = chp_measurement_read, |
diff --git a/drivers/s390/net/qeth_sys.c b/drivers/s390/net/qeth_sys.c index 65ffc21afc37..bb0287ad1aac 100644 --- a/drivers/s390/net/qeth_sys.c +++ b/drivers/s390/net/qeth_sys.c | |||
@@ -991,7 +991,7 @@ static struct attribute_group qeth_osn_device_attr_group = { | |||
991 | 991 | ||
992 | #define QETH_DEVICE_ATTR(_id,_name,_mode,_show,_store) \ | 992 | #define QETH_DEVICE_ATTR(_id,_name,_mode,_show,_store) \ |
993 | struct device_attribute dev_attr_##_id = { \ | 993 | struct device_attribute dev_attr_##_id = { \ |
994 | .attr = {.name=__stringify(_name), .mode=_mode, .owner=THIS_MODULE },\ | 994 | .attr = {.name=__stringify(_name), .mode=_mode, },\ |
995 | .show = _show, \ | 995 | .show = _show, \ |
996 | .store = _store, \ | 996 | .store = _store, \ |
997 | }; | 997 | }; |