]> git.kernelconcepts.de Git - karo-tx-linux.git/blobdiff - drivers/net/wireless/intel/iwlwifi/iwl-devtrace.h
Merge tag 'for-linus-20170812' of git://git.infradead.org/linux-mtd
[karo-tx-linux.git] / drivers / net / wireless / intel / iwlwifi / iwl-devtrace.h
index 545d14b0bc92fbca03b786f537b523e6ab453600..f5c1127253cb13fcccde047ba2d210b9f41fb556 100644 (file)
@@ -55,8 +55,8 @@ static inline bool iwl_trace_data(struct sk_buff *skb)
        /* also account for the RFC 1042 header, of course */
        offs += 6;
 
-       return skb->len > offs + 2 &&
-              *(__be16 *)(skb->data + offs) == cpu_to_be16(ETH_P_PAE);
+       return skb->len <= offs + 2 ||
+               *(__be16 *)(skb->data + offs) != cpu_to_be16(ETH_P_PAE);
 }
 
 static inline size_t iwl_rx_trace_len(const struct iwl_trans *trans,