USB: gadget: Replace %pM with %pm

commit c173d5504d ("USB: gadget: Replace %pK with
%pM") modified the MAC address format specifier to %pM.
So when the host PC asks for the MAC address, the
device sends the address with colons present. Linux
Host machines cannot handle this and ECM function fails
to bind. Fix this by changing the format specifier to
%pm which removes the colons and sends the MAC address.

Change-Id: Id3eebfa371bd2cf976ee0f44e8a7b54690f43e77
Signed-off-by: Ajay Agarwal <ajaya@codeaurora.org>
This commit is contained in:
Ajay Agarwal 2017-10-25 15:16:11 +05:30
parent 9d5748ab14
commit 20fca09e45

View file

@ -1132,7 +1132,7 @@ int gether_get_host_addr_cdc(struct net_device *net, char *host_addr, int len)
return -EINVAL;
dev = netdev_priv(net);
snprintf(host_addr, len, "%pM", dev->host_mac);
snprintf(host_addr, len, "%pm", dev->host_mac);
return strlen(host_addr);
}