-
Notifications
You must be signed in to change notification settings - Fork 2.7k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
bpf: simplify adding/removing types to alignchecker
Types in alignchecker were listed like 'TYPE _n', e.g., 'struct tunnel_key _53', so this was simple to add a new type: just add 1 to the last n. However, this is not obvious what to do when removing a type: to re-enumerate the remaining types or to leave holes? Fix this by using the __COUNTER__ macro. Now a new type can be listed as _(TYPE), e.g., '_(struct tunnel_key)', so this simple both to add and to remove types. Signed-off-by: Anton Protopopov <aspsk@isovalent.com>
- Loading branch information
Showing
1 changed file
with
66 additions
and
55 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters