From a9a6073c51ddc4f562b1918ded7e27830e0d9d9f Mon Sep 17 00:00:00 2001 From: Brett Rudley Date: Fri, 8 Oct 2010 17:35:02 -0700 Subject: [PATCH] staging: brcm80211: Purge unused packet engine We're not using the packet engine anymore - goodbye. Signed-off-by: Brett Rudley Signed-off-by: Greg Kroah-Hartman --- drivers/staging/brcm80211/include/wlioctl.h | 10 ---- drivers/staging/brcm80211/phy/wlc_phy_cmn.c | 2 +- drivers/staging/brcm80211/phy/wlc_phy_int.h | 1 - drivers/staging/brcm80211/phy/wlc_phy_lcn.c | 9 --- drivers/staging/brcm80211/sys/wlc_mac80211.c | 60 -------------------- drivers/staging/brcm80211/sys/wlc_mac80211.h | 2 - drivers/staging/brcm80211/sys/wlc_phy_shim.c | 7 --- drivers/staging/brcm80211/sys/wlc_phy_shim.h | 3 - 8 files changed, 1 insertion(+), 93 deletions(-) diff --git a/drivers/staging/brcm80211/include/wlioctl.h b/drivers/staging/brcm80211/include/wlioctl.h index 22227c1a7fb0..0b81807c2f98 100644 --- a/drivers/staging/brcm80211/include/wlioctl.h +++ b/drivers/staging/brcm80211/include/wlioctl.h @@ -1973,16 +1973,6 @@ typedef struct wl_pkt_filter_stats { u32 num_pkts_discarded; /* # packets discarded by dongle for all filters */ } wl_pkt_filter_stats_t; -typedef struct wl_pkteng { - u32 flags; - u32 delay; /* Inter-packet delay */ - u32 nframes; /* Number of frames */ - u32 length; /* Packet length */ - u8 seqno; /* Enable/disable sequence no. */ - struct ether_addr dest; /* Destination address */ - struct ether_addr src; /* Source address */ -} wl_pkteng_t; - #define WLC_RSSI_INVALID 0 /* invalid RSSI value */ /* require default structure packing */ diff --git a/drivers/staging/brcm80211/phy/wlc_phy_cmn.c b/drivers/staging/brcm80211/phy/wlc_phy_cmn.c index a778111d5422..63cc51c8546a 100644 --- a/drivers/staging/brcm80211/phy/wlc_phy_cmn.c +++ b/drivers/staging/brcm80211/phy/wlc_phy_cmn.c @@ -2990,7 +2990,7 @@ void wlc_phy_watchdog(wlc_phy_t *pih) (SCAN_RM_IN_PROGRESS(pi) || PLT_INPROG_PHY(pi) || ASSOC_INPROG_PHY(pi) || pi->carrier_suppr_disable - || pi->pkteng_in_progress || pi->disable_percal)) + || pi->disable_percal)) wlc_lcnphy_calib_modes(pi, PHY_PERICAL_WATCHDOG); } diff --git a/drivers/staging/brcm80211/phy/wlc_phy_int.h b/drivers/staging/brcm80211/phy/wlc_phy_int.h index 944a44f57a33..551bbff0f334 100644 --- a/drivers/staging/brcm80211/phy/wlc_phy_int.h +++ b/drivers/staging/brcm80211/phy/wlc_phy_int.h @@ -776,7 +776,6 @@ struct phy_info { uint phycal_mlo; uint phycal_txpower; - bool pkteng_in_progress; u8 phy_aa2g; bool nphy_tableloaded; diff --git a/drivers/staging/brcm80211/phy/wlc_phy_lcn.c b/drivers/staging/brcm80211/phy/wlc_phy_lcn.c index 10aa247da78b..cdf0f0a53564 100644 --- a/drivers/staging/brcm80211/phy/wlc_phy_lcn.c +++ b/drivers/staging/brcm80211/phy/wlc_phy_lcn.c @@ -1000,9 +1000,6 @@ static bool wlc_lcnphy_calc_rx_iq_comp(phy_info_t *pi, u16 num_samps); static u16 wlc_lcnphy_get_pa_gain(phy_info_t *pi); static void wlc_lcnphy_afe_clk_init(phy_info_t *pi, u8 mode); extern void wlc_lcnphy_tx_pwr_ctrl_init(wlc_phy_t *ppi); -extern void wlc_lcnphy_pktengtx(wlc_phy_t *ppi, wl_pkteng_t *pkteng, - u8 rate, struct ether_addr *sa, - u32 wait_delay); static void wlc_lcnphy_radio_2064_channel_tune_4313(phy_info_t *pi, u8 channel); @@ -3669,12 +3666,6 @@ static void wlc_lcnphy_set_chanspec_tweaks(phy_info_t *pi, chanspec_t chanspec) write_phy_reg(pi, 0x44a, 0x80); } -void -wlc_lcnphy_pktengtx(wlc_phy_t *ppi, wl_pkteng_t *pkteng, u8 rate, - struct ether_addr *sa, u32 wait_delay) -{ -} - void wlc_lcnphy_tx_power_adjustment(wlc_phy_t *ppi) { s8 index; diff --git a/drivers/staging/brcm80211/sys/wlc_mac80211.c b/drivers/staging/brcm80211/sys/wlc_mac80211.c index ae6a2fd4aad0..7bdd60efa544 100644 --- a/drivers/staging/brcm80211/sys/wlc_mac80211.c +++ b/drivers/staging/brcm80211/sys/wlc_mac80211.c @@ -8347,66 +8347,6 @@ wlc_duty_cycle_set(wlc_info_t *wlc, int duty_cycle, bool isOFDM, return BCME_OK; } -void -wlc_pktengtx(wlc_info_t *wlc, wl_pkteng_t *pkteng, u8 rate, - struct ether_addr *sa, u32 wait_delay) -{ - bool suspend; - u16 val = M_PKTENG_MODE_TX; - volatile u16 frame_cnt_check; - u8 counter = 0; - - wlc_bmac_set_deaf(wlc->hw, TRUE); - - suspend = - (0 == (R_REG(wlc->hw->osh, &wlc->regs->maccontrol) & MCTL_EN_MAC)); - if (suspend) - wlc_enable_mac(wlc); - - /* set nframes */ - if (pkteng->nframes) { - /* retry counter is used to replay the packet */ - wlc_bmac_write_shm(wlc->hw, M_PKTENG_FRMCNT_LO, - (pkteng->nframes & 0xffff)); - wlc_bmac_write_shm(wlc->hw, M_PKTENG_FRMCNT_HI, - ((pkteng->nframes >> 16) & 0xffff)); - val |= M_PKTENG_FRMCNT_VLD; - } - - if (pkteng->length) { - /* DATA frame */ - wlc_bmac_write_shm(wlc->hw, M_PKTENG_CTRL, val); - /* we write to M_MFGTEST_IFS the IFS required in 1/8us factor */ - /* 10 : for factoring difference b/w Tx.crs and energy in air */ - /* 44 : amount of time spent after TX_RRSP to frame start */ - /* IFS */ - wlc_bmac_write_shm(wlc->hw, M_PKTENG_IFS, - (pkteng->delay - 10) * 8 - 44); - } else { - /* CTS frame */ - val |= M_PKTENG_MODE_TX_CTS; - wlc_bmac_write_shm(wlc->hw, M_PKTENG_IFS, - (u16) pkteng->delay); - wlc_bmac_write_shm(wlc->hw, M_PKTENG_CTRL, val); - } - - /* Wait for packets to finish */ - frame_cnt_check = wlc_bmac_read_shm(wlc->hw, M_PKTENG_FRMCNT_LO); - while ((counter < 100) && (frame_cnt_check != 0)) { - OSL_DELAY(100); - frame_cnt_check = - wlc_bmac_read_shm(wlc->hw, M_PKTENG_FRMCNT_LO); - counter++; - } - - wlc_bmac_write_shm(wlc->hw, M_PKTENG_CTRL, 0); - - if (suspend) - wlc_suspend_mac_and_wait(wlc); - - wlc_bmac_set_deaf(wlc->hw, FALSE); -} - /* Read a single u16 from shared memory. * SHM 'offset' needs to be an even address */ diff --git a/drivers/staging/brcm80211/sys/wlc_mac80211.h b/drivers/staging/brcm80211/sys/wlc_mac80211.h index 8a726be9893d..1fb055e6444f 100644 --- a/drivers/staging/brcm80211/sys/wlc_mac80211.h +++ b/drivers/staging/brcm80211/sys/wlc_mac80211.h @@ -902,8 +902,6 @@ extern void wlc_reset_bmac_done(wlc_info_t *wlc); extern void wlc_protection_upd(wlc_info_t *wlc, uint idx, int val); extern void wlc_hwtimer_gptimer_set(wlc_info_t *wlc, uint us); extern void wlc_hwtimer_gptimer_abort(wlc_info_t *wlc); -extern void wlc_pktengtx(wlc_info_t *wlc, wl_pkteng_t *pkteng, u8 rate, - struct ether_addr *sa, u32 wait_delay); #if defined(BCMDBG) extern void wlc_print_rxh(d11rxhdr_t *rxh); diff --git a/drivers/staging/brcm80211/sys/wlc_phy_shim.c b/drivers/staging/brcm80211/sys/wlc_phy_shim.c index 9e8f19635f80..7c8193a3e6a4 100644 --- a/drivers/staging/brcm80211/sys/wlc_phy_shim.c +++ b/drivers/staging/brcm80211/sys/wlc_phy_shim.c @@ -244,10 +244,3 @@ wlapi_copyto_objmem(wlc_phy_shim_info_t *physhim, uint offset, const void *buf, { wlc_bmac_copyto_objmem(physhim->wlc_hw, offset, buf, l, sel); } - -void -wlapi_bmac_pktengtx(wlc_phy_shim_info_t *physhim, wl_pkteng_t *pkteng, - u8 rate, struct ether_addr *sa, u32 wait_delay) -{ - wlc_pktengtx(physhim->wlc, pkteng, rate, sa, wait_delay); -} diff --git a/drivers/staging/brcm80211/sys/wlc_phy_shim.h b/drivers/staging/brcm80211/sys/wlc_phy_shim.h index c5d911984605..c151a5d8c693 100644 --- a/drivers/staging/brcm80211/sys/wlc_phy_shim.h +++ b/drivers/staging/brcm80211/sys/wlc_phy_shim.h @@ -108,8 +108,5 @@ extern void wlapi_copyto_objmem(wlc_phy_shim_info_t *physhim, uint, extern void wlapi_high_update_phy_mode(wlc_phy_shim_info_t *physhim, u32 phy_mode); -extern void wlapi_bmac_pktengtx(wlc_phy_shim_info_t *physhim, - wl_pkteng_t *pkteng, u8 rate, - struct ether_addr *sa, u32 wait_delay); extern u16 wlapi_bmac_get_txant(wlc_phy_shim_info_t *physhim); #endif /* _wlc_phy_shim_h_ */