Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 660cd67d authored by Saravana Kannan's avatar Saravana Kannan
Browse files

UPSTREAM: driver core: Change delimiter in devlink device's name to "--"



The devlink device name is of the form "supplier:consumer". But ":" is
fairly common in device names and makes it visually hard to distinguish
supplier and consumer. So, replace it with "--" to make it easier.

Signed-off-by: default avatarSaravana Kannan <saravanak@google.com>
Link: https://lore.kernel.org/r/20200724180523.1393383-1-saravanak@google.com


Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
(cherry picked from commit 90b109d50da09ddaa179732c01ccba7f759c125d)
Signed-off-by: default avatarSaravana Kannan <saravanak@google.com>
Bug: 163090256
Change-Id: Ibda7db293de6c2e0d9f963e61f2cec0321c82e09
parent d75aed27
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -4,7 +4,7 @@ Contact: Saravana Kannan <saravanak@google.com>
Description:
		Provide a place in sysfs for the device link objects in the
		kernel at any given time.  The name of a device link directory,
		denoted as ... above, is of the form <supplier>:<consumer>
		denoted as ... above, is of the form <supplier>--<consumer>
		where <supplier> is the supplier device name and <consumer> is
		the consumer device name.

+1 −1
Original line number Diff line number Diff line
@@ -622,7 +622,7 @@ struct device_link *device_link_add(struct device *consumer,

	link->link_dev.class = &devlink_class;
	device_set_pm_not_required(&link->link_dev);
	dev_set_name(&link->link_dev, "%s:%s",
	dev_set_name(&link->link_dev, "%s--%s",
		     dev_name(supplier), dev_name(consumer));
	if (device_register(&link->link_dev)) {
		put_device(consumer);