Patchwork [Resend,2,BUILD,FAILURE,04/04] Next June 04:PPC64 randconfig [drivers/net/ucc_geth.o]

login
register
mail settings
Submitter Stephen Rothwell
Date June 17, 2009, 1:34 p.m.
Message ID <20090617233452.03ac78d5.sfr@canb.auug.org.au>
Download mbox | patch
Permalink /patch/28789/
State Superseded, archived
Delegated to: Kumar Gala
Headers show

Comments

Stephen Rothwell - June 17, 2009, 1:34 p.m.
On Wed, 17 Jun 2009 23:23:41 +1000 Stephen Rothwell <sfr@canb.auug.org.au> wrote:
>
> Hi Kumar,
> 
> On Wed, 17 Jun 2009 08:07:47 -0500 Kumar Gala <galak@kernel.crashing.org> wrote:
> >
> > 
> > I'm confused by the proposed fix as we already have *mdio & *ph  
> > defined in this function:
> 
> Which tree are you looking at?  Linus' tree, and linux-next, do not have
> those local variables ...

Hmmm, commit 0b9da337dca972e7a4144e298ec3adb8f244d4a4 ("net: Rework
ucc_geth driver to use of_mdio infrastructure") removed the locals along
with their usages, then commit 047584ce94108012288554a5f84585d792cc7f8f
("net/ucc_geth: Add SGMII support for UEC GETH driver") added more uses
without adding the variables back.

Here is the patch again:

From: Subrata Modak <subrata@linux.vnet.ibm.com>
Subject: [PATCH] Fix build error in ucc_geth.c

Fix the following build error:

drivers/net/ucc_geth.c: In function bucc_geth_probeb:
drivers/net/ucc_geth.c:3822: error: 'ph' undeclared (first use in this function)
drivers/net/ucc_geth.c:3822: error: (Each undeclared identifier is reported only once
drivers/net/ucc_geth.c:3822: error: for each function it appears in.)
drivers/net/ucc_geth.c:3832: error: 'mdio' undeclared (first use in this function)
make[2]: *** [drivers/net/ucc_geth.o] Error 1

Signed-off-by: Subrata Modak <subrata@linux.vnet.ibm.com>
Kumar Gala - June 17, 2009, 1:49 p.m.
On Jun 17, 2009, at 8:34 AM, Stephen Rothwell wrote:

> On Wed, 17 Jun 2009 23:23:41 +1000 Stephen Rothwell <sfr@canb.auug.org.au 
> > wrote:
>>
>> Hi Kumar,
>>
>> On Wed, 17 Jun 2009 08:07:47 -0500 Kumar Gala <galak@kernel.crashing.org 
>> > wrote:
>>>
>>>
>>> I'm confused by the proposed fix as we already have *mdio & *ph
>>> defined in this function:
>>
>> Which tree are you looking at?  Linus' tree, and linux-next, do not  
>> have
>> those local variables ...
>
> Hmmm, commit 0b9da337dca972e7a4144e298ec3adb8f244d4a4 ("net: Rework
> ucc_geth driver to use of_mdio infrastructure") removed the locals  
> along
> with their usages, then commit  
> 047584ce94108012288554a5f84585d792cc7f8f
> ("net/ucc_geth: Add SGMII support for UEC GETH driver") added more  
> uses
> without adding the variables back.
>
> Here is the patch again:
>
> From: Subrata Modak <subrata@linux.vnet.ibm.com>
> Subject: [PATCH] Fix build error in ucc_geth.c
>
> Fix the following build error:
>
> drivers/net/ucc_geth.c: In function bucc_geth_probeb:
> drivers/net/ucc_geth.c:3822: error: 'ph' undeclared (first use in  
> this function)
> drivers/net/ucc_geth.c:3822: error: (Each undeclared identifier is  
> reported only once
> drivers/net/ucc_geth.c:3822: error: for each function it appears in.)
> drivers/net/ucc_geth.c:3832: error: 'mdio' undeclared (first use in  
> this function)
> make[2]: *** [drivers/net/ucc_geth.o] Error 1
>
> Signed-off-by: Subrata Modak <subrata@linux.vnet.ibm.com>
>
> --- linux-2.6.30-rc8/drivers/net/ucc_geth.c.orig	2009-06-10  
> 11:58:39.000000000 -0500
> +++ linux-2.6.30-rc8/drivers/net/ucc_geth.c	2009-06-10  
> 22:28:13.000000000 -0500
> @@ -3595,6 +3595,8 @@ static const struct net_device_ops ucc_g
>
> static int ucc_geth_probe(struct of_device* ofdev, const struct  
> of_device_id *match)
> {
> +	struct device_node *mdio;
> +	const phandle *ph;
> 	struct device *device = &ofdev->dev;
> 	struct device_node *np = ofdev->node;
> 	struct net_device *dev = NULL;

ah... was looking at powerpc next which hasn't pulled in linus's  
latest tree w/netdev updates.

- k
Grant Likely - June 17, 2009, 5:29 p.m.
On Wed, Jun 17, 2009 at 7:34 AM, Stephen Rothwell<sfr@canb.auug.org.au> wrote:
> On Wed, 17 Jun 2009 23:23:41 +1000 Stephen Rothwell <sfr@canb.auug.org.au> wrote:
>>
>> Hi Kumar,
>>
>> On Wed, 17 Jun 2009 08:07:47 -0500 Kumar Gala <galak@kernel.crashing.org> wrote:
>> >
>> >
>> > I'm confused by the proposed fix as we already have *mdio & *ph
>> > defined in this function:
>>
>> Which tree are you looking at?  Linus' tree, and linux-next, do not have
>> those local variables ...
>
> Hmmm, commit 0b9da337dca972e7a4144e298ec3adb8f244d4a4 ("net: Rework
> ucc_geth driver to use of_mdio infrastructure") removed the locals along
> with their usages, then commit 047584ce94108012288554a5f84585d792cc7f8f
> ("net/ucc_geth: Add SGMII support for UEC GETH driver") added more uses
> without adding the variables back.
>
> Here is the patch again:
>
> From: Subrata Modak <subrata@linux.vnet.ibm.com>
> Subject: [PATCH] Fix build error in ucc_geth.c
>
> Fix the following build error:
>
> drivers/net/ucc_geth.c: In function bucc_geth_probeb:
> drivers/net/ucc_geth.c:3822: error: 'ph' undeclared (first use in this function)
> drivers/net/ucc_geth.c:3822: error: (Each undeclared identifier is reported only once
> drivers/net/ucc_geth.c:3822: error: for each function it appears in.)
> drivers/net/ucc_geth.c:3832: error: 'mdio' undeclared (first use in this function)
> make[2]: *** [drivers/net/ucc_geth.o] Error 1
>
> Signed-off-by: Subrata Modak <subrata@linux.vnet.ibm.com>
>
> --- linux-2.6.30-rc8/drivers/net/ucc_geth.c.orig        2009-06-10 11:58:39.000000000 -0500
> +++ linux-2.6.30-rc8/drivers/net/ucc_geth.c     2009-06-10 22:28:13.000000000 -0500
> @@ -3595,6 +3595,8 @@ static const struct net_device_ops ucc_g
>
>  static int ucc_geth_probe(struct of_device* ofdev, const struct of_device_id *match)
>  {
> +       struct device_node *mdio;
> +       const phandle *ph;
>        struct device *device = &ofdev->dev;
>        struct device_node *np = ofdev->node;
>        struct net_device *dev = NULL;

Ah, this might not be the right fix then.  I'll look.

g.
Grant Likely - June 17, 2009, 8:37 p.m.
On Wed, Jun 17, 2009 at 11:29 AM, Grant Likely<grant.likely@secretlab.ca> wrote:
> On Wed, Jun 17, 2009 at 7:34 AM, Stephen Rothwell<sfr@canb.auug.org.au> wrote:
>> On Wed, 17 Jun 2009 23:23:41 +1000 Stephen Rothwell <sfr@canb.auug.org.au> wrote:
>>>
>>> Hi Kumar,
>>>
>>> On Wed, 17 Jun 2009 08:07:47 -0500 Kumar Gala <galak@kernel.crashing.org> wrote:
>>> >
>>> >
>>> > I'm confused by the proposed fix as we already have *mdio & *ph
>>> > defined in this function:
>>>
>>> Which tree are you looking at?  Linus' tree, and linux-next, do not have
>>> those local variables ...
>>
>> Hmmm, commit 0b9da337dca972e7a4144e298ec3adb8f244d4a4 ("net: Rework
>> ucc_geth driver to use of_mdio infrastructure") removed the locals along
>> with their usages, then commit 047584ce94108012288554a5f84585d792cc7f8f
>> ("net/ucc_geth: Add SGMII support for UEC GETH driver") added more uses
>> without adding the variables back.
>>
>> Here is the patch again:
>>
>> From: Subrata Modak <subrata@linux.vnet.ibm.com>
>> Subject: [PATCH] Fix build error in ucc_geth.c
>>
>> Fix the following build error:
>>
>> drivers/net/ucc_geth.c: In function bucc_geth_probeb:
>> drivers/net/ucc_geth.c:3822: error: 'ph' undeclared (first use in this function)
>> drivers/net/ucc_geth.c:3822: error: (Each undeclared identifier is reported only once
>> drivers/net/ucc_geth.c:3822: error: for each function it appears in.)
>> drivers/net/ucc_geth.c:3832: error: 'mdio' undeclared (first use in this function)
>> make[2]: *** [drivers/net/ucc_geth.o] Error 1
>>
>> Signed-off-by: Subrata Modak <subrata@linux.vnet.ibm.com>
>>
>> --- linux-2.6.30-rc8/drivers/net/ucc_geth.c.orig        2009-06-10 11:58:39.000000000 -0500
>> +++ linux-2.6.30-rc8/drivers/net/ucc_geth.c     2009-06-10 22:28:13.000000000 -0500
>> @@ -3595,6 +3595,8 @@ static const struct net_device_ops ucc_g
>>
>>  static int ucc_geth_probe(struct of_device* ofdev, const struct of_device_id *match)
>>  {
>> +       struct device_node *mdio;
>> +       const phandle *ph;
>>        struct device *device = &ofdev->dev;
>>        struct device_node *np = ofdev->node;
>>        struct net_device *dev = NULL;
>
> Ah, this might not be the right fix then.  I'll look.

Yeah, this is not the right fix.  The SGMII change doesn't mesh well
with the of_mdio changes and needed some rewriting.  I'm about to post
a patch (compile tested only) which should make things happy.

Patch

--- linux-2.6.30-rc8/drivers/net/ucc_geth.c.orig	2009-06-10 11:58:39.000000000 -0500
+++ linux-2.6.30-rc8/drivers/net/ucc_geth.c	2009-06-10 22:28:13.000000000 -0500
@@ -3595,6 +3595,8 @@  static const struct net_device_ops ucc_g
 
 static int ucc_geth_probe(struct of_device* ofdev, const struct of_device_id *match)
 {
+	struct device_node *mdio;
+	const phandle *ph;
 	struct device *device = &ofdev->dev;
 	struct device_node *np = ofdev->node;
 	struct net_device *dev = NULL;