net: dsa: add slave notify helper
commit6158eaa7a717b469b1b0c0ae6d79910737686279
authorVivien Didelot <vivien.didelot@savoirfairelinux.com>
Mon, 16 Oct 2017 15:12:14 +0000 (16 11:12 -0400)
committerDavid S. Miller <davem@davemloft.net>
Wed, 18 Oct 2017 11:24:33 +0000 (18 12:24 +0100)
tree4ad56805616e9dd62c3d179da25bda131b7483ed
parenta5b930e0598dc46184af0282c23c75b2167d9384
net: dsa: add slave notify helper

Both DSA slave create and destroy functions call call_dsa_notifiers with
respectively DSA_PORT_REGISTER and DSA_PORT_UNREGISTER and the same
dsa_notifier_register_info structure.

Wrap this in a dsa_slave_notify helper so prevent cluttering these
functions.

Signed-off-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com>
Reviewed-by: Florian Fainelli <f.fainelli@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/dsa/slave.c