| To: | Sergei Shtylyov <sshtylyov@ru.mvista.com> |
|---|---|
| Subject: | Re: [PATCH] au1000_eth.c Power Management, driver registration and module support |
| From: | Rodolfo Giometti <giometti@linux.it> |
| Date: | Wed, 31 May 2006 17:21:41 +0200 |
| Cc: | jgarzik@pobox.com, netdev@vger.kernel.org, Linux-MIPS <linux-mips@linux-mips.org>, Jordan Crouse <jordan.crouse@amd.com> |
| In-reply-to: | <447DAFAE.10503@ru.mvista.com> |
| Organization: | GNU/Linux Device Drivers, Embedded Systems and Courses |
| Original-recipient: | rfc822;linux-mips@linux-mips.org |
| References: | <20060405154711.GL7029@enneenne.com> <20060405222332.GO7029@enneenne.com> <20060405222620.GP7029@enneenne.com> <4435290C.50607@ru.mvista.com> <20060406155011.GC23424@enneenne.com> <4446857D.90507@ru.mvista.com> <20060502150914.GE20543@gundam.enneenne.com> <447DAFAE.10503@ru.mvista.com> |
| Sender: | linux-mips-bounce@linux-mips.org |
| User-agent: | Mutt/1.5.11+cvs20060403 |
On Wed, May 31, 2006 at 07:01:02PM +0400, Sergei Shtylyov wrote:
>
> Now that this is merged, Rodolfo's patch should probably preempt mine...
> but it looks like something was lost during the transition: I failed to see
> where SYS_PINFUNC register is actually read (the comment mentioning this
> was retained :-) to check whether Ethernet port 1 is enabled (its pins are
> shared w/GPIO)...
You are right! Maybe something like this may fix the problem:
diff --git a/drivers/net/au1000_eth.c b/drivers/net/au1000_eth.c
index 341fdc4..8a6427e 100644
--- a/drivers/net/au1000_eth.c
+++ b/drivers/net/au1000_eth.c
@@ -2149,6 +2149,9 @@ static int au1000_drv_probe(struct devic
void *base_addr, *macen_addr;
int irq, ret;
+ if (pdev->id == 1 && (au_readl(SYS_PINFUNC) & SYS_PF_NI2) != 0)
+ return -ENODEV;
+
/* Get the resource info */
res = platform_get_resource_byname(pdev, IORESOURCE_MEM, "eth-base");
if (!res) {
Ciao,
Rodolfo
--
GNU/Linux Solutions e-mail: giometti@enneenne.com
Linux Device Driver giometti@gnudd.com
Embedded Systems giometti@linux.it
UNIX programming phone: +39 349 2432127
|
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| ||
| Previous by Date: | Re: [PATCH] au1000_eth.c Power Management, driver registration and module support, Sergei Shtylyov |
|---|---|
| Next by Date: | [PATCH] fix some compiler warnings (field width, unused variable), Atsushi Nemoto |
| Previous by Thread: | Re: [PATCH] au1000_eth.c Power Management, driver registration and module support, Sergei Shtylyov |
| Next by Thread: | Re: SETNAME (set nodename) in syscall.c, Ralf Baechle |
| Indexes: | [Date] [Thread] [Top] [All Lists] |