aboutsummaryrefslogtreecommitdiffstats
path: root/net/rfkill
diff options
context:
space:
mode:
authorKay Sievers <kay.sievers@vrfy.org>2008-11-10 16:55:14 -0500
committerDavid S. Miller <davem@davemloft.net>2008-11-10 16:55:14 -0500
commitfb28ad35906af2f042c94e2f9c0f898ef9acfa37 (patch)
treeee3d535ab38d680b424a857406789f8c28bf5266 /net/rfkill
parent23779897546c1effb546ff89b89803d9d955d517 (diff)
net: struct device - replace bus_id with dev_name(), dev_set_name()
Acked-by: Marcel Holtmann <marcel@holtmann.org> Acked-by: Greg Kroah-Hartman <gregkh@suse.de> Signed-off-by: Kay Sievers <kay.sievers@vrfy.org> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/rfkill')
-rw-r--r--net/rfkill/rfkill.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/net/rfkill/rfkill.c b/net/rfkill/rfkill.c
index 69f3a3b4dd61..ec26eae8004d 100644
--- a/net/rfkill/rfkill.c
+++ b/net/rfkill/rfkill.c
@@ -774,7 +774,7 @@ static void rfkill_led_trigger_register(struct rfkill *rfkill)
774 int error; 774 int error;
775 775
776 if (!rfkill->led_trigger.name) 776 if (!rfkill->led_trigger.name)
777 rfkill->led_trigger.name = rfkill->dev.bus_id; 777 rfkill->led_trigger.name = dev_name(&rfkill->dev);
778 if (!rfkill->led_trigger.activate) 778 if (!rfkill->led_trigger.activate)
779 rfkill->led_trigger.activate = rfkill_led_trigger_activate; 779 rfkill->led_trigger.activate = rfkill_led_trigger_activate;
780 error = led_trigger_register(&rfkill->led_trigger); 780 error = led_trigger_register(&rfkill->led_trigger);
@@ -815,8 +815,7 @@ int __must_check rfkill_register(struct rfkill *rfkill)
815 "badly initialized rfkill struct\n")) 815 "badly initialized rfkill struct\n"))
816 return -EINVAL; 816 return -EINVAL;
817 817
818 snprintf(dev->bus_id, sizeof(dev->bus_id), 818 dev_set_name(dev, "rfkill%ld", (long)atomic_inc_return(&rfkill_no) - 1);
819 "rfkill%ld", (long)atomic_inc_return(&rfkill_no) - 1);
820 819
821 rfkill_led_trigger_register(rfkill); 820 rfkill_led_trigger_register(rfkill);
822 821