Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

packet: rename offset_to_ptr to skb_offset_to_ptr to avoid conflicts with newer kernel #270

Merged
merged 1 commit into from Oct 2, 2018

Conversation

Projects
None yet
3 participants
@rsalveti
Copy link

rsalveti commented Oct 2, 2018

Rename offset_to_ptr to skb_offset_to_ptr to avoid definition conflict
when building jool against linux >= 4.19.

Fixes:
| mod/stateful/../common/packet.c:73:14: error: conflicting types for 'offset_to_ptr'
| static void *offset_to_ptr(struct sk_buff *skb, unsigned int offset)
| ^~~~~~~~~~~~~
| In file included from kernel-source/include/linux/export.h:45,
| from kernel-source/include/linux/linkage.h:7,
| from kernel-source/include/linux/kernel.h:7,
| from kernel-source/include/linux/skbuff.h:17,
| from mod/stateful/../../include/nat64/mod/common/packet.h:81,
| from mod/stateful/../common/packet.c:1:
| kernel-source/include/linux/compiler.h:297:21: note: previous definition of 'offset_to_ptr' was here
| static inline void *offset_to_ptr(const int *off)
| ^~~~~~~~~~~~~

Signed-off-by: Ricardo Salveti ricardo@foundries.io

packet: rename offset_to_ptr to skb_offset_to_ptr to avoid conflicts …
…with newer kernel

Rename offset_to_ptr to skb_offset_to_ptr to avoid definition conflict
when building jool against linux >= 4.19.

Fixes:
| mod/stateful/../common/packet.c:73:14: error: conflicting types for 'offset_to_ptr'
|  static void *offset_to_ptr(struct sk_buff *skb, unsigned int offset)
|               ^~~~~~~~~~~~~
| In file included from kernel-source/include/linux/export.h:45,
|                  from kernel-source/include/linux/linkage.h:7,
|                  from kernel-source/include/linux/kernel.h:7,
|                  from kernel-source/include/linux/skbuff.h:17,
|                  from mod/stateful/../../include/nat64/mod/common/packet.h:81,
|                  from mod/stateful/../common/packet.c:1:
| kernel-source/include/linux/compiler.h:297:21: note: previous definition of 'offset_to_ptr' was here
|  static inline void *offset_to_ptr(const int *off)
|                      ^~~~~~~~~~~~~

Signed-off-by: Ricardo Salveti <ricardo@foundries.io>

@ydahhrk ydahhrk merged commit 89b3c10 into NICMx:master Oct 2, 2018

@ydahhrk

This comment has been minimized.

Copy link
Member

ydahhrk commented Oct 2, 2018

No issues found; thank you.

@ydahhrk

This comment has been minimized.

Copy link
Member

ydahhrk commented Jan 3, 2019

Ran the test suite on kernel 4.19.0-041900-generic. The latest commit of Jool 3.6.0 is working fine there.

@ydahhrk

This comment has been minimized.

Copy link
Member

ydahhrk commented Jan 3, 2019

@rsalveti: Do you want credits in Jool's README? Oops, never mind. I had already asked.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.