]> git.karo-electronics.de Git - linux-beck.git/commitdiff
Staging: vt6655: use ETH_FRAME_LEN macro instead of custom one
authorCharles Clément <caratorn@gmail.com>
Tue, 18 May 2010 18:30:20 +0000 (11:30 -0700)
committerGreg Kroah-Hartman <gregkh@suse.de>
Tue, 18 May 2010 22:00:02 +0000 (15:00 -0700)
Replace custom maximum packet lenght definition MAX_PACKET_LEN by
ETH_FRAME_LEN from <linux/if_ether.h>.

Signed-off-by: Charles Clément <caratorn@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/staging/vt6655/mib.c
drivers/staging/vt6655/tether.h

index e5f06382e4f868afd84b2818ddffc70190458e7e..4ca7877075b2dd0d7d32fbf8ad52dc7c8ff6a5e0 100644 (file)
@@ -359,9 +359,9 @@ void STAvUpdateRDStatCounter (PSStatCounter pStatistic,
     else if ((512 <= cbFrameLength) && (cbFrameLength <= 1023)) {
         pStatistic->dwRsrRxFrmLen512_1023++;
     }
-    else if ((1024 <= cbFrameLength) && (cbFrameLength <= MAX_PACKET_LEN + 4)) {
+    else if ((1024 <= cbFrameLength) && (cbFrameLength <= ETH_FRAME_LEN + 4)) {
         pStatistic->dwRsrRxFrmLen1024_1518++;
-    } else if (cbFrameLength > MAX_PACKET_LEN + 4) {
+    } else if (cbFrameLength > ETH_FRAME_LEN + 4) {
         pStatistic->dwRsrLong++;
     }
 
index 5ade9b6b51c3d0de253772d6bcf6d48f9d1208e5..3c9acd7903a89178cd09d4a6071521a510e001b0 100644 (file)
 #define MIN_PACKET_LEN      (MIN_DATA_LEN + ETH_HLEN)
                                         // 60
                                         // min total packet length (tx)
-#define MAX_PACKET_LEN      (ETH_DATA_LEN + ETH_HLEN)
-                                        // 1514
-                                        // max total packet length (tx)
 
-#define MAX_LOOKAHEAD_SIZE  MAX_PACKET_LEN
+#define MAX_LOOKAHEAD_SIZE  ETH_FRAME_LEN
 
 #define U_MULTI_ADDR_LEN    8           // multicast address length