Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/netbsd-1-5]: src/sys/netinet Pullup 1.41 [enami]:



details:   https://anonhg.NetBSD.org/src/rev/b8066656dc64
branches:  netbsd-1-5
changeset: 489755:b8066656dc64
user:      tv <tv%NetBSD.org@localhost>
date:      Tue Oct 17 00:46:09 2000 +0000

description:
Pullup 1.41 [enami]:
- Keep track of allhost multicast address record we joined into
  each in_ifaddr and delete it when an address is purged.
- Don't simply try to delete a multicast address record listed in the
  ia_multiaddrs.  It results a dangling pointer.  Let who holds a
  reference to it to delete it.

Also 1.40 [itojun, req by enami]:
implement multicast kludge table for IPv4.
- when all the interface address is removed from an interface, and there's
  multicast groups still left joined, keep it in kludge table.
- when an interface address is added again, recover multicast groups from
  kludge table.
this will avoid problem with dangling in_ifaddr on pcmcia card removal,
due to the link from multicast group info (in_multi).

diffstat:

 sys/netinet/in_var.h |  7 ++++++-
 1 files changed, 6 insertions(+), 1 deletions(-)

diffs (28 lines):

diff -r fc5a4fcecf11 -r b8066656dc64 sys/netinet/in_var.h
--- a/sys/netinet/in_var.h      Tue Oct 17 00:45:36 2000 +0000
+++ b/sys/netinet/in_var.h      Tue Oct 17 00:46:09 2000 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: in_var.h,v 1.39 2000/03/30 13:24:57 augustss Exp $     */
+/*     $NetBSD: in_var.h,v 1.39.4.1 2000/10/17 00:46:09 tv Exp $       */
 
 /*-
  * Copyright (c) 1998 The NetBSD Foundation, Inc.
@@ -100,6 +100,8 @@
 #define        ia_broadaddr    ia_dstaddr
        struct  sockaddr_in ia_sockmask; /* reserve space for general netmask */
        LIST_HEAD(, in_multi) ia_multiaddrs; /* list of multicast addresses */
+       struct  in_multi *ia_allhosts;  /* multicast address record for
+                                          the allhosts multicast group */
 };
 
 struct in_aliasreq {
@@ -304,6 +306,9 @@
 
 int    in_ifinit __P((struct ifnet *,
            struct in_ifaddr *, struct sockaddr_in *, int));
+void   in_savemkludge __P((struct in_ifaddr *));
+void   in_restoremkludge __P((struct in_ifaddr *, struct ifnet *));
+void   in_purgemkludge __P((struct ifnet *));
 struct in_multi *in_addmulti __P((struct in_addr *, struct ifnet *));
 void   in_delmulti __P((struct in_multi *));
 void   in_ifscrub __P((struct ifnet *, struct in_ifaddr *));



Home | Main Index | Thread Index | Old Index