From 3345610229187d7ec621eebe0791208d81f056b0 Mon Sep 17 00:00:00 2001 From: Matt Sealey Date: Tue, 20 Dec 2011 21:38:11 -0600 Subject: [PATCH] put hex_to_bin back --- drivers/staging/rt2860/common/rtmp_init.c | 4 ++-- include/linux/kernel.h | 2 +- lib/hexdump.c | 8 ++++---- 3 files changed, 7 insertions(+), 7 deletions(-) diff --git a/drivers/staging/rt2860/common/rtmp_init.c b/drivers/staging/rt2860/common/rtmp_init.c index 925093ca552..d359a14f5d4 100644 --- a/drivers/staging/rt2860/common/rtmp_init.c +++ b/drivers/staging/rt2860/common/rtmp_init.c @@ -2829,8 +2829,8 @@ void AtoH(char *src, u8 *dest, int destlen) destTemp = (u8 *)dest; while (destlen--) { - *destTemp = hex_to_bin_old(*srcptr++) << 4; /* Put 1st ascii byte in upper nibble. */ - *destTemp += hex_to_bin_old(*srcptr++); /* Add 2nd ascii byte to above. */ + *destTemp = hex_to_bin(*srcptr++) << 4; /* Put 1st ascii byte in upper nibble. */ + *destTemp += hex_to_bin(*srcptr++); /* Add 2nd ascii byte to above. */ destTemp++; } } diff --git a/include/linux/kernel.h b/include/linux/kernel.h index 76510798336..653ab91fcc2 100644 --- a/include/linux/kernel.h +++ b/include/linux/kernel.h @@ -359,7 +359,7 @@ static inline char *pack_hex_byte(char *buf, u8 byte) return buf; } -extern int hex_to_bin_old(char ch); +extern int hex_to_bin(char ch); #ifndef pr_fmt #define pr_fmt(fmt) fmt diff --git a/lib/hexdump.c b/lib/hexdump.c index bcebe5c7fd7..5d7a4802c56 100644 --- a/lib/hexdump.c +++ b/lib/hexdump.c @@ -16,13 +16,13 @@ const char hex_asc[] = "0123456789abcdef"; EXPORT_SYMBOL(hex_asc); /** - * hex_to_bin_old - convert a hex digit to its real value + * hex_to_bin - convert a hex digit to its real value * @ch: ascii character represents hex digit * - * hex_to_bin_old() converts one hex digit to its actual value or -1 in case of bad + * hex_to_bin() converts one hex digit to its actual value or -1 in case of bad * input. */ -int hex_to_bin_old(char ch) +int hex_to_bin(char ch) { if ((ch >= '0') && (ch <= '9')) return ch - '0'; @@ -31,7 +31,7 @@ int hex_to_bin_old(char ch) return ch - 'a' + 10; return -1; } -EXPORT_SYMBOL(hex_to_bin_old); +EXPORT_SYMBOL(hex_to_bin); /** * hex_dump_to_buffer - convert a blob of data to "hex ASCII" in memory