staging: rtl8188eu: Use round_up() instead of _RND128()
authornavin patidar <navin.patidar@gmail.com>
Sun, 22 Jun 2014 08:51:39 +0000 (14:21 +0530)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 27 Jun 2014 00:27:15 +0000 (20:27 -0400)
Signed-off-by: navin patidar <navin.patidar@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/rtl8188eu/include/osdep_service.h
drivers/staging/rtl8188eu/os_dep/usb_ops_linux.c

index 1bf324c4c5a24a5bbefce77f0e018ae34cf1db3c..22025704d1fc0ce3b88f385dec55a1b2fb258f5a 100644 (file)
@@ -197,14 +197,6 @@ static inline u32 _RND8(u32 sz)
        return val;
 }
 
-static inline u32 _RND128(u32 sz)
-{
-       u32     val;
-
-       val = ((sz >> 7) + ((sz & 127) ? 1 : 0)) << 7;
-       return val;
-}
-
 struct rtw_netdev_priv_indicator {
        void *priv;
        u32 sizeof_priv;
index 8015c3a2f92c711d116d13a544e8c02f827b88a4..eddff419f4fd79fb5658da34109d3f4943d95084 100644 (file)
@@ -160,7 +160,7 @@ static int recvbuf2recvframe(struct adapter *adapt, struct sk_buff *pskb)
                switch (haldata->UsbRxAggMode) {
                case USB_RX_AGG_DMA:
                case USB_RX_AGG_MIX:
-                       pkt_offset = (u16)_RND128(pkt_offset);
+                       pkt_offset = (u16) round_up(pkt_offset, 128);
                        break;
                case USB_RX_AGG_USB:
                        pkt_offset = (u16)_RND4(pkt_offset);