Commit fbd39969 authored by Lee Jones's avatar Lee Jones Committed by Greg Kroah-Hartman
Browse files

staging: ks7010: ks_hostif: Remove a bunch of unused variables



Add comments to preserve documentation.

Fixes the following W=1 kernel build warning(s):

 drivers/staging/ks7010/ks_hostif.c: In function ‘hostif_mib_get_confirm’:
 drivers/staging/ks7010/ks_hostif.c:528:6: warning: variable ‘mib_val_type’ set but not used [-Wunused-but-set-variable]
 drivers/staging/ks7010/ks_hostif.c:527:6: warning: variable ‘mib_val_size’ set but not used [-Wunused-but-set-variable]
 drivers/staging/ks7010/ks_hostif.c: In function ‘hostif_infrastructure_set_confirm’:
 drivers/staging/ks7010/ks_hostif.c:849:6: warning: variable ‘result_code’ set but not used [-Wunused-but-set-variable]
 drivers/staging/ks7010/ks_hostif.c: In function ‘hostif_phy_information_confirm’:
 drivers/staging/ks7010/ks_hostif.c:929:19: warning: variable ‘noise’ set but not used [-Wunused-but-set-variable]

Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: linux-staging@lists.linux.dev
Signed-off-by: default avatarLee Jones <lee.jones@linaro.org>
Link: https://lore.kernel.org/r/20210414181129.1628598-24-lee.jones@linaro.org


Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent e950dd6b
Loading
Loading
Loading
Loading
+5 −9
Original line number Diff line number Diff line
@@ -524,13 +524,11 @@ void hostif_mib_get_confirm(struct ks_wlan_private *priv)
	struct net_device *dev = priv->net_dev;
	u32 mib_status;
	u32 mib_attribute;
	u16 mib_val_size;
	u16 mib_val_type;

	mib_status = get_dword(priv);
	mib_attribute = get_dword(priv);
	mib_val_size = get_word(priv);
	mib_val_type = get_word(priv);
	get_word(priv); /* mib_val_size */
	get_word(priv); /* mib_val_type */

	if (mib_status) {
		netdev_err(priv->net_dev, "attribute=%08X, status=%08X\n",
@@ -846,9 +844,7 @@ void hostif_ps_adhoc_set_confirm(struct ks_wlan_private *priv)
static
void hostif_infrastructure_set_confirm(struct ks_wlan_private *priv)
{
	u16 result_code;

	result_code = get_word(priv);
	get_word(priv); /* result_code */
	priv->infra_status = 1;	/* infrastructure mode set */
	hostif_sme_enqueue(priv, SME_MODE_SET_CONFIRM);
}
@@ -926,14 +922,14 @@ static
void hostif_phy_information_confirm(struct ks_wlan_private *priv)
{
	struct iw_statistics *wstats = &priv->wstats;
	u8 rssi, signal, noise;
	u8 rssi, signal;
	u8 link_speed;
	u32 transmitted_frame_count, received_fragment_count;
	u32 failed_count, fcs_error_count;

	rssi = get_byte(priv);
	signal = get_byte(priv);
	noise = get_byte(priv);
	get_byte(priv); /* noise */
	link_speed = get_byte(priv);
	transmitted_frame_count = get_dword(priv);
	received_fragment_count = get_dword(priv);