hc
2024-01-05 071106ecf68c401173c58808b1cf5f68cc50d390
kernel/drivers/net/wireless/ath/carl9170/rx.c
....@@ -427,7 +427,7 @@
427427 if (head->plcp[6] & 0x80)
428428 status->enc_flags |= RX_ENC_FLAG_SHORT_GI;
429429
430
- status->rate_idx = clamp(0, 75, head->plcp[3] & 0x7f);
430
+ status->rate_idx = clamp(head->plcp[3] & 0x7f, 0, 75);
431431 status->encoding = RX_ENC_HT;
432432 break;
433433
....@@ -766,6 +766,7 @@
766766
767767 goto drop;
768768 }
769
+ fallthrough;
769770
770771 case AR9170_RX_STATUS_MPDU_MIDDLE:
771772 /* These are just data + mac status */
....@@ -794,7 +795,7 @@
794795 break;
795796
796797 default:
797
- BUG_ON(1);
798
+ BUG();
798799 break;
799800 }
800801