]> Pileus Git - ~andy/linux/blobdiff - drivers/usb/gadget/f_ncm.c
Merge tag 'drivers' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc
[~andy/linux] / drivers / usb / gadget / f_ncm.c
index ae69ed7e6b99a8f4c6d2bfd71f61511dad5671fd..b651b529c67f070dcd4a545cea8cfc40010602f3 100644 (file)
  * it under the terms of the GNU General Public License as published by
  * the Free Software Foundation; either version 2 of the License, or
  * (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
  */
 
 #include <linux/kernel.h>
@@ -1355,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);