History

netfilter: ebtables: use __u8 instead of uint8_t in uapi header

When CONFIG_UAPI_HEADER_TEST=y, exported headers are compile-tested to make sure they can be included from user-space. Currently, linux/netfilter_bridge/ebtables.h is excluded from the test coverage. To make it join the compile-test, we need to fix the build errors attached below. For a case like this, we decided to use __u{8,16,32,64} variable types in this discussion: https://lkml.org/lkml/2019/6/5/18 Build log: CC usr/include/linux/netfilter_bridge/ebtables.h.s In file included from <command-line>:32:0: ./usr/include/linux/netfilter_bridge/ebtables.h:126:4: error: unknown type name ‘uint8_t’ uint8_t revision; ^~~~~~~ ./usr/include/linux/netfilter_bridge/ebtables.h:139:4: error: unknown type name ‘uint8_t’ uint8_t revision; ^~~~~~~ ./usr/include/linux/netfilter_bridge/ebtables.h:152:4: error: unknown type name ‘uint8_t’ uint8_t revision; ^~~~~~~

Masahiro Yamada committed 7 years ago

Commit 20ff1cb1 parent acab7132 files · +3 −4Browse files

Showing the changes to include/uapi/linux (1 of 2 files). Show all

Unified · Split

include/uapi/linux/netfilter_bridge/ebtables.h+3−3
@@ -123,7 +123,7 @@ struct ebt_entry_match { · 122 unmodified lines
123123 union {
124124 struct {
125125 char name[EBT_EXTENSION_MAXNAMELEN];
126− uint8_t revision;
126+ __u8 revision;
127127 };
128128 struct xt_match *match;
129129 } u;
@@ -136,7 +136,7 @@ struct ebt_entry_watcher { · 6 unmodified lines
136136 union {
137137 struct {
138138 char name[EBT_EXTENSION_MAXNAMELEN];
139− uint8_t revision;
139+ __u8 revision;
140140 };
141141 struct xt_target *watcher;
142142 } u;
@@ -149,7 +149,7 @@ struct ebt_entry_target { · 6 unmodified lines
149149 union {
150150 struct {
151151 char name[EBT_EXTENSION_MAXNAMELEN];
152− uint8_t revision;
152+ __u8 revision;
153153 };
154154 struct xt_target *target;
155155 } u;

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t