Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 393934c6 authored by John W. Linville's avatar John W. Linville
Browse files
Conflicts:
	drivers/net/wireless/ath/ath9k/ath9k.h
	drivers/net/wireless/ath/ath9k/main.c
	drivers/net/wireless/ath/ath9k/xmit.c
parents 69f4aab1 0a54917c
Loading
Loading
Loading
Loading
+8 −5
Original line number Original line Diff line number Diff line
@@ -1879,7 +1879,8 @@ ath5k_beacon_send(struct ath5k_softc *sc)
		sc->bmisscount = 0;
		sc->bmisscount = 0;
	}
	}


	if (sc->opmode == NL80211_IFTYPE_AP && sc->num_ap_vifs > 1) {
	if ((sc->opmode == NL80211_IFTYPE_AP && sc->num_ap_vifs > 1) ||
			sc->opmode == NL80211_IFTYPE_MESH_POINT) {
		u64 tsf = ath5k_hw_get_tsf64(ah);
		u64 tsf = ath5k_hw_get_tsf64(ah);
		u32 tsftu = TSF_TO_TU(tsf);
		u32 tsftu = TSF_TO_TU(tsf);
		int slot = ((tsftu % sc->bintval) * ATH_BCBUF) / sc->bintval;
		int slot = ((tsftu % sc->bintval) * ATH_BCBUF) / sc->bintval;
@@ -1911,8 +1912,9 @@ ath5k_beacon_send(struct ath5k_softc *sc)
		/* NB: hw still stops DMA, so proceed */
		/* NB: hw still stops DMA, so proceed */
	}
	}


	/* refresh the beacon for AP mode */
	/* refresh the beacon for AP or MESH mode */
	if (sc->opmode == NL80211_IFTYPE_AP)
	if (sc->opmode == NL80211_IFTYPE_AP ||
			sc->opmode == NL80211_IFTYPE_MESH_POINT)
		ath5k_beacon_update(sc->hw, vif);
		ath5k_beacon_update(sc->hw, vif);


	ath5k_hw_set_txdp(ah, sc->bhalq, bf->daddr);
	ath5k_hw_set_txdp(ah, sc->bhalq, bf->daddr);
@@ -2997,7 +2999,8 @@ static int ath5k_add_interface(struct ieee80211_hw *hw,


	/* Assign the vap/adhoc to a beacon xmit slot. */
	/* Assign the vap/adhoc to a beacon xmit slot. */
	if ((avf->opmode == NL80211_IFTYPE_AP) ||
	if ((avf->opmode == NL80211_IFTYPE_AP) ||
	    (avf->opmode == NL80211_IFTYPE_ADHOC)) {
	    (avf->opmode == NL80211_IFTYPE_ADHOC) ||
	    (avf->opmode == NL80211_IFTYPE_MESH_POINT)) {
		int slot;
		int slot;


		WARN_ON(list_empty(&sc->bcbuf));
		WARN_ON(list_empty(&sc->bcbuf));
@@ -3016,7 +3019,7 @@ static int ath5k_add_interface(struct ieee80211_hw *hw,
		sc->bslot[avf->bslot] = vif;
		sc->bslot[avf->bslot] = vif;
		if (avf->opmode == NL80211_IFTYPE_AP)
		if (avf->opmode == NL80211_IFTYPE_AP)
			sc->num_ap_vifs++;
			sc->num_ap_vifs++;
		else
		else if (avf->opmode == NL80211_IFTYPE_ADHOC)
			sc->num_adhoc_vifs++;
			sc->num_adhoc_vifs++;
	}
	}


+1 −1
Original line number Original line Diff line number Diff line
@@ -311,7 +311,7 @@ void ath_rx_cleanup(struct ath_softc *sc);
int ath_rx_tasklet(struct ath_softc *sc, int flush, bool hp);
int ath_rx_tasklet(struct ath_softc *sc, int flush, bool hp);
struct ath_txq *ath_txq_setup(struct ath_softc *sc, int qtype, int subtype);
struct ath_txq *ath_txq_setup(struct ath_softc *sc, int qtype, int subtype);
void ath_tx_cleanupq(struct ath_softc *sc, struct ath_txq *txq);
void ath_tx_cleanupq(struct ath_softc *sc, struct ath_txq *txq);
void ath_drain_all_txq(struct ath_softc *sc, bool retry_tx);
bool ath_drain_all_txq(struct ath_softc *sc, bool retry_tx);
void ath_draintxq(struct ath_softc *sc,
void ath_draintxq(struct ath_softc *sc,
		     struct ath_txq *txq, bool retry_tx);
		     struct ath_txq *txq, bool retry_tx);
void ath_tx_node_init(struct ath_softc *sc, struct ath_node *an);
void ath_tx_node_init(struct ath_softc *sc, struct ath_node *an);
+8 −4
Original line number Original line Diff line number Diff line
@@ -1063,15 +1063,19 @@ static void ath9k_hw_set_def_power_per_rate_table(struct ath_hw *ah,
	case 1:
	case 1:
		break;
		break;
	case 2:
	case 2:
		if (scaledPower > REDUCE_SCALED_POWER_BY_TWO_CHAIN)
			scaledPower -= REDUCE_SCALED_POWER_BY_TWO_CHAIN;
			scaledPower -= REDUCE_SCALED_POWER_BY_TWO_CHAIN;
		else
			scaledPower = 0;
		break;
		break;
	case 3:
	case 3:
		if (scaledPower > REDUCE_SCALED_POWER_BY_THREE_CHAIN)
			scaledPower -= REDUCE_SCALED_POWER_BY_THREE_CHAIN;
			scaledPower -= REDUCE_SCALED_POWER_BY_THREE_CHAIN;
		else
			scaledPower = 0;
		break;
		break;
	}
	}


	scaledPower = max((u16)0, scaledPower);

	if (IS_CHAN_2GHZ(chan)) {
	if (IS_CHAN_2GHZ(chan)) {
		numCtlModes = ARRAY_SIZE(ctlModesFor11g) -
		numCtlModes = ARRAY_SIZE(ctlModesFor11g) -
			SUB_NUM_CTL_MODES_AT_2G_40;
			SUB_NUM_CTL_MODES_AT_2G_40;
+7 −0
Original line number Original line Diff line number Diff line
@@ -1015,6 +1015,13 @@ static int ath9k_hif_usb_suspend(struct usb_interface *interface,
{
{
	struct hif_device_usb *hif_dev = usb_get_intfdata(interface);
	struct hif_device_usb *hif_dev = usb_get_intfdata(interface);


	/*
	 * The device has to be set to FULLSLEEP mode in case no
	 * interface is up.
	 */
	if (!(hif_dev->flags & HIF_USB_START))
		ath9k_htc_suspend(hif_dev->htc_handle);

	ath9k_hif_usb_dealloc_urbs(hif_dev);
	ath9k_hif_usb_dealloc_urbs(hif_dev);


	return 0;
	return 0;
+3 −0
Original line number Original line Diff line number Diff line
@@ -455,6 +455,8 @@ u32 ath9k_htc_calcrxfilter(struct ath9k_htc_priv *priv);
void ath9k_htc_ps_wakeup(struct ath9k_htc_priv *priv);
void ath9k_htc_ps_wakeup(struct ath9k_htc_priv *priv);
void ath9k_htc_ps_restore(struct ath9k_htc_priv *priv);
void ath9k_htc_ps_restore(struct ath9k_htc_priv *priv);
void ath9k_ps_work(struct work_struct *work);
void ath9k_ps_work(struct work_struct *work);
bool ath9k_htc_setpower(struct ath9k_htc_priv *priv,
			enum ath9k_power_mode mode);


void ath9k_start_rfkill_poll(struct ath9k_htc_priv *priv);
void ath9k_start_rfkill_poll(struct ath9k_htc_priv *priv);
void ath9k_init_leds(struct ath9k_htc_priv *priv);
void ath9k_init_leds(struct ath9k_htc_priv *priv);
@@ -464,6 +466,7 @@ int ath9k_htc_probe_device(struct htc_target *htc_handle, struct device *dev,
			   u16 devid, char *product, u32 drv_info);
			   u16 devid, char *product, u32 drv_info);
void ath9k_htc_disconnect_device(struct htc_target *htc_handle, bool hotunplug);
void ath9k_htc_disconnect_device(struct htc_target *htc_handle, bool hotunplug);
#ifdef CONFIG_PM
#ifdef CONFIG_PM
void ath9k_htc_suspend(struct htc_target *htc_handle);
int ath9k_htc_resume(struct htc_target *htc_handle);
int ath9k_htc_resume(struct htc_target *htc_handle);
#endif
#endif
#ifdef CONFIG_ATH9K_HTC_DEBUGFS
#ifdef CONFIG_ATH9K_HTC_DEBUGFS
Loading