Skip to content

Commit 90b109d

Browse files
Saravana Kannangregkh
authored andcommitted
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: Saravana Kannan <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Greg Kroah-Hartman <[email protected]>
1 parent a24c6f7 commit 90b109d

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

Documentation/ABI/testing/sysfs-class-devlink

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ Contact: Saravana Kannan <[email protected]>
44
Description:
55
Provide a place in sysfs for the device link objects in the
66
kernel at any given time. The name of a device link directory,
7-
denoted as ... above, is of the form <supplier>:<consumer>
7+
denoted as ... above, is of the form <supplier>--<consumer>
88
where <supplier> is the supplier device name and <consumer> is
99
the consumer device name.
1010

drivers/base/core.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -623,7 +623,7 @@ struct device_link *device_link_add(struct device *consumer,
623623

624624
link->link_dev.class = &devlink_class;
625625
device_set_pm_not_required(&link->link_dev);
626-
dev_set_name(&link->link_dev, "%s:%s",
626+
dev_set_name(&link->link_dev, "%s--%s",
627627
dev_name(supplier), dev_name(consumer));
628628
if (device_register(&link->link_dev)) {
629629
put_device(consumer);

0 commit comments

Comments
 (0)