[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <87wplxdsln.fsf@kamboji.qca.qualcomm.com>
Date: Fri, 10 Jun 2016 17:30:12 +0300
From: Kalle Valo <kvalo@...eaurora.org>
To: Javier Martinez Canillas <javier@....samsung.com>
Cc: linux-kernel@...r.kernel.org,
Julian Calaby <julian.calaby@...il.com>,
Shengzhen Li <szli@...vell.com>,
Enric Balletbo i Serra <enric.balletbo@...labora.com>,
Amitkumar Karwar <akarwar@...vell.com>, netdev@...r.kernel.org,
linux-wireless@...r.kernel.org,
Nishant Sarmukadam <nishants@...vell.com>
Subject: Re: [PATCH v2 2/3] mwifiex: move .get_tx_power logic to station ioctl file
Javier Martinez Canillas <javier@....samsung.com> writes:
> From: Shengzhen Li <szli@...vell.com>
>
> Most cfg80211 operations are just a wrappers to functions defined in the
> sta_ioctl.c file, so for consistency move the .get_tx_power logic there.
>
> Signed-off-by: Shengzhen Li <szli@...vell.com>
> Signed-off-by: Amitkumar Karwar <akarwar@...vell.com>
> [javier: update the subject line and commit message]
> Signed-off-by: Javier Martinez Canillas <javier@....samsung.com>
[...]
> --- a/drivers/net/wireless/marvell/mwifiex/cfg80211.c
> +++ b/drivers/net/wireless/marvell/mwifiex/cfg80211.c
> @@ -385,18 +385,10 @@ mwifiex_cfg80211_get_tx_power(struct wiphy *wiphy,
> int *dbm)
> {
> struct mwifiex_adapter *adapter = mwifiex_cfg80211_get_adapter(wiphy);
> - struct mwifiex_private *priv = mwifiex_get_priv(adapter,
> - MWIFIEX_BSS_ROLE_ANY);
> - int ret = mwifiex_send_cmd(priv, HostCmd_CMD_RF_TX_PWR,
> - HostCmd_ACT_GEN_GET, 0, NULL, true);
> -
> - if (ret < 0)
> - return ret;
> -
> - /* tx_power_level is set in HostCmd_CMD_RF_TX_PWR command handler */
> - *dbm = priv->tx_power_level;
> + struct mwifiex_private *priv;
>
> - return 0;
> + priv = mwifiex_get_priv(adapter, MWIFIEX_BSS_ROLE_ANY);
> + return mwifiex_get_tx_power(priv, dbm);
> }
So in patch 1 you added the patch and in patch 2 you move it to a
different location? That doesn't make any sense, can't you just fold the
two patches into one so that the function is added only once.
--
Kalle Valo
Powered by blists - more mailing lists