Commit ea72ab22 authored by Michael Buesch's avatar Michael Buesch Committed by John W. Linville

[PATCH] bcm43xx: sync with svn.berlios.de

Signed-off-by: default avatarMichael Buesch <mbuesch@freenet.de>
Signed-off-by: default avatarJohn W. Linville <linville@tuxdriver.com>
parent 70e5e983
This diff is collapsed.
...@@ -122,7 +122,6 @@ struct bcm43xx_dmadesc_meta { ...@@ -122,7 +122,6 @@ struct bcm43xx_dmadesc_meta {
}; };
struct bcm43xx_dmaring { struct bcm43xx_dmaring {
spinlock_t lock;
struct bcm43xx_private *bcm; struct bcm43xx_private *bcm;
/* Kernel virtual base address of the ring memory. */ /* Kernel virtual base address of the ring memory. */
struct bcm43xx_dmadesc *vbase; struct bcm43xx_dmadesc *vbase;
...@@ -166,11 +165,11 @@ int bcm43xx_dmacontroller_rx_reset(struct bcm43xx_private *bcm, ...@@ -166,11 +165,11 @@ int bcm43xx_dmacontroller_rx_reset(struct bcm43xx_private *bcm,
int bcm43xx_dmacontroller_tx_reset(struct bcm43xx_private *bcm, int bcm43xx_dmacontroller_tx_reset(struct bcm43xx_private *bcm,
u16 dmacontroller_mmio_base); u16 dmacontroller_mmio_base);
int FASTCALL(bcm43xx_dma_transfer_txb(struct bcm43xx_private *bcm, void bcm43xx_dma_handle_xmitstatus(struct bcm43xx_private *bcm,
struct ieee80211_txb *txb)); struct bcm43xx_xmitstatus *status);
void FASTCALL(bcm43xx_dma_handle_xmitstatus(struct bcm43xx_private *bcm,
struct bcm43xx_xmitstatus *status));
void FASTCALL(bcm43xx_dma_rx(struct bcm43xx_dmaring *ring)); int bcm43xx_dma_tx(struct bcm43xx_private *bcm,
struct ieee80211_txb *txb);
void bcm43xx_dma_rx(struct bcm43xx_dmaring *ring);
#endif /* BCM43xx_DMA_H_ */ #endif /* BCM43xx_DMA_H_ */
...@@ -4097,7 +4097,6 @@ int fastcall bcm43xx_rx(struct bcm43xx_private *bcm, ...@@ -4097,7 +4097,6 @@ int fastcall bcm43xx_rx(struct bcm43xx_private *bcm,
} }
frame_ctl = le16_to_cpu(wlhdr->frame_ctl); frame_ctl = le16_to_cpu(wlhdr->frame_ctl);
if ((frame_ctl & IEEE80211_FCTL_PROTECTED) && !bcm->ieee->host_decrypt) { if ((frame_ctl & IEEE80211_FCTL_PROTECTED) && !bcm->ieee->host_decrypt) {
frame_ctl &= ~IEEE80211_FCTL_PROTECTED; frame_ctl &= ~IEEE80211_FCTL_PROTECTED;
wlhdr->frame_ctl = cpu_to_le16(frame_ctl); wlhdr->frame_ctl = cpu_to_le16(frame_ctl);
...@@ -4113,12 +4112,12 @@ int fastcall bcm43xx_rx(struct bcm43xx_private *bcm, ...@@ -4113,12 +4112,12 @@ int fastcall bcm43xx_rx(struct bcm43xx_private *bcm,
skb_trim(skb, skb->len - 4); skb_trim(skb, skb->len - 4);
stats.len -= 8; stats.len -= 8;
} }
/* do _not_ use wlhdr again without reassigning it */ wlhdr = (struct ieee80211_hdr_4addr *)(skb->data);
} }
switch (WLAN_FC_GET_TYPE(frame_ctl)) { switch (WLAN_FC_GET_TYPE(frame_ctl)) {
case IEEE80211_FTYPE_MGMT: case IEEE80211_FTYPE_MGMT:
ieee80211_rx_mgt(bcm->ieee, skb->data, &stats); ieee80211_rx_mgt(bcm->ieee, wlhdr, &stats);
break; break;
case IEEE80211_FTYPE_DATA: case IEEE80211_FTYPE_DATA:
if (is_packet_for_us) if (is_packet_for_us)
...@@ -4143,7 +4142,7 @@ static inline int bcm43xx_tx(struct bcm43xx_private *bcm, ...@@ -4143,7 +4142,7 @@ static inline int bcm43xx_tx(struct bcm43xx_private *bcm,
if (bcm->pio_mode) if (bcm->pio_mode)
err = bcm43xx_pio_transfer_txb(bcm, txb); err = bcm43xx_pio_transfer_txb(bcm, txb);
else else
err = bcm43xx_dma_transfer_txb(bcm, txb); err = bcm43xx_dma_tx(bcm, txb);
return err; return err;
} }
......
...@@ -1161,7 +1161,7 @@ void bcm43xx_phy_lo_b_measure(struct bcm43xx_private *bcm) ...@@ -1161,7 +1161,7 @@ void bcm43xx_phy_lo_b_measure(struct bcm43xx_private *bcm)
phy->minlowsigpos[1] += 0x0101; phy->minlowsigpos[1] += 0x0101;
bcm43xx_phy_write(bcm, 0x002F, phy->minlowsigpos[1]); bcm43xx_phy_write(bcm, 0x002F, phy->minlowsigpos[1]);
if (radio->version == 2053) { if (radio->version == 0x2053) {
bcm43xx_phy_write(bcm, 0x000A, regstack[2]); bcm43xx_phy_write(bcm, 0x000A, regstack[2]);
bcm43xx_phy_write(bcm, 0x002A, regstack[3]); bcm43xx_phy_write(bcm, 0x002A, regstack[3]);
bcm43xx_phy_write(bcm, 0x0035, regstack[4]); bcm43xx_phy_write(bcm, 0x0035, regstack[4]);
......
...@@ -467,8 +467,8 @@ static void bcm43xx_calc_nrssi_offset(struct bcm43xx_private *bcm) ...@@ -467,8 +467,8 @@ static void bcm43xx_calc_nrssi_offset(struct bcm43xx_private *bcm)
bcm43xx_phy_write(bcm, 0x0003, bcm43xx_phy_write(bcm, 0x0003,
(bcm43xx_phy_read(bcm, 0x0003) & 0xFF9F) (bcm43xx_phy_read(bcm, 0x0003) & 0xFF9F)
| 0x0040); | 0x0040);
bcm43xx_phy_write(bcm, 0x007A, bcm43xx_radio_write16(bcm, 0x007A,
bcm43xx_phy_read(bcm, 0x007A) | 0x000F); bcm43xx_radio_read16(bcm, 0x007A) | 0x000F);
bcm43xx_set_all_gains(bcm, 3, 0, 1); bcm43xx_set_all_gains(bcm, 3, 0, 1);
bcm43xx_radio_write16(bcm, 0x0043, bcm43xx_radio_write16(bcm, 0x0043,
(bcm43xx_radio_read16(bcm, 0x0043) (bcm43xx_radio_read16(bcm, 0x0043)
...@@ -761,8 +761,8 @@ void bcm43xx_calc_nrssi_slope(struct bcm43xx_private *bcm) ...@@ -761,8 +761,8 @@ void bcm43xx_calc_nrssi_slope(struct bcm43xx_private *bcm)
bcm43xx_phy_write(bcm, 0x0802, bcm43xx_phy_write(bcm, 0x0802,
bcm43xx_phy_read(bcm, 0x0802) | (0x0001 | 0x0002)); bcm43xx_phy_read(bcm, 0x0802) | (0x0001 | 0x0002));
bcm43xx_set_original_gains(bcm); bcm43xx_set_original_gains(bcm);
bcm43xx_phy_write(bcm, 0x0802, bcm43xx_phy_write(bcm, BCM43xx_PHY_G_CRS,
bcm43xx_phy_read(bcm, 0x0802) | 0x8000); bcm43xx_phy_read(bcm, BCM43xx_PHY_G_CRS) | 0x8000);
if (phy->rev >= 3) { if (phy->rev >= 3) {
bcm43xx_phy_write(bcm, 0x0801, backup[14]); bcm43xx_phy_write(bcm, 0x0801, backup[14]);
bcm43xx_phy_write(bcm, 0x0060, backup[15]); bcm43xx_phy_write(bcm, 0x0060, backup[15]);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment