Skip to content

Commit

Permalink
Use more portable attribute
Browse files Browse the repository at this point in the history
  • Loading branch information
MattCatz committed Oct 30, 2024
1 parent 71056ee commit 6d15571
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/mdio/mdio.h
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ struct cmd {

// Derived from https://stackoverflow.com/a/4152185
#define DEFINE_CMD(_name, _exec) \
__attribute__((externally_visible, section(".cmd_registry"), aligned(__alignof__(struct cmd)) )) \
__attribute__((used, section(".cmd_registry"), aligned(__alignof__(struct cmd)) )) \
struct cmd _exec ## _cmd = { .name = _name, .exec = _exec }

extern struct cmd cmds_start;
Expand Down

0 comments on commit 6d15571

Please sign in to comment.