aboutsummaryrefslogtreecommitdiff
path: root/sys/dev/axgbe
diff options
context:
space:
mode:
authorAlexander Kabaev <kan@FreeBSD.org>2017-12-25 04:48:39 +0000
committerAlexander Kabaev <kan@FreeBSD.org>2017-12-25 04:48:39 +0000
commit151ba7933aab5c8edc094715bffd9b97d84d2407 (patch)
tree167df86be6de8b19aed984ed6729a169885f0c33 /sys/dev/axgbe
parent280d15cd0af7a89bbb9703ead1a83a3258fa3495 (diff)
Notes
Diffstat (limited to 'sys/dev/axgbe')
-rw-r--r--sys/dev/axgbe/xgbe-drv.c5
-rw-r--r--sys/dev/axgbe/xgbe-mdio.c6
2 files changed, 1 insertions, 10 deletions
diff --git a/sys/dev/axgbe/xgbe-drv.c b/sys/dev/axgbe/xgbe-drv.c
index 32a6cfe239c1..81f8f30b927a 100644
--- a/sys/dev/axgbe/xgbe-drv.c
+++ b/sys/dev/axgbe/xgbe-drv.c
@@ -954,7 +954,7 @@ static int xgbe_rx_poll(struct xgbe_channel *channel, int budget)
struct xgbe_packet_data *packet;
struct ifnet *ifp = pdata->netdev;
struct mbuf *m;
- unsigned int incomplete, context_next, context;
+ unsigned int incomplete, context_next;
unsigned int received = 0;
int packet_count = 0;
@@ -992,9 +992,6 @@ read_again:
context_next = XGMAC_GET_BITS(packet->attributes,
RX_PACKET_ATTRIBUTES,
CONTEXT_NEXT);
- context = XGMAC_GET_BITS(packet->attributes,
- RX_PACKET_ATTRIBUTES,
- CONTEXT);
/* Earlier error, just drain the remaining data */
if (incomplete || context_next) {
diff --git a/sys/dev/axgbe/xgbe-mdio.c b/sys/dev/axgbe/xgbe-mdio.c
index 6967d54da521..850a58e04107 100644
--- a/sys/dev/axgbe/xgbe-mdio.c
+++ b/sys/dev/axgbe/xgbe-mdio.c
@@ -752,36 +752,30 @@ static void xgbe_an_init(struct xgbe_prv_data *pdata)
static void xgbe_phy_adjust_link(struct xgbe_prv_data *pdata)
{
- int new_state = 0;
if (pdata->phy.link) {
/* Flow control support */
pdata->pause_autoneg = pdata->phy.pause_autoneg;
if (pdata->tx_pause != pdata->phy.tx_pause) {
- new_state = 1;
pdata->hw_if.config_tx_flow_control(pdata);
pdata->tx_pause = pdata->phy.tx_pause;
}
if (pdata->rx_pause != pdata->phy.rx_pause) {
- new_state = 1;
pdata->hw_if.config_rx_flow_control(pdata);
pdata->rx_pause = pdata->phy.rx_pause;
}
/* Speed support */
if (pdata->phy_speed != pdata->phy.speed) {
- new_state = 1;
pdata->phy_speed = pdata->phy.speed;
}
if (pdata->phy_link != pdata->phy.link) {
- new_state = 1;
pdata->phy_link = pdata->phy.link;
}
} else if (pdata->phy_link) {
- new_state = 1;
pdata->phy_link = 0;
pdata->phy_speed = SPEED_UNKNOWN;
}