Commit 0a122576 authored by shemminger@osdl.org's avatar shemminger@osdl.org Committed by Jeff Garzik

[PATCH] sky2: change netif_rx_schedule_test to __netif_schedule_prep

I didn't like the name netif_rx_schedule_test(), in earlier patches
and changed to __netif_rx_schedule_prep to be more consistent.
Signed-off-by: default avatarStephen Hemminger <shemminger@osdl.org>
Signed-off-by: default avatarJeff Garzik <jgarzik@pobox.com>
parent a018e330
...@@ -1961,11 +1961,12 @@ static irqreturn_t sky2_intr(int irq, void *dev_id, struct pt_regs *regs) ...@@ -1961,11 +1961,12 @@ static irqreturn_t sky2_intr(int irq, void *dev_id, struct pt_regs *regs)
if (status & Y2_IS_STAT_BMU) { if (status & Y2_IS_STAT_BMU) {
hw->intr_mask &= ~Y2_IS_STAT_BMU; hw->intr_mask &= ~Y2_IS_STAT_BMU;
sky2_write32(hw, B0_IMSK, hw->intr_mask); sky2_write32(hw, B0_IMSK, hw->intr_mask);
prefetch(&hw->st_le[hw->st_idx]);
if (netif_rx_schedule_test(dev0)) if (likely(__netif_rx_schedule_prep(dev0))) {
prefetch(&hw->st_le[hw->st_idx]);
__netif_rx_schedule(dev0); __netif_rx_schedule(dev0);
} }
}
if (status & Y2_IS_IRQ_PHY1) if (status & Y2_IS_IRQ_PHY1)
sky2_phy_intr(hw, 0); sky2_phy_intr(hw, 0);
......
...@@ -802,16 +802,16 @@ static inline u32 netif_msg_init(int debug_value, int default_msg_enable_bits) ...@@ -802,16 +802,16 @@ static inline u32 netif_msg_init(int debug_value, int default_msg_enable_bits)
return (1 << debug_value) - 1; return (1 << debug_value) - 1;
} }
/* Schedule rx intr now? */ /* Test if receive needs to be scheduled */
static inline int netif_rx_schedule_test(struct net_device *dev) static inline int __netif_rx_schedule_prep(struct net_device *dev)
{ {
return !test_and_set_bit(__LINK_STATE_RX_SCHED, &dev->state); return !test_and_set_bit(__LINK_STATE_RX_SCHED, &dev->state);
} }
/* Schedule only if device is up */ /* Test if receive needs to be scheduled but only if up */
static inline int netif_rx_schedule_prep(struct net_device *dev) static inline int netif_rx_schedule_prep(struct net_device *dev)
{ {
return netif_running(dev) && netif_rx_schedule_test(dev); return netif_running(dev) && __netif_rx_schedule_prep(dev);
} }
/* Add interface to tail of rx poll list. This assumes that _prep has /* Add interface to tail of rx poll list. This assumes that _prep has
......
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