These changes are the raw update to linux-4.4.6-rt14. Kernel sources
[kvmfornfv.git] / kernel / drivers / staging / rtl8188eu / hal / mac_cfg.c
index febc83a..0bc1b21 100644 (file)
@@ -123,10 +123,10 @@ bool rtl88eu_phy_mac_config(struct adapter *adapt)
        u32 arraylength;
        u32 *ptrarray;
 
-       arraylength = sizeof(array_MAC_REG_8188E)/sizeof(u32);
+       arraylength = ARRAY_SIZE(array_MAC_REG_8188E);
        ptrarray = array_MAC_REG_8188E;
 
-       for (i = 0; i < arraylength; i = i + 2)
+       for (i = 0; i < arraylength; i += 2)
                usb_write8(adapt, ptrarray[i], (u8)ptrarray[i + 1]);
 
        usb_write8(adapt, REG_MAX_AGGR_NUM, MAX_AGGR_NUM);