Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1534196 > unrolled thread

[PATCH 1/2] net: stmmac: avoid Camelcase naming

Started byCorentin Labbe <clabbe.montjoie@gmail.com>
First post2016-12-01 16:30 +0100
Last post2016-12-03 21:40 +0100
Articles 5 — 3 participants

Back to article view | Back to linux.kernel


Contents

  [PATCH 1/2] net: stmmac: avoid Camelcase naming Corentin Labbe <clabbe.montjoie@gmail.com> - 2016-12-01 16:30 +0100
    Re: [PATCH 1/2] net: stmmac: avoid Camelcase naming Giuseppe CAVALLARO <peppe.cavallaro@st.com> - 2016-12-02 09:50 +0100
      Re: [PATCH 1/2] net: stmmac: avoid Camelcase naming Corentin Labbe <clabbe.montjoie@gmail.com> - 2016-12-02 10:00 +0100
        Re: [PATCH 1/2] net: stmmac: avoid Camelcase naming Giuseppe CAVALLARO <peppe.cavallaro@st.com> - 2016-12-02 10:30 +0100
    Re: [PATCH 1/2] net: stmmac: avoid Camelcase naming David Miller <davem@davemloft.net> - 2016-12-03 21:40 +0100

#1534196 — [PATCH 1/2] net: stmmac: avoid Camelcase naming

FromCorentin Labbe <clabbe.montjoie@gmail.com>
Date2016-12-01 16:30 +0100
Subject[PATCH 1/2] net: stmmac: avoid Camelcase naming
Message-ID<sJBt7-5DE-13@gated-at.bofh.it>
This patch simply rename regValue to value, like it was named in other
mdio functions.

Signed-off-by: Corentin Labbe <clabbe.montjoie@gmail.com>
---
 drivers/net/ethernet/stmicro/stmmac/stmmac_mdio.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/drivers/net/ethernet/stmicro/stmmac/stmmac_mdio.c b/drivers/net/ethernet/stmicro/stmmac/stmmac_mdio.c
index e3216e5..6796c28 100644
--- a/drivers/net/ethernet/stmicro/stmmac/stmmac_mdio.c
+++ b/drivers/net/ethernet/stmicro/stmmac/stmmac_mdio.c
@@ -83,14 +83,14 @@ static int stmmac_mdio_read(struct mii_bus *bus, int phyaddr, int phyreg)
 	unsigned int mii_data = priv->hw->mii.data;
 
 	int data;
-	u16 regValue = (((phyaddr << 11) & (0x0000F800)) |
+	u16 value = (((phyaddr << 11) & (0x0000F800)) |
 			((phyreg << 6) & (0x000007C0)));
-	regValue |= MII_BUSY | ((priv->clk_csr & 0xF) << 2);
+	value |= MII_BUSY | ((priv->clk_csr & 0xF) << 2);
 
 	if (stmmac_mdio_busy_wait(priv->ioaddr, mii_address))
 		return -EBUSY;
 
-	writel(regValue, priv->ioaddr + mii_address);
+	writel(value, priv->ioaddr + mii_address);
 
 	if (stmmac_mdio_busy_wait(priv->ioaddr, mii_address))
 		return -EBUSY;
-- 
2.7.3

[toc] | [next] | [standalone]


#1534744

FromGiuseppe CAVALLARO <peppe.cavallaro@st.com>
Date2016-12-02 09:50 +0100
Message-ID<sJRHA-1oa-13@gated-at.bofh.it>
In reply to#1534196
Hello Corentin

patches look ok, I just wonder if you tested it in case of
the stmmac is connected to a transceiver. Let me consider it
a critical part of the driver to properly work.

Regards
Peppe

On 12/1/2016 4:19 PM, Corentin Labbe wrote:
> This patch simply rename regValue to value, like it was named in other
> mdio functions.
>
> Signed-off-by: Corentin Labbe <clabbe.montjoie@gmail.com>
> ---
>  drivers/net/ethernet/stmicro/stmmac/stmmac_mdio.c | 6 +++---
>  1 file changed, 3 insertions(+), 3 deletions(-)
>
> diff --git a/drivers/net/ethernet/stmicro/stmmac/stmmac_mdio.c b/drivers/net/ethernet/stmicro/stmmac/stmmac_mdio.c
> index e3216e5..6796c28 100644
> --- a/drivers/net/ethernet/stmicro/stmmac/stmmac_mdio.c
> +++ b/drivers/net/ethernet/stmicro/stmmac/stmmac_mdio.c
> @@ -83,14 +83,14 @@ static int stmmac_mdio_read(struct mii_bus *bus, int phyaddr, int phyreg)
>  	unsigned int mii_data = priv->hw->mii.data;
>
>  	int data;
> -	u16 regValue = (((phyaddr << 11) & (0x0000F800)) |
> +	u16 value = (((phyaddr << 11) & (0x0000F800)) |
>  			((phyreg << 6) & (0x000007C0)));
> -	regValue |= MII_BUSY | ((priv->clk_csr & 0xF) << 2);
> +	value |= MII_BUSY | ((priv->clk_csr & 0xF) << 2);
>
>  	if (stmmac_mdio_busy_wait(priv->ioaddr, mii_address))
>  		return -EBUSY;
>
> -	writel(regValue, priv->ioaddr + mii_address);
> +	writel(value, priv->ioaddr + mii_address);
>
>  	if (stmmac_mdio_busy_wait(priv->ioaddr, mii_address))
>  		return -EBUSY;
>

[toc] | [prev] | [next] | [standalone]


#1534753

FromCorentin Labbe <clabbe.montjoie@gmail.com>
Date2016-12-02 10:00 +0100
Message-ID<sJRRl-1vC-17@gated-at.bofh.it>
In reply to#1534744
On Fri, Dec 02, 2016 at 09:44:48AM +0100, Giuseppe CAVALLARO wrote:
> Hello Corentin
> 
> patches look ok, I just wonder if you tested it in case of
> the stmmac is connected to a transceiver. Let me consider it
> a critical part of the driver to properly work.
> 
> Regards
> Peppe
> 

I tested it on a Cubieboard 2 (dwmac-sunxi).
What do you mean by "connected to a transceiver" ? an external PHY ?

Regards

[toc] | [prev] | [next] | [standalone]


#1534764

FromGiuseppe CAVALLARO <peppe.cavallaro@st.com>
Date2016-12-02 10:30 +0100
Message-ID<sJSkh-1ZS-11@gated-at.bofh.it>
In reply to#1534753
On 12/2/2016 9:58 AM, Corentin Labbe wrote:
> On Fri, Dec 02, 2016 at 09:44:48AM +0100, Giuseppe CAVALLARO wrote:
>> Hello Corentin
>>
>> patches look ok, I just wonder if you tested it in case of
>> the stmmac is connected to a transceiver. Let me consider it
>> a critical part of the driver to properly work.
>>
>> Regards
>> Peppe
>>
>
> I tested it on a Cubieboard 2 (dwmac-sunxi).
> What do you mean by "connected to a transceiver" ? an external PHY ?

yes an external PHY. AFAIK, users have, sometime, a switch
with fixed link enabled.

Thx for your support and patches

Acked-by: Giuseppe Cavallaro <peppe.cavallaro@st.com>

>
> Regards
>

[toc] | [prev] | [next] | [standalone]


#1535520

FromDavid Miller <davem@davemloft.net>
Date2016-12-03 21:40 +0100
Message-ID<sKpge-62v-23@gated-at.bofh.it>
In reply to#1534196
From: Corentin Labbe <clabbe.montjoie@gmail.com>
Date: Thu,  1 Dec 2016 16:19:40 +0100

> This patch simply rename regValue to value, like it was named in other
> mdio functions.
> 
> Signed-off-by: Corentin Labbe <clabbe.montjoie@gmail.com>

Applied.

[toc] | [prev] | [standalone]


Back to top | Article view | linux.kernel


csiph-web