Convert patches for RT3883 and RT3663 as well as support for external PA on MT7620 to use the changed calling convention for rt2.*_read(...) functions.
Signed-off-by: Daniel Golle <dan...@makrotopia.org> --- ...rt2800lib-add-channel-configuration-function-.patch | 18 +++++++++--------- ...rt2800lib-add-RFCSR-initialization-for-RT3883.patch | 12 ++++++------ ...rt2800mmio-add-a-workaround-for-spurious-TX_F.patch | 2 +- ...-rt2x00-add-support-for-external-PA-on-MT7620.patch | 6 +++--- 4 files changed, 19 insertions(+), 19 deletions(-) diff --git a/package/kernel/mac80211/patches/600-05-rt2x00-rt2800lib-add-channel-configuration-function-.patch b/package/kernel/mac80211/patches/600-05-rt2x00-rt2800lib-add-channel-configuration-function-.patch index 890ae8a1db..1d6e312037 100644 --- a/package/kernel/mac80211/patches/600-05-rt2x00-rt2800lib-add-channel-configuration-function-.patch +++ b/package/kernel/mac80211/patches/600-05-rt2x00-rt2800lib-add-channel-configuration-function-.patch @@ -50,7 +50,7 @@ Signed-off-by: Gabor Juhos <juh...@openwrt.org> + + rt2800_rfcsr_write(rt2x00dev, 13, 0x12); + -+ rt2800_rfcsr_read(rt2x00dev, 1, &rfcsr); ++ rfcsr = rt2800_rfcsr_read(rt2x00dev, 1); + rt2x00_set_field8(&rfcsr, RFCSR1_RX0_PD, 0); + rt2x00_set_field8(&rfcsr, RFCSR1_TX0_PD, 0); + rt2x00_set_field8(&rfcsr, RFCSR1_RX1_PD, 0); @@ -87,7 +87,7 @@ Signed-off-by: Gabor Juhos <juh...@openwrt.org> + + rt2800_freq_cal_mode1(rt2x00dev); + -+ rt2800_rfcsr_read(rt2x00dev, 30, &rfcsr); ++ rfcsr = rt2800_rfcsr_read(rt2x00dev, 30); + if (!conf_is_ht40(conf)) + rfcsr &= ~(0x06); + else @@ -110,7 +110,7 @@ Signed-off-by: Gabor Juhos <juh...@openwrt.org> + rt2800_rfcsr_write(rt2x00dev, 34, 0x20); + + /* loopback RF_BS */ -+ rt2800_rfcsr_read(rt2x00dev, 36, &rfcsr); ++ rfcsr = rt2800_rfcsr_read(rt2x00dev, 36); + if (rf->channel <= 14) + rt2x00_set_field8(&rfcsr, RFCSR36_RF_BS, 1); + else @@ -158,13 +158,13 @@ Signed-off-by: Gabor Juhos <juh...@openwrt.org> + + rt2800_rfcsr_write(rt2x00dev, 50, 0x86); + -+ rt2800_rfcsr_read(rt2x00dev, 51, &rfcsr); ++ rfcsr = rt2800_rfcsr_read(rt2x00dev, 51); + if (rf->channel <= 14) + rt2800_rfcsr_write(rt2x00dev, 51, 0x75); + else + rt2800_rfcsr_write(rt2x00dev, 51, 0x51); + -+ rt2800_rfcsr_read(rt2x00dev, 52, &rfcsr); ++ rfcsr = rt2800_rfcsr_read(rt2x00dev, 52); + if (rf->channel <= 14) + rt2800_rfcsr_write(rt2x00dev, 52, 0x45); + else @@ -194,25 +194,25 @@ Signed-off-by: Gabor Juhos <juh...@openwrt.org> + ((info->default_power2 & 0xe0) >> 1); + rt2800_bbp_write(rt2x00dev, 109, bbp); + -+ rt2800_bbp_read(rt2x00dev, 110, &bbp); ++ bbp = rt2800_bbp_read(rt2x00dev, 110); + bbp &= 0x0f; + bbp |= (info->default_power3 & 0xe0) >> 1; + rt2800_bbp_write(rt2x00dev, 110, bbp); + -+ rt2800_rfcsr_read(rt2x00dev, 57, &rfcsr); ++ rfcsr = rt2800_rfcsr_read(rt2x00dev, 57); + if (rf->channel <= 14) + rt2800_rfcsr_write(rt2x00dev, 57, 0x6e); + else + rt2800_rfcsr_write(rt2x00dev, 57, 0x3e); + + /* Enable RF tuning */ -+ rt2800_rfcsr_read(rt2x00dev, 3, &rfcsr); ++ rfcsr = rt2800_rfcsr_read(rt2x00dev, 3); + rt2x00_set_field8(&rfcsr, RFCSR3_VCOCAL_EN, 1); + rt2800_rfcsr_write(rt2x00dev, 3, rfcsr); + + udelay(2000); + -+ rt2800_bbp_read(rt2x00dev, 49, &bbp); ++ bbp = rt2800_bbp_read(rt2x00dev, 49); + /* clear update flag */ + rt2800_bbp_write(rt2x00dev, 49, bbp & 0xfe); + rt2800_bbp_write(rt2x00dev, 49, bbp); diff --git a/package/kernel/mac80211/patches/600-10-rt2x00-rt2800lib-add-RFCSR-initialization-for-RT3883.patch b/package/kernel/mac80211/patches/600-10-rt2x00-rt2800lib-add-RFCSR-initialization-for-RT3883.patch index a4967c6474..a542c35327 100644 --- a/package/kernel/mac80211/patches/600-10-rt2x00-rt2800lib-add-RFCSR-initialization-for-RT3883.patch +++ b/package/kernel/mac80211/patches/600-10-rt2x00-rt2800lib-add-RFCSR-initialization-for-RT3883.patch @@ -134,7 +134,7 @@ Signed-off-by: Gabor Juhos <juh...@openwrt.org> + rt2800_rfcsr_write(rt2x00dev, 33, 0x32); + } + -+ rt2800_rfcsr_read(rt2x00dev, 2, &rfcsr); ++ rfcsr = rt2800_rfcsr_read(rt2x00dev, 2); + rt2x00_set_field8(&rfcsr, RFCSR2_RESCAL_BP, 0); + rt2x00_set_field8(&rfcsr, RFCSR2_RESCAL_EN, 1); + rt2800_rfcsr_write(rt2x00dev, 2, rfcsr); @@ -142,23 +142,23 @@ Signed-off-by: Gabor Juhos <juh...@openwrt.org> + rt2x00_set_field8(&rfcsr, RFCSR2_RESCAL_EN, 0); + rt2800_rfcsr_write(rt2x00dev, 2, rfcsr); + -+ rt2800_rfcsr_read(rt2x00dev, 1, &rfcsr); ++ rfcsr = rt2800_rfcsr_read(rt2x00dev, 1); + rt2x00_set_field8(&rfcsr, RFCSR1_RF_BLOCK_EN, 1); + rt2800_rfcsr_write(rt2x00dev, 1, rfcsr); + -+ rt2800_rfcsr_read(rt2x00dev, 6, &rfcsr); ++ rfcsr = rt2800_rfcsr_read(rt2x00dev, 6); + rfcsr |= 0xc0; + rt2800_rfcsr_write(rt2x00dev, 6, rfcsr); + -+ rt2800_rfcsr_read(rt2x00dev, 22, &rfcsr); ++ rfcsr = rt2800_rfcsr_read(rt2x00dev, 22); + rfcsr |= 0x20; + rt2800_rfcsr_write(rt2x00dev, 22, rfcsr); + -+ rt2800_rfcsr_read(rt2x00dev, 46, &rfcsr); ++ rfcsr = rt2800_rfcsr_read(rt2x00dev, 46); + rfcsr |= 0x20; + rt2800_rfcsr_write(rt2x00dev, 46, rfcsr); + -+ rt2800_rfcsr_read(rt2x00dev, 20, &rfcsr); ++ rfcsr = rt2800_rfcsr_read(rt2x00dev, 20); + rfcsr &= ~0xee; + rt2800_rfcsr_write(rt2x00dev, 20, rfcsr); +} diff --git a/package/kernel/mac80211/patches/600-23-rt2x00-rt2800mmio-add-a-workaround-for-spurious-TX_F.patch b/package/kernel/mac80211/patches/600-23-rt2x00-rt2800mmio-add-a-workaround-for-spurious-TX_F.patch index 46fc2f0375..b864549735 100644 --- a/package/kernel/mac80211/patches/600-23-rt2x00-rt2800mmio-add-a-workaround-for-spurious-TX_F.patch +++ b/package/kernel/mac80211/patches/600-23-rt2x00-rt2800mmio-add-a-workaround-for-spurious-TX_F.patch @@ -96,7 +96,7 @@ Signed-off-by: Gabor Juhos <juh...@openwrt.org> + * here to see if we have to process the actual + * request. + */ -+ rt2x00mmio_register_read(rt2x00dev, TX_STA_FIFO, &txstatus); ++ txstatus = rt2x00mmio_register_read(rt2x00dev, TX_STA_FIFO); + if (rt2800mmio_txstatus_is_spurious(rt2x00dev, txstatus)) { + /* Remove the TX_FIFO_STATUS bit so it won't be + * processed in this turn. The hardware will diff --git a/package/kernel/mac80211/patches/650-rt2x00-add-support-for-external-PA-on-MT7620.patch b/package/kernel/mac80211/patches/650-rt2x00-add-support-for-external-PA-on-MT7620.patch index 0d227cd711..c1fed6369f 100644 --- a/package/kernel/mac80211/patches/650-rt2x00-add-support-for-external-PA-on-MT7620.patch +++ b/package/kernel/mac80211/patches/650-rt2x00-add-support-for-external-PA-on-MT7620.patch @@ -34,11 +34,11 @@ Signed-off-by: Daniel Golle <dan...@makrotopia.org> + &rt2x00dev->cap_flags)) { + rt2x00_warn(rt2x00dev, "Using incomplete support for " \ + "external PA\n"); -+ rt2800_register_read(rt2x00dev, RF_CONTROL3, ®); ++ reg = rt2800_register_read(rt2x00dev, RF_CONTROL3); + reg |= 0x00000101; + rt2800_register_write(rt2x00dev, RF_CONTROL3, reg); + -+ rt2800_register_read(rt2x00dev, RF_BYPASS3, ®); ++ reg = rt2800_register_read(rt2x00dev, RF_BYPASS3); + reg |= 0x00000101; + rt2800_register_write(rt2x00dev, RF_BYPASS3, reg); + @@ -101,7 +101,7 @@ Signed-off-by: Daniel Golle <dan...@makrotopia.org> &rt2x00dev->cap_flags); } -+ rt2800_eeprom_read(rt2x00dev, EEPROM_NIC_CONF2, &eeprom); ++ eeprom = rt2800_eeprom_read(rt2x00dev, EEPROM_NIC_CONF2); + + if (rt2x00_rt(rt2x00dev, RT6352) && eeprom != 0 && eeprom != 0xffff) { + if (rt2x00_get_field16(eeprom, -- 2.14.1 _______________________________________________ Lede-dev mailing list Lede-dev@lists.infradead.org http://lists.infradead.org/mailman/listinfo/lede-dev