Commit fad09c73 authored by Vivien Didelot's avatar Vivien Didelot Committed by David S. Miller

net: dsa: mv88e6xxx: rename single-chip support

With the upcoming support for cross-chip operations, it will be hard to
distinguish portions of code supporting a single-chip or a switch fabric
of interconnected chips.

Make the code clearer now, by renaming the mv88e6xxx_priv_state chip
structure to mv88e6xxx_chip. This patch brings no functional changes.
Signed-off-by: default avatarVivien Didelot <vivien.didelot@savoirfairelinux.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 0d3cd4b6
obj-$(CONFIG_NET_DSA_MV88E6XXX) += mv88e6xxx.o obj-$(CONFIG_NET_DSA_MV88E6XXX) += chip.o
This source diff could not be displayed because it is too large. You can view the blob instead.
...@@ -563,7 +563,7 @@ struct mv88e6xxx_priv_port { ...@@ -563,7 +563,7 @@ struct mv88e6xxx_priv_port {
struct net_device *bridge_dev; struct net_device *bridge_dev;
}; };
struct mv88e6xxx_priv_state { struct mv88e6xxx_chip {
const struct mv88e6xxx_info *info; const struct mv88e6xxx_info *info;
/* The dsa_switch this private structure is related to */ /* The dsa_switch this private structure is related to */
...@@ -625,10 +625,8 @@ struct mv88e6xxx_priv_state { ...@@ -625,10 +625,8 @@ struct mv88e6xxx_priv_state {
}; };
struct mv88e6xxx_ops { struct mv88e6xxx_ops {
int (*read)(struct mv88e6xxx_priv_state *ps, int (*read)(struct mv88e6xxx_chip *chip, int addr, int reg, u16 *val);
int addr, int reg, u16 *val); int (*write)(struct mv88e6xxx_chip *chip, int addr, int reg, u16 val);
int (*write)(struct mv88e6xxx_priv_state *ps,
int addr, int reg, u16 val);
}; };
enum stat_type { enum stat_type {
...@@ -644,10 +642,10 @@ struct mv88e6xxx_hw_stat { ...@@ -644,10 +642,10 @@ struct mv88e6xxx_hw_stat {
enum stat_type type; enum stat_type type;
}; };
static inline bool mv88e6xxx_has(struct mv88e6xxx_priv_state *ps, static inline bool mv88e6xxx_has(struct mv88e6xxx_chip *chip,
unsigned long flags) unsigned long flags)
{ {
return (ps->info->flags & flags) == flags; return (chip->info->flags & flags) == flags;
} }
#endif #endif
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