1. 27 11月, 2012 15 次提交
  2. 17 11月, 2012 1 次提交
    • J
      drivers/net/wireless/ti/wlcore/main.c: eliminate possible double power off · 4fb4e0be
      Julia Lawall 提交于
      The function wl12xx_set_power_on is only called twice, once in
      wl12xx_chip_wakeup and once in wl12xx_get_hw_info.  On the failure of the
      call in wl12xx_chip_wakeup, the containing function just returns, but on
      the failure of the call in wl12xx_get_hw_info, the containing function
      calls wl1271_power_off.  This does not seem necessary, because if
      wl12xx_set_power_on has set the power on and then fails, it has already
      turned the power off.
      
      A simplified version of the semantic match that finds this problem is as
      follows: (http://coccinelle.lip6.fr/)
      
      // <smpl>
      @r@
      identifier f,free,a;
      parameter list[n] ps;
      type T;
      expression e;
      @@
      
      f(ps,T a,...) {
        ... when any
            when != a = e
        if(...) { ... free(a); ... return ...; }
        ... when any
      }
      
      @@
      identifier r.f,r.free;
      expression x,a;
      expression list[r.n] xs;
      @@
      
      * x = f(xs,a,...);
        if (...) { ... free(a); ... return ...; }
      // </smpl>
      Signed-off-by: NJulia Lawall <Julia.Lawall@lip6.fr>
      Signed-off-by: NLuciano Coelho <luca@coelho.fi>
      4fb4e0be
  3. 27 9月, 2012 16 次提交
  4. 31 7月, 2012 2 次提交
  5. 18 7月, 2012 3 次提交
  6. 11 7月, 2012 3 次提交
    • A
      wlcore: define number of supported bands internally · 091185d6
      Arik Nemtsov 提交于
      Avoid using the IEEE80211_NUM_BANDS constant for arrays sizes etc, as
      this can contain bands unsupported by the driver (e.g. 60Ghz). Use an
      internal constant to determine the number of bands.
      Signed-off-by: NArik Nemtsov <arik@wizery.com>
      091185d6
    • I
      wlcore: Prevent processing of work items during op_stop · c24ec83b
      Ido Yariv 提交于
      The interrupt line is disabled in op_stop using disable_irq. Since
      pending interrupts are synchronized, the mutex has to be released before
      disabling the interrupt to avoid a deadlock with the interrupt handler.
      
      In addition, the internal state of the driver is only set to 'off'
      after the interrupt is disabled. Otherwise, if an interrupt fires after
      the state is set but before the interrupt line is disabled, the
      interrupt handler will not be able to acknowledge the interrupt
      resulting in an interrupt storm.
      
      The driver's operations might be called during recovery. If these
      acquire the mutex after it was released by op_stop, but before the
      driver's state is changed, they may queue new work items instead of just
      failing. This is especially problematic in the case of scans, in which a
      new scan may be scheduled after all scan requests were cancelled.
      Signed-off-by: NIdo Yariv <ido@wizery.com>
      Signed-off-by: NArik Nemtsov <arik@wizery.com>
      c24ec83b
    • E
      wlcore: implement .flush callback · d8ae5a25
      Eliad Peller 提交于
      implement the .flush() callback by simply calling wl1271_tx_flush().
      Signed-off-by: NEliad Peller <eliad@wizery.com>
      Signed-off-by: NLuciano Coelho <coelho@ti.com>
      d8ae5a25