Skip to content

Commit 29247de

Browse files
ldzhongmpe
authored andcommitted
powerpc/pseries/vio: Don't return ENODEV if node or compatible missing
We noticed the following nuisance messages during boot process: vio vio: uevent: failed to send synthetic uevent vio 4000: uevent: failed to send synthetic uevent vio 4001: uevent: failed to send synthetic uevent vio 4002: uevent: failedto send synthetic uevent vio 4004: uevent: failed to send synthetic uevent It's caused by either vio_register_device_node() failing to set dev->of_node or the node is missing a "compatible" property. To match the definition of modalias in modalias_show(), remove the return of ENODEV in such cases. The failure messages is also suppressed with this change. Signed-off-by: Lidong Zhong <[email protected]> Signed-off-by: Michael Ellerman <[email protected]> Link: https://msgid.link/[email protected]
1 parent ff2e185 commit 29247de

File tree

1 file changed

+2
-6
lines changed
  • arch/powerpc/platforms/pseries

1 file changed

+2
-6
lines changed

arch/powerpc/platforms/pseries/vio.c

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1592,13 +1592,9 @@ static int vio_hotplug(const struct device *dev, struct kobj_uevent_env *env)
15921592
const char *cp;
15931593

15941594
dn = dev->of_node;
1595-
if (!dn)
1596-
return -ENODEV;
1597-
cp = of_get_property(dn, "compatible", NULL);
1598-
if (!cp)
1599-
return -ENODEV;
1595+
if (dn && (cp = of_get_property(dn, "compatible", NULL)))
1596+
add_uevent_var(env, "MODALIAS=vio:T%sS%s", vio_dev->type, cp);
16001597

1601-
add_uevent_var(env, "MODALIAS=vio:T%sS%s", vio_dev->type, cp);
16021598
return 0;
16031599
}
16041600

0 commit comments

Comments
 (0)