aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/b43/main.c
diff options
context:
space:
mode:
authorRafał Miłecki <zajec5@gmail.com>2011-09-21 15:44:13 -0400
committerJohn W. Linville <linville@tuxdriver.com>2011-09-27 14:34:01 -0400
commit7955d87f5ce94bb19554892b5dee963f276fd265 (patch)
treef38b4dfa9f79948769e0525f8c4d98a579d082bd /drivers/net/wireless/b43/main.c
parentb4c3f34afffcab01b6eb5155399a0b85b1123ada (diff)
b43: add missing MMIO defines
Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/b43/main.c')
-rw-r--r--drivers/net/wireless/b43/main.c38
1 files changed, 21 insertions, 17 deletions
diff --git a/drivers/net/wireless/b43/main.c b/drivers/net/wireless/b43/main.c
index 559bcd6688ec..fa27c3d97d8b 100644
--- a/drivers/net/wireless/b43/main.c
+++ b/drivers/net/wireless/b43/main.c
@@ -729,52 +729,56 @@ void b43_dummy_transmission(struct b43_wldev *dev, bool ofdm, bool pa_on)
729 for (i = 0; i < 5; i++) 729 for (i = 0; i < 5; i++)
730 b43_ram_write(dev, i * 4, buffer[i]); 730 b43_ram_write(dev, i * 4, buffer[i]);
731 731
732 b43_write16(dev, 0x0568, 0x0000); 732 b43_write16(dev, B43_MMIO_XMTSEL, 0x0000);
733
733 if (dev->dev->core_rev < 11) 734 if (dev->dev->core_rev < 11)
734 b43_write16(dev, 0x07C0, 0x0000); 735 b43_write16(dev, B43_MMIO_WEPCTL, 0x0000);
735 else 736 else
736 b43_write16(dev, 0x07C0, 0x0100); 737 b43_write16(dev, B43_MMIO_WEPCTL, 0x0100);
738
737 value = (ofdm ? 0x41 : 0x40); 739 value = (ofdm ? 0x41 : 0x40);
738 b43_write16(dev, 0x050C, value); 740 b43_write16(dev, B43_MMIO_TXE0_PHYCTL, value);
739 if ((phy->type == B43_PHYTYPE_N) || (phy->type == B43_PHYTYPE_LP)) 741 if ((phy->type == B43_PHYTYPE_N) || (phy->type == B43_PHYTYPE_LP))
740 b43_write16(dev, 0x0514, 0x1A02); 742 b43_write16(dev, B43_MMIO_TXE0_PHYCTL1, 0x1A02);
741 b43_write16(dev, 0x0508, 0x0000); 743
742 b43_write16(dev, 0x050A, 0x0000); 744 b43_write16(dev, B43_MMIO_TXE0_WM_0, 0x0000);
743 b43_write16(dev, 0x054C, 0x0000); 745 b43_write16(dev, B43_MMIO_TXE0_WM_1, 0x0000);
744 b43_write16(dev, 0x056A, 0x0014); 746
745 b43_write16(dev, 0x0568, 0x0826); 747 b43_write16(dev, B43_MMIO_XMTTPLATETXPTR, 0x0000);
746 b43_write16(dev, 0x0500, 0x0000); 748 b43_write16(dev, B43_MMIO_XMTTXCNT, 0x0014);
749 b43_write16(dev, B43_MMIO_XMTSEL, 0x0826);
750 b43_write16(dev, B43_MMIO_TXE0_CTL, 0x0000);
747 if (!pa_on && (phy->type == B43_PHYTYPE_N)) { 751 if (!pa_on && (phy->type == B43_PHYTYPE_N)) {
748 //SPEC TODO 752 //SPEC TODO
749 } 753 }
750 754
751 switch (phy->type) { 755 switch (phy->type) {
752 case B43_PHYTYPE_N: 756 case B43_PHYTYPE_N:
753 b43_write16(dev, 0x0502, 0x00D0); 757 b43_write16(dev, B43_MMIO_TXE0_AUX, 0x00D0);
754 break; 758 break;
755 case B43_PHYTYPE_LP: 759 case B43_PHYTYPE_LP:
756 b43_write16(dev, 0x0502, 0x0050); 760 b43_write16(dev, B43_MMIO_TXE0_AUX, 0x0050);
757 break; 761 break;
758 default: 762 default:
759 b43_write16(dev, 0x0502, 0x0030); 763 b43_write16(dev, B43_MMIO_TXE0_AUX, 0x0030);
760 } 764 }
761 765
762 if (phy->radio_ver == 0x2050 && phy->radio_rev <= 0x5) 766 if (phy->radio_ver == 0x2050 && phy->radio_rev <= 0x5)
763 b43_radio_write16(dev, 0x0051, 0x0017); 767 b43_radio_write16(dev, 0x0051, 0x0017);
764 for (i = 0x00; i < max_loop; i++) { 768 for (i = 0x00; i < max_loop; i++) {
765 value = b43_read16(dev, 0x050E); 769 value = b43_read16(dev, B43_MMIO_TXE0_STATUS);
766 if (value & 0x0080) 770 if (value & 0x0080)
767 break; 771 break;
768 udelay(10); 772 udelay(10);
769 } 773 }
770 for (i = 0x00; i < 0x0A; i++) { 774 for (i = 0x00; i < 0x0A; i++) {
771 value = b43_read16(dev, 0x050E); 775 value = b43_read16(dev, B43_MMIO_TXE0_STATUS);
772 if (value & 0x0400) 776 if (value & 0x0400)
773 break; 777 break;
774 udelay(10); 778 udelay(10);
775 } 779 }
776 for (i = 0x00; i < 0x19; i++) { 780 for (i = 0x00; i < 0x19; i++) {
777 value = b43_read16(dev, 0x0690); 781 value = b43_read16(dev, B43_MMIO_IFSSTAT);
778 if (!(value & 0x0100)) 782 if (!(value & 0x0100))
779 break; 783 break;
780 udelay(10); 784 udelay(10);