summaryrefslogtreecommitdiff
path: root/drivers/net/ethernet
diff options
context:
space:
mode:
authorPaul Pluzhnikov <ppluzhnikov@google.com>2012-06-09 14:53:03 (GMT)
committerDavid S. Miller <davem@davemloft.net>2012-06-10 04:27:18 (GMT)
commit8876d6b5f81f4e242a6660da22bbd92f17a8d058 (patch)
treeb1e70628e42d7f1567a1816c84b8aec1bb564989 /drivers/net/ethernet
parentf41ef2e7dc4515777810016612316c38f84275e7 (diff)
downloadlinux-fsl-qoriq-8876d6b5f81f4e242a6660da22bbd92f17a8d058.tar.xz
net: Make linux/tcp.h C++ friendly (trivial)
I originally sent this patch to <trivial@kernel.org>, but Jiri Kosina did not feel that this is fully appropriate for the trivial tree. Using linux/tcp.h from C++ results in: cat t.cc #include <linux/tcp.h> int main() { } g++ -c t.cc In file included from t.cc:1: /usr/include/linux/tcp.h:72: error: '__u32 __fswab32(__u32)' cannot appear in a constant-expression /usr/include/linux/tcp.h:72: error: a function call cannot appear in a constant-expression ... Attached trivial patch fixes this problem. Tested: - the t.cc above compiles with g++ and - the following program generates the same output before/after the patch: #include <linux/tcp.h> #include <stdio.h> int main () { #define P(a) printf("%s: %08x\n", #a, (int)a) P(TCP_FLAG_CWR); P(TCP_FLAG_ECE); P(TCP_FLAG_URG); P(TCP_FLAG_ACK); P(TCP_FLAG_PSH); P(TCP_FLAG_RST); P(TCP_FLAG_SYN); P(TCP_FLAG_FIN); P(TCP_RESERVED_BITS); P(TCP_DATA_OFFSET); #undef P return 0; } Signed-off-by: Paul Pluzhnikov <ppluzhnikov@google.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet')
0 files changed, 0 insertions, 0 deletions