lkml.org 
[lkml]   [2010]   [Sep]   [13]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    Patch in this message
    /
    From
    Subject[PATCHv2 03/10] staging: brcm80211: use '%pM' format to print MAC address
    Date
    Signed-off-by: Andy Shevchenko <andy.shevchenko@gmail.com>
    Cc: Nohee Ko <noheek@broadcom.com>
    Cc: linux-wireless@vger.kernel.org
    ---
    drivers/staging/brcm80211/util/bcmutils.c | 5 +----
    1 files changed, 1 insertions(+), 4 deletions(-)

    diff --git a/drivers/staging/brcm80211/util/bcmutils.c b/drivers/staging/brcm80211/util/bcmutils.c
    index 364f837..c6c63a8 100644
    --- a/drivers/staging/brcm80211/util/bcmutils.c
    +++ b/drivers/staging/brcm80211/util/bcmutils.c
    @@ -792,10 +792,7 @@ int BCMROMFN(bcm_ether_atoe) (char *p, struct ether_addr * ea) {

    char *bcm_ether_ntoa(const struct ether_addr *ea, char *buf)
    {
    - static const char template[] = "%02x:%02x:%02x:%02x:%02x:%02x";
    - snprintf(buf, 18, template,
    - ea->octet[0] & 0xff, ea->octet[1] & 0xff, ea->octet[2] & 0xff,
    - ea->octet[3] & 0xff, ea->octet[4] & 0xff, ea->octet[5] & 0xff);
    + snprintf(buf, 18, "%pM", ea->octet);
    return (buf);
    }

    --
    1.7.2.2


    \
     
     \ /
      Last update: 2010-09-13 10:45    [W:0.036 / U:61.588 seconds]
    ©2003-2016 Jasper Spaans. hosted at Digital OceanAdvertise on this site