arm qemu boot failures in -next due to 'PM / Domains: add setter for dev.pm_domain'

10 messages, 5 authors, 2016-01-12 · open the first message on its own page

arm qemu boot failures in -next due to 'PM / Domains: add setter for dev.pm_domain'

From: Guenter Roeck <linux@roeck-us.net>
Date: 2016-01-11 17:51:12

Hi,

I see 6 out of 24 arm qemu tests failing in next-20160111. Bisect points
to commit 989561de9b51 ("PM / Domains: add setter for dev.pm_domain").
Failures are silent - there is no output on the console.
Affected tests are

arm:beagle:multi_v7_defconfig:omap3-beagle
arm:beaglexm:multi_v7_defconfig:omap3-beagle-xm
arm:overo:multi_v7_defconfig:omap3-overo-tobi
arm:beagle:omap2plus_defconfig:omap3-beagle
arm:beaglexm:omap2plus_defconfig:omap3-beagle-xm
arm:overo:omap2plus_defconfig:omap3-overo-tobi

For details please see the 'next' column at http://server.roeck-us.net:8010/builders.

Reverting the offending commit fixes the problems.

Please let me know if there is anything I can do to help tracking down the problem.

Thanks,
Guenter

---
bisect log:

# bad: [bf976ab690dea9d0ee260fc8881fef511a0e3566] Add linux-next specific files for 20160111
# good: [168309855a7d1e16db751e9c647119fe2d2dc878] Linux 4.4-rc8
git bisect start 'HEAD' 'v4.4-rc8'
# bad: [a4fcd5c159c2b7a080f6c9fbefe8a85302390513] Merge remote-tracking branch 'crypto/master'
git bisect bad a4fcd5c159c2b7a080f6c9fbefe8a85302390513
# good: [9d242008d7c9e46327364a57793bada3509ebf0f] Merge remote-tracking branch 'hwmon-staging/hwmon-next'
git bisect good 9d242008d7c9e46327364a57793bada3509ebf0f
# good: [cc69d3dbbbfa134df2a7e7a72da6484c5d34fb0d] batman-adv: Change ifconfig examples to iproute2
git bisect good cc69d3dbbbfa134df2a7e7a72da6484c5d34fb0d
# bad: [995bfc729f919f2fe70e06d56aca3ffa90e0ebe6] Merge remote-tracking branch 'pm/linux-next'
git bisect bad 995bfc729f919f2fe70e06d56aca3ffa90e0ebe6
# good: [e27bc2ab8e774738b9c7c0356beab3a9ebdb3903] Merge ../mc_dvb into to_next
git bisect good e27bc2ab8e774738b9c7c0356beab3a9ebdb3903
# good: [f851f1f95258dd413ee6c09a889732d0a88c1b23] Merge branch 'pm-cpufreq' into linux-next
git bisect good f851f1f95258dd413ee6c09a889732d0a88c1b23
# good: [5bced7a1834aabf4ad348bbf59404ff45fdf569b] Merge branch 'kbuild/misc' into kbuild/for-next
git bisect good 5bced7a1834aabf4ad348bbf59404ff45fdf569b
# good: [44858e07ff879048f8f5cf315715ecc23d1a8462] Merge branch 'for-4.5' into for-next
git bisect good 44858e07ff879048f8f5cf315715ecc23d1a8462
# good: [e03445d23fdc32c167841b7dd9c3ff92c4b02d5d] Merge branch 'kbuild/misc' into kbuild/for-next
git bisect good e03445d23fdc32c167841b7dd9c3ff92c4b02d5d
# good: [31778c3c5abf4fb70c3465b072cd18f0a6e795f8] Merge branch 'powercap' into linux-next
git bisect good 31778c3c5abf4fb70c3465b072cd18f0a6e795f8
# bad: [e3345db85068ddb937fc0ba40dfc39c293dad977] USB / PM: Allow USB devices to remain runtime-suspended when sleeping
git bisect bad e3345db85068ddb937fc0ba40dfc39c293dad977
# good: [6b9cb42752dafba3761dde0002ca58ca518b6311] device core: add device_is_bound()
git bisect good 6b9cb42752dafba3761dde0002ca58ca518b6311
# bad: [aa8e54b559479d0cb7eb632ba443b8cacd20cd4b] PM / sleep: Go direct_complete if driver has no callbacks
git bisect bad aa8e54b559479d0cb7eb632ba443b8cacd20cd4b
# bad: [989561de9b5112999475b406557d9c7e9e59c041] PM / Domains: add setter for dev.pm_domain
git bisect bad 989561de9b5112999475b406557d9c7e9e59c041
# first bad commit: [989561de9b5112999475b406557d9c7e9e59c041] PM / Domains: add setter for dev.pm_domain

Re: arm qemu boot failures in -next due to 'PM / Domains: add setter for dev.pm_domain'

From: Tony Lindgren <tony@atomide.com>
Date: 2016-01-11 18:55:07

* Guenter Roeck [off-list ref] [160111 09:51]:
Hi,

I see 6 out of 24 arm qemu tests failing in next-20160111. Bisect points
to commit 989561de9b51 ("PM / Domains: add setter for dev.pm_domain").
Failures are silent - there is no output on the console.
Affected tests are

arm:beagle:multi_v7_defconfig:omap3-beagle
arm:beaglexm:multi_v7_defconfig:omap3-beagle-xm
arm:overo:multi_v7_defconfig:omap3-overo-tobi
arm:beagle:omap2plus_defconfig:omap3-beagle
arm:beaglexm:omap2plus_defconfig:omap3-beagle-xm
arm:overo:omap2plus_defconfig:omap3-overo-tobi

For details please see the 'next' column at http://server.roeck-us.net:8010/builders.

Reverting the offending commit fixes the problems.

Please let me know if there is anything I can do to help tracking down the problem.
The following fixes the booting, but I wonder if it's a
proper fix?
--- a/drivers/base/power/common.c
+++ b/drivers/base/power/common.c
@@ -145,9 +145,10 @@ void dev_pm_domain_set(struct device *dev, struct dev_pm_domain *pd)
 {
 	if (dev->pm_domain == pd)
 		return;
-
-	WARN(device_is_bound(dev),
-	     "PM domains can only be changed for unbound devices\n");
+	if (device_is_registered(dev)) {
+		WARN(device_is_bound(dev),
+		     "PM domains can only be changed for unbound devices\n");
+	}
 	dev->pm_domain = pd;
 	device_pm_check_callbacks(dev);
 }

Re: arm qemu boot failures in -next due to 'PM / Domains: add setter for dev.pm_domain'

From: Guenter Roeck <linux@roeck-us.net>
Date: 2016-01-11 20:04:55

On Mon, Jan 11, 2016 at 10:55:00AM -0800, Tony Lindgren wrote:
* Guenter Roeck [off-list ref] [160111 09:51]:
quoted
Hi,

I see 6 out of 24 arm qemu tests failing in next-20160111. Bisect points
to commit 989561de9b51 ("PM / Domains: add setter for dev.pm_domain").
Failures are silent - there is no output on the console.
Affected tests are

arm:beagle:multi_v7_defconfig:omap3-beagle
arm:beaglexm:multi_v7_defconfig:omap3-beagle-xm
arm:overo:multi_v7_defconfig:omap3-overo-tobi
arm:beagle:omap2plus_defconfig:omap3-beagle
arm:beaglexm:omap2plus_defconfig:omap3-beagle-xm
arm:overo:omap2plus_defconfig:omap3-overo-tobi

For details please see the 'next' column at http://server.roeck-us.net:8010/builders.

Reverting the offending commit fixes the problems.

Please let me know if there is anything I can do to help tracking down the problem.
The following fixes the booting, but I wonder if it's a
Yes, it does. 

Tested-by: Guenter Roeck <linux@roeck-us.net>
proper fix?
That I don't know.

Guenter
quoted hunk
--- a/drivers/base/power/common.c
+++ b/drivers/base/power/common.c
@@ -145,9 +145,10 @@ void dev_pm_domain_set(struct device *dev, struct dev_pm_domain *pd)
 {
 	if (dev->pm_domain == pd)
 		return;
-
-	WARN(device_is_bound(dev),
-	     "PM domains can only be changed for unbound devices\n");
+	if (device_is_registered(dev)) {
+		WARN(device_is_bound(dev),
+		     "PM domains can only be changed for unbound devices\n");
+	}
 	dev->pm_domain = pd;
 	device_pm_check_callbacks(dev);
 }

Re: arm qemu boot failures in -next due to 'PM / Domains: add setter for dev.pm_domain'

From: Fabio Estevam <festevam@gmail.com>
Date: 2016-01-11 20:14:33

[Adding Rafael]

On Mon, Jan 11, 2016 at 4:55 PM, Tony Lindgren [off-list ref] wrote:
quoted hunk
quoted
I see 6 out of 24 arm qemu tests failing in next-20160111. Bisect points
to commit 989561de9b51 ("PM / Domains: add setter for dev.pm_domain").
Failures are silent - there is no output on the console.
Affected tests are

arm:beagle:multi_v7_defconfig:omap3-beagle
arm:beaglexm:multi_v7_defconfig:omap3-beagle-xm
arm:overo:multi_v7_defconfig:omap3-overo-tobi
arm:beagle:omap2plus_defconfig:omap3-beagle
arm:beaglexm:omap2plus_defconfig:omap3-beagle-xm
arm:overo:omap2plus_defconfig:omap3-overo-tobi

For details please see the 'next' column at http://server.roeck-us.net:8010/builders.

Reverting the offending commit fixes the problems.

Please let me know if there is anything I can do to help tracking down the problem.
The following fixes the booting, but I wonder if it's a
proper fix?
--- a/drivers/base/power/common.c
+++ b/drivers/base/power/common.c
@@ -145,9 +145,10 @@ void dev_pm_domain_set(struct device *dev, struct dev_pm_domain *pd)
 {
        if (dev->pm_domain == pd)
                return;
-
-       WARN(device_is_bound(dev),
-            "PM domains can only be changed for unbound devices\n");
+       if (device_is_registered(dev)) {
+               WARN(device_is_bound(dev),
+                    "PM domains can only be changed for unbound devices\n");
+       }
        dev->pm_domain = pd;
        device_pm_check_callbacks(dev);
Commit 989561de9b51 ("PM / Domains: add setter for dev.pm_domain")
causes issues for me after doing a 'reboot' command.

Rafael proposed a patch which fixed the 'reboot' problem:
http://www.spinics.net/lists/arm-kernel/msg473562.html

Re: arm qemu boot failures in -next due to 'PM / Domains: add setter for dev.pm_domain'

From: Guenter Roeck <linux@roeck-us.net>
Date: 2016-01-11 20:48:24

On Mon, Jan 11, 2016 at 06:14:31PM -0200, Fabio Estevam wrote:
[Adding Rafael]

On Mon, Jan 11, 2016 at 4:55 PM, Tony Lindgren [off-list ref] wrote:
quoted
quoted
I see 6 out of 24 arm qemu tests failing in next-20160111. Bisect points
to commit 989561de9b51 ("PM / Domains: add setter for dev.pm_domain").
Failures are silent - there is no output on the console.
Affected tests are

arm:beagle:multi_v7_defconfig:omap3-beagle
arm:beaglexm:multi_v7_defconfig:omap3-beagle-xm
arm:overo:multi_v7_defconfig:omap3-overo-tobi
arm:beagle:omap2plus_defconfig:omap3-beagle
arm:beaglexm:omap2plus_defconfig:omap3-beagle-xm
arm:overo:omap2plus_defconfig:omap3-overo-tobi

For details please see the 'next' column at http://server.roeck-us.net:8010/builders.

Reverting the offending commit fixes the problems.

Please let me know if there is anything I can do to help tracking down the problem.
The following fixes the booting, but I wonder if it's a
proper fix?
--- a/drivers/base/power/common.c
+++ b/drivers/base/power/common.c
@@ -145,9 +145,10 @@ void dev_pm_domain_set(struct device *dev, struct dev_pm_domain *pd)
 {
        if (dev->pm_domain == pd)
                return;
-
-       WARN(device_is_bound(dev),
-            "PM domains can only be changed for unbound devices\n");
+       if (device_is_registered(dev)) {
+               WARN(device_is_bound(dev),
+                    "PM domains can only be changed for unbound devices\n");
+       }
        dev->pm_domain = pd;
        device_pm_check_callbacks(dev);
Commit 989561de9b51 ("PM / Domains: add setter for dev.pm_domain")
causes issues for me after doing a 'reboot' command.

Rafael proposed a patch which fixed the 'reboot' problem:
http://www.spinics.net/lists/arm-kernel/msg473562.html
Looks like a different problem.

Guenter

Re: arm qemu boot failures in -next due to 'PM / Domains: add setter for dev.pm_domain'

From: Rafael J. Wysocki <hidden>
Date: 2016-01-11 22:49:30

On Monday, January 11, 2016 12:04:50 PM Guenter Roeck wrote:
On Mon, Jan 11, 2016 at 10:55:00AM -0800, Tony Lindgren wrote:
quoted
* Guenter Roeck [off-list ref] [160111 09:51]:
quoted
Hi,

I see 6 out of 24 arm qemu tests failing in next-20160111. Bisect points
to commit 989561de9b51 ("PM / Domains: add setter for dev.pm_domain").
Failures are silent - there is no output on the console.
Affected tests are

arm:beagle:multi_v7_defconfig:omap3-beagle
arm:beaglexm:multi_v7_defconfig:omap3-beagle-xm
arm:overo:multi_v7_defconfig:omap3-overo-tobi
arm:beagle:omap2plus_defconfig:omap3-beagle
arm:beaglexm:omap2plus_defconfig:omap3-beagle-xm
arm:overo:omap2plus_defconfig:omap3-overo-tobi

For details please see the 'next' column at http://server.roeck-us.net:8010/builders.

Reverting the offending commit fixes the problems.

Please let me know if there is anything I can do to help tracking down the problem.
The following fixes the booting, but I wonder if it's a
Yes, it does. 

Tested-by: Guenter Roeck <linux@roeck-us.net>
quoted
proper fix?
That I don't know.
If I'm not mistaken, what happens is that device_is_bound() tries to
dereference dev->p which is NULL.  If that's the case, the appended one
should help too.

Can you please check?

---
 drivers/base/dd.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Index: linux-pm/drivers/base/dd.c
===================================================================
--- linux-pm.orig/drivers/base/dd.c
+++ linux-pm/drivers/base/dd.c
@@ -234,7 +234,7 @@ late_initcall(deferred_probe_initcall);
  */
 bool device_is_bound(struct device *dev)
 {
-	return klist_node_attached(&dev->p->knode_driver);
+	return dev->p && klist_node_attached(&dev->p->knode_driver);
 }
 
 static void driver_bound(struct device *dev)

Re: arm qemu boot failures in -next due to 'PM / Domains: add setter for dev.pm_domain'

From: Rafael J. Wysocki <hidden>
Date: 2016-01-11 22:51:03

On Monday, January 11, 2016 12:48:19 PM Guenter Roeck wrote:
On Mon, Jan 11, 2016 at 06:14:31PM -0200, Fabio Estevam wrote:
quoted
[Adding Rafael]

On Mon, Jan 11, 2016 at 4:55 PM, Tony Lindgren [off-list ref] wrote:
quoted
quoted
I see 6 out of 24 arm qemu tests failing in next-20160111. Bisect points
to commit 989561de9b51 ("PM / Domains: add setter for dev.pm_domain").
Failures are silent - there is no output on the console.
Affected tests are

arm:beagle:multi_v7_defconfig:omap3-beagle
arm:beaglexm:multi_v7_defconfig:omap3-beagle-xm
arm:overo:multi_v7_defconfig:omap3-overo-tobi
arm:beagle:omap2plus_defconfig:omap3-beagle
arm:beaglexm:omap2plus_defconfig:omap3-beagle-xm
arm:overo:omap2plus_defconfig:omap3-overo-tobi

For details please see the 'next' column at http://server.roeck-us.net:8010/builders.

Reverting the offending commit fixes the problems.

Please let me know if there is anything I can do to help tracking down the problem.
The following fixes the booting, but I wonder if it's a
proper fix?
--- a/drivers/base/power/common.c
+++ b/drivers/base/power/common.c
@@ -145,9 +145,10 @@ void dev_pm_domain_set(struct device *dev, struct dev_pm_domain *pd)
 {
        if (dev->pm_domain == pd)
                return;
-
-       WARN(device_is_bound(dev),
-            "PM domains can only be changed for unbound devices\n");
+       if (device_is_registered(dev)) {
+               WARN(device_is_bound(dev),
+                    "PM domains can only be changed for unbound devices\n");
+       }
        dev->pm_domain = pd;
        device_pm_check_callbacks(dev);
Commit 989561de9b51 ("PM / Domains: add setter for dev.pm_domain")
causes issues for me after doing a 'reboot' command.

Rafael proposed a patch which fixed the 'reboot' problem:
http://www.spinics.net/lists/arm-kernel/msg473562.html
Looks like a different problem.
Yes, it is a different problem.

Fabio, thanks for CCing me.

Thanks,
Rafael

Re: arm qemu boot failures in -next due to 'PM / Domains: add setter for dev.pm_domain'

From: Guenter Roeck <linux@roeck-us.net>
Date: 2016-01-11 23:39:55

On 01/11/2016 02:49 PM, Rafael J. Wysocki wrote:
quoted hunk
On Monday, January 11, 2016 12:04:50 PM Guenter Roeck wrote:
quoted
On Mon, Jan 11, 2016 at 10:55:00AM -0800, Tony Lindgren wrote:
quoted
* Guenter Roeck [off-list ref] [160111 09:51]:
quoted
Hi,

I see 6 out of 24 arm qemu tests failing in next-20160111. Bisect points
to commit 989561de9b51 ("PM / Domains: add setter for dev.pm_domain").
Failures are silent - there is no output on the console.
Affected tests are

arm:beagle:multi_v7_defconfig:omap3-beagle
arm:beaglexm:multi_v7_defconfig:omap3-beagle-xm
arm:overo:multi_v7_defconfig:omap3-overo-tobi
arm:beagle:omap2plus_defconfig:omap3-beagle
arm:beaglexm:omap2plus_defconfig:omap3-beagle-xm
arm:overo:omap2plus_defconfig:omap3-overo-tobi

For details please see the 'next' column at http://server.roeck-us.net:8010/builders.

Reverting the offending commit fixes the problems.

Please let me know if there is anything I can do to help tracking down the problem.
The following fixes the booting, but I wonder if it's a
Yes, it does.

Tested-by: Guenter Roeck <linux@roeck-us.net>
quoted
proper fix?
That I don't know.
If I'm not mistaken, what happens is that device_is_bound() tries to
dereference dev->p which is NULL.  If that's the case, the appended one
should help too.

Can you please check?

---
  drivers/base/dd.c |    2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)

Index: linux-pm/drivers/base/dd.c
===================================================================
--- linux-pm.orig/drivers/base/dd.c
+++ linux-pm/drivers/base/dd.c
@@ -234,7 +234,7 @@ late_initcall(deferred_probe_initcall);
   */
  bool device_is_bound(struct device *dev)
  {
-	return klist_node_attached(&dev->p->knode_driver);
+	return dev->p && klist_node_attached(&dev->p->knode_driver);
Yes, that fixes the problem as well.

Guenter

Re: arm qemu boot failures in -next due to 'PM / Domains: add setter for dev.pm_domain'

From: Tony Lindgren <tony@atomide.com>
Date: 2016-01-12 00:15:41

* Guenter Roeck [off-list ref] [160111 15:40]:
On 01/11/2016 02:49 PM, Rafael J. Wysocki wrote:
quoted
On Monday, January 11, 2016 12:04:50 PM Guenter Roeck wrote:
quoted
On Mon, Jan 11, 2016 at 10:55:00AM -0800, Tony Lindgren wrote:
quoted
* Guenter Roeck [off-list ref] [160111 09:51]:
quoted
Hi,

I see 6 out of 24 arm qemu tests failing in next-20160111. Bisect points
to commit 989561de9b51 ("PM / Domains: add setter for dev.pm_domain").
Failures are silent - there is no output on the console.
Affected tests are

arm:beagle:multi_v7_defconfig:omap3-beagle
arm:beaglexm:multi_v7_defconfig:omap3-beagle-xm
arm:overo:multi_v7_defconfig:omap3-overo-tobi
arm:beagle:omap2plus_defconfig:omap3-beagle
arm:beaglexm:omap2plus_defconfig:omap3-beagle-xm
arm:overo:omap2plus_defconfig:omap3-overo-tobi

For details please see the 'next' column at http://server.roeck-us.net:8010/builders.

Reverting the offending commit fixes the problems.

Please let me know if there is anything I can do to help tracking down the problem.
The following fixes the booting, but I wonder if it's a
Yes, it does.

Tested-by: Guenter Roeck <linux@roeck-us.net>
quoted
proper fix?
That I don't know.
If I'm not mistaken, what happens is that device_is_bound() tries to
dereference dev->p which is NULL.  If that's the case, the appended one
should help too.

Can you please check?

---
 drivers/base/dd.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Index: linux-pm/drivers/base/dd.c
===================================================================
--- linux-pm.orig/drivers/base/dd.c
+++ linux-pm/drivers/base/dd.c
@@ -234,7 +234,7 @@ late_initcall(deferred_probe_initcall);
  */
 bool device_is_bound(struct device *dev)
 {
-	return klist_node_attached(&dev->p->knode_driver);
+	return dev->p && klist_node_attached(&dev->p->knode_driver);
Yes, that fixes the problem as well.
Yeah works for me too:

Tested-by: Tony Lindgren <tony@atomide.com>

Re: arm qemu boot failures in -next due to 'PM / Domains: add setter for dev.pm_domain'

From: "Rafael J. Wysocki" <rafael@kernel.org>
Date: 2016-01-12 00:24:32

On Tue, Jan 12, 2016 at 1:15 AM, Tony Lindgren [off-list ref] wrote:
* Guenter Roeck [off-list ref] [160111 15:40]:
quoted
On 01/11/2016 02:49 PM, Rafael J. Wysocki wrote:
quoted
On Monday, January 11, 2016 12:04:50 PM Guenter Roeck wrote:
quoted
On Mon, Jan 11, 2016 at 10:55:00AM -0800, Tony Lindgren wrote:
quoted
* Guenter Roeck [off-list ref] [160111 09:51]:
quoted
Hi,

I see 6 out of 24 arm qemu tests failing in next-20160111. Bisect points
to commit 989561de9b51 ("PM / Domains: add setter for dev.pm_domain").
Failures are silent - there is no output on the console.
Affected tests are

arm:beagle:multi_v7_defconfig:omap3-beagle
arm:beaglexm:multi_v7_defconfig:omap3-beagle-xm
arm:overo:multi_v7_defconfig:omap3-overo-tobi
arm:beagle:omap2plus_defconfig:omap3-beagle
arm:beaglexm:omap2plus_defconfig:omap3-beagle-xm
arm:overo:omap2plus_defconfig:omap3-overo-tobi

For details please see the 'next' column at http://server.roeck-us.net:8010/builders.

Reverting the offending commit fixes the problems.

Please let me know if there is anything I can do to help tracking down the problem.
The following fixes the booting, but I wonder if it's a
Yes, it does.

Tested-by: Guenter Roeck <linux@roeck-us.net>
quoted
proper fix?
That I don't know.
If I'm not mistaken, what happens is that device_is_bound() tries to
dereference dev->p which is NULL.  If that's the case, the appended one
should help too.

Can you please check?

---
 drivers/base/dd.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Index: linux-pm/drivers/base/dd.c
===================================================================
--- linux-pm.orig/drivers/base/dd.c
+++ linux-pm/drivers/base/dd.c
@@ -234,7 +234,7 @@ late_initcall(deferred_probe_initcall);
  */
 bool device_is_bound(struct device *dev)
 {
-    return klist_node_attached(&dev->p->knode_driver);
+    return dev->p && klist_node_attached(&dev->p->knode_driver);
Yes, that fixes the problem as well.
Yeah works for me too:

Tested-by: Tony Lindgren <tony@atomide.com>
OK, thanks!

I'll add a changelog to this one and queue it up then.

Thanks,
Rafael
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help