Search Linux Wireless

[Bug report] Probably variable is being overwritten

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,

A bit in rfb0r1 is being cleared and result is stored in rfval. Then the
first bit is being set without reusing the rfval. It is probably bug or
dead code? The same pattern can be seen repeated below as well.


diff --git a/drivers/net/wireless/ralink/rt2x00/rt2800lib.c
b/drivers/net/wireless/ralink/rt2x00/rt2800lib.c
index cbbb1a4849cf..4857e3818418 100644
--- a/drivers/net/wireless/ralink/rt2x00/rt2800lib.c
+++ b/drivers/net/wireless/ralink/rt2x00/rt2800lib.c
@@ -8844,7 +8844,7 @@ static void rt2800_rxiq_calibration(struct
rt2x00_dev *rt2x00dev)
        for (ch_idx = 0; ch_idx < 2; ch_idx = ch_idx + 1) {
                if (ch_idx == 0) {
                        rfval = rfb0r1 & (~0x3);
-                       rfval = rfb0r1 | 0x1;
+                       rfval = rfval | 0x1;
                        rt2800_rfcsr_write_bank(rt2x00dev, 0, 1, rfval);
                        rfval = rfb0r2 & (~0x33);
                        rfval = rfb0r2 | 0x11;


-- 
Muhammad Usama Anjum



[Index of Archives]     [Linux Host AP]     [ATH6KL]     [Linux Wireless Personal Area Network]     [Linux Bluetooth]     [Wireless Regulations]     [Linux Netdev]     [Kernel Newbies]     [Linux Kernel]     [IDE]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite Hiking]     [MIPS Linux]     [ARM Linux]     [Linux RAID]

  Powered by Linux