Wen Gong <wgong@xxxxxxxxxxxxxxxx> writes: >> -----Original Message----- >> From: ath10k <ath10k-bounces@xxxxxxxxxxxxxxxxxxx> On Behalf Of Kalle Valo >> Sent: Tuesday, April 30, 2019 5:37 PM >> To: Nicolas Boichat <drinkcat@xxxxxxxxxxxx> >> Cc: Claire Chang <tientzu@xxxxxxxxxxxx>; linux-wireless@xxxxxxxxxxxxxxx; >> ath10k@xxxxxxxxxxxxxxxxxxx; Wen Gong <wgong@xxxxxxxxxxxxxx> >> Subject: [EXT] Re: [PATCH] ath10k: add peer id check in >> ath10k_peer_find_by_id >> >> --- a/drivers/net/wireless/ath/ath10k/txrx.c >> >> +++ b/drivers/net/wireless/ath/ath10k/txrx.c >> >> @@ -157,6 +157,9 @@ struct ath10k_peer >> *ath10k_peer_find_by_id(struct ath10k *ar, int peer_id) >> >> { >> >> struct ath10k_peer *peer; >> >> >> >> + if (peer_id >= sizeof(peer->peer_ids) * BITS_PER_BYTE) >> > >> > I'd use >= BITS_PER_TYPE(peer->peer_ids). >> >> Nice, I didn't know about that. Wen, please submit v2 using this. >> >> -- >> Kalle Valo > Yes, > I have send v2 yesterday: > [PATCH v2] ath10k: add peer id check in ath10k_peer_find_by_id Ok, I didn't notice that yet. But in general it's good practise to reply to review comments and let the reviewer (and others) know if you agree with the comment or not. For example, in this case you could have said to Nicolas: "Ok, I'll send v2". -- Kalle Valo