lkml.org 
[lkml]   [2010]   [Feb]   [18]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    Patch in this message
    /
    From
    Subject[PATCH 09/12] drivers: net: use kernel's method to get byte in hex form
    Date
    From: Andy Shevchenko <ext-andriy.shevchenko@nokia.com>

    Signed-off-by: Andy Shevchenko <ext-andriy.shevchenko@nokia.com>
    ---
    drivers/net/ppp_synctty.c | 4 +---
    1 files changed, 1 insertions(+), 3 deletions(-)

    diff --git a/drivers/net/ppp_synctty.c b/drivers/net/ppp_synctty.c
    index 3a13cec..e4b3cf6 100644
    --- a/drivers/net/ppp_synctty.c
    +++ b/drivers/net/ppp_synctty.c
    @@ -108,12 +108,10 @@ static void
    ppp_print_hex (register __u8 * out, const __u8 * in, int count)
    {
    register __u8 next_ch;
    - static const char hex[] = "0123456789ABCDEF";

    while (count-- > 0) {
    next_ch = *in++;
    - *out++ = hex[(next_ch >> 4) & 0x0F];
    - *out++ = hex[next_ch & 0x0F];
    + out = pack_hex_byte(out, next_ch);
    ++out;
    }
    }
    --
    1.5.6.5


    \
     
     \ /
      Last update: 2010-02-18 20:01    [W:2.900 / U:0.232 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site