OSDN Git Service

rtl8723au: Fix smatch errors/warnings for hal/HalDMOutSrc8192C_CE.c
authorLarry Finger <Larry.Finger@lwfinger.net>
Wed, 11 Sep 2013 23:50:13 +0000 (18:50 -0500)
committerLarry Finger <Larry.Finger@lwfinger.net>
Wed, 11 Sep 2013 23:50:13 +0000 (18:50 -0500)
commit1fc63599564690b323e83d64b6ffa98f07780fb1
treec866f5536dde23ef9d58627b8ef883fcd97cbfab
parent1fea5f3002c89a7db2cb781017435f0c4ff89d79
rtl8723au: Fix smatch errors/warnings for hal/HalDMOutSrc8192C_CE.c

Smatch shows the following:
  CHECK   /home/finger/rtl8723au/hal/HalDMOutSrc8192C_CE.c
/home/finger/rtl8723au/hal/HalDMOutSrc8192C_CE.c:313 odm_TXPowerTrackingCallback_ThermalMeter_92C() error: buffer overflow 'TxPwrLevel' 2 <= 2
/home/finger/rtl8723au/hal/HalDMOutSrc8192C_CE.c:313 odm_TXPowerTrackingCallback_ThermalMeter_92C() error: buffer overflow 'TxPwrLevel' 2 <= 2
/home/finger/rtl8723au/hal/HalDMOutSrc8192C_CE.c:327 odm_TXPowerTrackingCallback_ThermalMeter_92C() error: buffer overflow 'TxPwrLevel' 2 <= 2
/home/finger/rtl8723au/hal/HalDMOutSrc8192C_CE.c:327 odm_TXPowerTrackingCallback_ThermalMeter_92C() error: buffer overflow 'TxPwrLevel' 2 <= 2
/home/finger/rtl8723au/hal/HalDMOutSrc8192C_CE.c:334 odm_TXPowerTrackingCallback_ThermalMeter_92C() error: buffer overflow 'TxPwrLevel' 2 <= 2
/home/finger/rtl8723au/hal/HalDMOutSrc8192C_CE.c:334 odm_TXPowerTrackingCallback_ThermalMeter_92C() error: buffer overflow 'TxPwrLevel' 2 <= 2
/home/finger/rtl8723au/hal/HalDMOutSrc8192C_CE.c:2014 rtl8192c_PHY_APCalibrate() info: ignoring unreachable code.
/home/finger/rtl8723au/hal/HalDMOutSrc8192C_CE.c:2014 rtl8192c_PHY_APCalibrate() info: ignoring unreachable code.

The buffer overflow errors are due to an off-by-one error.

Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
hal/HalDMOutSrc8192C_CE.c
include/rtw_mp.h