From: YueHaibing <yuehaibing@huawei.com> To: Alexandre Belloni <alexandre.belloni@bootlin.com>, "David S. Miller" <davem@davemloft.net> Cc: YueHaibing <yuehaibing@huawei.com>, <netdev@vger.kernel.org>, <kernel-janitors@vger.kernel.org> Subject: [PATCH net-next] net: mscc: ocelot: remove set but not used variable 'phy_mode' Date: Mon, 8 Oct 2018 14:07:50 +0000 [thread overview] Message-ID: <1539007670-82488-1-git-send-email-yuehaibing@huawei.com> (raw) Fixes gcc '-Wunused-but-set-variable' warning: drivers/net/ethernet/mscc/ocelot_board.c: In function 'mscc_ocelot_probe': drivers/net/ethernet/mscc/ocelot_board.c:262:17: warning: variable 'phy_mode' set but not used [-Wunused-but-set-variable] enum phy_mode phy_mode; It never used since introduction in commit 71e32a20cfbf ("net: mscc: ocelot: make use of SerDes PHYs for handling their configuration") Signed-off-by: YueHaibing <yuehaibing@huawei.com> --- drivers/net/ethernet/mscc/ocelot_board.c | 3 --- 1 file changed, 3 deletions(-) diff --git a/drivers/net/ethernet/mscc/ocelot_board.c b/drivers/net/ethernet/mscc/ocelot_board.c index 953b326..0cf0b09 100644 --- a/drivers/net/ethernet/mscc/ocelot_board.c +++ b/drivers/net/ethernet/mscc/ocelot_board.c @@ -259,7 +259,6 @@ static int mscc_ocelot_probe(struct platform_device *pdev) struct phy_device *phy; struct resource *res; struct phy *serdes; - enum phy_mode phy_mode; void __iomem *regs; char res_name[8]; u32 port; @@ -297,10 +296,8 @@ static int mscc_ocelot_probe(struct platform_device *pdev) case PHY_INTERFACE_MODE_NA: continue; case PHY_INTERFACE_MODE_SGMII: - phy_mode = PHY_MODE_SGMII; break; case PHY_INTERFACE_MODE_QSGMII: - phy_mode = PHY_MODE_QSGMII; break; default: dev_err(ocelot->dev,
WARNING: multiple messages have this Message-ID (diff)
From: YueHaibing <yuehaibing@huawei.com> To: Alexandre Belloni <alexandre.belloni@bootlin.com>, "David S. Miller" <davem@davemloft.net> Cc: YueHaibing <yuehaibing@huawei.com>, netdev@vger.kernel.org, kernel-janitors@vger.kernel.org Subject: [PATCH net-next] net: mscc: ocelot: remove set but not used variable 'phy_mode' Date: Mon, 08 Oct 2018 13:56:42 +0000 [thread overview] Message-ID: <1539007670-82488-1-git-send-email-yuehaibing@huawei.com> (raw) Fixes gcc '-Wunused-but-set-variable' warning: drivers/net/ethernet/mscc/ocelot_board.c: In function 'mscc_ocelot_probe': drivers/net/ethernet/mscc/ocelot_board.c:262:17: warning: variable 'phy_mode' set but not used [-Wunused-but-set-variable] enum phy_mode phy_mode; It never used since introduction in commit 71e32a20cfbf ("net: mscc: ocelot: make use of SerDes PHYs for handling their configuration") Signed-off-by: YueHaibing <yuehaibing@huawei.com> --- drivers/net/ethernet/mscc/ocelot_board.c | 3 --- 1 file changed, 3 deletions(-) diff --git a/drivers/net/ethernet/mscc/ocelot_board.c b/drivers/net/ethernet/mscc/ocelot_board.c index 953b326..0cf0b09 100644 --- a/drivers/net/ethernet/mscc/ocelot_board.c +++ b/drivers/net/ethernet/mscc/ocelot_board.c @@ -259,7 +259,6 @@ static int mscc_ocelot_probe(struct platform_device *pdev) struct phy_device *phy; struct resource *res; struct phy *serdes; - enum phy_mode phy_mode; void __iomem *regs; char res_name[8]; u32 port; @@ -297,10 +296,8 @@ static int mscc_ocelot_probe(struct platform_device *pdev) case PHY_INTERFACE_MODE_NA: continue; case PHY_INTERFACE_MODE_SGMII: - phy_mode = PHY_MODE_SGMII; break; case PHY_INTERFACE_MODE_QSGMII: - phy_mode = PHY_MODE_QSGMII; break; default: dev_err(ocelot->dev,
next reply other threads:[~2018-10-08 21:08 UTC|newest] Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top 2018-10-08 13:56 YueHaibing [this message] 2018-10-08 14:07 ` [PATCH net-next] net: mscc: ocelot: remove set but not used variable 'phy_mode' YueHaibing 2018-10-08 18:04 ` David Miller 2018-10-08 18:04 ` David Miller
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=1539007670-82488-1-git-send-email-yuehaibing@huawei.com \ --to=yuehaibing@huawei.com \ --cc=alexandre.belloni@bootlin.com \ --cc=davem@davemloft.net \ --cc=kernel-janitors@vger.kernel.org \ --cc=netdev@vger.kernel.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes, see mirroring instructions on how to clone and mirror all data and code used by this external index.