mirror of
https://github.com/FEX-Emu/linux.git
synced 2024-12-20 08:22:39 +00:00
b43: Really disable QoS, if requested
Currently, when QoS-disable is requested, we would leave QoS enabled in firmware, but only queue frames on one queue. Change that and also tell firmware about disabled QoS, so it completely ignores all the QoS parameters. Also don't upload the parameters, if QoS is disabled. Signed-off-by: Michael Buesch <mb@bu3sch.de> Signed-off-by: John W. Linville <linville@tuxdriver.com>
This commit is contained in:
parent
4789666e13
commit
b0544eb601
@ -3093,7 +3093,6 @@ static int b43_op_tx(struct ieee80211_hw *hw,
|
|||||||
return NETDEV_TX_OK;
|
return NETDEV_TX_OK;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Locking: wl->irq_lock */
|
|
||||||
static void b43_qos_params_upload(struct b43_wldev *dev,
|
static void b43_qos_params_upload(struct b43_wldev *dev,
|
||||||
const struct ieee80211_tx_queue_params *p,
|
const struct ieee80211_tx_queue_params *p,
|
||||||
u16 shm_offset)
|
u16 shm_offset)
|
||||||
@ -3102,6 +3101,9 @@ static void b43_qos_params_upload(struct b43_wldev *dev,
|
|||||||
int bslots, tmp;
|
int bslots, tmp;
|
||||||
unsigned int i;
|
unsigned int i;
|
||||||
|
|
||||||
|
if (!dev->qos_enabled)
|
||||||
|
return;
|
||||||
|
|
||||||
bslots = b43_read16(dev, B43_MMIO_RNG) & p->cw_min;
|
bslots = b43_read16(dev, B43_MMIO_RNG) & p->cw_min;
|
||||||
|
|
||||||
memset(¶ms, 0, sizeof(params));
|
memset(¶ms, 0, sizeof(params));
|
||||||
@ -3147,6 +3149,9 @@ static void b43_qos_upload_all(struct b43_wldev *dev)
|
|||||||
struct b43_qos_params *params;
|
struct b43_qos_params *params;
|
||||||
unsigned int i;
|
unsigned int i;
|
||||||
|
|
||||||
|
if (!dev->qos_enabled)
|
||||||
|
return;
|
||||||
|
|
||||||
BUILD_BUG_ON(ARRAY_SIZE(b43_qos_shm_offsets) !=
|
BUILD_BUG_ON(ARRAY_SIZE(b43_qos_shm_offsets) !=
|
||||||
ARRAY_SIZE(wl->qos_params));
|
ARRAY_SIZE(wl->qos_params));
|
||||||
|
|
||||||
@ -3206,6 +3211,16 @@ static void b43_qos_clear(struct b43_wl *wl)
|
|||||||
/* Initialize the core's QOS capabilities */
|
/* Initialize the core's QOS capabilities */
|
||||||
static void b43_qos_init(struct b43_wldev *dev)
|
static void b43_qos_init(struct b43_wldev *dev)
|
||||||
{
|
{
|
||||||
|
if (!dev->qos_enabled) {
|
||||||
|
/* Disable QOS support. */
|
||||||
|
b43_hf_write(dev, b43_hf_read(dev) & ~B43_HF_EDCF);
|
||||||
|
b43_write16(dev, B43_MMIO_IFSCTL,
|
||||||
|
b43_read16(dev, B43_MMIO_IFSCTL)
|
||||||
|
& ~B43_MMIO_IFSCTL_USE_EDCF);
|
||||||
|
b43dbg(dev->wl, "QoS disabled\n");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
/* Upload the current QOS parameters. */
|
/* Upload the current QOS parameters. */
|
||||||
b43_qos_upload_all(dev);
|
b43_qos_upload_all(dev);
|
||||||
|
|
||||||
@ -3214,6 +3229,7 @@ static void b43_qos_init(struct b43_wldev *dev)
|
|||||||
b43_write16(dev, B43_MMIO_IFSCTL,
|
b43_write16(dev, B43_MMIO_IFSCTL,
|
||||||
b43_read16(dev, B43_MMIO_IFSCTL)
|
b43_read16(dev, B43_MMIO_IFSCTL)
|
||||||
| B43_MMIO_IFSCTL_USE_EDCF);
|
| B43_MMIO_IFSCTL_USE_EDCF);
|
||||||
|
b43dbg(dev->wl, "QoS enabled\n");
|
||||||
}
|
}
|
||||||
|
|
||||||
static int b43_op_conf_tx(struct ieee80211_hw *hw, u16 _queue,
|
static int b43_op_conf_tx(struct ieee80211_hw *hw, u16 _queue,
|
||||||
|
Loading…
Reference in New Issue
Block a user