projects
/
GitHub
/
LineageOS
/
G12
/
android_kernel_amlogic_linux-4.9.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
d9fd1b2
)
drivers: atm: use native kernel's hex_to_bin() func
author
Andy Shevchenko
<andy.shevchenko@gmail.com>
Mon, 20 Sep 2010 20:40:24 +0000
(20:40 +0000)
committer
David S. Miller
<davem@davemloft.net>
Wed, 22 Sep 2010 01:04:44 +0000
(18:04 -0700)
Signed-off-by: Andy Shevchenko <andy.shevchenko@gmail.com>
Cc: Chas Williams <chas@cmf.nrl.navy.mil>
Cc: linux-atm-general@lists.sourceforge.net
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/atm/horizon.c
patch
|
blob
|
blame
|
history
diff --git
a/drivers/atm/horizon.c
b/drivers/atm/horizon.c
index 54720baa7363996203a9489a0bfae45e0fa4a7da..a95790452a685f3325ed64af5db2f2596f911236 100644
(file)
--- a/
drivers/atm/horizon.c
+++ b/
drivers/atm/horizon.c
@@
-1645,10
+1645,8
@@
static int hrz_send (struct atm_vcc * atm_vcc, struct sk_buff * skb) {
unsigned short d = 0;
char * s = skb->data;
if (*s++ == 'D') {
- for (i = 0; i < 4; ++i) {
- d = (d<<4) | ((*s <= '9') ? (*s - '0') : (*s - 'a' + 10));
- ++s;
- }
+ for (i = 0; i < 4; ++i)
+ d = (d << 4) | hex_to_bin(*s++);
PRINTK (KERN_INFO, "debug bitmap is now %hx", debug = d);
}
}