linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* linux-next: build warning after merge of the driver-core tree
@ 2019-08-01  5:05 Stephen Rothwell
  2019-08-01  6:10 ` Greg KH
  0 siblings, 1 reply; 41+ messages in thread
From: Stephen Rothwell @ 2019-08-01  5:05 UTC (permalink / raw)
  To: Greg KH
  Cc: Linux Next Mailing List, Linux Kernel Mailing List, Suzuki K Poulose

[-- Attachment #1: Type: text/plain, Size: 505 bytes --]

Hi all,

After merging the driver-core tree, today's linux-next build (x86_64
allmodconfig) produced this warning:

drivers/i2c/i2c-core-acpi.c:347:12: warning: 'i2c_acpi_find_match_adapter' defined but not used [-Wunused-function]
 static int i2c_acpi_find_match_adapter(struct device *dev, const void *data)
            ^~~~~~~~~~~~~~~~~~~~~~~~~~~

Introduced by commit

  00500147cbd3 ("drivers: Introduce device lookup variants by ACPI_COMPANION device")

-- 
Cheers,
Stephen Rothwell

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 488 bytes --]

^ permalink raw reply	[flat|nested] 41+ messages in thread

* Re: linux-next: build warning after merge of the driver-core tree
  2019-08-01  5:05 linux-next: build warning after merge of the driver-core tree Stephen Rothwell
@ 2019-08-01  6:10 ` Greg KH
  2019-08-01 10:20   ` [PATCH 1/3] i2c: Revert incorrect conversion to use generic helper Suzuki K Poulose
  0 siblings, 1 reply; 41+ messages in thread
From: Greg KH @ 2019-08-01  6:10 UTC (permalink / raw)
  To: Stephen Rothwell, Suzuki K Poulose
  Cc: Linux Next Mailing List, Linux Kernel Mailing List

On Thu, Aug 01, 2019 at 03:05:37PM +1000, Stephen Rothwell wrote:
> Hi all,
> 
> After merging the driver-core tree, today's linux-next build (x86_64
> allmodconfig) produced this warning:
> 
> drivers/i2c/i2c-core-acpi.c:347:12: warning: 'i2c_acpi_find_match_adapter' defined but not used [-Wunused-function]
>  static int i2c_acpi_find_match_adapter(struct device *dev, const void *data)
>             ^~~~~~~~~~~~~~~~~~~~~~~~~~~
> 
> Introduced by commit
> 
>   00500147cbd3 ("drivers: Introduce device lookup variants by ACPI_COMPANION device")

Oops, missed that one.

Suzuki, can you send a follow-on patch to fix this up?

thanks,

greg k-h

^ permalink raw reply	[flat|nested] 41+ messages in thread

* [PATCH 1/3] i2c: Revert incorrect conversion to use generic helper
  2019-08-01  6:10 ` Greg KH
@ 2019-08-01 10:20   ` Suzuki K Poulose
  2019-08-01 10:20     ` [PATCH 2/3] drivers: Fix typo in parameter description for driver_find_device_by_acpi_dev Suzuki K Poulose
                       ` (2 more replies)
  0 siblings, 3 replies; 41+ messages in thread
From: Suzuki K Poulose @ 2019-08-01 10:20 UTC (permalink / raw)
  To: gregkh
  Cc: linux-kernel, linux-next, sfr, lkp, Suzuki K Poulose,
	Mika Westerberg, Wolfram Sang

The patch "drivers: Introduce device lookup variants by ACPI_COMPANION device"
converted an incorrect instance in i2c driver to a new helper. Revert this
change.

Reported-by: Stephen Rothwell <sfr@canb.auug.org.au>
Cc: Mika Westerberg <mika.westerberg@linux.intel.com>
Cc: Wolfram Sang <wsa@the-dreams.de>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Suzuki K Poulose <suzuki.poulose@arm.com>
---
 drivers/i2c/i2c-core-acpi.c | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/drivers/i2c/i2c-core-acpi.c b/drivers/i2c/i2c-core-acpi.c
index bc80aafb521f..f60f7a95d48e 100644
--- a/drivers/i2c/i2c-core-acpi.c
+++ b/drivers/i2c/i2c-core-acpi.c
@@ -357,7 +357,10 @@ static int i2c_acpi_find_match_adapter(struct device *dev, const void *data)
 
 struct i2c_adapter *i2c_acpi_find_adapter_by_handle(acpi_handle handle)
 {
-	struct device *dev = bus_find_device_by_acpi_dev(&i2c_bus_type, handle);
+	struct device *dev;
+
+	dev = bus_find_device(&i2c_bus_type, NULL, handle,
+			      i2c_acpi_find_match_adapter);
 
 	return dev ? i2c_verify_adapter(dev) : NULL;
 }
-- 
2.21.0


^ permalink raw reply	[flat|nested] 41+ messages in thread

* [PATCH 2/3] drivers: Fix typo in parameter description for driver_find_device_by_acpi_dev
  2019-08-01 10:20   ` [PATCH 1/3] i2c: Revert incorrect conversion to use generic helper Suzuki K Poulose
@ 2019-08-01 10:20     ` Suzuki K Poulose
  2019-08-01 10:20     ` [PATCH 3/3] drivers: Fix htmldocs warnings with bus_find_next_device() Suzuki K Poulose
  2019-08-01 13:54     ` [PATCH 1/3] i2c: Revert incorrect conversion to use generic helper Greg KH
  2 siblings, 0 replies; 41+ messages in thread
From: Suzuki K Poulose @ 2019-08-01 10:20 UTC (permalink / raw)
  To: gregkh; +Cc: linux-kernel, linux-next, sfr, lkp, Suzuki K Poulose

Fix a typo in the comment describing the parameters for the new API, which
triggers the following warning for htmldocs:

include/linux/device.h:479: warning: Function parameter or member 'drv' not described in 'driver_find_device_by_acpi_dev'

Reported-by: kbuild test robot <lkp@intel.com>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Suzuki K Poulose <suzuki.poulose@arm.com>
---
 include/linux/device.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/include/linux/device.h b/include/linux/device.h
index 26af63847ca7..b17548b94c3e 100644
--- a/include/linux/device.h
+++ b/include/linux/device.h
@@ -467,7 +467,7 @@ driver_find_device_by_fwnode(struct device_driver *drv,
 /**
  * driver_find_device_by_devt- device iterator for locating a particular device
  * by devt.
- * @driver: the driver we're iterating
+ * @drv: the driver we're iterating
  * @devt: devt pointer to match.
  */
 static inline struct device *driver_find_device_by_devt(struct device_driver *drv,
-- 
2.21.0


^ permalink raw reply	[flat|nested] 41+ messages in thread

* [PATCH 3/3] drivers: Fix htmldocs warnings with bus_find_next_device()
  2019-08-01 10:20   ` [PATCH 1/3] i2c: Revert incorrect conversion to use generic helper Suzuki K Poulose
  2019-08-01 10:20     ` [PATCH 2/3] drivers: Fix typo in parameter description for driver_find_device_by_acpi_dev Suzuki K Poulose
@ 2019-08-01 10:20     ` Suzuki K Poulose
  2019-08-01 13:54     ` [PATCH 1/3] i2c: Revert incorrect conversion to use generic helper Greg KH
  2 siblings, 0 replies; 41+ messages in thread
From: Suzuki K Poulose @ 2019-08-01 10:20 UTC (permalink / raw)
  To: gregkh; +Cc: linux-kernel, linux-next, sfr, lkp, Suzuki K Poulose

Document the parameters for bus_find_next_device() to avoid
htmldocs build warnings as reported below :

include/linux/device.h:236: warning: Function parameter or member 'bus' not described in 'bus_find_next_device'
include/linux/device.h:236: warning: Function parameter or member 'cur' not described in 'bus_find_next_device'

Reported-by: kbuild test robot <lkp@intel.com>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Suzuki K Poulose <suzuki.poulose@arm.com>
---
 include/linux/device.h | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/include/linux/device.h b/include/linux/device.h
index b17548b94c3e..ea0238c73a9c 100644
--- a/include/linux/device.h
+++ b/include/linux/device.h
@@ -229,6 +229,8 @@ static inline struct device *bus_find_device_by_devt(struct bus_type *bus,
 /**
  * bus_find_next_device - Find the next device after a given device in a
  * given bus.
+ * @bus: bus type
+ * @cur: device to begin the search with.
  */
 static inline struct device *
 bus_find_next_device(struct bus_type *bus,struct device *cur)
-- 
2.21.0


^ permalink raw reply	[flat|nested] 41+ messages in thread

* Re: [PATCH 1/3] i2c: Revert incorrect conversion to use generic helper
  2019-08-01 10:20   ` [PATCH 1/3] i2c: Revert incorrect conversion to use generic helper Suzuki K Poulose
  2019-08-01 10:20     ` [PATCH 2/3] drivers: Fix typo in parameter description for driver_find_device_by_acpi_dev Suzuki K Poulose
  2019-08-01 10:20     ` [PATCH 3/3] drivers: Fix htmldocs warnings with bus_find_next_device() Suzuki K Poulose
@ 2019-08-01 13:54     ` Greg KH
  2019-08-01 14:03       ` Suzuki K Poulose
  2 siblings, 1 reply; 41+ messages in thread
From: Greg KH @ 2019-08-01 13:54 UTC (permalink / raw)
  To: Suzuki K Poulose
  Cc: linux-kernel, linux-next, sfr, lkp, Mika Westerberg, Wolfram Sang

On Thu, Aug 01, 2019 at 11:20:24AM +0100, Suzuki K Poulose wrote:
> The patch "drivers: Introduce device lookup variants by ACPI_COMPANION device"
> converted an incorrect instance in i2c driver to a new helper. Revert this
> change.
> 
> Reported-by: Stephen Rothwell <sfr@canb.auug.org.au>
> Cc: Mika Westerberg <mika.westerberg@linux.intel.com>
> Cc: Wolfram Sang <wsa@the-dreams.de>
> Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>

Fixes: 00500147cbd3 ("drivers: Introduce device lookup variants by ACPI_COMPANION device")

I'll go add this...

^ permalink raw reply	[flat|nested] 41+ messages in thread

* Re: [PATCH 1/3] i2c: Revert incorrect conversion to use generic helper
  2019-08-01 13:54     ` [PATCH 1/3] i2c: Revert incorrect conversion to use generic helper Greg KH
@ 2019-08-01 14:03       ` Suzuki K Poulose
  2019-08-01 14:05         ` Greg KH
  0 siblings, 1 reply; 41+ messages in thread
From: Suzuki K Poulose @ 2019-08-01 14:03 UTC (permalink / raw)
  To: gregkh; +Cc: linux-kernel, linux-next, sfr, lkp, mika.westerberg, wsa

On 08/01/2019 02:54 PM, Greg KH wrote:
> On Thu, Aug 01, 2019 at 11:20:24AM +0100, Suzuki K Poulose wrote:
>> The patch "drivers: Introduce device lookup variants by ACPI_COMPANION device"
>> converted an incorrect instance in i2c driver to a new helper. Revert this
>> change.
>>
>> Reported-by: Stephen Rothwell <sfr@canb.auug.org.au>
>> Cc: Mika Westerberg <mika.westerberg@linux.intel.com>
>> Cc: Wolfram Sang <wsa@the-dreams.de>
>> Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
> 
> Fixes: 00500147cbd3 ("drivers: Introduce device lookup variants by ACPI_COMPANION device")
> 
> I'll go add this...

Thanks Greg ! Sorry, I thought the commit ids may change in linus's and
thus I referred to the "commit subject"

Cheers



^ permalink raw reply	[flat|nested] 41+ messages in thread

* Re: [PATCH 1/3] i2c: Revert incorrect conversion to use generic helper
  2019-08-01 14:03       ` Suzuki K Poulose
@ 2019-08-01 14:05         ` Greg KH
  0 siblings, 0 replies; 41+ messages in thread
From: Greg KH @ 2019-08-01 14:05 UTC (permalink / raw)
  To: Suzuki K Poulose; +Cc: linux-kernel, linux-next, sfr, lkp, mika.westerberg, wsa

On Thu, Aug 01, 2019 at 03:03:06PM +0100, Suzuki K Poulose wrote:
> On 08/01/2019 02:54 PM, Greg KH wrote:
> > On Thu, Aug 01, 2019 at 11:20:24AM +0100, Suzuki K Poulose wrote:
> > > The patch "drivers: Introduce device lookup variants by ACPI_COMPANION device"
> > > converted an incorrect instance in i2c driver to a new helper. Revert this
> > > change.
> > > 
> > > Reported-by: Stephen Rothwell <sfr@canb.auug.org.au>
> > > Cc: Mika Westerberg <mika.westerberg@linux.intel.com>
> > > Cc: Wolfram Sang <wsa@the-dreams.de>
> > > Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
> > 
> > Fixes: 00500147cbd3 ("drivers: Introduce device lookup variants by ACPI_COMPANION device")
> > 
> > I'll go add this...
> 
> Thanks Greg ! Sorry, I thought the commit ids may change in linus's and
> thus I referred to the "commit subject"

Once they are in my -next branch, they will not change.

thanks,

greg k-h

^ permalink raw reply	[flat|nested] 41+ messages in thread

* Re: linux-next: build warning after merge of the driver-core tree
  2020-09-09  7:23 linux-next: build warning after merge of the driver-core tree Stephen Rothwell
@ 2020-09-09  7:40 ` Greg KH
  0 siblings, 0 replies; 41+ messages in thread
From: Greg KH @ 2020-09-09  7:40 UTC (permalink / raw)
  To: Stephen Rothwell
  Cc: Ulf Hansson, Krzysztof Kozlowski, Andy Shevchenko,
	Linux Next Mailing List, Linux Kernel Mailing List

On Wed, Sep 09, 2020 at 05:23:17PM +1000, Stephen Rothwell wrote:
> Hi all,
> 
> After merging the driver-core tree, today's linux-next build produced
> this warning:
> 
> drivers/mmc/host/davinci_mmc.c: In function 'davinci_mmcsd_probe':
> drivers/mmc/host/davinci_mmc.c:1243:4: warning: ignoring return value of 'dev_err_probe' declared with attribute 'warn_unused_result' [-Wunused-result]
>  1243 |    dev_err_probe(&pdev->dev, ret,
>       |    ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>  1244 |           "could not parse of data\n");
>       |           ~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> 
> Introduced by commit
> 
>   e1f82a0dcf38 ("driver core: Annotate dev_err_probe() with __must_check")
> 
> interacting with commit
> 
>   3a35e7e1bd50 ("mmc: davinci: Simplify with dev_err_probe()")
> 
> from the mmc tree.

Offending patch now dropped from the driver-core tree, thanks.

greg k-h

^ permalink raw reply	[flat|nested] 41+ messages in thread

* linux-next: build warning after merge of the driver-core tree
@ 2020-09-09  7:23 Stephen Rothwell
  2020-09-09  7:40 ` Greg KH
  0 siblings, 1 reply; 41+ messages in thread
From: Stephen Rothwell @ 2020-09-09  7:23 UTC (permalink / raw)
  To: Greg KH, Ulf Hansson
  Cc: Krzysztof Kozlowski, Andy Shevchenko, Linux Next Mailing List,
	Linux Kernel Mailing List

[-- Attachment #1: Type: text/plain, Size: 754 bytes --]

Hi all,

After merging the driver-core tree, today's linux-next build produced
this warning:

drivers/mmc/host/davinci_mmc.c: In function 'davinci_mmcsd_probe':
drivers/mmc/host/davinci_mmc.c:1243:4: warning: ignoring return value of 'dev_err_probe' declared with attribute 'warn_unused_result' [-Wunused-result]
 1243 |    dev_err_probe(&pdev->dev, ret,
      |    ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
 1244 |           "could not parse of data\n");
      |           ~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Introduced by commit

  e1f82a0dcf38 ("driver core: Annotate dev_err_probe() with __must_check")

interacting with commit

  3a35e7e1bd50 ("mmc: davinci: Simplify with dev_err_probe()")

from the mmc tree.

-- 
Cheers,
Stephen Rothwell

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 488 bytes --]

^ permalink raw reply	[flat|nested] 41+ messages in thread

* Re: linux-next: build warning after merge of the driver-core tree
  2019-08-05  4:56 ` Stephen Rothwell
@ 2019-08-06  0:03   ` Saravana Kannan
  0 siblings, 0 replies; 41+ messages in thread
From: Saravana Kannan @ 2019-08-06  0:03 UTC (permalink / raw)
  To: Stephen Rothwell
  Cc: Greg KH, Linux Next Mailing List, Linux Kernel Mailing List

On Sun, Aug 4, 2019 at 9:56 PM Stephen Rothwell <sfr@canb.auug.org.au> wrote:
>
> Hi all,
>
> On Mon, 5 Aug 2019 13:04:03 +1000 Stephen Rothwell <sfr@canb.auug.org.au> wrote:
> >
> > After merging the driver-core tree, today's linux-next build (powerpc
> > ppc64_defconfig) produced this warning:
> >
> > drivers/of/platform.c:674:12: warning: 'of_link_to_suppliers' defined but not used [-Wunused-function]
> >  static int of_link_to_suppliers(struct device *dev)
> >             ^~~~~~~~~~~~~~~~~~~~
> >
> > Introduced by commit
> >
> >   690ff7881b26 ("of/platform: Add functional dependency link from DT bindings")
>
> It also produced this warning:
>
> drivers/of/platform.c: In function 'of_link_property':
> drivers/of/platform.c:650:18: warning: ?: using integer constants in boolean context [-Wint-in-bool-context]
>   return done ? 0 : -ENODEV;
>

Thanks for reporting Stephen!

I'll fix the bool vs int thing right away. Weird that no other
compilation caught it.

As for the function not used, I'll move all the new code into the
already existing ifndef CONFIG_PPC for now.

Looks like PPC doesn't populate platform devices from DT using the
generic of_platform_default_populate_init() in drivers/of/platform.c.
I tried grepping around, but I don't see clearly where all the devices
are populated from DT for PPC. I'm not familiar with PPC, so if you or
someone else can give me a pointer to how devices are populated in
PPC, that's be helpful. If there's interest in this series for PPC,
I'd be happy to add support to however PPC populates the devices from
DT -- specifically, creating device links for devices as they are
populated.

Thanks,
Saravana

^ permalink raw reply	[flat|nested] 41+ messages in thread

* Re: linux-next: build warning after merge of the driver-core tree
  2019-08-05  3:04 Stephen Rothwell
@ 2019-08-05  4:56 ` Stephen Rothwell
  2019-08-06  0:03   ` Saravana Kannan
  0 siblings, 1 reply; 41+ messages in thread
From: Stephen Rothwell @ 2019-08-05  4:56 UTC (permalink / raw)
  To: Greg KH
  Cc: Linux Next Mailing List, Linux Kernel Mailing List, Saravana Kannan

[-- Attachment #1: Type: text/plain, Size: 795 bytes --]

Hi all,

On Mon, 5 Aug 2019 13:04:03 +1000 Stephen Rothwell <sfr@canb.auug.org.au> wrote:
>
> After merging the driver-core tree, today's linux-next build (powerpc
> ppc64_defconfig) produced this warning:
> 
> drivers/of/platform.c:674:12: warning: 'of_link_to_suppliers' defined but not used [-Wunused-function]
>  static int of_link_to_suppliers(struct device *dev)
>             ^~~~~~~~~~~~~~~~~~~~
> 
> Introduced by commit
> 
>   690ff7881b26 ("of/platform: Add functional dependency link from DT bindings")

It also produced this warning:

drivers/of/platform.c: In function 'of_link_property':
drivers/of/platform.c:650:18: warning: ?: using integer constants in boolean context [-Wint-in-bool-context]
  return done ? 0 : -ENODEV;

-- 
Cheers,
Stephen Rothwell

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 488 bytes --]

^ permalink raw reply	[flat|nested] 41+ messages in thread

* linux-next: build warning after merge of the driver-core tree
@ 2019-08-05  3:04 Stephen Rothwell
  2019-08-05  4:56 ` Stephen Rothwell
  0 siblings, 1 reply; 41+ messages in thread
From: Stephen Rothwell @ 2019-08-05  3:04 UTC (permalink / raw)
  To: Greg KH
  Cc: Linux Next Mailing List, Linux Kernel Mailing List, Saravana Kannan

[-- Attachment #1: Type: text/plain, Size: 458 bytes --]

Hi all,

After merging the driver-core tree, today's linux-next build (powerpc
ppc64_defconfig) produced this warning:

drivers/of/platform.c:674:12: warning: 'of_link_to_suppliers' defined but not used [-Wunused-function]
 static int of_link_to_suppliers(struct device *dev)
            ^~~~~~~~~~~~~~~~~~~~

Introduced by commit

  690ff7881b26 ("of/platform: Add functional dependency link from DT bindings")

-- 
Cheers,
Stephen Rothwell

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 488 bytes --]

^ permalink raw reply	[flat|nested] 41+ messages in thread

* Re: linux-next: build warning after merge of the driver-core tree
  2019-07-04  6:24 Stephen Rothwell
@ 2019-07-04  8:21 ` Greg KH
  0 siblings, 0 replies; 41+ messages in thread
From: Greg KH @ 2019-07-04  8:21 UTC (permalink / raw)
  To: Stephen Rothwell; +Cc: Linux Next Mailing List, Linux Kernel Mailing List

On Thu, Jul 04, 2019 at 04:24:35PM +1000, Stephen Rothwell wrote:
> Hi all,
> 
> After merging the driver-core tree, today's linux-next build (x86_64
> allmodconfig) produced this warning:
> 
> fs/orangefs/orangefs-debugfs.c: In function 'orangefs_debugfs_init':
> fs/orangefs/orangefs-debugfs.c:193:1: warning: label 'out' defined but not used [-Wunused-label]
>  out:
>  ^~~
> fs/orangefs/orangefs-debugfs.c: In function 'orangefs_kernel_debug_init':
> fs/orangefs/orangefs-debugfs.c:204:17: warning: unused variable 'ret' [-Wunused-variable]
>   struct dentry *ret;
>                  ^~~
> 
> Introduced by commit
> 
>   f095adba36bb ("orangefs: no need to check return value of debugfs_create functions")

Ugh, sorry about that, will fix it up as well...


^ permalink raw reply	[flat|nested] 41+ messages in thread

* Re: linux-next: build warning after merge of the driver-core tree
  2019-07-04  6:17 Stephen Rothwell
@ 2019-07-04  6:30 ` Greg KH
  0 siblings, 0 replies; 41+ messages in thread
From: Greg KH @ 2019-07-04  6:30 UTC (permalink / raw)
  To: Stephen Rothwell; +Cc: Linux Next Mailing List, Linux Kernel Mailing List

On Thu, Jul 04, 2019 at 04:17:30PM +1000, Stephen Rothwell wrote:
> Hi all,
> 
> After merging the driver-core tree, today's linux-next build (arm
> multi_v7_defconfig) produced this warning:
> 
> fs/ubifs/debug.c: In function 'dbg_debugfs_init_fs':
> fs/ubifs/debug.c:2812:6: warning: unused variable 'err' [-Wunused-variable]
>   int err, n;
>       ^~~
> 
> Introduced by commit
> 
>   702d6a834b49 ("ubifs: no need to check return value of debugfs_create functions")

Argh, 0-day seems to have failed me here :(

Will go fix it up now, thanks.

greg k-h

^ permalink raw reply	[flat|nested] 41+ messages in thread

* linux-next: build warning after merge of the driver-core tree
@ 2019-07-04  6:24 Stephen Rothwell
  2019-07-04  8:21 ` Greg KH
  0 siblings, 1 reply; 41+ messages in thread
From: Stephen Rothwell @ 2019-07-04  6:24 UTC (permalink / raw)
  To: Greg KH; +Cc: Linux Next Mailing List, Linux Kernel Mailing List

[-- Attachment #1: Type: text/plain, Size: 661 bytes --]

Hi all,

After merging the driver-core tree, today's linux-next build (x86_64
allmodconfig) produced this warning:

fs/orangefs/orangefs-debugfs.c: In function 'orangefs_debugfs_init':
fs/orangefs/orangefs-debugfs.c:193:1: warning: label 'out' defined but not used [-Wunused-label]
 out:
 ^~~
fs/orangefs/orangefs-debugfs.c: In function 'orangefs_kernel_debug_init':
fs/orangefs/orangefs-debugfs.c:204:17: warning: unused variable 'ret' [-Wunused-variable]
  struct dentry *ret;
                 ^~~

Introduced by commit

  f095adba36bb ("orangefs: no need to check return value of debugfs_create functions")

-- 
Cheers,
Stephen Rothwell

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 488 bytes --]

^ permalink raw reply	[flat|nested] 41+ messages in thread

* linux-next: build warning after merge of the driver-core tree
@ 2019-07-04  6:17 Stephen Rothwell
  2019-07-04  6:30 ` Greg KH
  0 siblings, 1 reply; 41+ messages in thread
From: Stephen Rothwell @ 2019-07-04  6:17 UTC (permalink / raw)
  To: Greg KH; +Cc: Linux Next Mailing List, Linux Kernel Mailing List

[-- Attachment #1: Type: text/plain, Size: 426 bytes --]

Hi all,

After merging the driver-core tree, today's linux-next build (arm
multi_v7_defconfig) produced this warning:

fs/ubifs/debug.c: In function 'dbg_debugfs_init_fs':
fs/ubifs/debug.c:2812:6: warning: unused variable 'err' [-Wunused-variable]
  int err, n;
      ^~~

Introduced by commit

  702d6a834b49 ("ubifs: no need to check return value of debugfs_create functions")

-- 
Cheers,
Stephen Rothwell

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 488 bytes --]

^ permalink raw reply	[flat|nested] 41+ messages in thread

* Re: linux-next: build warning after merge of the driver-core tree
  2015-10-09  6:31               ` Viresh Kumar
@ 2015-10-09 20:49                 ` Rafael J. Wysocki
  0 siblings, 0 replies; 41+ messages in thread
From: Rafael J. Wysocki @ 2015-10-09 20:49 UTC (permalink / raw)
  To: Viresh Kumar, Stephen Rothwell
  Cc: Greg KH, linux-next list, Linux Kernel Mailing List

On Friday, October 09, 2015 12:01:55 PM Viresh Kumar wrote:
> On 09-10-15, 16:36, Stephen Rothwell wrote:
> > Hi Rafael,
> > 
> > On Thu, 08 Oct 2015 22:30:45 +0200 "Rafael J. Wysocki" <rjw@rjwysocki.net> wrote:
> > >
> > > On Thursday, October 08, 2015 12:39:54 PM Viresh Kumar wrote:
> > > > 1840995c52d4 PM / OPP: reuse of_parse_phandle()
> > > > f0489a5ef4d0 PM / OPP: Rename opp init/free table routines
> > > > 8f8d37b2537a PM / OPP: Prefix exported opp routines with dev_pm_opp_
> > > > 33692dc381f9 PM / OPP: Move opp core to its own directory
> > > > f59d3ee8480d PM / OPP: Move cpu specific code to opp/cpu.c
> > > > 5cb5fdbf3877 PM / OPP: Add debugfs support
> > > > 
> > > > I though you just dropped the last commit, but no.
> > > 
> > > My bad, I rebased the pm-opp branch, but then have forgotten to merge it.
> > > 
> > > Sorry about that, should be fixed now.
> > 
> > And the warnings are back :-)
> 
> Rafael did it incorrectly once again :)
> 
> He picked the faulty patch once again, which he should have dropped.

Right, sorry about that.

It should be gone now for real.

Thanks,
Rafael


^ permalink raw reply	[flat|nested] 41+ messages in thread

* Re: linux-next: build warning after merge of the driver-core tree
  2015-10-08 20:30           ` Rafael J. Wysocki
  2015-10-09  5:36             ` Stephen Rothwell
@ 2015-10-09  6:37             ` Viresh Kumar
  1 sibling, 0 replies; 41+ messages in thread
From: Viresh Kumar @ 2015-10-09  6:37 UTC (permalink / raw)
  To: Rafael J. Wysocki
  Cc: Stephen Rothwell, Greg KH, linux-next list, Linux Kernel Mailing List

On 08-10-15, 22:30, Rafael J. Wysocki wrote:
> You could have asked me to drop that commit when you decided to rework the API.
> 
> That would have been much less painful to everybody (and especially to the
> people who saw the breakage and have tried to fix it).

My apologies, I could have done more. And then the timing wasn't
great, as I went on a 10 day holiday right after Linaro conference.

-- 
viresh

^ permalink raw reply	[flat|nested] 41+ messages in thread

* Re: linux-next: build warning after merge of the driver-core tree
  2015-10-09  5:36             ` Stephen Rothwell
@ 2015-10-09  6:31               ` Viresh Kumar
  2015-10-09 20:49                 ` Rafael J. Wysocki
  0 siblings, 1 reply; 41+ messages in thread
From: Viresh Kumar @ 2015-10-09  6:31 UTC (permalink / raw)
  To: Stephen Rothwell
  Cc: Rafael J. Wysocki, Greg KH, linux-next list, Linux Kernel Mailing List

On 09-10-15, 16:36, Stephen Rothwell wrote:
> Hi Rafael,
> 
> On Thu, 08 Oct 2015 22:30:45 +0200 "Rafael J. Wysocki" <rjw@rjwysocki.net> wrote:
> >
> > On Thursday, October 08, 2015 12:39:54 PM Viresh Kumar wrote:
> > > 1840995c52d4 PM / OPP: reuse of_parse_phandle()
> > > f0489a5ef4d0 PM / OPP: Rename opp init/free table routines
> > > 8f8d37b2537a PM / OPP: Prefix exported opp routines with dev_pm_opp_
> > > 33692dc381f9 PM / OPP: Move opp core to its own directory
> > > f59d3ee8480d PM / OPP: Move cpu specific code to opp/cpu.c
> > > 5cb5fdbf3877 PM / OPP: Add debugfs support
> > > 
> > > I though you just dropped the last commit, but no.
> > 
> > My bad, I rebased the pm-opp branch, but then have forgotten to merge it.
> > 
> > Sorry about that, should be fixed now.
> 
> And the warnings are back :-)

Rafael did it incorrectly once again :)

He picked the faulty patch once again, which he should have dropped.

> Can someone (Viresh) just send me a patch on top of today's linux-next
> (when I release it) and I will us it as a merge fix patch from Monday
> and then hopefully it will be passed on to Linus at the right time.

Because that's what Rafael is going to do once he is back, can can
just revert

5cb5fdbf3877 PM / OPP: Add debugfs support

for the time being. Will that be fine?

-- 
viresh

^ permalink raw reply	[flat|nested] 41+ messages in thread

* Re: linux-next: build warning after merge of the driver-core tree
  2015-10-08 20:30           ` Rafael J. Wysocki
@ 2015-10-09  5:36             ` Stephen Rothwell
  2015-10-09  6:31               ` Viresh Kumar
  2015-10-09  6:37             ` Viresh Kumar
  1 sibling, 1 reply; 41+ messages in thread
From: Stephen Rothwell @ 2015-10-09  5:36 UTC (permalink / raw)
  To: Rafael J. Wysocki
  Cc: Viresh Kumar, Greg KH, linux-next list, Linux Kernel Mailing List

Hi Rafael,

On Thu, 08 Oct 2015 22:30:45 +0200 "Rafael J. Wysocki" <rjw@rjwysocki.net> wrote:
>
> On Thursday, October 08, 2015 12:39:54 PM Viresh Kumar wrote:
> > 1840995c52d4 PM / OPP: reuse of_parse_phandle()
> > f0489a5ef4d0 PM / OPP: Rename opp init/free table routines
> > 8f8d37b2537a PM / OPP: Prefix exported opp routines with dev_pm_opp_
> > 33692dc381f9 PM / OPP: Move opp core to its own directory
> > f59d3ee8480d PM / OPP: Move cpu specific code to opp/cpu.c
> > 5cb5fdbf3877 PM / OPP: Add debugfs support
> > 
> > I though you just dropped the last commit, but no.
> 
> My bad, I rebased the pm-opp branch, but then have forgotten to merge it.
> 
> Sorry about that, should be fixed now.

And the warnings are back :-)

Can someone (Viresh) just send me a patch on top of today's linux-next
(when I release it) and I will us it as a merge fix patch from Monday
and then hopefully it will be passed on to Linus at the right time.
-- 
Cheers,
Stephen Rothwell                    sfr@canb.auug.org.au

^ permalink raw reply	[flat|nested] 41+ messages in thread

* Re: linux-next: build warning after merge of the driver-core tree
  2015-10-08  7:09         ` Viresh Kumar
@ 2015-10-08 20:30           ` Rafael J. Wysocki
  2015-10-09  5:36             ` Stephen Rothwell
  2015-10-09  6:37             ` Viresh Kumar
  0 siblings, 2 replies; 41+ messages in thread
From: Rafael J. Wysocki @ 2015-10-08 20:30 UTC (permalink / raw)
  To: Viresh Kumar
  Cc: Stephen Rothwell, Greg KH, linux-next list, Linux Kernel Mailing List

On Thursday, October 08, 2015 12:39:54 PM Viresh Kumar wrote:
> On 08-10-15, 00:47, Rafael J. Wysocki wrote:
> > Well, the conflicting commits here were from the same developer which is kind
> > of annoying.
> 
> I do understand why its annoying, but I wasn't doing them in parallel.
> The patches in Greg's tree were written long after the other series
> got applied to your tree.
> 
> So, I was kind of helpless here :(

You could have asked me to drop that commit when you decided to rework the API.

That would have been much less painful to everybody (and especially to the
people who saw the breakage and have tried to fix it).

> > The new use in my tree can wait until the API update in the Greg's tree is
> > merged IMO.  That's why I've now dropped the commit that added it. :-)
> 
> Looking at the current state of your tree, looks like you have dropped
> way too many patches. Was it intentional?
> 
> Missing commits:
> 
> 1840995c52d4 PM / OPP: reuse of_parse_phandle()
> f0489a5ef4d0 PM / OPP: Rename opp init/free table routines
> 8f8d37b2537a PM / OPP: Prefix exported opp routines with dev_pm_opp_
> 33692dc381f9 PM / OPP: Move opp core to its own directory
> f59d3ee8480d PM / OPP: Move cpu specific code to opp/cpu.c
> 5cb5fdbf3877 PM / OPP: Add debugfs support
> 
> I though you just dropped the last commit, but no.

My bad, I rebased the pm-opp branch, but then have forgotten to merge it.

Sorry about that, should be fixed now.

Thanks,
Rafael


^ permalink raw reply	[flat|nested] 41+ messages in thread

* Re: linux-next: build warning after merge of the driver-core tree
  2015-10-07 22:47       ` Rafael J. Wysocki
@ 2015-10-08  7:09         ` Viresh Kumar
  2015-10-08 20:30           ` Rafael J. Wysocki
  0 siblings, 1 reply; 41+ messages in thread
From: Viresh Kumar @ 2015-10-08  7:09 UTC (permalink / raw)
  To: Rafael J. Wysocki
  Cc: Stephen Rothwell, Greg KH, linux-next list, Linux Kernel Mailing List

On 08-10-15, 00:47, Rafael J. Wysocki wrote:
> Well, the conflicting commits here were from the same developer which is kind
> of annoying.

I do understand why its annoying, but I wasn't doing them in parallel.
The patches in Greg's tree were written long after the other series
got applied to your tree.

So, I was kind of helpless here :(

> The new use in my tree can wait until the API update in the Greg's tree is
> merged IMO.  That's why I've now dropped the commit that added it. :-)

Looking at the current state of your tree, looks like you have dropped
way too many patches. Was it intentional?

Missing commits:

1840995c52d4 PM / OPP: reuse of_parse_phandle()
f0489a5ef4d0 PM / OPP: Rename opp init/free table routines
8f8d37b2537a PM / OPP: Prefix exported opp routines with dev_pm_opp_
33692dc381f9 PM / OPP: Move opp core to its own directory
f59d3ee8480d PM / OPP: Move cpu specific code to opp/cpu.c
5cb5fdbf3877 PM / OPP: Add debugfs support

I though you just dropped the last commit, but no.

-- 
viresh

^ permalink raw reply	[flat|nested] 41+ messages in thread

* Re: linux-next: build warning after merge of the driver-core tree
  2015-10-07 22:04     ` Stephen Rothwell
@ 2015-10-07 22:47       ` Rafael J. Wysocki
  2015-10-08  7:09         ` Viresh Kumar
  0 siblings, 1 reply; 41+ messages in thread
From: Rafael J. Wysocki @ 2015-10-07 22:47 UTC (permalink / raw)
  To: Stephen Rothwell
  Cc: Viresh Kumar, Greg KH, linux-next list, Linux Kernel Mailing List

On Thursday, October 08, 2015 09:04:27 AM Stephen Rothwell wrote:
> Hi Rafael,
> 
> On Wed, 07 Oct 2015 23:48:11 +0200 "Rafael J. Wysocki" <rjw@rjwysocki.net> wrote:
> >
> > On Wednesday, October 07, 2015 08:40:59 AM Viresh Kumar wrote:
> > > 
> > > On 7 October 2015 at 06:51, Stephen Rothwell <sfr@canb.auug.org.au> wrote:
> > > >
> > > > After merging the driver-core tree, today's linux-next build (arm
> > > > multi_v7_defconfig) produced this warning:
> > > >
> > > > drivers/base/power/opp/debugfs.c: In function 'opp_debug_create_one':
> > > > drivers/base/power/opp/debugfs.c:48:7: warning: passing argument 4 of 'debugfs_create_bool' from incompatible pointer type
> > > >   if (!debugfs_create_bool("available", S_IRUGO, d,
> > > >        ^
> > > > In file included from drivers/base/power/opp/debugfs.c:13:0:
> > > > include/linux/debugfs.h:94:16: note: expected 'bool *' but argument is of type 'u32 *'
> > > >  struct dentry *debugfs_create_bool(const char *name, umode_t mode,
> > > >                 ^
> > > > drivers/base/power/opp/debugfs.c:52:7: warning: passing argument 4 of 'debugfs_create_bool' from incompatible pointer type
> > > >   if (!debugfs_create_bool("dynamic", S_IRUGO, d, (u32 *)&opp->dynamic))
> > > >        ^
> > > > In file included from drivers/base/power/opp/debugfs.c:13:0:
> > > > include/linux/debugfs.h:94:16: note: expected 'bool *' but argument is of type 'u32 *'
> > > >  struct dentry *debugfs_create_bool(const char *name, umode_t mode,
> > > >                 ^
> > > > drivers/base/power/opp/debugfs.c:55:7: warning: passing argument 4 of 'debugfs_create_bool' from incompatible pointer type
> > > >   if (!debugfs_create_bool("turbo", S_IRUGO, d, (u32 *)&opp->turbo))
> > > >        ^
> > > > In file included from drivers/base/power/opp/debugfs.c:13:0:
> > > > include/linux/debugfs.h:94:16: note: expected 'bool *' but argument is of type 'u32 *'
> > > >  struct dentry *debugfs_create_bool(const char *name, umode_t mode,
> > > >                 ^
> > > >
> > > > Introduced by commit
> > > >
> > > >   621a5f7ad9cd ("debugfs: Pass bool pointer to debugfs_create_bool()")
> > > >
> > > > interacting with commit
> > > >
> > > >   5cb5fdbf3877 ("PM / OPP: Add debugfs support")
> > > >
> > > > from the pm tree.
> > > 
> > > That was expected and the PM tree needs to get updated to get it fixed.
> > > And I will be doing that soon.
> > 
> > For the record, I'm tired of your breaking things on a regular basis like this.
> > 
> > I'm dropping 5cb5fdbf3877 from the PM tree.
> 
> To be fair, this is caused by in interaction between your tree and
> Greg's ... i.e. the API for debugfs_create_bool() was updated in Greg's
> tree while a new use of it was added to your tree.  It can only be
> fixed by one of you merging the other's tree (or part of it) or by
> someone giving me a merge resolution patch (or just a hint) and me
> carrying that (and someone remembering to tell Linus about it.

Well, the conflicting commits here were from the same developer which is kind
of annoying.

The new use in my tree can wait until the API update in the Greg's tree is
merged IMO.  That's why I've now dropped the commit that added it. :-)

Thanks,
Rafael


^ permalink raw reply	[flat|nested] 41+ messages in thread

* Re: linux-next: build warning after merge of the driver-core tree
  2015-10-07 21:48   ` Rafael J. Wysocki
@ 2015-10-07 22:04     ` Stephen Rothwell
  2015-10-07 22:47       ` Rafael J. Wysocki
  0 siblings, 1 reply; 41+ messages in thread
From: Stephen Rothwell @ 2015-10-07 22:04 UTC (permalink / raw)
  To: Rafael J. Wysocki
  Cc: Viresh Kumar, Greg KH, linux-next list, Linux Kernel Mailing List

Hi Rafael,

On Wed, 07 Oct 2015 23:48:11 +0200 "Rafael J. Wysocki" <rjw@rjwysocki.net> wrote:
>
> On Wednesday, October 07, 2015 08:40:59 AM Viresh Kumar wrote:
> > 
> > On 7 October 2015 at 06:51, Stephen Rothwell <sfr@canb.auug.org.au> wrote:
> > >
> > > After merging the driver-core tree, today's linux-next build (arm
> > > multi_v7_defconfig) produced this warning:
> > >
> > > drivers/base/power/opp/debugfs.c: In function 'opp_debug_create_one':
> > > drivers/base/power/opp/debugfs.c:48:7: warning: passing argument 4 of 'debugfs_create_bool' from incompatible pointer type
> > >   if (!debugfs_create_bool("available", S_IRUGO, d,
> > >        ^
> > > In file included from drivers/base/power/opp/debugfs.c:13:0:
> > > include/linux/debugfs.h:94:16: note: expected 'bool *' but argument is of type 'u32 *'
> > >  struct dentry *debugfs_create_bool(const char *name, umode_t mode,
> > >                 ^
> > > drivers/base/power/opp/debugfs.c:52:7: warning: passing argument 4 of 'debugfs_create_bool' from incompatible pointer type
> > >   if (!debugfs_create_bool("dynamic", S_IRUGO, d, (u32 *)&opp->dynamic))
> > >        ^
> > > In file included from drivers/base/power/opp/debugfs.c:13:0:
> > > include/linux/debugfs.h:94:16: note: expected 'bool *' but argument is of type 'u32 *'
> > >  struct dentry *debugfs_create_bool(const char *name, umode_t mode,
> > >                 ^
> > > drivers/base/power/opp/debugfs.c:55:7: warning: passing argument 4 of 'debugfs_create_bool' from incompatible pointer type
> > >   if (!debugfs_create_bool("turbo", S_IRUGO, d, (u32 *)&opp->turbo))
> > >        ^
> > > In file included from drivers/base/power/opp/debugfs.c:13:0:
> > > include/linux/debugfs.h:94:16: note: expected 'bool *' but argument is of type 'u32 *'
> > >  struct dentry *debugfs_create_bool(const char *name, umode_t mode,
> > >                 ^
> > >
> > > Introduced by commit
> > >
> > >   621a5f7ad9cd ("debugfs: Pass bool pointer to debugfs_create_bool()")
> > >
> > > interacting with commit
> > >
> > >   5cb5fdbf3877 ("PM / OPP: Add debugfs support")
> > >
> > > from the pm tree.
> > 
> > That was expected and the PM tree needs to get updated to get it fixed.
> > And I will be doing that soon.
> 
> For the record, I'm tired of your breaking things on a regular basis like this.
> 
> I'm dropping 5cb5fdbf3877 from the PM tree.

To be fair, this is caused by in interaction between your tree and
Greg's ... i.e. the API for debugfs_create_bool() was updated in Greg's
tree while a new use of it was added to your tree.  It can only be
fixed by one of you merging the other's tree (or part of it) or by
someone giving me a merge resolution patch (or just a hint) and me
carrying that (and someone remembering to tell Linus about it.

-- 
Cheers,
Stephen Rothwell                    sfr@canb.auug.org.au

^ permalink raw reply	[flat|nested] 41+ messages in thread

* Re: linux-next: build warning after merge of the driver-core tree
  2015-10-07  6:40 ` Viresh Kumar
@ 2015-10-07 21:48   ` Rafael J. Wysocki
  2015-10-07 22:04     ` Stephen Rothwell
  0 siblings, 1 reply; 41+ messages in thread
From: Rafael J. Wysocki @ 2015-10-07 21:48 UTC (permalink / raw)
  To: Viresh Kumar
  Cc: Stephen Rothwell, Greg KH, linux-next list, Linux Kernel Mailing List

On Wednesday, October 07, 2015 08:40:59 AM Viresh Kumar wrote:
> Hi Stephen,
> 
> On 7 October 2015 at 06:51, Stephen Rothwell <sfr@canb.auug.org.au> wrote:
> > Hi Greg,
> >
> > After merging the driver-core tree, today's linux-next build (arm
> > multi_v7_defconfig) produced this warning:
> >
> > drivers/base/power/opp/debugfs.c: In function 'opp_debug_create_one':
> > drivers/base/power/opp/debugfs.c:48:7: warning: passing argument 4 of 'debugfs_create_bool' from incompatible pointer type
> >   if (!debugfs_create_bool("available", S_IRUGO, d,
> >        ^
> > In file included from drivers/base/power/opp/debugfs.c:13:0:
> > include/linux/debugfs.h:94:16: note: expected 'bool *' but argument is of type 'u32 *'
> >  struct dentry *debugfs_create_bool(const char *name, umode_t mode,
> >                 ^
> > drivers/base/power/opp/debugfs.c:52:7: warning: passing argument 4 of 'debugfs_create_bool' from incompatible pointer type
> >   if (!debugfs_create_bool("dynamic", S_IRUGO, d, (u32 *)&opp->dynamic))
> >        ^
> > In file included from drivers/base/power/opp/debugfs.c:13:0:
> > include/linux/debugfs.h:94:16: note: expected 'bool *' but argument is of type 'u32 *'
> >  struct dentry *debugfs_create_bool(const char *name, umode_t mode,
> >                 ^
> > drivers/base/power/opp/debugfs.c:55:7: warning: passing argument 4 of 'debugfs_create_bool' from incompatible pointer type
> >   if (!debugfs_create_bool("turbo", S_IRUGO, d, (u32 *)&opp->turbo))
> >        ^
> > In file included from drivers/base/power/opp/debugfs.c:13:0:
> > include/linux/debugfs.h:94:16: note: expected 'bool *' but argument is of type 'u32 *'
> >  struct dentry *debugfs_create_bool(const char *name, umode_t mode,
> >                 ^
> >
> > Introduced by commit
> >
> >   621a5f7ad9cd ("debugfs: Pass bool pointer to debugfs_create_bool()")
> >
> > interacting with commit
> >
> >   5cb5fdbf3877 ("PM / OPP: Add debugfs support")
> >
> > from the pm tree.
> 
> That was expected and the PM tree needs to get updated to get it fixed.
> And I will be doing that soon.

For the record, I'm tired of your breaking things on a regular basis like this.

I'm dropping 5cb5fdbf3877 from the PM tree.

Thanks,
Rafael


^ permalink raw reply	[flat|nested] 41+ messages in thread

* Re: linux-next: build warning after merge of the driver-core tree
  2015-10-07  4:51 Stephen Rothwell
@ 2015-10-07  6:40 ` Viresh Kumar
  2015-10-07 21:48   ` Rafael J. Wysocki
  0 siblings, 1 reply; 41+ messages in thread
From: Viresh Kumar @ 2015-10-07  6:40 UTC (permalink / raw)
  To: Stephen Rothwell
  Cc: Greg KH, Rafael J. Wysocki, linux-next list, Linux Kernel Mailing List

Hi Stephen,

On 7 October 2015 at 06:51, Stephen Rothwell <sfr@canb.auug.org.au> wrote:
> Hi Greg,
>
> After merging the driver-core tree, today's linux-next build (arm
> multi_v7_defconfig) produced this warning:
>
> drivers/base/power/opp/debugfs.c: In function 'opp_debug_create_one':
> drivers/base/power/opp/debugfs.c:48:7: warning: passing argument 4 of 'debugfs_create_bool' from incompatible pointer type
>   if (!debugfs_create_bool("available", S_IRUGO, d,
>        ^
> In file included from drivers/base/power/opp/debugfs.c:13:0:
> include/linux/debugfs.h:94:16: note: expected 'bool *' but argument is of type 'u32 *'
>  struct dentry *debugfs_create_bool(const char *name, umode_t mode,
>                 ^
> drivers/base/power/opp/debugfs.c:52:7: warning: passing argument 4 of 'debugfs_create_bool' from incompatible pointer type
>   if (!debugfs_create_bool("dynamic", S_IRUGO, d, (u32 *)&opp->dynamic))
>        ^
> In file included from drivers/base/power/opp/debugfs.c:13:0:
> include/linux/debugfs.h:94:16: note: expected 'bool *' but argument is of type 'u32 *'
>  struct dentry *debugfs_create_bool(const char *name, umode_t mode,
>                 ^
> drivers/base/power/opp/debugfs.c:55:7: warning: passing argument 4 of 'debugfs_create_bool' from incompatible pointer type
>   if (!debugfs_create_bool("turbo", S_IRUGO, d, (u32 *)&opp->turbo))
>        ^
> In file included from drivers/base/power/opp/debugfs.c:13:0:
> include/linux/debugfs.h:94:16: note: expected 'bool *' but argument is of type 'u32 *'
>  struct dentry *debugfs_create_bool(const char *name, umode_t mode,
>                 ^
>
> Introduced by commit
>
>   621a5f7ad9cd ("debugfs: Pass bool pointer to debugfs_create_bool()")
>
> interacting with commit
>
>   5cb5fdbf3877 ("PM / OPP: Add debugfs support")
>
> from the pm tree.

That was expected and the PM tree needs to get updated to get it fixed.
And I will be doing that soon.

--
viresh

^ permalink raw reply	[flat|nested] 41+ messages in thread

* linux-next: build warning after merge of the driver-core tree
@ 2015-10-07  4:51 Stephen Rothwell
  2015-10-07  6:40 ` Viresh Kumar
  0 siblings, 1 reply; 41+ messages in thread
From: Stephen Rothwell @ 2015-10-07  4:51 UTC (permalink / raw)
  To: Greg KH, Rafael J. Wysocki; +Cc: linux-next, linux-kernel, Viresh Kumar

Hi Greg,

After merging the driver-core tree, today's linux-next build (arm
multi_v7_defconfig) produced this warning:

drivers/base/power/opp/debugfs.c: In function 'opp_debug_create_one':
drivers/base/power/opp/debugfs.c:48:7: warning: passing argument 4 of 'debugfs_create_bool' from incompatible pointer type
  if (!debugfs_create_bool("available", S_IRUGO, d,
       ^
In file included from drivers/base/power/opp/debugfs.c:13:0:
include/linux/debugfs.h:94:16: note: expected 'bool *' but argument is of type 'u32 *'
 struct dentry *debugfs_create_bool(const char *name, umode_t mode,
                ^
drivers/base/power/opp/debugfs.c:52:7: warning: passing argument 4 of 'debugfs_create_bool' from incompatible pointer type
  if (!debugfs_create_bool("dynamic", S_IRUGO, d, (u32 *)&opp->dynamic))
       ^
In file included from drivers/base/power/opp/debugfs.c:13:0:
include/linux/debugfs.h:94:16: note: expected 'bool *' but argument is of type 'u32 *'
 struct dentry *debugfs_create_bool(const char *name, umode_t mode,
                ^
drivers/base/power/opp/debugfs.c:55:7: warning: passing argument 4 of 'debugfs_create_bool' from incompatible pointer type
  if (!debugfs_create_bool("turbo", S_IRUGO, d, (u32 *)&opp->turbo))
       ^
In file included from drivers/base/power/opp/debugfs.c:13:0:
include/linux/debugfs.h:94:16: note: expected 'bool *' but argument is of type 'u32 *'
 struct dentry *debugfs_create_bool(const char *name, umode_t mode,
                ^

Introduced by commit

  621a5f7ad9cd ("debugfs: Pass bool pointer to debugfs_create_bool()")

interacting with commit

  5cb5fdbf3877 ("PM / OPP: Add debugfs support")

from the pm tree.

-- 
Cheers,
Stephen Rothwell                    sfr@canb.auug.org.au

^ permalink raw reply	[flat|nested] 41+ messages in thread

* Re: linux-next: build warning after merge of the driver-core tree
  2013-06-25  8:33 Stephen Rothwell
@ 2013-06-25 12:00 ` Ming Lei
  0 siblings, 0 replies; 41+ messages in thread
From: Ming Lei @ 2013-06-25 12:00 UTC (permalink / raw)
  To: Stephen Rothwell; +Cc: Greg KH, linux-next, linux-kernel

On Tue, Jun 25, 2013 at 4:33 PM, Stephen Rothwell <sfr@canb.auug.org.au> wrote:
> Hi Greg,
>
> After merging the driver-core tree, today's linux-next build (powerpc
> allnoconfig) produced this warning:
>
> drivers/base/firmware_class.c:221:29: warning: 'fw_lookup_buf' defined but not used [-Wunused-function]
>
> Introduced by commit 90f8908127b5 ("firmware loader: fix compile warning
> with PM_SLEEP set").

OK, I will submit a patch to kill the warning later, thanks again for
your report.


Thanks,
--
Ming Lei

^ permalink raw reply	[flat|nested] 41+ messages in thread

* linux-next: build warning after merge of the driver-core tree
@ 2013-06-25  8:33 Stephen Rothwell
  2013-06-25 12:00 ` Ming Lei
  0 siblings, 1 reply; 41+ messages in thread
From: Stephen Rothwell @ 2013-06-25  8:33 UTC (permalink / raw)
  To: Greg KH; +Cc: linux-next, linux-kernel, Ming Lei

[-- Attachment #1: Type: text/plain, Size: 399 bytes --]

Hi Greg,

After merging the driver-core tree, today's linux-next build (powerpc
allnoconfig) produced this warning:

drivers/base/firmware_class.c:221:29: warning: 'fw_lookup_buf' defined but not used [-Wunused-function]

Introduced by commit 90f8908127b5 ("firmware loader: fix compile warning
with PM_SLEEP set").

-- 
Cheers,
Stephen Rothwell                    sfr@canb.auug.org.au

[-- Attachment #2: Type: application/pgp-signature, Size: 836 bytes --]

^ permalink raw reply	[flat|nested] 41+ messages in thread

* Re: linux-next: build warning after merge of the driver-core tree
  2011-02-21  5:50 ` Stephen Rothwell
  2011-02-21  6:31   ` Greg KH
@ 2011-03-17 23:10   ` Stephen Rothwell
  1 sibling, 0 replies; 41+ messages in thread
From: Stephen Rothwell @ 2011-03-17 23:10 UTC (permalink / raw)
  To: Kim B. Heino, Alessandro Zummo, Andrew Morton, Mark Jackson,
	Dennis Aberilla
  Cc: linux-next, linux-kernel, Greg KH

[-- Attachment #1: Type: text/plain, Size: 1700 bytes --]

Hi All,

On Mon, 21 Feb 2011 16:50:23 +1100 Stephen Rothwell <sfr@canb.auug.org.au> wrote:
>
> On Mon, 21 Feb 2011 16:37:27 +1100 Stephen Rothwell <sfr@canb.auug.org.au> wrote:
> >
> > After merging the driver-core tree, today's linux-next build (x86_64
> > allmodconfig) produced this warning:
> > 
> > drivers/rtc/rtc-m41t94.c: In function 'm41t94_remove':
> > drivers/rtc/rtc-m41t94.c:139: warning: passing argument 1 of 'platform_get_drvdata' from incompatible pointer type
> > include/linux/platform_device.h:133: note: expected 'const struct platform_device *' but argument is of type 'struct spi_device *'
> > 
> > Revealed by commit 71d642908d4e8e7a2a4a6e0490432e719ff466d5 ("Driver
> > core: convert platform_{get,set}_drvdata to static inline functions").
> > The warning is in code introduced by commit
> > 8fc2c767b06067b417c565c4e75731e68ed41fd8 ("rtc: add support for ST M41T94
> > SPI RTC").
> 
> There are also:
> 
> drivers/rtc/rtc-ds1390.c: In function 'ds1390_remove':
> drivers/rtc/rtc-ds1390.c:161: warning: passing argument 1 of 'platform_get_drvdata' from incompatible pointer type
> 
> Introduced in commit 06de18085122b873012cb23f043e2bdcf5f50923 ("rtc: add
> Dallas DS1390/93/94 RTC chips").
> 
> drivers/rtc/rtc-ds3234.c: In function 'ds3234_remove':
> drivers/rtc/rtc-ds3234.c:161: warning: passing argument 1 of 'platform_get_drvdata' from incompatible pointer type
> 
> Introduced in commit 2f9b75e09ec3f62f2ebecec0ac9aec58656c2459 ("rtc: add
> device driver for Dallas DS3234 SPI RTC chip").

These are now in Linus' tree :-(

-- 
Cheers,
Stephen Rothwell                    sfr@canb.auug.org.au
http://www.canb.auug.org.au/~sfr/

[-- Attachment #2: Type: application/pgp-signature, Size: 490 bytes --]

^ permalink raw reply	[flat|nested] 41+ messages in thread

* Re: linux-next: build warning after merge of the driver-core tree
  2011-02-21  6:02 Stephen Rothwell
  2011-02-21  6:32 ` Greg KH
@ 2011-02-21 20:18 ` Ilya Yanok
  1 sibling, 0 replies; 41+ messages in thread
From: Ilya Yanok @ 2011-02-21 20:18 UTC (permalink / raw)
  To: Stephen Rothwell
  Cc: Greg KH, linux-next, linux-kernel, Marc Kleine-Budde,
	David Miller, netdev

Hi Stephen, Greg,

On 21.02.2011 09:02, Stephen Rothwell wrote:
> After merging the driver-core tree, today's linux-next build (x86_64
> allmodconfig) produced this warning:
>
> drivers/net/dnet.c: In function 'dnet_mii_init':
> drivers/net/dnet.c:340: warning: passing argument 1 of 'platform_set_drvdata' from incompatible pointer type
> include/linux/platform_device.h:138: note: expected 'struct platform_device *' but argument is of type 'struct net_device *'

It's actually a bug in the driver. Thanks for reporting. I'll send the 
patch as a follow up.

Regards, Ilya.

^ permalink raw reply	[flat|nested] 41+ messages in thread

* Re: linux-next: build warning after merge of the driver-core tree
  2011-02-21  6:02 Stephen Rothwell
@ 2011-02-21  6:32 ` Greg KH
  2011-02-21 20:18 ` Ilya Yanok
  1 sibling, 0 replies; 41+ messages in thread
From: Greg KH @ 2011-02-21  6:32 UTC (permalink / raw)
  To: Stephen Rothwell
  Cc: linux-next, linux-kernel, Marc Kleine-Budde, Ilya Yanok,
	David Miller, netdev

On Mon, Feb 21, 2011 at 05:02:26PM +1100, Stephen Rothwell wrote:
> Hi Greg,
> 
> After merging the driver-core tree, today's linux-next build (x86_64
> allmodconfig) produced this warning:
> 
> drivers/net/dnet.c: In function 'dnet_mii_init':
> drivers/net/dnet.c:340: warning: passing argument 1 of 'platform_set_drvdata' from incompatible pointer type
> include/linux/platform_device.h:138: note: expected 'struct platform_device *' but argument is of type 'struct net_device *'
> 
> Revealed by commit 71d642908d4e8e7a2a4a6e0490432e719ff466d5 ("Driver
> core: convert platform_{get,set}_drvdata to static inline functions").
> Introduced by commit 4796417417a62e2ae83d92cb92e1ecf9ec67b5f5 ("dnet:
> Dave DNET ethernet controller driver (updated)").

It sounds like the driver is wrong here :(

thanks,

greg k-h

^ permalink raw reply	[flat|nested] 41+ messages in thread

* Re: linux-next: build warning after merge of the driver-core tree
  2011-02-21  5:50 ` Stephen Rothwell
@ 2011-02-21  6:31   ` Greg KH
  2011-03-17 23:10   ` Stephen Rothwell
  1 sibling, 0 replies; 41+ messages in thread
From: Greg KH @ 2011-02-21  6:31 UTC (permalink / raw)
  To: Stephen Rothwell
  Cc: linux-next, linux-kernel, Kim B. Heino, Alessandro Zummo,
	Andrew Morton, Mark Jackson, Dennis Aberilla

On Mon, Feb 21, 2011 at 04:50:23PM +1100, Stephen Rothwell wrote:
> Hi Greg,
> 
> On Mon, 21 Feb 2011 16:37:27 +1100 Stephen Rothwell <sfr@canb.auug.org.au> wrote:
> >
> > After merging the driver-core tree, today's linux-next build (x86_64
> > allmodconfig) produced this warning:
> > 
> > drivers/rtc/rtc-m41t94.c: In function 'm41t94_remove':
> > drivers/rtc/rtc-m41t94.c:139: warning: passing argument 1 of 'platform_get_drvdata' from incompatible pointer type
> > include/linux/platform_device.h:133: note: expected 'const struct platform_device *' but argument is of type 'struct spi_device *'
> > 
> > Revealed by commit 71d642908d4e8e7a2a4a6e0490432e719ff466d5 ("Driver
> > core: convert platform_{get,set}_drvdata to static inline functions").
> > The warning is in code introduced by commit
> > 8fc2c767b06067b417c565c4e75731e68ed41fd8 ("rtc: add support for ST M41T94
> > SPI RTC").
> 
> There are also:
> 
> drivers/rtc/rtc-ds1390.c: In function 'ds1390_remove':
> drivers/rtc/rtc-ds1390.c:161: warning: passing argument 1 of 'platform_get_drvdata' from incompatible pointer type
> 
> Introduced in commit 06de18085122b873012cb23f043e2bdcf5f50923 ("rtc: add
> Dallas DS1390/93/94 RTC chips").
> 
> drivers/rtc/rtc-ds3234.c: In function 'ds3234_remove':
> drivers/rtc/rtc-ds3234.c:161: warning: passing argument 1 of 'platform_get_drvdata' from incompatible pointer type
> 
> Introduced in commit 2f9b75e09ec3f62f2ebecec0ac9aec58656c2459 ("rtc: add
> device driver for Dallas DS3234 SPI RTC chip").

Wow, all of these are driver errors, it's amazing it was all working
properly before.  It's not the core's fault here, so there's nothing I
can do in my tree :(

thanks,

greg k-h

^ permalink raw reply	[flat|nested] 41+ messages in thread

* linux-next: build warning after merge of the driver-core tree
@ 2011-02-21  6:02 Stephen Rothwell
  2011-02-21  6:32 ` Greg KH
  2011-02-21 20:18 ` Ilya Yanok
  0 siblings, 2 replies; 41+ messages in thread
From: Stephen Rothwell @ 2011-02-21  6:02 UTC (permalink / raw)
  To: Greg KH
  Cc: linux-next, linux-kernel, Marc Kleine-Budde, Ilya Yanok,
	David Miller, netdev

[-- Attachment #1: Type: text/plain, Size: 781 bytes --]

Hi Greg,

After merging the driver-core tree, today's linux-next build (x86_64
allmodconfig) produced this warning:

drivers/net/dnet.c: In function 'dnet_mii_init':
drivers/net/dnet.c:340: warning: passing argument 1 of 'platform_set_drvdata' from incompatible pointer type
include/linux/platform_device.h:138: note: expected 'struct platform_device *' but argument is of type 'struct net_device *'

Revealed by commit 71d642908d4e8e7a2a4a6e0490432e719ff466d5 ("Driver
core: convert platform_{get,set}_drvdata to static inline functions").
Introduced by commit 4796417417a62e2ae83d92cb92e1ecf9ec67b5f5 ("dnet:
Dave DNET ethernet controller driver (updated)").
-- 
Cheers,
Stephen Rothwell                    sfr@canb.auug.org.au
http://www.canb.auug.org.au/~sfr/

[-- Attachment #2: Type: application/pgp-signature, Size: 490 bytes --]

^ permalink raw reply	[flat|nested] 41+ messages in thread

* Re: linux-next: build warning after merge of the driver-core tree
  2011-02-21  5:37 Stephen Rothwell
@ 2011-02-21  5:50 ` Stephen Rothwell
  2011-02-21  6:31   ` Greg KH
  2011-03-17 23:10   ` Stephen Rothwell
  0 siblings, 2 replies; 41+ messages in thread
From: Stephen Rothwell @ 2011-02-21  5:50 UTC (permalink / raw)
  To: Greg KH
  Cc: linux-next, linux-kernel, Kim B. Heino, Alessandro Zummo,
	Andrew Morton, Mark Jackson, Dennis Aberilla

[-- Attachment #1: Type: text/plain, Size: 1525 bytes --]

Hi Greg,

On Mon, 21 Feb 2011 16:37:27 +1100 Stephen Rothwell <sfr@canb.auug.org.au> wrote:
>
> After merging the driver-core tree, today's linux-next build (x86_64
> allmodconfig) produced this warning:
> 
> drivers/rtc/rtc-m41t94.c: In function 'm41t94_remove':
> drivers/rtc/rtc-m41t94.c:139: warning: passing argument 1 of 'platform_get_drvdata' from incompatible pointer type
> include/linux/platform_device.h:133: note: expected 'const struct platform_device *' but argument is of type 'struct spi_device *'
> 
> Revealed by commit 71d642908d4e8e7a2a4a6e0490432e719ff466d5 ("Driver
> core: convert platform_{get,set}_drvdata to static inline functions").
> The warning is in code introduced by commit
> 8fc2c767b06067b417c565c4e75731e68ed41fd8 ("rtc: add support for ST M41T94
> SPI RTC").

There are also:

drivers/rtc/rtc-ds1390.c: In function 'ds1390_remove':
drivers/rtc/rtc-ds1390.c:161: warning: passing argument 1 of 'platform_get_drvdata' from incompatible pointer type

Introduced in commit 06de18085122b873012cb23f043e2bdcf5f50923 ("rtc: add
Dallas DS1390/93/94 RTC chips").

drivers/rtc/rtc-ds3234.c: In function 'ds3234_remove':
drivers/rtc/rtc-ds3234.c:161: warning: passing argument 1 of 'platform_get_drvdata' from incompatible pointer type

Introduced in commit 2f9b75e09ec3f62f2ebecec0ac9aec58656c2459 ("rtc: add
device driver for Dallas DS3234 SPI RTC chip").


-- 
Cheers,
Stephen Rothwell                    sfr@canb.auug.org.au
http://www.canb.auug.org.au/~sfr/

[-- Attachment #2: Type: application/pgp-signature, Size: 490 bytes --]

^ permalink raw reply	[flat|nested] 41+ messages in thread

* linux-next: build warning after merge of the driver-core tree
@ 2011-02-21  5:37 Stephen Rothwell
  2011-02-21  5:50 ` Stephen Rothwell
  0 siblings, 1 reply; 41+ messages in thread
From: Stephen Rothwell @ 2011-02-21  5:37 UTC (permalink / raw)
  To: Greg KH
  Cc: linux-next, linux-kernel, Kim B. Heino, Alessandro Zummo, Andrew Morton

[-- Attachment #1: Type: text/plain, Size: 811 bytes --]

Hi Greg,

After merging the driver-core tree, today's linux-next build (x86_64
allmodconfig) produced this warning:

drivers/rtc/rtc-m41t94.c: In function 'm41t94_remove':
drivers/rtc/rtc-m41t94.c:139: warning: passing argument 1 of 'platform_get_drvdata' from incompatible pointer type
include/linux/platform_device.h:133: note: expected 'const struct platform_device *' but argument is of type 'struct spi_device *'

Revealed by commit 71d642908d4e8e7a2a4a6e0490432e719ff466d5 ("Driver
core: convert platform_{get,set}_drvdata to static inline functions").
The warning is in code introduced by commit
8fc2c767b06067b417c565c4e75731e68ed41fd8 ("rtc: add support for ST M41T94
SPI RTC").

-- 
Cheers,
Stephen Rothwell                    sfr@canb.auug.org.au
http://www.canb.auug.org.au/~sfr/

[-- Attachment #2: Type: application/pgp-signature, Size: 490 bytes --]

^ permalink raw reply	[flat|nested] 41+ messages in thread

* Re: linux-next: build warning after merge of the driver-core tree
  2010-09-02 10:14   ` Thomas Renninger
@ 2010-09-02 19:59     ` Greg KH
  0 siblings, 0 replies; 41+ messages in thread
From: Greg KH @ 2010-09-02 19:59 UTC (permalink / raw)
  To: Thomas Renninger; +Cc: Stephen Rothwell, linux-next, linux-kernel, Jason Baron

On Thu, Sep 02, 2010 at 12:14:27PM +0200, Thomas Renninger wrote:
> On Thursday 02 September 2010 05:29:11 Greg KH wrote:
> > On Thu, Sep 02, 2010 at 01:18:35PM +1000, Stephen Rothwell wrote:
> > > Hi Greg,
> ...
> > > kernel/params.c: In function 'parse_args':
> > > kernel/params.c:200: warning: passing argument 2 of 'snprintf' makes integer from pointer without a cast
> > > include/linux/kernel.h:203: note: expected 'size_t' but argument is of type 'char *'
> > > 
> > > Caused by commit d1aa8e2ab38942b21d543611d4f829597d8791d4 ("Dynamic
> > > Debug: Introduce global fake module param module.ddebug").
> > > 
> > > Some warnings should not be ignored ... and it does make me wonder how
> > > much testing this has had ...
> Strange, I tried this out and it worked, I doubt that this version could.
> Possibly it slipped in when getting dddebug patches together for resending
> to Greg, no idea.

Ok, I've replaced it with this version, looks better.

thanks,

greg k-h

^ permalink raw reply	[flat|nested] 41+ messages in thread

* Re: linux-next: build warning after merge of the driver-core tree
  2010-09-02  3:29 ` Greg KH
@ 2010-09-02 10:14   ` Thomas Renninger
  2010-09-02 19:59     ` Greg KH
  0 siblings, 1 reply; 41+ messages in thread
From: Thomas Renninger @ 2010-09-02 10:14 UTC (permalink / raw)
  To: Greg KH; +Cc: Stephen Rothwell, linux-next, linux-kernel, Jason Baron

On Thursday 02 September 2010 05:29:11 Greg KH wrote:
> On Thu, Sep 02, 2010 at 01:18:35PM +1000, Stephen Rothwell wrote:
> > Hi Greg,
...
> > kernel/params.c: In function 'parse_args':
> > kernel/params.c:200: warning: passing argument 2 of 'snprintf' makes integer from pointer without a cast
> > include/linux/kernel.h:203: note: expected 'size_t' but argument is of type 'char *'
> > 
> > Caused by commit d1aa8e2ab38942b21d543611d4f829597d8791d4 ("Dynamic
> > Debug: Introduce global fake module param module.ddebug").
> > 
> > Some warnings should not be ignored ... and it does make me wonder how
> > much testing this has had ...
Strange, I tried this out and it worked, I doubt that this version could.
Possibly it slipped in when getting dddebug patches together for resending
to Greg, no idea.

Sorry about that,

      Thomas

Fixed version:

---------

Dynamic Debug: Introduce global fake module param module.ddebug - V2

Dynamic Debug allows enabling of pr_debug or KERN_DEBUG messages at runtime.
This is controlled via /sys/kernel/debug/dynamic_debug/control.
One major drawback is that the whole initialization of a module cannot be
tracked, because ddebug is only aware of debug strings of loaded modules.
But this is the most interesting part...

This patch introduces a fake module parameter module.ddebug(not shown in
/sys/module/*/parameters, thus it does not use any resources/memory).

If a module passes ddebug as a module parameter (e.g. via module.ddebug
kernel boot param or via "modprobe module ddebug"), all debug strings of this
module get activated by issuing "module module_name +p" internally
(not via sysfs) when the module gets loaded.

Possible enhancements for the future if ddebug might get extended with
further flags:
module.ddebug=flags
Then module.ddebug="p" would be the same as module.ddebug, but if there
is a "x" ddebug flag added, one could pass:
module.ddebug="xp"
which would result in such a dynamic debug query:
module module_name +xp

Modules must not use "ddebug" as module parameter or it will get ignored.
If it's tried, a warning will show up at module load time that it will get
ignored (this is the only part which got added late and is compile tested only).

Tested with (additional added pr_debug messages):
options hp-wmi ddebug
in modprobe.conf
-> works and pr_debug messages issued at module initialization time show
up. Also "p" flag gets set for the whole hp-wmi module:
grep hp-wmi /sys/../dynamic_debug/control

Signed-off-by: Thomas Renninger <trenn@suse.de>
Acked-by: Jason Baron <jbaron@redhat.com>
CC: greg@kroah.com

diff --git a/Documentation/dynamic-debug-howto.txt b/Documentation/dynamic-debug-howto.txt
index 58ea64a..ebbbbdd 100644
--- a/Documentation/dynamic-debug-howto.txt
+++ b/Documentation/dynamic-debug-howto.txt
@@ -213,7 +213,7 @@ Note also that there is no convenient syntax to remove all
 the flags at once, you need to use "-psc".
 
 
-Debug messages during boot process
+Debug Messages during Boot Process
 ==================================
 
 To be able to activate debug messages during the boot process,
@@ -232,6 +232,32 @@ PCI (or other devices) initialization also is a hot candidate for using
 this boot parameter for debugging purposes.
 
 
+Debug Messages at Module Initialization Time
+============================================
+
+Enabling debug messages inside a module is only possible if the module itself
+is loaded already. If you unload a module, the dynamic debug flags associated
+to its debug messages are lost.
+Therefore, enabling debug messages that get processed at module initialization
+time through the <debugfs>/dynamic_debug/control interface is not possible.
+Instead, a "ddebug" module paramter can be passed:
+
+	- via kernel boot parameter:
+	  module.ddebug
+
+	- as an ordinary module parameter via modprobe
+	  modprobe module ddebug
+
+	- or the parameter can be used permanently via modprobe.conf(.local)
+	  options module ddebug
+
+The ddebug option is not implemented as an ordinary module parameter and thus
+will not show up in /sys/module/module_name/parameters/ddebug
+The settings can get reverted through the sysfs interface again when the
+module got loaded as soon as debug messages are not needed anymore:
+echo "module module_name -p" > <debugfs>/dynamic_debug/control
+as described in the "Command Language Reference" chapter above.
+
 Examples
 ========
 
diff --git a/include/linux/dynamic_debug.h b/include/linux/dynamic_debug.h
index 52c0da4..095adf6 100644
--- a/include/linux/dynamic_debug.h
+++ b/include/linux/dynamic_debug.h
@@ -41,6 +41,7 @@ int ddebug_add_module(struct _ddebug *tab, unsigned int n,
 
 #if defined(CONFIG_DYNAMIC_DEBUG)
 extern int ddebug_remove_module(const char *mod_name);
+extern int ddebug_exec_query(char *query_string);
 
 #define __dynamic_dbg_enabled(dd)  ({	     \
 	int __ret = 0;							     \
@@ -77,6 +78,10 @@ static inline int ddebug_remove_module(const char *mod)
 {
 	return 0;
 }
+static inline int ddebug_exec_query(char *query_string)
+{
+	return 0;
+}
 
 #define dynamic_pr_debug(fmt, ...)					\
 	do { if (0) printk(KERN_DEBUG pr_fmt(fmt), ##__VA_ARGS__); } while (0)
diff --git a/kernel/params.c b/kernel/params.c
index 0b30ecd..42f49c5 100644
--- a/kernel/params.c
+++ b/kernel/params.c
@@ -24,6 +24,7 @@
 #include <linux/err.h>
 #include <linux/slab.h>
 #include <linux/ctype.h>
+#include <linux/dynamic_debug.h>
 
 #if 0
 #define DEBUGP printk
@@ -132,10 +133,17 @@ int parse_args(const char *name,
 	       unsigned num,
 	       int (*unknown)(char *param, char *val))
 {
-	char *param, *val;
+	char *param, *val, ddebug[1024];
+	int i;
 
 	DEBUGP("Parsing ARGS: %s\n", args);
 
+	for (i = 0; i < num; i++) {
+		if (parameq("ddebug", params[i].name))
+			pr_warning("Module %s uses reserved keyword *ddebug* as"
+				   "parameter which will get ignored\n", name);
+	}
+
 	/* Chew leading spaces */
 	args = skip_spaces(args);
 
@@ -144,6 +152,13 @@ int parse_args(const char *name,
 		int irq_was_disabled;
 
 		args = next_arg(args, &param, &val);
+
+		if (parameq(param, "ddebug")) {
+			snprintf(ddebug, 1024, "module %s +p", name);
+			ddebug_exec_query(ddebug);
+			continue;
+		}
+
 		irq_was_disabled = irqs_disabled();
 		ret = parse_one(param, val, params, num, unknown);
 		if (irq_was_disabled && !irqs_disabled()) {
diff --git a/lib/dynamic_debug.c b/lib/dynamic_debug.c
index a687d90..7f8ba5f 100644
--- a/lib/dynamic_debug.c
+++ b/lib/dynamic_debug.c
@@ -429,7 +429,7 @@ static int ddebug_parse_flags(const char *str, unsigned int *flagsp,
 	return 0;
 }
 
-static int ddebug_exec_query(char *query_string)
+int ddebug_exec_query(char *query_string)
 {
 	unsigned int flags = 0, mask = 0;
 	struct ddebug_query query;

^ permalink raw reply	[flat|nested] 41+ messages in thread

* Re: linux-next: build warning after merge of the driver-core tree
  2010-09-02  3:18 Stephen Rothwell
@ 2010-09-02  3:29 ` Greg KH
  2010-09-02 10:14   ` Thomas Renninger
  0 siblings, 1 reply; 41+ messages in thread
From: Greg KH @ 2010-09-02  3:29 UTC (permalink / raw)
  To: Stephen Rothwell; +Cc: linux-next, linux-kernel, Thomas Renninger, Jason Baron

On Thu, Sep 02, 2010 at 01:18:35PM +1000, Stephen Rothwell wrote:
> Hi Greg,
> 
> After merging the driver-core tree, today's linux-next build (powerpc
> ppc64_defconfig) produced this warning:
> 
> kernel/params.c: In function 'parse_args':
> kernel/params.c:200: warning: passing argument 2 of 'snprintf' makes integer from pointer without a cast
> include/linux/kernel.h:203: note: expected 'size_t' but argument is of type 'char *'
> 
> Caused by commit d1aa8e2ab38942b21d543611d4f829597d8791d4 ("Dynamic
> Debug: Introduce global fake module param module.ddebug").
> 
> Some warnings should not be ignored ... and it does make me wonder how
> much testing this has had ...

Odd.  Thomas and Jason, care to fix this up please?

thanks,

greg k-h

^ permalink raw reply	[flat|nested] 41+ messages in thread

* linux-next: build warning after merge of the driver-core tree
@ 2010-09-02  3:18 Stephen Rothwell
  2010-09-02  3:29 ` Greg KH
  0 siblings, 1 reply; 41+ messages in thread
From: Stephen Rothwell @ 2010-09-02  3:18 UTC (permalink / raw)
  To: Greg KH; +Cc: linux-next, linux-kernel, Thomas Renninger, Jason Baron

[-- Attachment #1: Type: text/plain, Size: 707 bytes --]

Hi Greg,

After merging the driver-core tree, today's linux-next build (powerpc
ppc64_defconfig) produced this warning:

kernel/params.c: In function 'parse_args':
kernel/params.c:200: warning: passing argument 2 of 'snprintf' makes integer from pointer without a cast
include/linux/kernel.h:203: note: expected 'size_t' but argument is of type 'char *'

Caused by commit d1aa8e2ab38942b21d543611d4f829597d8791d4 ("Dynamic
Debug: Introduce global fake module param module.ddebug").

Some warnings should not be ignored ... and it does make me wonder how
much testing this has had ...

-- 
Cheers,
Stephen Rothwell                    sfr@canb.auug.org.au
http://www.canb.auug.org.au/~sfr/

[-- Attachment #2: Type: application/pgp-signature, Size: 490 bytes --]

^ permalink raw reply	[flat|nested] 41+ messages in thread

end of thread, other threads:[~2020-09-09  7:40 UTC | newest]

Thread overview: 41+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-08-01  5:05 linux-next: build warning after merge of the driver-core tree Stephen Rothwell
2019-08-01  6:10 ` Greg KH
2019-08-01 10:20   ` [PATCH 1/3] i2c: Revert incorrect conversion to use generic helper Suzuki K Poulose
2019-08-01 10:20     ` [PATCH 2/3] drivers: Fix typo in parameter description for driver_find_device_by_acpi_dev Suzuki K Poulose
2019-08-01 10:20     ` [PATCH 3/3] drivers: Fix htmldocs warnings with bus_find_next_device() Suzuki K Poulose
2019-08-01 13:54     ` [PATCH 1/3] i2c: Revert incorrect conversion to use generic helper Greg KH
2019-08-01 14:03       ` Suzuki K Poulose
2019-08-01 14:05         ` Greg KH
  -- strict thread matches above, loose matches on Subject: below --
2020-09-09  7:23 linux-next: build warning after merge of the driver-core tree Stephen Rothwell
2020-09-09  7:40 ` Greg KH
2019-08-05  3:04 Stephen Rothwell
2019-08-05  4:56 ` Stephen Rothwell
2019-08-06  0:03   ` Saravana Kannan
2019-07-04  6:24 Stephen Rothwell
2019-07-04  8:21 ` Greg KH
2019-07-04  6:17 Stephen Rothwell
2019-07-04  6:30 ` Greg KH
2015-10-07  4:51 Stephen Rothwell
2015-10-07  6:40 ` Viresh Kumar
2015-10-07 21:48   ` Rafael J. Wysocki
2015-10-07 22:04     ` Stephen Rothwell
2015-10-07 22:47       ` Rafael J. Wysocki
2015-10-08  7:09         ` Viresh Kumar
2015-10-08 20:30           ` Rafael J. Wysocki
2015-10-09  5:36             ` Stephen Rothwell
2015-10-09  6:31               ` Viresh Kumar
2015-10-09 20:49                 ` Rafael J. Wysocki
2015-10-09  6:37             ` Viresh Kumar
2013-06-25  8:33 Stephen Rothwell
2013-06-25 12:00 ` Ming Lei
2011-02-21  6:02 Stephen Rothwell
2011-02-21  6:32 ` Greg KH
2011-02-21 20:18 ` Ilya Yanok
2011-02-21  5:37 Stephen Rothwell
2011-02-21  5:50 ` Stephen Rothwell
2011-02-21  6:31   ` Greg KH
2011-03-17 23:10   ` Stephen Rothwell
2010-09-02  3:18 Stephen Rothwell
2010-09-02  3:29 ` Greg KH
2010-09-02 10:14   ` Thomas Renninger
2010-09-02 19:59     ` Greg KH

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).