genetlink: no longer support using static family IDs
authorJohannes Berg <johannes.berg@intel.com>
Mon, 24 Oct 2016 12:40:02 +0000 (14:40 +0200)
committerDavid S. Miller <davem@davemloft.net>
Thu, 27 Oct 2016 20:16:09 +0000 (16:16 -0400)
Static family IDs have never really been used, the only
use case was the workaround I introduced for those users
that assumed their family ID was also their multicast
group ID.

Additionally, because static family IDs would never be
reserved by the generic netlink code, using a relatively
low ID would only work for built-in families that can be
registered immediately after generic netlink is started,
which is basically only the control family (apart from
the workaround code, which I also had to add code for so
it would reserve those IDs)

Thus, anything other than GENL_ID_GENERATE is flawed and
luckily not used except in the cases I mentioned. Move
those workarounds into a few lines of code, and then get
rid of GENL_ID_GENERATE entirely, making it more robust.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
37 files changed:
drivers/acpi/event.c
drivers/net/gtp.c
drivers/net/macsec.c
drivers/net/team/team.c
drivers/net/wireless/mac80211_hwsim.c
drivers/scsi/pmcraid.c
drivers/target/target_core_user.c
drivers/thermal/thermal_core.c
fs/dlm/netlink.c
fs/quota/netlink.c
include/linux/genl_magic_func.h
include/net/genetlink.h
include/uapi/linux/genetlink.h
kernel/taskstats.c
net/batman-adv/netlink.c
net/core/devlink.c
net/core/drop_monitor.c
net/hsr/hsr_netlink.c
net/ieee802154/netlink.c
net/ieee802154/nl802154.c
net/ipv4/fou.c
net/ipv4/tcp_metrics.c
net/ipv6/ila/ila_xlat.c
net/irda/irnetlink.c
net/l2tp/l2tp_netlink.c
net/netfilter/ipvs/ip_vs_ctl.c
net/netlabel/netlabel_calipso.c
net/netlabel/netlabel_cipso_v4.c
net/netlabel/netlabel_mgmt.c
net/netlabel/netlabel_unlabeled.c
net/netlink/genetlink.c
net/nfc/netlink.c
net/openvswitch/datapath.c
net/tipc/netlink.c
net/tipc/netlink_compat.c
net/wimax/stack.c
net/wireless/nl80211.c

index e24ea4e796e4b920cdc437f3f76a69eb391b85c7..8dfca3d531313d7a56a38cb99217b0096adb3119 100644 (file)
@@ -83,7 +83,6 @@ static const struct genl_multicast_group acpi_event_mcgrps[] = {
 };
 
 static struct genl_family acpi_event_genl_family = {
-       .id = GENL_ID_GENERATE,
        .name = ACPI_GENL_FAMILY_NAME,
        .version = ACPI_GENL_VERSION,
        .maxattr = ACPI_GENL_ATTR_MAX,
index 97e0cbca0a08a15af666fdb17ebc0c87e2a09bda..f66737ba129964a19c45aa212400fa043b5a3dea 100644 (file)
@@ -1095,7 +1095,6 @@ static int gtp_genl_del_pdp(struct sk_buff *skb, struct genl_info *info)
 }
 
 static struct genl_family gtp_genl_family = {
-       .id             = GENL_ID_GENERATE,
        .name           = "gtp",
        .version        = 0,
        .hdrsize        = 0,
index 1a134cb2d52cba5afc1dd8d53143cdb4587e1304..a5309b81a78658a8678b50911bd043778d7e77e1 100644 (file)
@@ -1422,7 +1422,6 @@ static void clear_tx_sa(struct macsec_tx_sa *tx_sa)
 }
 
 static struct genl_family macsec_fam = {
-       .id             = GENL_ID_GENERATE,
        .name           = MACSEC_GENL_NAME,
        .hdrsize        = 0,
        .version        = MACSEC_GENL_VERSION,
index a380649bf6b5c2242edac044b497bf15922cffe5..0b50205764ff24a905aefefd0d45412e45d58ff1 100644 (file)
@@ -2151,7 +2151,6 @@ static struct rtnl_link_ops team_link_ops __read_mostly = {
  ***********************************/
 
 static struct genl_family team_nl_family = {
-       .id             = GENL_ID_GENERATE,
        .name           = TEAM_GENL_NAME,
        .version        = TEAM_GENL_VERSION,
        .maxattr        = TEAM_ATTR_MAX,
index e95b79bccf9b2e8acfd2b83973d6bbe397ec0727..54b6cd62676e44a99172e6efc67c49ae6e501f88 100644 (file)
@@ -589,7 +589,6 @@ struct hwsim_radiotap_ack_hdr {
 
 /* MAC80211_HWSIM netlinf family */
 static struct genl_family hwsim_genl_family = {
-       .id = GENL_ID_GENERATE,
        .hdrsize = 0,
        .name = "MAC80211_HWSIM",
        .version = 1,
index 68a5c347fae9a578fdcacbf6c618a0c15f4f6bb6..cc50eb87b28a394ee47c80ff61d41ccaedc4f3b7 100644 (file)
@@ -1369,12 +1369,6 @@ static struct genl_multicast_group pmcraid_mcgrps[] = {
 };
 
 static struct genl_family pmcraid_event_family = {
-       /*
-        * Due to prior multicast group abuse (the code having assumed that
-        * the family ID can be used as a multicast group ID) we need to
-        * statically allocate a family (and thus group) ID.
-        */
-       .id = GENL_ID_PMCRAID,
        .name = "pmcraid",
        .version = 1,
        .maxattr = PMCRAID_AEN_ATTR_MAX,
index 62bf4fe5704a929aa01a5f970f26e7f1020f9442..313a0ef3cda7dcbb5bf7cb5a027b3e69fbd757f8 100644 (file)
@@ -148,7 +148,6 @@ static const struct genl_multicast_group tcmu_mcgrps[] = {
 
 /* Our generic netlink family */
 static struct genl_family tcmu_genl_family = {
-       .id = GENL_ID_GENERATE,
        .hdrsize = 0,
        .name = "TCM-USER",
        .version = 1,
index 226b0b4aced6a2e9fd348086259fc517e3f674ee..68d7503f64174beba83a188b69da7978c38f1061 100644 (file)
@@ -2164,7 +2164,6 @@ static const struct genl_multicast_group thermal_event_mcgrps[] = {
 };
 
 static struct genl_family thermal_event_genl_family = {
-       .id = GENL_ID_GENERATE,
        .name = THERMAL_GENL_FAMILY_NAME,
        .version = THERMAL_GENL_VERSION,
        .maxattr = THERMAL_GENL_ATTR_MAX,
index 1e6e227134d7b5dae4fa3fc43feafeb994bfa708..00d2269562644872344025bd860e656760b572b4 100644 (file)
@@ -17,7 +17,6 @@ static uint32_t dlm_nl_seqnum;
 static uint32_t listener_nlportid;
 
 static struct genl_family family = {
-       .id             = GENL_ID_GENERATE,
        .name           = DLM_GENL_NAME,
        .version        = DLM_GENL_VERSION,
 };
index 8b252673d4540b519e4a46096869ff039246e614..3965a5cdfaa2597d7e6c9f7922228c967ecfe2f3 100644 (file)
@@ -13,13 +13,6 @@ static const struct genl_multicast_group quota_mcgrps[] = {
 
 /* Netlink family structure for quota */
 static struct genl_family quota_genl_family = {
-       /*
-        * Needed due to multicast group ID abuse - old code assumed
-        * the family ID was also a valid multicast group ID (which
-        * isn't true) and userspace might thus rely on it. Assign a
-        * static ID for this group to make dealing with that easier.
-        */
-       .id = GENL_ID_VFS_DQUOT,
        .hdrsize = 0,
        .name = "VFS_DQUOT",
        .version = 1,
index 667c31101b8b91f0b1d17a99a08edd9cf8d29d63..7c070c1fe4577dcb84c956fcbe3d6f46558994c5 100644 (file)
@@ -260,7 +260,6 @@ static struct genl_ops ZZZ_genl_ops[] __read_mostly = {
  */
 #define ZZZ_genl_family                CONCAT_(GENL_MAGIC_FAMILY, _genl_family)
 static struct genl_family ZZZ_genl_family __read_mostly = {
-       .id = GENL_ID_GENERATE,
        .name = __stringify(GENL_MAGIC_FAMILY),
        .version = GENL_MAGIC_VERSION,
 #ifdef GENL_MAGIC_FAMILY_HDRSZ
index ef9defb3f5bc0ac0a7bbf0512392b71d15bea424..43a5c3975a2f1815fd362943f29188fdfac647c1 100644 (file)
@@ -20,7 +20,7 @@ struct genl_info;
 
 /**
  * struct genl_family - generic netlink family
- * @id: protocol family idenfitier
+ * @id: protocol family identifier (private)
  * @hdrsize: length of user specific header in bytes
  * @name: name of family
  * @version: protocol version
@@ -48,7 +48,7 @@ struct genl_info;
  * @n_ops: number of operations supported by this family (private)
  */
 struct genl_family {
-       unsigned int            id;
+       unsigned int            id;             /* private */
        unsigned int            hdrsize;
        char                    name[GENL_NAMSIZ];
        unsigned int            version;
@@ -149,9 +149,6 @@ static inline int genl_register_family(struct genl_family *family)
  * Registers the specified family and operations from the specified table.
  * Only one family may be registered with the same family name or identifier.
  *
- * The family id may equal GENL_ID_GENERATE causing an unique id to
- * be automatically generated and assigned.
- *
  * Either a doit or dumpit callback must be specified for every registered
  * operation or the function will fail. Only one operation structure per
  * command identifier may be registered.
index 5512c90af7e30f5593fbba398882f99a62fe65c0..d9b2db4a29c69bd657801000cfdaf7aff0271b41 100644 (file)
@@ -26,7 +26,6 @@ struct genlmsghdr {
 /*
  * List of reserved static generic netlink identifiers:
  */
-#define GENL_ID_GENERATE       0
 #define GENL_ID_CTRL           NLMSG_MIN_TYPE
 #define GENL_ID_VFS_DQUOT      (NLMSG_MIN_TYPE + 1)
 #define GENL_ID_PMCRAID                (NLMSG_MIN_TYPE + 2)
index b3f05ee20d1845736580d3c4fbd55d67e7fc3b51..d7a1a9461a10e3a85891413f2ab52c789475599a 100644 (file)
@@ -42,7 +42,6 @@ static int family_registered;
 struct kmem_cache *taskstats_cache;
 
 static struct genl_family family = {
-       .id             = GENL_ID_GENERATE,
        .name           = TASKSTATS_GENL_NAME,
        .version        = TASKSTATS_GENL_VERSION,
        .maxattr        = TASKSTATS_CMD_ATTR_MAX,
index 64cb6acbe0a64bf8da5c5b03c1874b9e886f369f..a03b0ed7e8dd6a8196e34c28dde9b23c5260c861 100644 (file)
@@ -49,7 +49,6 @@
 #include "translation-table.h"
 
 struct genl_family batadv_netlink_family = {
-       .id = GENL_ID_GENERATE,
        .hdrsize = 0,
        .name = BATADV_NL_NAME,
        .version = 1,
index d2fd736de6a29f8cbf77da29ba5162245f919ce5..3008d9c33875cd77ad327ee5b87349927939c92b 100644 (file)
@@ -342,7 +342,6 @@ static void devlink_nl_post_doit(const struct genl_ops *ops,
 }
 
 static struct genl_family devlink_nl_family = {
-       .id             = GENL_ID_GENERATE,
        .name           = DEVLINK_GENL_NAME,
        .version        = DEVLINK_GENL_VERSION,
        .maxattr        = DEVLINK_ATTR_MAX,
index 72cfb0c611254cbe48885e4d3a7b497e91d94fed..a5320dfcd978d09a7fd9d32b95fedaee1b4756d2 100644 (file)
@@ -60,7 +60,6 @@ struct dm_hw_stat_delta {
 };
 
 static struct genl_family net_drop_monitor_family = {
-       .id             = GENL_ID_GENERATE,
        .hdrsize        = 0,
        .name           = "NET_DM",
        .version        = 2,
index d4d1617f43a8bfb842a8017dc51655ae1065942b..2ad039492bee8beb913f46349b29ea8aa9c6c47e 100644 (file)
@@ -132,7 +132,6 @@ static const struct nla_policy hsr_genl_policy[HSR_A_MAX + 1] = {
 };
 
 static struct genl_family hsr_genl_family = {
-       .id = GENL_ID_GENERATE,
        .hdrsize = 0,
        .name = "HSR",
        .version = 1,
index c8133c07ceee4ce29411a5f9ea47c0c529231223..19144158b69661386f8d3395f25403ecbd30ebb4 100644 (file)
@@ -29,7 +29,6 @@ static unsigned int ieee802154_seq_num;
 static DEFINE_SPINLOCK(ieee802154_seq_lock);
 
 struct genl_family nl802154_family = {
-       .id             = GENL_ID_GENERATE,
        .hdrsize        = 0,
        .name           = IEEE802154_NL_NAME,
        .version        = 1,
index 21aabadccd0ee1b37163f286d7768aaec8f31725..182299858f1d89b1c8771a064a10e38483c54ff1 100644 (file)
@@ -34,7 +34,6 @@ static void nl802154_post_doit(const struct genl_ops *ops, struct sk_buff *skb,
 
 /* the netlink family */
 static struct genl_family nl802154_fam = {
-       .id = GENL_ID_GENERATE,         /* don't bother with a hardcoded ID */
        .name = NL802154_GENL_NAME,     /* have users key off the name instead */
        .hdrsize = 0,                   /* no private header */
        .version = 1,                   /* no particular meaning now */
index cf50f7e2b0124d3bfa6ad2caae65cf1cf590ad44..e3fc527c5d3786dd48b359ac6f0cedf4c96630bb 100644 (file)
@@ -623,7 +623,6 @@ static int fou_destroy(struct net *net, struct fou_cfg *cfg)
 }
 
 static struct genl_family fou_nl_family = {
-       .id             = GENL_ID_GENERATE,
        .hdrsize        = 0,
        .name           = FOU_GENL_NAME,
        .version        = FOU_GENL_VERSION,
index bf1f3b2b29d1226b572fdc6286c697c2f75b805b..3da305127b32a067ac420db2be160bf203288e2d 100644 (file)
@@ -743,7 +743,6 @@ void tcp_fastopen_cache_set(struct sock *sk, u16 mss,
 }
 
 static struct genl_family tcp_metrics_nl_family = {
-       .id             = GENL_ID_GENERATE,
        .hdrsize        = 0,
        .name           = TCP_METRICS_GENL_NAME,
        .version        = TCP_METRICS_GENL_VERSION,
index e604013dd8147a36ac247ef44f0c37c6519cbcc4..0d57e27d1cdd2dc744a1f7bbae3032aa6955f986 100644 (file)
@@ -119,7 +119,6 @@ static const struct rhashtable_params rht_params = {
 };
 
 static struct genl_family ila_nl_family = {
-       .id             = GENL_ID_GENERATE,
        .hdrsize        = 0,
        .name           = ILA_GENL_NAME,
        .version        = ILA_GENL_VERSION,
index e15c40e86660cf204cc1bc734abde164fb3ef22e..f23b81aa91fefb2bcd8de1aa9fcbff160e981541 100644 (file)
@@ -25,7 +25,6 @@
 
 
 static struct genl_family irda_nl_family = {
-       .id = GENL_ID_GENERATE,
        .name = IRDA_NL_NAME,
        .hdrsize = 0,
        .version = IRDA_NL_VERSION,
index bf3117771822af3f8cdfcbc956d5b8018050c732..4fbf1f41ac5249e557d5306ae5d49aa815fb2f33 100644 (file)
@@ -32,7 +32,6 @@
 
 
 static struct genl_family l2tp_nl_family = {
-       .id             = GENL_ID_GENERATE,
        .name           = L2TP_GENL_NAME,
        .version        = L2TP_GENL_VERSION,
        .hdrsize        = 0,
index c3c809b2e7122daabac5b45ffed67979e0fecb28..ceed66cdd03e5b4b2f5c6bb07189a2b55f7fa157 100644 (file)
@@ -2841,7 +2841,6 @@ static struct nf_sockopt_ops ip_vs_sockopts = {
 
 /* IPVS genetlink family */
 static struct genl_family ip_vs_genl_family = {
-       .id             = GENL_ID_GENERATE,
        .hdrsize        = 0,
        .name           = IPVS_GENL_NAME,
        .version        = IPVS_GENL_VERSION,
index 2ec93c5e77bb07ce82ccb4d1ff8418660960d06c..152e503b8c5ddeda59ee7ab40c49e471d4aace8a 100644 (file)
@@ -61,7 +61,6 @@ struct netlbl_domhsh_walk_arg {
 
 /* NetLabel Generic NETLINK CALIPSO family */
 static struct genl_family netlbl_calipso_gnl_family = {
-       .id = GENL_ID_GENERATE,
        .hdrsize = 0,
        .name = NETLBL_NLTYPE_CALIPSO_NAME,
        .version = NETLBL_PROTO_VERSION,
index 7fd1104ba9007ec0d731d97d0a245eb3da7b4436..755b284e7ad404a7654234f5dab307b2e4a32166 100644 (file)
@@ -60,7 +60,6 @@ struct netlbl_domhsh_walk_arg {
 
 /* NetLabel Generic NETLINK CIPSOv4 family */
 static struct genl_family netlbl_cipsov4_gnl_family = {
-       .id = GENL_ID_GENERATE,
        .hdrsize = 0,
        .name = NETLBL_NLTYPE_CIPSOV4_NAME,
        .version = NETLBL_PROTO_VERSION,
index f85d0e07af2dd9c7f4f4fb2f6b05fcf99b21c8eb..3b00f2368fcd49eee521caf917bdd276c6584d20 100644 (file)
@@ -61,7 +61,6 @@ struct netlbl_domhsh_walk_arg {
 
 /* NetLabel Generic NETLINK CIPSOv4 family */
 static struct genl_family netlbl_mgmt_gnl_family = {
-       .id = GENL_ID_GENERATE,
        .hdrsize = 0,
        .name = NETLBL_NLTYPE_MGMT_NAME,
        .version = NETLBL_PROTO_VERSION,
index 4528cff9138b5499f7577bf2801dac8f85e0fcda..c2ea8d1f653acbdcfeacc977cf581cbc21809d6d 100644 (file)
@@ -124,7 +124,6 @@ static u8 netlabel_unlabel_acceptflg;
 
 /* NetLabel Generic NETLINK unlabeled family */
 static struct genl_family netlbl_unlabel_gnl_family = {
-       .id = GENL_ID_GENERATE,
        .hdrsize = 0,
        .name = NETLBL_NLTYPE_UNLABELED_NAME,
        .version = NETLBL_PROTO_VERSION,
index 01291b7a27bb6401b884367a6453d0167d6d6aaa..f19ec969edee93ddf55bae4e14ca3a5cf96a0901 100644 (file)
@@ -349,8 +349,6 @@ static int genl_validate_ops(const struct genl_family *family)
  *
  * Registers the specified family after validating it first. Only one
  * family may be registered with the same family name or identifier.
- * The family id may equal GENL_ID_GENERATE causing an unique id to
- * be automatically generated and assigned.
  *
  * The family's ops array must already be assigned, you can use the
  * genl_register_family_with_ops() helper function.
@@ -359,13 +357,7 @@ static int genl_validate_ops(const struct genl_family *family)
  */
 int __genl_register_family(struct genl_family *family)
 {
-       int err = -EINVAL, i;
-
-       if (family->id && family->id < GENL_MIN_ID)
-               goto errout;
-
-       if (family->id > GENL_MAX_ID)
-               goto errout;
+       int err, i;
 
        err = genl_validate_ops(family);
        if (err)
@@ -378,8 +370,27 @@ int __genl_register_family(struct genl_family *family)
                goto errout_locked;
        }
 
-       if (family->id == GENL_ID_GENERATE) {
-               u16 newid = genl_generate_id();
+       if (family == &genl_ctrl) {
+               family->id = GENL_ID_CTRL;
+       } else {
+               u16 newid;
+
+               /* this should be left zero in the struct */
+               WARN_ON(family->id);
+
+               /*
+                * Sadly, a few cases need to be special-cased
+                * due to them having previously abused the API
+                * and having used their family ID also as their
+                * multicast group ID, so we use reserved IDs
+                * for both to be sure we can do that mapping.
+                */
+               if (strcmp(family->name, "pmcraid") == 0)
+                       newid = GENL_ID_PMCRAID;
+               else if (strcmp(family->name, "VFS_DQUOT") == 0)
+                       newid = GENL_ID_VFS_DQUOT;
+               else
+                       newid = genl_generate_id();
 
                if (!newid) {
                        err = -ENOMEM;
@@ -387,9 +398,6 @@ int __genl_register_family(struct genl_family *family)
                }
 
                family->id = newid;
-       } else if (genl_family_find_byid(family->id)) {
-               err = -EEXIST;
-               goto errout_locked;
        }
 
        if (family->maxattr && !family->parallel_ops) {
@@ -419,7 +427,6 @@ int __genl_register_family(struct genl_family *family)
 
 errout_locked:
        genl_unlock_all();
-errout:
        return err;
 }
 EXPORT_SYMBOL(__genl_register_family);
index 79786bf62b88c2036b461a3a4b631d159dad92fd..c230403e066c10934d693d07a8ee67f2b18f0163 100644 (file)
@@ -39,7 +39,6 @@ static const struct genl_multicast_group nfc_genl_mcgrps[] = {
 };
 
 static struct genl_family nfc_genl_family = {
-       .id = GENL_ID_GENERATE,
        .hdrsize = 0,
        .name = NFC_GENL_NAME,
        .version = NFC_GENL_VERSION,
index 194435aa1165442fb4943ea935ff52ca83dbf1ea..f9fef7dfba15a2bfbfa0c46f74ca5e1962eab82e 100644 (file)
@@ -671,7 +671,6 @@ static const struct genl_ops dp_packet_genl_ops[] = {
 };
 
 static struct genl_family dp_packet_genl_family = {
-       .id = GENL_ID_GENERATE,
        .hdrsize = sizeof(struct ovs_header),
        .name = OVS_PACKET_FAMILY,
        .version = OVS_PACKET_VERSION,
@@ -1436,7 +1435,6 @@ static const struct genl_ops dp_flow_genl_ops[] = {
 };
 
 static struct genl_family dp_flow_genl_family = {
-       .id = GENL_ID_GENERATE,
        .hdrsize = sizeof(struct ovs_header),
        .name = OVS_FLOW_FAMILY,
        .version = OVS_FLOW_VERSION,
@@ -1822,7 +1820,6 @@ static const struct genl_ops dp_datapath_genl_ops[] = {
 };
 
 static struct genl_family dp_datapath_genl_family = {
-       .id = GENL_ID_GENERATE,
        .hdrsize = sizeof(struct ovs_header),
        .name = OVS_DATAPATH_FAMILY,
        .version = OVS_DATAPATH_VERSION,
@@ -2244,7 +2241,6 @@ static const struct genl_ops dp_vport_genl_ops[] = {
 };
 
 struct genl_family dp_vport_genl_family = {
-       .id = GENL_ID_GENERATE,
        .hdrsize = sizeof(struct ovs_header),
        .name = OVS_VPORT_FAMILY,
        .version = OVS_VPORT_VERSION,
index 4b94f3cfe3af41225a31157e904780be0d914928..383b8fedabc76b14030b38614ca2f30cb539219e 100644 (file)
@@ -136,7 +136,6 @@ const struct nla_policy tipc_nl_udp_policy[TIPC_NLA_UDP_MAX + 1] = {
  * so we have a separate genl handling for the new API.
  */
 struct genl_family tipc_genl_family = {
-       .id             = GENL_ID_GENERATE,
        .name           = TIPC_GENL_V2_NAME,
        .version        = TIPC_GENL_V2_VERSION,
        .hdrsize        = 0,
index 1fd4647647650b75f17f41d19d288be7abe436a3..f04428e4c8e56beb83309a34afb96e8c95e397ff 100644 (file)
@@ -1216,7 +1216,6 @@ send:
 }
 
 static struct genl_family tipc_genl_compat_family = {
-       .id             = GENL_ID_GENERATE,
        .name           = TIPC_GENL_NAME,
        .version        = TIPC_GENL_VERSION,
        .hdrsize        = TIPC_GENL_HDRLEN,
index 3f816e2971ee26d97bfb4cd12976d6f67980fce6..8ac83a41585f2c4866786d45a87f8302ea8d4a57 100644 (file)
@@ -573,7 +573,6 @@ size_t D_LEVEL_SIZE = ARRAY_SIZE(D_LEVEL);
 
 
 struct genl_family wimax_gnl_family = {
-       .id = GENL_ID_GENERATE,
        .name = "WiMAX",
        .version = WIMAX_GNL_VERSION,
        .hdrsize = 0,
index 7d8cb3330c8631f677df0df2e4d29fb8e3263b58..714beafe05e0d8fec01b128290413745efcc5b96 100644 (file)
@@ -39,7 +39,6 @@ static void nl80211_post_doit(const struct genl_ops *ops, struct sk_buff *skb,
 
 /* the netlink family */
 static struct genl_family nl80211_fam = {
-       .id = GENL_ID_GENERATE,         /* don't bother with a hardcoded ID */
        .name = NL80211_GENL_NAME,      /* have users key off the name instead */
        .hdrsize = 0,                   /* no private header */
        .version = 1,                   /* no particular meaning now */