From 875138f81d71af3cfa80df57e32fe9efbc4f95bc Mon Sep 17 00:00:00 2001 From: Andrew Lunn Date: Sun, 28 Apr 2019 19:37:11 +0200 Subject: dsa: Move tagger name into its ops structure Rather than keep a list to map a tagger ops to a name, place the name into the ops structure. This removes the hard coded list, a step towards making the taggers more dynamic. Signed-off-by: Andrew Lunn Reviewed-by: Florian Fainelli v2: Move name to end of structure, keeping the hot entries at the beginning. Signed-off-by: David S. Miller --- net/dsa/tag_ksz.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'net/dsa/tag_ksz.c') diff --git a/net/dsa/tag_ksz.c b/net/dsa/tag_ksz.c index 12b2f58786ee..631094599514 100644 --- a/net/dsa/tag_ksz.c +++ b/net/dsa/tag_ksz.c @@ -134,6 +134,7 @@ static struct sk_buff *ksz9477_rcv(struct sk_buff *skb, struct net_device *dev, } const struct dsa_device_ops ksz9477_netdev_ops = { + .name = "ksz9477", .xmit = ksz9477_xmit, .rcv = ksz9477_rcv, .overhead = KSZ9477_INGRESS_TAG_LEN, @@ -167,6 +168,7 @@ static struct sk_buff *ksz9893_xmit(struct sk_buff *skb, } const struct dsa_device_ops ksz9893_netdev_ops = { + .name = "ksz9893", .xmit = ksz9893_xmit, .rcv = ksz9477_rcv, .overhead = KSZ_INGRESS_TAG_LEN, -- cgit v1.2.3