netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH][ATM] iphase: doesn't call phy->start due to a bogus #ifndef
@ 2008-06-05 16:17 Jorge Boncompte [DTI2]
  2008-06-14 21:24 ` Chas Williams (CONTRACTOR)
  0 siblings, 1 reply; 5+ messages in thread
From: Jorge Boncompte [DTI2] @ 2008-06-05 16:17 UTC (permalink / raw)
  To: netdev; +Cc: chas williams

	This causes the suni driver to oops if you try to use sonetdiag to
get the statistics. Also add the corresponding phy->stop call to fix another
oops if you try to remove the module.

Signed-off-by: Jorge Boncompte [DTI2] <jorge@dti2.net>
---
  drivers/atm/iphase.c |   25 +++++++++++++------------
  1 files changed, 13 insertions(+), 12 deletions(-)

diff --git a/drivers/atm/iphase.c b/drivers/atm/iphase.c
index 1b7090a..521d8af 100644
--- a/drivers/atm/iphase.c
+++ b/drivers/atm/iphase.c
@@ -2556,17 +2556,13 @@ static int __devinit ia_start(struct atm_dev *dev)
  		error = suni_init(dev);
  		if (error)
  			goto err_free_rx;
-		/*
-		 * Enable interrupt on loss of signal
-		 * SUNI_RSOP_CIE - 0x10
-		 * SUNI_RSOP_CIE_LOSE - 0x04
-		 */
-		ia_phy_put(dev, ia_phy_get(dev, 0x10) | 0x04, 0x10);
-#ifndef MODULE
-		error = dev->phy->start(dev);
-		if (error)
-			goto err_free_rx;
-#endif
+
+		if (dev->phy->start) {
+			error = dev->phy->start(dev);
+			if (error)
+				goto err_free_rx;
+		}
+
  		/* Get iadev->carrier_detect status */
  		IaFrontEndIntr(iadev);
  	}
@@ -3226,9 +3222,14 @@ static void __devexit ia_remove_one(struct pci_dev *pdev)
  	struct atm_dev *dev = pci_get_drvdata(pdev);
  	IADEV *iadev = INPH_IA_DEV(dev);

-	ia_phy_put(dev, ia_phy_get(dev,0x10) & ~(0x4), 0x10);
+	/* Disable phy interrupts */
+	ia_phy_put(dev, ia_phy_get(dev,
+			SUNI_RSOP_CIE) & ~(SUNI_RSOP_CIE_LOSE), SUNI_RSOP_CIE);
  	udelay(1);

+	if (dev->phy && dev->phy->stop)
+		dev->phy->stop(dev);
+
  	/* De-register device */
        	free_irq(iadev->irq, dev);
  	iadev_count--;
-- 


^ permalink raw reply related	[flat|nested] 5+ messages in thread

* Re: [PATCH][ATM] iphase: doesn't call phy->start due to a bogus #ifndef
  2008-06-05 16:17 [PATCH][ATM] iphase: doesn't call phy->start due to a bogus #ifndef Jorge Boncompte [DTI2]
@ 2008-06-14 21:24 ` Chas Williams (CONTRACTOR)
  2008-06-14 23:35   ` David Miller
  0 siblings, 1 reply; 5+ messages in thread
From: Chas Williams (CONTRACTOR) @ 2008-06-14 21:24 UTC (permalink / raw)
  To: jorge; +Cc: netdev

In message <4848117C.5040801@dti2.net>,"Jorge Boncompte [DTI2]" writes:
>	This causes the suni driver to oops if you try to use sonetdiag to
>get the statistics. Also add the corresponding phy->stop call to fix another
>oops if you try to remove the module.
>
>Signed-off-by: Jorge Boncompte [DTI2] <jorge@dti2.net>

looks good.  i will submit to davem with the next batch of atm patches.

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH][ATM] iphase: doesn't call phy->start due to a bogus #ifndef
  2008-06-14 21:24 ` Chas Williams (CONTRACTOR)
@ 2008-06-14 23:35   ` David Miller
  2008-06-14 23:45     ` Chas Williams (CONTRACTOR)
  0 siblings, 1 reply; 5+ messages in thread
From: David Miller @ 2008-06-14 23:35 UTC (permalink / raw)
  To: chas3, chas; +Cc: jorge, netdev

From: "Chas Williams (CONTRACTOR)" <chas@cmf.nrl.navy.mil>
Date: Sat, 14 Jun 2008 17:24:05 -0400

> i will submit to davem with the next batch of atm patches.

Please do so soon, I've been waiting (too) patiently.

All of those ATM patches have been sitting in my mailbox rotting, and
I easily could have applied them even while I was travelling
constantly for 3 weeks.

The only reason I didn't was to give you an opportunity to look at
them and give feedback.  But that feedback and submission needs to be
measured in days, not weeks.

Thanks.


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH][ATM] iphase: doesn't call phy->start due to a bogus #ifndef
  2008-06-14 23:35   ` David Miller
@ 2008-06-14 23:45     ` Chas Williams (CONTRACTOR)
  2008-06-14 23:59       ` David Miller
  0 siblings, 1 reply; 5+ messages in thread
From: Chas Williams (CONTRACTOR) @ 2008-06-14 23:45 UTC (permalink / raw)
  To: David Miller; +Cc: jorge, netdev

In message <20080614.163522.127295395.davem@davemloft.net>,David Miller writes:
>> i will submit to davem with the next batch of atm patches.
>
>Please do so soon, I've been waiting (too) patiently.

ok.  they would need to go on 2.6.27 though.  are you taking
those at the moment?

>All of those ATM patches have been sitting in my mailbox rotting, and
>I easily could have applied them even while I was travelling
>constantly for 3 weeks.

doubt it.  his mailer mangled them pretty good.

>The only reason I didn't was to give you an opportunity to look at
>them and give feedback.  But that feedback and submission needs to be
>measured in days, not weeks.

ok.  only 10 days actually. not quite weeks.

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH][ATM] iphase: doesn't call phy->start due to a bogus #ifndef
  2008-06-14 23:45     ` Chas Williams (CONTRACTOR)
@ 2008-06-14 23:59       ` David Miller
  0 siblings, 0 replies; 5+ messages in thread
From: David Miller @ 2008-06-14 23:59 UTC (permalink / raw)
  To: chas3, chas; +Cc: jorge, netdev

From: "Chas Williams (CONTRACTOR)" <chas@cmf.nrl.navy.mil>
Date: Sat, 14 Jun 2008 19:45:12 -0400

> In message <20080614.163522.127295395.davem@davemloft.net>,David Miller writes:
> >> i will submit to davem with the next batch of atm patches.
> >
> >Please do so soon, I've been waiting (too) patiently.
> 
> ok.  they would need to go on 2.6.27 though.  are you taking
> those at the moment?

Yes I am, but some of those changes are bug fixes and thus should be
submitted for 2.6.26

As I often indicate here, my two trees are:

	master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6.git

for "bug fix current release" stuff and:

	master.kernel.org:/pub/scm/linux/kernel/git/davem/net-next-2.6.git

for "features/cleanups bound for next release".

So please post those patches relative to that, as appropriate.

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2008-06-14 23:59 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-06-05 16:17 [PATCH][ATM] iphase: doesn't call phy->start due to a bogus #ifndef Jorge Boncompte [DTI2]
2008-06-14 21:24 ` Chas Williams (CONTRACTOR)
2008-06-14 23:35   ` David Miller
2008-06-14 23:45     ` Chas Williams (CONTRACTOR)
2008-06-14 23:59       ` David Miller

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).