The following comment is found in include/linux/sysfs.h:
/* FIXME
* The *owner field is no longer used.
* x86 tree has been cleaned up. The owner
* attribute is still left for other arches.
*/
As it turns out, the *owner field is (again?) initialized in several modules,
suggesting that such initialization may be creeping back into the code.
This patch set removes the above comment, the *owner field, and each instance
in the code where it was found to be initialized.
Compiled with x86 allmodconfig as well as with all alpha, arm, mips, powerpc,
and sparc defconfig builds.
Signed-off-by: Guenter Roeck <[email protected]>
---
drivers/leds/leds-bd2802.c | 4 +---
1 files changed, 1 insertions(+), 3 deletions(-)
diff --git a/drivers/leds/leds-bd2802.c b/drivers/leds/leds-bd2802.c
index 5dcdf9d..19dc4b6 100644
--- a/drivers/leds/leds-bd2802.c
+++ b/drivers/leds/leds-bd2802.c
@@ -351,7 +351,7 @@ static ssize_t bd2802_store_reg##reg_addr(struct device *dev, \
return count; \
} \
static struct device_attribute bd2802_reg##reg_addr##_attr = { \
- .attr = {.name = reg_name, .mode = 0644, .owner = THIS_MODULE}, \
+ .attr = {.name = reg_name, .mode = 0644}, \
.store = bd2802_store_reg##reg_addr, \
};
@@ -482,7 +482,6 @@ static struct device_attribute bd2802_adv_conf_attr = {
.attr = {
.name = "advanced_configuration",
.mode = 0644,
- .owner = THIS_MODULE
},
.show = bd2802_show_adv_conf,
.store = bd2802_store_adv_conf,
@@ -519,7 +518,6 @@ static struct device_attribute bd2802_##attr_name##_attr = { \
.attr = { \
.name = name_str, \
.mode = 0644, \
- .owner = THIS_MODULE \
}, \
.show = bd2802_show_##attr_name, \
.store = bd2802_store_##attr_name, \
--
1.7.0.87.g0901d
Signed-off-by: Guenter Roeck <[email protected]>
---
arch/powerpc/sysdev/mv64x60_pci.c | 1 -
1 files changed, 0 insertions(+), 1 deletions(-)
diff --git a/arch/powerpc/sysdev/mv64x60_pci.c b/arch/powerpc/sysdev/mv64x60_pci.c
index 198f288..77bb3f4 100644
--- a/arch/powerpc/sysdev/mv64x60_pci.c
+++ b/arch/powerpc/sysdev/mv64x60_pci.c
@@ -73,7 +73,6 @@ static struct bin_attribute mv64x60_hs_reg_attr = { /* Hotswap register */
.attr = {
.name = "hs_reg",
.mode = S_IRUGO | S_IWUSR,
- .owner = THIS_MODULE,
},
.size = MV64X60_VAL_LEN_MAX,
.read = mv64x60_hs_reg_read,
--
1.7.0.87.g0901d
Signed-off-by: Guenter Roeck <[email protected]>
---
drivers/scsi/arcmsr/arcmsr_attr.c | 3 ---
1 files changed, 0 insertions(+), 3 deletions(-)
diff --git a/drivers/scsi/arcmsr/arcmsr_attr.c b/drivers/scsi/arcmsr/arcmsr_attr.c
index 07fdfe5..a4e04c5 100644
--- a/drivers/scsi/arcmsr/arcmsr_attr.c
+++ b/drivers/scsi/arcmsr/arcmsr_attr.c
@@ -192,7 +192,6 @@ static struct bin_attribute arcmsr_sysfs_message_read_attr = {
.attr = {
.name = "mu_read",
.mode = S_IRUSR ,
- .owner = THIS_MODULE,
},
.size = 1032,
.read = arcmsr_sysfs_iop_message_read,
@@ -202,7 +201,6 @@ static struct bin_attribute arcmsr_sysfs_message_write_attr = {
.attr = {
.name = "mu_write",
.mode = S_IWUSR,
- .owner = THIS_MODULE,
},
.size = 1032,
.write = arcmsr_sysfs_iop_message_write,
@@ -212,7 +210,6 @@ static struct bin_attribute arcmsr_sysfs_message_clear_attr = {
.attr = {
.name = "mu_clear",
.mode = S_IWUSR,
- .owner = THIS_MODULE,
},
.size = 1,
.write = arcmsr_sysfs_iop_message_clear,
--
1.7.0.87.g0901d
Signed-off-by: Guenter Roeck <[email protected]>
---
include/linux/sysfs.h | 6 ------
1 files changed, 0 insertions(+), 6 deletions(-)
diff --git a/include/linux/sysfs.h b/include/linux/sysfs.h
index f2694eb..880fa1a 100644
--- a/include/linux/sysfs.h
+++ b/include/linux/sysfs.h
@@ -22,14 +22,8 @@ struct kobject;
struct module;
enum kobj_ns_type;
-/* FIXME
- * The *owner field is no longer used.
- * x86 tree has been cleaned up. The owner
- * attribute is still left for other arches.
- */
struct attribute {
const char *name;
- struct module *owner;
mode_t mode;
#ifdef CONFIG_DEBUG_LOCK_ALLOC
struct lock_class_key *key;
--
1.7.0.87.g0901d
Signed-off-by: Guenter Roeck <[email protected]>
---
drivers/scsi/lpfc/lpfc_attr.c | 1 -
1 files changed, 0 insertions(+), 1 deletions(-)
diff --git a/drivers/scsi/lpfc/lpfc_attr.c b/drivers/scsi/lpfc/lpfc_attr.c
index bf33b31..8f89edf 100644
--- a/drivers/scsi/lpfc/lpfc_attr.c
+++ b/drivers/scsi/lpfc/lpfc_attr.c
@@ -2720,7 +2720,6 @@ static struct bin_attribute sysfs_drvr_stat_data_attr = {
.attr = {
.name = "lpfc_drvr_stat_data",
.mode = S_IRUSR,
- .owner = THIS_MODULE,
},
.size = LPFC_MAX_TARGET * MAX_STAT_DATA_SIZE_PER_TARGET,
.read = sysfs_drvr_stat_data_read,
--
1.7.0.87.g0901d
Signed-off-by: Guenter Roeck <[email protected]>
---
drivers/regulator/core.c | 1 -
1 files changed, 0 insertions(+), 1 deletions(-)
diff --git a/drivers/regulator/core.c b/drivers/regulator/core.c
index 2248087..422a709 100644
--- a/drivers/regulator/core.c
+++ b/drivers/regulator/core.c
@@ -1025,7 +1025,6 @@ static struct regulator *create_regulator(struct regulator_dev *rdev,
if (regulator->dev_attr.attr.name == NULL)
goto attr_name_err;
- regulator->dev_attr.attr.owner = THIS_MODULE;
regulator->dev_attr.attr.mode = 0444;
regulator->dev_attr.show = device_requested_uA_show;
err = device_create_file(dev, ®ulator->dev_attr);
--
1.7.0.87.g0901d
On Wed, Jul 28, 2010 at 10:09 PM, Guenter Roeck
<[email protected]> wrote:
> The following comment is found in include/linux/sysfs.h:
>
> ? /* FIXME
> ? ?* The *owner field is no longer used.
> ? ?* x86 tree has been cleaned up. The owner
> ? ?* attribute is still left for other arches.
> ? ?*/
>
> As it turns out, the *owner field is (again?) initialized in several modules,
> suggesting that such initialization may be creeping back into the code.
>
> This patch set removes the above comment, the *owner field, and each instance
> in the code where it was found to be initialized.
>
> Compiled with x86 allmodconfig as well as with all alpha, arm, mips, powerpc,
> and sparc defconfig builds.
This seems reasonable to me. Can we get this in linux-next?
Eric
On Wed, Jul 28, 2010 at 10:09:24PM -0700, Guenter Roeck wrote:
> Signed-off-by: Guenter Roeck <[email protected]>
Acked-by: Mark Brown <[email protected]>
On 07/29/2010 07:09 AM, Guenter Roeck wrote:
> The following comment is found in include/linux/sysfs.h:
>
> /* FIXME
> * The *owner field is no longer used.
> * x86 tree has been cleaned up. The owner
> * attribute is still left for other arches.
> */
>
> As it turns out, the *owner field is (again?) initialized in several modules,
> suggesting that such initialization may be creeping back into the code.
>
> This patch set removes the above comment, the *owner field, and each instance
> in the code where it was found to be initialized.
>
> Compiled with x86 allmodconfig as well as with all alpha, arm, mips, powerpc,
> and sparc defconfig builds.
Yeah, the change is way overdue. Maybe we should have just removed
them back then.
Acked-by: Tejun Heo <[email protected]>
Thanks.
--
tejun
On Fri, 2010-07-30 at 10:45 +0200, Tejun Heo wrote:
> On 07/29/2010 07:09 AM, Guenter Roeck wrote:
> > The following comment is found in include/linux/sysfs.h:
> >
> > /* FIXME
> > * The *owner field is no longer used.
> > * x86 tree has been cleaned up. The owner
> > * attribute is still left for other arches.
> > */
> >
> > As it turns out, the *owner field is (again?) initialized in several modules,
> > suggesting that such initialization may be creeping back into the code.
> >
> > This patch set removes the above comment, the *owner field, and each instance
> > in the code where it was found to be initialized.
> >
> > Compiled with x86 allmodconfig as well as with all alpha, arm, mips, powerpc,
> > and sparc defconfig builds.
>
> Yeah, the change is way overdue. Maybe we should have just removed
> them back then.
I'm happy with the powerpc related patches as long as we all agree that
needs to go. Do you need me to put some of this in powerpc.git or are
you carrying them all to Linus ?
Cheers,
Ben.
> Acked-by: Tejun Heo <[email protected]>
>
> Thanks.
>
On Fri, Jul 30, 2010 at 08:28:10PM +1000, Benjamin Herrenschmidt wrote:
> On Fri, 2010-07-30 at 10:45 +0200, Tejun Heo wrote:
> > On 07/29/2010 07:09 AM, Guenter Roeck wrote:
> > > The following comment is found in include/linux/sysfs.h:
> > >
> > > /* FIXME
> > > * The *owner field is no longer used.
> > > * x86 tree has been cleaned up. The owner
> > > * attribute is still left for other arches.
> > > */
> > >
> > > As it turns out, the *owner field is (again?) initialized in several modules,
> > > suggesting that such initialization may be creeping back into the code.
> > >
> > > This patch set removes the above comment, the *owner field, and each instance
> > > in the code where it was found to be initialized.
> > >
> > > Compiled with x86 allmodconfig as well as with all alpha, arm, mips, powerpc,
> > > and sparc defconfig builds.
> >
> > Yeah, the change is way overdue. Maybe we should have just removed
> > them back then.
>
> I'm happy with the powerpc related patches as long as we all agree that
> needs to go. Do you need me to put some of this in powerpc.git or are
> you carrying them all to Linus ?
I can carry them all in my driver-core tree if you don't object.
thanks,
greg k-h
On Fri, 2010-07-30 at 10:36 -0400, Greg KH wrote:
> On Fri, Jul 30, 2010 at 08:28:10PM +1000, Benjamin Herrenschmidt wrote:
> > On Fri, 2010-07-30 at 10:45 +0200, Tejun Heo wrote:
> > > On 07/29/2010 07:09 AM, Guenter Roeck wrote:
> > > > The following comment is found in include/linux/sysfs.h:
> > > >
> > > > /* FIXME
> > > > * The *owner field is no longer used.
> > > > * x86 tree has been cleaned up. The owner
> > > > * attribute is still left for other arches.
> > > > */
> > > >
> > > > As it turns out, the *owner field is (again?) initialized in several modules,
> > > > suggesting that such initialization may be creeping back into the code.
> > > >
> > > > This patch set removes the above comment, the *owner field, and each instance
> > > > in the code where it was found to be initialized.
> > > >
> > > > Compiled with x86 allmodconfig as well as with all alpha, arm, mips, powerpc,
> > > > and sparc defconfig builds.
> > >
> > > Yeah, the change is way overdue. Maybe we should have just removed
> > > them back then.
> >
> > I'm happy with the powerpc related patches as long as we all agree that
> > needs to go. Do you need me to put some of this in powerpc.git or are
> > you carrying them all to Linus ?
>
> I can carry them all in my driver-core tree if you don't object.
>
Any final verdict ?
Not that it is my decision to make, but I think it would be better to
have it all in one tree. Otherwise the timing for the last patch would
get a bit complicated.
Thanks,
Guenter
On Mon, Aug 02, 2010 at 09:15:24AM -0700, Guenter Roeck wrote:
> On Fri, 2010-07-30 at 10:36 -0400, Greg KH wrote:
> > On Fri, Jul 30, 2010 at 08:28:10PM +1000, Benjamin Herrenschmidt wrote:
> > > On Fri, 2010-07-30 at 10:45 +0200, Tejun Heo wrote:
> > > > On 07/29/2010 07:09 AM, Guenter Roeck wrote:
> > > > > The following comment is found in include/linux/sysfs.h:
> > > > >
> > > > > /* FIXME
> > > > > * The *owner field is no longer used.
> > > > > * x86 tree has been cleaned up. The owner
> > > > > * attribute is still left for other arches.
> > > > > */
> > > > >
> > > > > As it turns out, the *owner field is (again?) initialized in several modules,
> > > > > suggesting that such initialization may be creeping back into the code.
> > > > >
> > > > > This patch set removes the above comment, the *owner field, and each instance
> > > > > in the code where it was found to be initialized.
> > > > >
> > > > > Compiled with x86 allmodconfig as well as with all alpha, arm, mips, powerpc,
> > > > > and sparc defconfig builds.
> > > >
> > > > Yeah, the change is way overdue. Maybe we should have just removed
> > > > them back then.
> > >
> > > I'm happy with the powerpc related patches as long as we all agree that
> > > needs to go. Do you need me to put some of this in powerpc.git or are
> > > you carrying them all to Linus ?
> >
> > I can carry them all in my driver-core tree if you don't object.
> >
> Any final verdict ?
>
> Not that it is my decision to make, but I think it would be better to
> have it all in one tree. Otherwise the timing for the last patch would
> get a bit complicated.
I'll take it.
thanks,
greg k-h
On Wed, Jul 28, 2010 at 11:16:35PM -0700, Eric Biederman wrote:
> On Wed, Jul 28, 2010 at 10:09 PM, Guenter Roeck
> <[email protected]> wrote:
> > The following comment is found in include/linux/sysfs.h:
> >
> > ? /* FIXME
> > ? ?* The *owner field is no longer used.
> > ? ?* x86 tree has been cleaned up. The owner
> > ? ?* attribute is still left for other arches.
> > ? ?*/
> >
> > As it turns out, the *owner field is (again?) initialized in several modules,
> > suggesting that such initialization may be creeping back into the code.
> >
> > This patch set removes the above comment, the *owner field, and each instance
> > in the code where it was found to be initialized.
> >
> > Compiled with x86 allmodconfig as well as with all alpha, arm, mips, powerpc,
> > and sparc defconfig builds.
>
> This seems reasonable to me. Can we get this in linux-next?
It will show up in linux-next tomorrow.
thanks,
greg k-h
On Mon, 2 Aug 2010 16:31:28 -0700, Greg KH wrote:
> On Wed, Jul 28, 2010 at 11:16:35PM -0700, Eric Biederman wrote:
> > On Wed, Jul 28, 2010 at 10:09 PM, Guenter Roeck
> > <[email protected]> wrote:
> > > The following comment is found in include/linux/sysfs.h:
> > >
> > > /* FIXME
> > > * The *owner field is no longer used.
> > > * x86 tree has been cleaned up. The owner
> > > * attribute is still left for other arches.
> > > */
> > >
> > > As it turns out, the *owner field is (again?) initialized in several modules,
> > > suggesting that such initialization may be creeping back into the code.
> > >
> > > This patch set removes the above comment, the *owner field, and each instance
> > > in the code where it was found to be initialized.
> > >
> > > Compiled with x86 allmodconfig as well as with all alpha, arm, mips, powerpc,
> > > and sparc defconfig builds.
> >
> > This seems reasonable to me. Can we get this in linux-next?
>
> It will show up in linux-next tomorrow.
Related bug?
https://bugzilla.kernel.org/show_bug.cgi?id=16544
--
Jean Delvare
Hi Jean,
On Tue, 10 Aug 2010 15:43:37 +0200 Jean Delvare <[email protected]> wrote:
>
> Related bug?
>
> https://bugzilla.kernel.org/show_bug.cgi?id=16544
Yep, fixed in linux-next today - hopefully the fix is on its way to Linus.
--
Cheers,
Stephen Rothwell [email protected]
http://www.canb.auug.org.au/~sfr/
Hi Jean,
On Wed, 11 Aug 2010 01:17:33 +1000 Stephen Rothwell <[email protected]> wrote:
>
> On Tue, 10 Aug 2010 15:43:37 +0200 Jean Delvare <[email protected]> wrote:
> >
> > Related bug?
> >
> > https://bugzilla.kernel.org/show_bug.cgi?id=16544
>
> Yep, fixed in linux-next today - hopefully the fix is on its way to Linus.
Sorry, more info:
Fixed by commit 690e85a3957291f4cfe0cac22d97994ec7e5ee45 ("olpc_battery:
Fix build failure caused by sysfs changes") from the battery tree.
--
Cheers,
Stephen Rothwell [email protected]
http://www.canb.auug.org.au/~sfr/
On Tue, 2010-08-10 at 11:20 -0400, Stephen Rothwell wrote:
> Hi Jean,
>
> On Wed, 11 Aug 2010 01:17:33 +1000 Stephen Rothwell <[email protected]> wrote:
> >
> > On Tue, 10 Aug 2010 15:43:37 +0200 Jean Delvare <[email protected]> wrote:
> > >
> > > Related bug?
> > >
> > > https://bugzilla.kernel.org/show_bug.cgi?id=16544
> >
> > Yep, fixed in linux-next today - hopefully the fix is on its way to Linus.
>
> Sorry, more info:
>
> Fixed by commit 690e85a3957291f4cfe0cac22d97994ec7e5ee45 ("olpc_battery:
> Fix build failure caused by sysfs changes") from the battery tree.
Excellent. Guess the patch I sent out earlier today to fix the problem
wasn't needed then.
Guenter