Commit 0c603136 authored by Vladimir Oltean's avatar Vladimir Oltean Committed by Jakub Kicinski

net: dsa: move headers exported by switch.c to switch.h

Reduce code bloat in dsa_priv.h by moving the prototypes exported by
switch.h into their own header file.
Signed-off-by: default avatarVladimir Oltean <vladimir.oltean@nxp.com>
Reviewed-by: default avatarFlorian Fainelli <f.fainelli@gmail.com>
Signed-off-by: default avatarJakub Kicinski <kuba@kernel.org>
parent bd954b82
......@@ -22,6 +22,7 @@
#include "master.h"
#include "port.h"
#include "slave.h"
#include "switch.h"
#include "tag.h"
static DEFINE_MUTEX(dsa2_mutex);
......
......@@ -155,10 +155,6 @@ bool dsa_schedule_work(struct work_struct *work);
/* netlink.c */
extern struct rtnl_link_ops dsa_link_ops __read_mostly;
/* switch.c */
int dsa_switch_register_notifier(struct dsa_switch *ds);
void dsa_switch_unregister_notifier(struct dsa_switch *ds);
static inline bool dsa_switch_supports_uc_filtering(struct dsa_switch *ds)
{
return ds->ops->port_fdb_add && ds->ops->port_fdb_del &&
......
......@@ -15,6 +15,7 @@
#include "dsa_priv.h"
#include "port.h"
#include "slave.h"
#include "switch.h"
/**
* dsa_port_notify - Notify the switching fabric of changes to a port
......
......@@ -15,6 +15,7 @@
#include "dsa_priv.h"
#include "port.h"
#include "slave.h"
#include "switch.h"
static unsigned int dsa_switch_fastest_ageing_time(struct dsa_switch *ds,
unsigned int ageing_time)
......
/* SPDX-License-Identifier: GPL-2.0-or-later */
#ifndef __DSA_SWITCH_H
#define __DSA_SWITCH_H
struct dsa_switch;
int dsa_switch_register_notifier(struct dsa_switch *ds);
void dsa_switch_unregister_notifier(struct dsa_switch *ds);
#endif
......@@ -9,6 +9,7 @@
#include "dsa_priv.h"
#include "port.h"
#include "switch.h"
#include "tag.h"
/* Binary structure of the fake 12-bit VID field (when the TPID is
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment