projects
/
firefly-linux-kernel-4.4.55.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
[IP6TUNNEL]: Add (ip6_tnl_)net argument to some calls.
[firefly-linux-kernel-4.4.55.git]
/
net
/
x25
/
x25_facilities.c
diff --git
a/net/x25/x25_facilities.c
b/net/x25/x25_facilities.c
index dec404afa11333830ac69330ce2d6ef4a7fa357a..a21f6646eb3a85cd1275708ba53960ed085402da 100644
(file)
--- a/
net/x25/x25_facilities.c
+++ b/
net/x25/x25_facilities.c
@@
-205,9
+205,7
@@
int x25_create_facilities(unsigned char *buffer,
}
if (dte_facs->calling_len && (facil_mask & X25_MASK_CALLING_AE)) {
}
if (dte_facs->calling_len && (facil_mask & X25_MASK_CALLING_AE)) {
- unsigned bytecount = (dte_facs->calling_len % 2) ?
- dte_facs->calling_len / 2 + 1 :
- dte_facs->calling_len / 2;
+ unsigned bytecount = (dte_facs->calling_len + 1) >> 1;
*p++ = X25_FAC_CALLING_AE;
*p++ = 1 + bytecount;
*p++ = dte_facs->calling_len;
*p++ = X25_FAC_CALLING_AE;
*p++ = 1 + bytecount;
*p++ = dte_facs->calling_len;