diff options
Diffstat (limited to 'drivers/net/wireless/rt2x00/rt2500pci.c')
-rw-r--r-- | drivers/net/wireless/rt2x00/rt2500pci.c | 14 |
1 files changed, 6 insertions, 8 deletions
diff --git a/drivers/net/wireless/rt2x00/rt2500pci.c b/drivers/net/wireless/rt2x00/rt2500pci.c index 4386823f49d1..a9872f95361b 100644 --- a/drivers/net/wireless/rt2x00/rt2500pci.c +++ b/drivers/net/wireless/rt2x00/rt2500pci.c | |||
@@ -424,7 +424,7 @@ static void rt2500pci_config_txpower(struct rt2x00_dev *rt2x00dev, | |||
424 | } | 424 | } |
425 | 425 | ||
426 | static void rt2500pci_config_antenna(struct rt2x00_dev *rt2x00dev, | 426 | static void rt2500pci_config_antenna(struct rt2x00_dev *rt2x00dev, |
427 | const int antenna_tx, const int antenna_rx) | 427 | struct antenna_setup *ant) |
428 | { | 428 | { |
429 | u32 reg; | 429 | u32 reg; |
430 | u8 r14; | 430 | u8 r14; |
@@ -437,7 +437,7 @@ static void rt2500pci_config_antenna(struct rt2x00_dev *rt2x00dev, | |||
437 | /* | 437 | /* |
438 | * Configure the TX antenna. | 438 | * Configure the TX antenna. |
439 | */ | 439 | */ |
440 | switch (antenna_tx) { | 440 | switch (ant->tx) { |
441 | case ANTENNA_SW_DIVERSITY: | 441 | case ANTENNA_SW_DIVERSITY: |
442 | case ANTENNA_HW_DIVERSITY: | 442 | case ANTENNA_HW_DIVERSITY: |
443 | rt2x00_set_field8(&r2, BBP_R2_TX_ANTENNA, 2); | 443 | rt2x00_set_field8(&r2, BBP_R2_TX_ANTENNA, 2); |
@@ -459,7 +459,7 @@ static void rt2500pci_config_antenna(struct rt2x00_dev *rt2x00dev, | |||
459 | /* | 459 | /* |
460 | * Configure the RX antenna. | 460 | * Configure the RX antenna. |
461 | */ | 461 | */ |
462 | switch (antenna_rx) { | 462 | switch (ant->rx) { |
463 | case ANTENNA_SW_DIVERSITY: | 463 | case ANTENNA_SW_DIVERSITY: |
464 | case ANTENNA_HW_DIVERSITY: | 464 | case ANTENNA_HW_DIVERSITY: |
465 | rt2x00_set_field8(&r14, BBP_R14_RX_ANTENNA, 2); | 465 | rt2x00_set_field8(&r14, BBP_R14_RX_ANTENNA, 2); |
@@ -541,9 +541,7 @@ static void rt2500pci_config(struct rt2x00_dev *rt2x00dev, | |||
541 | rt2500pci_config_txpower(rt2x00dev, | 541 | rt2500pci_config_txpower(rt2x00dev, |
542 | libconf->conf->power_level); | 542 | libconf->conf->power_level); |
543 | if (flags & CONFIG_UPDATE_ANTENNA) | 543 | if (flags & CONFIG_UPDATE_ANTENNA) |
544 | rt2500pci_config_antenna(rt2x00dev, | 544 | rt2500pci_config_antenna(rt2x00dev, &libconf->ant); |
545 | libconf->conf->antenna_sel_tx, | ||
546 | libconf->conf->antenna_sel_rx); | ||
547 | if (flags & (CONFIG_UPDATE_SLOT_TIME | CONFIG_UPDATE_BEACON_INT)) | 545 | if (flags & (CONFIG_UPDATE_SLOT_TIME | CONFIG_UPDATE_BEACON_INT)) |
548 | rt2500pci_config_duration(rt2x00dev, libconf); | 546 | rt2500pci_config_duration(rt2x00dev, libconf); |
549 | } | 547 | } |
@@ -1485,9 +1483,9 @@ static int rt2500pci_init_eeprom(struct rt2x00_dev *rt2x00dev) | |||
1485 | /* | 1483 | /* |
1486 | * Identify default antenna configuration. | 1484 | * Identify default antenna configuration. |
1487 | */ | 1485 | */ |
1488 | rt2x00dev->hw->conf.antenna_sel_tx = | 1486 | rt2x00dev->default_ant.tx = |
1489 | rt2x00_get_field16(eeprom, EEPROM_ANTENNA_TX_DEFAULT); | 1487 | rt2x00_get_field16(eeprom, EEPROM_ANTENNA_TX_DEFAULT); |
1490 | rt2x00dev->hw->conf.antenna_sel_rx = | 1488 | rt2x00dev->default_ant.rx = |
1491 | rt2x00_get_field16(eeprom, EEPROM_ANTENNA_RX_DEFAULT); | 1489 | rt2x00_get_field16(eeprom, EEPROM_ANTENNA_RX_DEFAULT); |
1492 | 1490 | ||
1493 | /* | 1491 | /* |