Re: [PATCH 4/5] fs: fat: use hex_asc_lo/hex_asc_hi instead ofcustom one
From: Joe Perches
Date: Thu Mar 11 2010 - 03:10:35 EST
On Thu, 2010-03-11 at 09:59 +0200, Andy Shevchenko wrote:
> On Thu, Mar 11, 2010 at 9:21 AM, Joe Perches <joe@xxxxxxxxxxx> wrote:
> >> > + *op++ = hex_asc_hi(ec >> 8);
> >> > + *op++ = hex_asc_lo(ec >> 8);
> >> > + *op++ = hex_asc_hi(ec);
> >> > + *op++ = hex_asc_lo(ec);
> >> Why doesn't this use pack_hex_byte()?
> > or snprintf
> sprintf looks like overkill here.
It's shorter and more intelligible though
op += sprintf(op, ":%04x:%04x", etc)
cheers, Joe
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/