summaryrefslogtreecommitdiffstats
path: root/drivers/net/dsa/bcm_sf2.h
diff options
context:
space:
mode:
authorFlorian Fainelli <f.fainelli@gmail.com>2014-09-19 02:31:25 +0200
committerDavid S. Miller <davem@davemloft.net>2014-09-22 20:41:23 +0200
commit96e65d7f3f88d6e117ff80f3003d13c65e85cb03 (patch)
treed1103c98dd7273538de10bea5c0e259816e8c409 /drivers/net/dsa/bcm_sf2.h
parentnet: dsa: add {get, set}_wol callbacks to slave devices (diff)
downloadlinux-96e65d7f3f88d6e117ff80f3003d13c65e85cb03.tar.xz
linux-96e65d7f3f88d6e117ff80f3003d13c65e85cb03.zip
net: dsa: bcm_sf2: add support for Wake-on-LAN
In order for Wake-on-LAN to work properly, we query the parent network device Wake-on-LAN features and advertise those. Similarly, when configuring Wake-on-LAN on a per-port network interface, we make sure that we do not accept something the master network devices does not support. Finally, we need to maintain a bitmask of the ports enabled for Wake-on-LAN to prevent the suspend() callback from disabling a port that is used for waking up the system. Signed-off-by: Florian Fainelli <f.fainelli@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/dsa/bcm_sf2.h')
-rw-r--r--drivers/net/dsa/bcm_sf2.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/net/dsa/bcm_sf2.h b/drivers/net/dsa/bcm_sf2.h
index d3bd52dc40d2..8fd6c1451a84 100644
--- a/drivers/net/dsa/bcm_sf2.h
+++ b/drivers/net/dsa/bcm_sf2.h
@@ -70,6 +70,9 @@ struct bcm_sf2_priv {
struct bcm_sf2_hw_params hw_params;
struct bcm_sf2_port_status port_sts[DSA_MAX_PORTS];
+
+ /* Mask of ports enabled for Wake-on-LAN */
+ u32 wol_ports_mask;
};
struct bcm_sf2_hw_stats {