]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
Prepare for improved (read: pcie) suspend/resume support.
authoradrian <adrian@FreeBSD.org>
Fri, 25 May 2012 02:07:59 +0000 (02:07 +0000)
committeradrian <adrian@FreeBSD.org>
Fri, 25 May 2012 02:07:59 +0000 (02:07 +0000)
commitbe5ba4a1c6b29919d741be32fb51b3137e7b545c
tree7feb46b6a04f7501d7da33c80208994f4ab2045e
parenteda9e50c52e3c3311e30b433606b4c3cf6d6126a
Prepare for improved (read: pcie) suspend/resume support.

* Flesh out the pcie disable method for 11n chips, as they were defaulting
  to the AR5212 (empty) PCIe disable method.

* Add accessor macros for the HAL PCIe enable/disable calls.

* Call disable on ath_suspend()

* Call enable on ath_resume()

NOTE:

* This has nothing to do with the NIC sleep/run state - the NIC still
  will stay in network-run state rather than supporting network-sleep
  state.  This is preparation work for supporting correct suspend/resume
  WARs for the 11n PCIe NICs.

TODO:

* It may be feasible at this point to keep the chip powered down during
  initial probe/attach and only power it up upon the first configure/reset
  pass.  This however would require correct (for values of "correct")
  tracking of the NIC power configuration state from the driver and that
  just isn't attempted at the moment.

Tested:

* AR9280 on my Lenovo T60, but with no suspend/resume pass (yet).
sys/dev/ath/ath_hal/ar5416/ar5416_attach.c
sys/dev/ath/ath_hal/ar9002/ar9280_attach.c
sys/dev/ath/ath_hal/ar9002/ar9285_attach.c
sys/dev/ath/ath_hal/ar9002/ar9287_attach.c
sys/dev/ath/if_ath.c
sys/dev/ath/if_athvar.h