ath10k: don't remove peer that doesn't exist
authorMichal Kazior <michal.kazior@tieto.com>
Wed, 5 Aug 2015 10:15:23 +0000 (12:15 +0200)
committerKalle Valo <kvalo@qca.qualcomm.com>
Thu, 13 Aug 2015 11:29:55 +0000 (14:29 +0300)
commitadaeed74bc085bc59991cd6e23ee7f720b6c6aab
treefaf14de9790d895ced76b3d185bb03b1f22e0ef0
parent6f7429c29b9979d64d067543caec940bbc023340
ath10k: don't remove peer that doesn't exist

If peer creation failed during offchannel Tx the
driver attempted to delete the peer nonetheless.
This caused the ar->num_peers counter to be
incorrectly decremented. This subsequently could
cause the counter to drop below 0 and also
eventually lead to firmware crash because host
would think there are less peer entries created in
firmware then there really were.

Signed-off-by: Michal Kazior <michal.kazior@tieto.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
drivers/net/wireless/ath/ath10k/mac.c