From 4fe2b16a935c66090583006412077740d9be9dbc Mon Sep 17 00:00:00 2001 From: Stanislaw Gruszka Date: Tue, 7 Aug 2018 10:43:09 +0200 Subject: [PATCH] mt76x0: correct type for eeprom gain value Change type to u8 to allow sanity check agaist 0xff; Reported-by: Dan Carpenter Fixes: e87b5039511a ("mt76x0: eeprom files") Signed-off-by: Stanislaw Gruszka Signed-off-by: Kalle Valo --- mt76x0/eeprom.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mt76x0/eeprom.c b/mt76x0/eeprom.c index 1ecd018f..9ea5f5eb 100644 --- a/mt76x0/eeprom.c +++ b/mt76x0/eeprom.c @@ -241,7 +241,7 @@ mt76x0_set_rf_freq_off(struct mt76x0_dev *dev, u8 *eeprom) static void mt76x0_set_lna_gain(struct mt76x0_dev *dev, u8 *eeprom) { - s8 gain; + u8 gain; dev->ee->lna_gain_2ghz = eeprom[MT_EE_LNA_GAIN_2GHZ]; dev->ee->lna_gain_5ghz[0] = eeprom[MT_EE_LNA_GAIN_5GHZ_0];