diff options
author | Inaky Perez-Gonzalez <inaky@linux.intel.com> | 2009-05-02 02:50:03 -0700 |
---|---|---|
committer | Inaky Perez-Gonzalez <inaky@linux.intel.com> | 2009-05-28 18:01:58 -0700 |
commit | 052991d7ac7f7b2c0319e6ccd2e8a48a71f2bd58 (patch) | |
tree | 07706156ef906951c2f602aadfa7793c4409aa0b /drivers/net/wimax/i2400m/control.c | |
parent | 8ac1101f8cd58a62517ba86745bc000d3a21f09b (diff) | |
download | op-kernel-dev-052991d7ac7f7b2c0319e6ccd2e8a48a71f2bd58.zip op-kernel-dev-052991d7ac7f7b2c0319e6ccd2e8a48a71f2bd58.tar.gz |
wimax/i2400m: remove redundant readiness checks from i2400m_report_tlv_*()
Functions i2400m_report_tlv*() are only called from
i2400m_report_hook(), called in a workqueue by
i2400m_report_hook_work(). The scheduler checks for device readiness
before scheduling.
Added an extra check for readiness in i2400m_report_hook_work(), which
makes all the checks down the line redundant.
Obviously the device state could change in the middle, but error
handling would take care of that.
Signed-off-by: Inaky Perez-Gonzalez <inaky@linux.intel.com>
Diffstat (limited to 'drivers/net/wimax/i2400m/control.c')
-rw-r--r-- | drivers/net/wimax/i2400m/control.c | 6 |
1 files changed, 0 insertions, 6 deletions
diff --git a/drivers/net/wimax/i2400m/control.c b/drivers/net/wimax/i2400m/control.c index b42e347..bd193ae 100644 --- a/drivers/net/wimax/i2400m/control.c +++ b/drivers/net/wimax/i2400m/control.c @@ -292,8 +292,6 @@ void i2400m_report_tlv_system_state(struct i2400m *i2400m, d_fnstart(3, dev, "(i2400m %p ss %p [%u])\n", i2400m, ss, i2400m_state); - if (unlikely(i2400m->ready == 0)) /* act if up */ - goto out; if (i2400m->state != i2400m_state) { i2400m->state = i2400m_state; wake_up_all(&i2400m->state_wq); @@ -341,7 +339,6 @@ void i2400m_report_tlv_system_state(struct i2400m *i2400m, i2400m->bus_reset(i2400m, I2400M_RT_WARM); break; }; -out: d_fnend(3, dev, "(i2400m %p ss %p [%u]) = void\n", i2400m, ss, i2400m_state); } @@ -372,8 +369,6 @@ void i2400m_report_tlv_media_status(struct i2400m *i2400m, d_fnstart(3, dev, "(i2400m %p ms %p [%u])\n", i2400m, ms, status); - if (unlikely(i2400m->ready == 0)) /* act if up */ - goto out; switch (status) { case I2400M_MEDIA_STATUS_LINK_UP: netif_carrier_on(net_dev); @@ -393,7 +388,6 @@ void i2400m_report_tlv_media_status(struct i2400m *i2400m, dev_err(dev, "HW BUG? unknown media status %u\n", status); }; -out: d_fnend(3, dev, "(i2400m %p ms %p [%u]) = void\n", i2400m, ms, status); } |