Skip to content

Commit c7c3e6a

Browse files
kuba-mooNipaLocal
authored andcommitted
net: ethtool: remove duplicate defines for family info
Commit under fixes switched to uAPI generation from the YAML spec. A number of custom defines were left behind, mostly for commands very hard to express in YAML spec. Among what was left behind was the name and version of the generic netlink family. Problem is that the codegen always outputs those values so we ended up with a duplicated, differently named set of defines. Provide naming info in YAML and remove the incorrect defines. Fixes: 8d0580c ("ethtool: regenerate uapi header from the spec") Signed-off-by: Jakub Kicinski <[email protected]> Acked-by: Stanislav Fomichev <[email protected]> Signed-off-by: NipaLocal <nipa@local>
1 parent 4bcf6b1 commit c7c3e6a

File tree

3 files changed

+5
-6
lines changed

3 files changed

+5
-6
lines changed

Documentation/netlink/specs/ethtool.yaml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,9 @@ protocol: genetlink-legacy
77
doc: Partial family for Ethtool Netlink.
88
uapi-header: linux/ethtool_netlink_generated.h
99

10+
c-family-name: ethtool-genl-name
11+
c-version-name: ethtool-genl-version
12+
1013
definitions:
1114
-
1215
name: udp-tunnel-type

include/uapi/linux/ethtool_netlink.h

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -208,10 +208,6 @@ enum {
208208
ETHTOOL_A_STATS_PHY_MAX = (__ETHTOOL_A_STATS_PHY_CNT - 1)
209209
};
210210

211-
/* generic netlink info */
212-
#define ETHTOOL_GENL_NAME "ethtool"
213-
#define ETHTOOL_GENL_VERSION 1
214-
215211
#define ETHTOOL_MCGRP_MONITOR_NAME "monitor"
216212

217213
#endif /* _UAPI_LINUX_ETHTOOL_NETLINK_H_ */

include/uapi/linux/ethtool_netlink_generated.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@
66
#ifndef _UAPI_LINUX_ETHTOOL_NETLINK_GENERATED_H
77
#define _UAPI_LINUX_ETHTOOL_NETLINK_GENERATED_H
88

9-
#define ETHTOOL_FAMILY_NAME "ethtool"
10-
#define ETHTOOL_FAMILY_VERSION 1
9+
#define ETHTOOL_GENL_NAME "ethtool"
10+
#define ETHTOOL_GENL_VERSION 1
1111

1212
enum {
1313
ETHTOOL_UDP_TUNNEL_TYPE_VXLAN,

0 commit comments

Comments
 (0)