| .. | .. |
|---|
| 281 | 281 | struct ath9k_htc_rx { |
|---|
| 282 | 282 | struct list_head rxbuf; |
|---|
| 283 | 283 | spinlock_t rxbuflock; |
|---|
| 284 | + bool initialized; |
|---|
| 284 | 285 | }; |
|---|
| 285 | 286 | |
|---|
| 286 | 287 | #define ATH9K_HTC_TX_CLEANUP_INTERVAL 50 /* ms */ |
|---|
| .. | .. |
|---|
| 305 | 306 | DECLARE_BITMAP(tx_slot, MAX_TX_BUF_NUM); |
|---|
| 306 | 307 | struct timer_list cleanup_timer; |
|---|
| 307 | 308 | spinlock_t tx_lock; |
|---|
| 309 | + bool initialized; |
|---|
| 308 | 310 | }; |
|---|
| 309 | 311 | |
|---|
| 310 | 312 | struct ath9k_htc_tx_ctl { |
|---|
| .. | .. |
|---|
| 325 | 327 | } |
|---|
| 326 | 328 | |
|---|
| 327 | 329 | #ifdef CONFIG_ATH9K_HTC_DEBUGFS |
|---|
| 328 | | - |
|---|
| 329 | | -#define TX_STAT_INC(c) (hif_dev->htc_handle->drv_priv->debug.tx_stats.c++) |
|---|
| 330 | | -#define TX_STAT_ADD(c, a) (hif_dev->htc_handle->drv_priv->debug.tx_stats.c += a) |
|---|
| 331 | | -#define RX_STAT_INC(c) (hif_dev->htc_handle->drv_priv->debug.skbrx_stats.c++) |
|---|
| 332 | | -#define RX_STAT_ADD(c, a) (hif_dev->htc_handle->drv_priv->debug.skbrx_stats.c += a) |
|---|
| 330 | +#define __STAT_SAFE(expr) (hif_dev->htc_handle->drv_priv ? (expr) : 0) |
|---|
| 331 | +#define TX_STAT_INC(c) __STAT_SAFE(hif_dev->htc_handle->drv_priv->debug.tx_stats.c++) |
|---|
| 332 | +#define TX_STAT_ADD(c, a) __STAT_SAFE(hif_dev->htc_handle->drv_priv->debug.tx_stats.c += a) |
|---|
| 333 | +#define RX_STAT_INC(c) __STAT_SAFE(hif_dev->htc_handle->drv_priv->debug.skbrx_stats.c++) |
|---|
| 334 | +#define RX_STAT_ADD(c, a) __STAT_SAFE(hif_dev->htc_handle->drv_priv->debug.skbrx_stats.c += a) |
|---|
| 333 | 335 | #define CAB_STAT_INC priv->debug.tx_stats.cab_queued++ |
|---|
| 334 | 336 | |
|---|
| 335 | 337 | #define TX_QSTAT_INC(q) (priv->debug.tx_stats.queue_stats[q]++) |
|---|
| .. | .. |
|---|
| 583 | 585 | void ath9k_htc_tx_clear_slot(struct ath9k_htc_priv *priv, int slot); |
|---|
| 584 | 586 | void ath9k_htc_tx_drain(struct ath9k_htc_priv *priv); |
|---|
| 585 | 587 | void ath9k_htc_txstatus(struct ath9k_htc_priv *priv, void *wmi_event); |
|---|
| 586 | | -void ath9k_tx_failed_tasklet(unsigned long data); |
|---|
| 588 | +void ath9k_tx_failed_tasklet(struct tasklet_struct *t); |
|---|
| 587 | 589 | void ath9k_htc_tx_cleanup_timer(struct timer_list *t); |
|---|
| 588 | 590 | bool ath9k_htc_csa_is_finished(struct ath9k_htc_priv *priv); |
|---|
| 589 | 591 | |
|---|
| 590 | 592 | int ath9k_rx_init(struct ath9k_htc_priv *priv); |
|---|
| 591 | 593 | void ath9k_rx_cleanup(struct ath9k_htc_priv *priv); |
|---|
| 592 | 594 | void ath9k_host_rx_init(struct ath9k_htc_priv *priv); |
|---|
| 593 | | -void ath9k_rx_tasklet(unsigned long data); |
|---|
| 595 | +void ath9k_rx_tasklet(struct tasklet_struct *t); |
|---|
| 594 | 596 | u32 ath9k_htc_calcrxfilter(struct ath9k_htc_priv *priv); |
|---|
| 595 | 597 | |
|---|
| 596 | 598 | void ath9k_htc_ps_wakeup(struct ath9k_htc_priv *priv); |
|---|