diff mbox series

net: stmmac: dwmac-intel-plat: remove unnecessary initialization

Message ID 20210210175935.3967631-1-nobuhiro1.iwamatsu@toshiba.co.jp (mailing list archive)
State Accepted
Commit 0d645232ddbfea2ee59fdb6ec48ced4cf69aaf9f
Delegated to: Netdev Maintainers
Headers show
Series net: stmmac: dwmac-intel-plat: remove unnecessary initialization | expand

Checks

Context Check Description
netdev/cover_letter success Link
netdev/fixes_present success Link
netdev/patch_count success Link
netdev/tree_selection success Guessed tree name to be net-next
netdev/subject_prefix warning Target tree name not specified in the subject
netdev/cc_maintainers warning 6 maintainers not CCed: joabreu@synopsys.com linux-arm-kernel@lists.infradead.org mcoquelin.stm32@gmail.com linux-stm32@st-md-mailman.stormreply.com alexandre.torgue@st.com peppe.cavallaro@st.com
netdev/source_inline success Was 0 now: 0
netdev/verify_signedoff success Link
netdev/module_param success Was 0 now: 0
netdev/build_32bit success Errors and warnings before: 0 this patch: 0
netdev/kdoc success Errors and warnings before: 0 this patch: 0
netdev/verify_fixes success Link
netdev/checkpatch success total: 0 errors, 0 warnings, 0 checks, 15 lines checked
netdev/build_allmodconfig_warn success Errors and warnings before: 0 this patch: 0
netdev/header_inline success Link
netdev/stable success Stable not CCed

Commit Message

Nobuhiro Iwamatsu Feb. 10, 2021, 5:59 p.m. UTC
plat_dat is initialized by stmmac_probe_config_dt().
So, initialization is not required by priv->plat.
This removes unnecessary initialization and variables.

Signed-off-by: Nobuhiro Iwamatsu <nobuhiro1.iwamatsu@toshiba.co.jp>
---
 drivers/net/ethernet/stmicro/stmmac/dwmac-intel-plat.c | 3 ---
 1 file changed, 3 deletions(-)

Comments

patchwork-bot+netdevbpf@kernel.org Feb. 11, 2021, 10:30 p.m. UTC | #1
Hello:

This patch was applied to netdev/net-next.git (refs/heads/master):

On Thu, 11 Feb 2021 02:59:35 +0900 you wrote:
> plat_dat is initialized by stmmac_probe_config_dt().
> So, initialization is not required by priv->plat.
> This removes unnecessary initialization and variables.
> 
> Signed-off-by: Nobuhiro Iwamatsu <nobuhiro1.iwamatsu@toshiba.co.jp>
> ---
>  drivers/net/ethernet/stmicro/stmmac/dwmac-intel-plat.c | 3 ---
>  1 file changed, 3 deletions(-)

Here is the summary with links:
  - net: stmmac: dwmac-intel-plat: remove unnecessary initialization
    https://git.kernel.org/netdev/net-next/c/0d645232ddbf

You are awesome, thank you!
--
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html
diff mbox series

Patch

diff --git a/drivers/net/ethernet/stmicro/stmmac/dwmac-intel-plat.c b/drivers/net/ethernet/stmicro/stmmac/dwmac-intel-plat.c
index ba0e4d2b256a..6c19fcc76c6f 100644
--- a/drivers/net/ethernet/stmicro/stmmac/dwmac-intel-plat.c
+++ b/drivers/net/ethernet/stmicro/stmmac/dwmac-intel-plat.c
@@ -74,8 +74,6 @@  MODULE_DEVICE_TABLE(of, intel_eth_plat_match);
 
 static int intel_eth_plat_probe(struct platform_device *pdev)
 {
-	struct net_device *ndev = platform_get_drvdata(pdev);
-	struct stmmac_priv *priv = netdev_priv(ndev);
 	struct plat_stmmacenet_data *plat_dat;
 	struct stmmac_resources stmmac_res;
 	const struct of_device_id *match;
@@ -83,7 +81,6 @@  static int intel_eth_plat_probe(struct platform_device *pdev)
 	unsigned long rate;
 	int ret;
 
-	plat_dat = priv->plat;
 	ret = stmmac_get_platform_resources(pdev, &stmmac_res);
 	if (ret)
 		return ret;