From d3b8c04988ca1685700e345a82a1396df79e6291 Mon Sep 17 00:00:00 2001 From: Andrew Lunn Date: Sun, 28 Apr 2019 19:37:15 +0200 Subject: dsa: Add boilerplate helper to register DSA tag driver modules A DSA tag driver module will need to register the tag protocols it implements with the DSA core. Add macros containing this boiler plate. The registration/unregistration code is currently just a stub. A Later patch will add the real implementation. Signed-off-by: Andrew Lunn Reviewed-by: Florian Fainelli v2 Fix indent of #endif Rewrite to move list pointer into a new structure v3 Move kdoc next to macro Fix THIS_MODULE indentation Signed-off-by: David S. Miller --- net/dsa/dsa.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'net/dsa/dsa.c') diff --git a/net/dsa/dsa.c b/net/dsa/dsa.c index 2da733dff86b..34becafbd37b 100644 --- a/net/dsa/dsa.c +++ b/net/dsa/dsa.c @@ -76,6 +76,18 @@ const struct dsa_device_ops *dsa_device_ops[DSA_TAG_LAST] = { [DSA_TAG_PROTO_NONE] = &none_ops, }; +void dsa_tag_drivers_register(struct dsa_tag_driver *dsa_tag_driver_array[], + unsigned int count, struct module *owner) +{ +} +EXPORT_SYMBOL_GPL(dsa_tag_drivers_register); + +void dsa_tag_drivers_unregister(struct dsa_tag_driver *dsa_tag_driver_array[], + unsigned int count) +{ +} +EXPORT_SYMBOL_GPL(dsa_tag_drivers_unregister); + const char *dsa_tag_protocol_to_str(const struct dsa_device_ops *ops) { return ops->name; -- cgit v1.2.3