mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH] Updated ATM patch for 2.4.19-pre4
@ 2002-03-23  1:15 Maksim Krasnyanskiy
  2002-03-23  1:54 ` Mr. James W. Laferriere
  2002-03-23 21:10 ` Francois Romieu
  0 siblings, 2 replies; 6+ messages in thread
From: Maksim Krasnyanskiy @ 2002-03-23  1:15 UTC (permalink / raw)
  To: linux kernel mailing list; +Cc: marcelo Tosatti, Alan

Marcelo, Alan,

I updated ATM patch for 2.4.19-pre4. It includes couple of fixes that I 
missed in my first patch
and includes ATM Ethernet bridging support (RFC2684) implemented by Marcell 
GAL.
It is rather big for email. Here is the URL:
         http://bluez.sourceforge.net/patches/atm.patch-2.4.19-pre4.gz

Please apply.
Thanks



Max

http://bluez.sf.net
http://vtun.sf.net


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

* Re: [PATCH] Updated ATM patch for 2.4.19-pre4
  2002-03-23  1:15 [PATCH] Updated ATM patch for 2.4.19-pre4 Maksim Krasnyanskiy
@ 2002-03-23  1:54 ` Mr. James W. Laferriere
  2002-03-23  1:58   ` Mr. James W. Laferriere
  2002-03-23 21:10 ` Francois Romieu
  1 sibling, 1 reply; 6+ messages in thread
From: Mr. James W. Laferriere @ 2002-03-23  1:54 UTC (permalink / raw)
  To: Maksim Krasnyanskiy; +Cc: linux kernel mailing list, marcelo Tosatti, Alan


	Hello Maksim ,  Could you please also cc:
	linux-atm@vger.kernel.org
	That is where the rest of the people that would be giving your
	patches a try listen .  More at bottom .  Tia ,  JimL

On Fri, 22 Mar 2002, Maksim Krasnyanskiy wrote:
> Marcelo, Alan,
> I updated ATM patch for 2.4.19-pre4. It includes couple of fixes that I
> missed in my first patch
> and includes ATM Ethernet bridging support (RFC2684) implemented by Marcell
> GAL.
> It is rather big for email. Here is the URL:
>          http://bluez.sourceforge.net/patches/atm.patch-2.4.19-pre4.gz
>
> Please apply.
> Thanks
> Max
>
> http://bluez.sf.net
> http://vtun.sf.net
  ^^^^^^^^^^^^^^^^^^ Cool !-) , IPSec available ?

       +------------------------------------------------------------------+
       | James   W.   Laferriere | System    Techniques | Give me VMS     |
       | Network        Engineer |     P.O. Box 854     |  Give me Linux  |
       | babydr@baby-dragons.com | Coudersport PA 16915 |   only  on  AXP |
       +------------------------------------------------------------------+


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

* Re: [PATCH] Updated ATM patch for 2.4.19-pre4
  2002-03-23  1:54 ` Mr. James W. Laferriere
@ 2002-03-23  1:58   ` Mr. James W. Laferriere
  0 siblings, 0 replies; 6+ messages in thread
From: Mr. James W. Laferriere @ 2002-03-23  1:58 UTC (permalink / raw)
  To: Maksim Krasnyanskiy; +Cc: linux kernel mailing list, marcelo Tosatti, Alan


	Hello Maksim & all ,  OOPS , Sorry .  Make that ...

	linux-atm-general@lists.sourceforge.net

On Fri, 22 Mar 2002, Mr. James W. Laferriere wrote:
> 	Hello Maksim ,  Could you please also cc:
> 	linux-atm@vger.kernel.org
> 	That is where the rest of the people that would be giving your
> 	patches a try listen .  More at bottom .  Tia ,  JimL

> On Fri, 22 Mar 2002, Maksim Krasnyanskiy wrote:
> > Marcelo, Alan,
> > I updated ATM patch for 2.4.19-pre4. It includes couple of fixes that I
> > missed in my first patch
> > and includes ATM Ethernet bridging support (RFC2684) implemented by Marcell
> > GAL.
> > It is rather big for email. Here is the URL:
> >          http://bluez.sourceforge.net/patches/atm.patch-2.4.19-pre4.gz
> >
> > Please apply.
> > Thanks
> > Max
> >
> > http://bluez.sf.net
> > http://vtun.sf.net
>   ^^^^^^^^^^^^^^^^^^ Cool !-) , IPSec available ?
>
>        +------------------------------------------------------------------+
>        | James   W.   Laferriere | System    Techniques | Give me VMS     |
>        | Network        Engineer |     P.O. Box 854     |  Give me Linux  |
>        | babydr@baby-dragons.com | Coudersport PA 16915 |   only  on  AXP |
>        +------------------------------------------------------------------+
>
>

       +------------------------------------------------------------------+
       | James   W.   Laferriere | System    Techniques | Give me VMS     |
       | Network        Engineer |     P.O. Box 854     |  Give me Linux  |
       | babydr@baby-dragons.com | Coudersport PA 16915 |   only  on  AXP |
       +------------------------------------------------------------------+



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

* Re: [PATCH] Updated ATM patch for 2.4.19-pre4
  2002-03-23  1:15 [PATCH] Updated ATM patch for 2.4.19-pre4 Maksim Krasnyanskiy
  2002-03-23  1:54 ` Mr. James W. Laferriere
@ 2002-03-23 21:10 ` Francois Romieu
  2002-03-24 21:06   ` Francois Romieu
  1 sibling, 1 reply; 6+ messages in thread
From: Francois Romieu @ 2002-03-23 21:10 UTC (permalink / raw)
  To: Maksim Krasnyanskiy; +Cc: linux kernel mailing list, marcelo Tosatti, Alan

Maksim Krasnyanskiy <maxk@qualcomm.com> :
[...]
> I updated ATM patch for 2.4.19-pre4. It includes couple of fixes that I 
> missed in my first patch
> and includes ATM Ethernet bridging support (RFC2684) implemented by Marcell 
> GAL.
> It is rather big for email. Here is the URL:
>          http://bluez.sourceforge.net/patches/atm.patch-2.4.19-pre4.gz

1 - It won't compile with CONFIG_ATM_BR2684_IPFILTER=y (see error message 
below). Suggested fix:
ed net/atm/br2684.c <<EOF
17a
#include <linux/ip.h>
.
wq
EOF

-> Error message:
make[2]: Entering directory `/tmp/romieu/kernel/linux-2.4.19-pre4/net/atm'
kgcc -D__KERNEL__ -I/tmp/romieu/kernel/linux-2.4.19-pre4/include -Wall
-Wstrict-prototypes -Wno-trigraphs -O2 -fomit-frame-pointer -fno-strict-aliasing
-fno-common -pipe  -march=i686 -DMODULE  -DKBUILD_BASENAME=br2684  -c -o
br2684.o br2684.c
br2684.c: In function `packet_fails_filter':
br2684.c:378: dereferencing pointer to incomplete type
make[2]: *** [br2684.o] Error 1
make[2]: Leaving directory `/tmp/romieu/kernel/linux-2.4.19-pre4/net/atm'
make[1]: *** [_modsubdir_atm] Error 2
make[1]: Leaving directory `/tmp/romieu/kernel/linux-2.4.19-pre4/net'
make: *** [_mod_net] Error 2

2 - As the patch does many things, splitting it in parts would be nice imho.

3 - I have on my TODO a 'please ifconfig down before killing br2684ctl' BUG
that Marcell Gal told me a few months ago (*spleen*). Did someone take care
of it ?

-- 
Ueimor

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

* Re: [PATCH] Updated ATM patch for 2.4.19-pre4
  2002-03-23 21:10 ` Francois Romieu
@ 2002-03-24 21:06   ` Francois Romieu
  2002-03-25 21:53     ` [Linux-ATM-General] " Maksim Krasnyanskiy
  0 siblings, 1 reply; 6+ messages in thread
From: Francois Romieu @ 2002-03-24 21:06 UTC (permalink / raw)
  To: Maksim Krasnyanskiy
  Cc: linux kernel mailing list, marcelo Tosatti, Alan, cell,
	linux-atm-general

[thread starts at:
http://www.cs.Helsinki.FI/linux/linux-kernel/2002-11/1311.html]

The following patch applies on top of Maksim's one. It:
- adds a missing include (hunk #1);
- turns a cast fiesta into the equivalent list_entry (hunk #2);
- unregisters net_device once it isn't needed for bridging (hunk #3);
- compiles and stands a kill-br2684ctl-before-ifconfig-down test: nas0 
  disappeared as it should.

Without the patch an oops happens, see:
<URL:http://www.cogenit.fr/linux/atm/oopses/text-6>

Comments welcome.

--- net/atm/br2684.c.orig	Sat Mar 23 21:21:41 2002
+++ net/atm/br2684.c	Sun Mar 24 21:42:30 2002
@@ -15,6 +15,7 @@ Author: Marcell GAL, 2000, XDSL Ltd, Hun
 #include <linux/etherdevice.h>
 #include <net/arp.h>
 #include <linux/rtnetlink.h>
+#include <linux/ip.h>
 #include <linux/atmbr2684.h>
 
 #include "ipcommon.h"
@@ -97,8 +98,7 @@ static LIST_HEAD(br2684_devs);
 
 static inline struct br2684_dev *BRPRIV(const struct net_device *net_dev)
 {
-	return (struct br2684_dev *) ((char *) (net_dev) -
-	    (unsigned long) (&((struct br2684_dev *) 0)->net_dev));
+	return list_entry(net_dev, struct br2684_dev, net_dev);
 }
 
 static inline struct br2684_dev *list_entry_brdev(const struct list_head *le)
@@ -410,6 +410,13 @@ static void br2684_push(struct atm_vcc *
 
 	if (skb == NULL) {	/* skb==NULL means VCC is being destroyed */
 		br2684_close_vcc(brvcc);
+		if (list_empty(&brdev->brvccs)) {
+			read_lock(&devs_lock);
+			list_del(&brdev->br2684_devs);
+			read_unlock(&devs_lock);
+			unregister_netdev(&brdev->net_dev);
+			kfree(brdev);
+		}
 		return;
 	}
 
-- 
Ueimor

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

* Re: [Linux-ATM-General] Re: [PATCH] Updated ATM patch for 2.4.19-pre4
  2002-03-24 21:06   ` Francois Romieu
@ 2002-03-25 21:53     ` Maksim Krasnyanskiy
  0 siblings, 0 replies; 6+ messages in thread
From: Maksim Krasnyanskiy @ 2002-03-25 21:53 UTC (permalink / raw)
  To: Francois Romieu
  Cc: linux kernel mailing list, marcelo Tosatti, Alan, cell,
	linux-atm-general


>Comments welcome.
Looks ok to me.

>  static inline struct br2684_dev *BRPRIV(const struct net_device *net_dev)
>  {
>-       return (struct br2684_dev *) ((char *) (net_dev) -
>-           (unsigned long) (&((struct br2684_dev *) 0)->net_dev));
>+       return list_entry(net_dev, struct br2684_dev, net_dev);
>  }
Although list_entry does the same thing it's inappropriate here. People 
will be confused.

Max


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

end of thread, other threads:[~2002-03-25 21:55 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2002-03-23  1:15 [PATCH] Updated ATM patch for 2.4.19-pre4 Maksim Krasnyanskiy
2002-03-23  1:54 ` Mr. James W. Laferriere
2002-03-23  1:58   ` Mr. James W. Laferriere
2002-03-23 21:10 ` Francois Romieu
2002-03-24 21:06   ` Francois Romieu
2002-03-25 21:53     ` [Linux-ATM-General] " Maksim Krasnyanskiy

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®