ath6kl: Print bad trailer data only when htc fails to parse trailer info
authorRaja Mani <rmani@qca.qualcomm.com>
Tue, 19 Jul 2011 13:57:30 +0000 (19:27 +0530)
committerKalle Valo <kvalo@qca.qualcomm.com>
Tue, 9 Aug 2011 16:45:21 +0000 (19:45 +0300)
Signed-off-by: Raja Mani <rmani@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
drivers/net/wireless/ath/ath6kl/htc.c

index 836797947805ca6572d54e85065435f5da6fb467..9d9948ed18df5c87109b6ad1dc3cc5a8c6fac981 100644 (file)
@@ -1400,8 +1400,9 @@ static int htc_proc_trailer(struct htc_target *target,
                len -= record->len;
        }
 
-       ath6kl_dbg_dump(ATH6KL_DBG_RAW_BYTES, "BAD Recv Trailer",
-                    orig_buf, orig_len);
+       if (status)
+               ath6kl_dbg_dump(ATH6KL_DBG_RAW_BYTES, "BAD Recv Trailer",
+                               orig_buf, orig_len);
 
        return status;
 }