diff options
author | Andy Shevchenko <andriy.shevchenko@linux.intel.com> | 2012-07-06 15:30:21 (GMT) |
---|---|---|
committer | Felipe Balbi <balbi@ti.com> | 2012-08-23 08:04:20 (GMT) |
commit | 8c7ca99250de69dfe97c5f4f6e2eb11dc6145779 (patch) | |
tree | 6580bd515aff40c1959141d4bfa44091f80948bc /drivers/usb/gadget/f_ncm.c | |
parent | 974e9323deefbab923d7aa8f0e4bcf9066c2ec97 (diff) | |
download | linux-fsl-qoriq-8c7ca99250de69dfe97c5f4f6e2eb11dc6145779.tar.xz |
usb: gadget: use %pm to print mac addresses
%pm already provides pretty print for mac addresses, let's
use that and drop homebrew mac address printing.
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Signed-off-by: Felipe Balbi <balbi@ti.com>
Diffstat (limited to 'drivers/usb/gadget/f_ncm.c')
-rw-r--r-- | drivers/usb/gadget/f_ncm.c | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/drivers/usb/gadget/f_ncm.c b/drivers/usb/gadget/f_ncm.c index aab8ede..b651b52 100644 --- a/drivers/usb/gadget/f_ncm.c +++ b/drivers/usb/gadget/f_ncm.c @@ -1346,10 +1346,7 @@ int __init ncm_bind_config(struct usb_configuration *c, u8 ethaddr[ETH_ALEN]) return -ENOMEM; /* export host's Ethernet address in CDC format */ - snprintf(ncm->ethaddr, sizeof ncm->ethaddr, - "%02X%02X%02X%02X%02X%02X", - ethaddr[0], ethaddr[1], ethaddr[2], - ethaddr[3], ethaddr[4], ethaddr[5]); + snprintf(ncm->ethaddr, sizeof ncm->ethaddr, "%pm", ethaddr); ncm_string_defs[1].s = ncm->ethaddr; spin_lock_init(&ncm->lock); |