Net-Tools 1.53 update for new token ring type

Mike Phillips (phillim@amtrak.com)
Fri, 10 Dec 1999 10:34:32 -0500


This is a MIME message. If you are reading this text, you may want to
consider changing to a mail reader or gateway that understands how to
properly handle MIME multipart messages.

--=_732A1750.89E88EC4
Content-Type: text/plain; charset=US-ASCII
Content-Transfer-Encoding: quoted-printable
Content-Disposition: inline

> > Ok, the first patch looks kosher, but does the second patch require =
2.3.xx
> > kernels?
> No, it changes /usr/include/if_arp.h, not /usr/src/linux/include/linux

> > I bounce betwixt 2.2.xx (14pre12) and 2.3.30, so I'd like to have =
bi-lingual
> > net-tools if at all possible.
> Not with the simple patch I produced, now I know what they other problem =
is (smp > dies, up doesn't), I'll try to work up a patch that will work =
with both kernel versions.

Attached is the diff against net-tools-1.53. This should allow ifconfig =
to work with both the old TR type (2.2.x) and the new TR type (2.3.x).=20

You'll still need the other patch for /usr/include/net/if_arp.h.

Mike

--=_732A1750.89E88EC4
Content-Type: text/plain
Content-Disposition: attachment; filename="NTTR.PAT"
Content-Description: WordPerfect 4.2

diff -urN net-tools-1.53/lib/hw.c net-tools.mlp/lib/hw.c
--- net-tools-1.53/lib/hw.c Sat Aug 28 07:36:18 1999
+++ net-tools.mlp/lib/hw.c Fri Dec 10 11:08:30 1999
@@ -19,6 +19,7 @@
*/
#include <sys/types.h>
#include <sys/socket.h>
+#include <net/if_arp.h>
#include <stdlib.h>
#include <stdio.h>
#include <errno.h>
@@ -43,6 +44,9 @@
extern struct hwtype fddi_hwtype;
extern struct hwtype hippi_hwtype;
extern struct hwtype tr_hwtype;
+#ifdef ARPHRD_IEEE802_TR
+extern struct hwtype tr_hwtype1;
+#endif

extern struct hwtype ax25_hwtype;
extern struct hwtype rose_hwtype;
@@ -87,6 +91,9 @@
#endif
#if HAVE_HWTR
&tr_hwtype,
+#ifdef ARPHRD_IEEE802_TR
+ &tr_hwtype1,
+#endif
#endif
#if HAVE_HWAX25
&ax25_hwtype,
@@ -192,6 +199,9 @@
#endif
#if HAVE_HWTR
tr_hwtype.title = _("16/4 Mbps Token Ring");
+#ifdef ARPHRD_IEEE802_TR
+ tr_hwtype1.title = _("16/4 Mbps Token Ring (New)") ;
+#endif
#endif
#if HAVE_HWEC
ec_hwtype.title = _("Econet");
diff -urN net-tools-1.53/lib/tr.c net-tools.mlp/lib/tr.c
--- net-tools-1.53/lib/tr.c Sat Aug 28 07:36:18 1999
+++ net-tools.mlp/lib/tr.c Fri Dec 10 11:06:28 1999
@@ -19,7 +19,7 @@
#include <asm/types.h>
#include <sys/types.h>
#include <sys/socket.h>
-#include <net/if_arp.h>
+#include <net/if_arp.h>
#include <linux/if_tr.h>
#include <stdlib.h>
#include <stdio.h>
@@ -132,6 +132,13 @@
"tr", NULL /* "16/4 Mbps Token Ring" */, ARPHRD_IEEE802, TR_ALEN,
pr_tr, pr_str, in_tr, NULL
};
+#ifdef ARPHRD_IEEE802_TR
+struct hwtype tr_hwtype1 =
+{
+ "tr", NULL /* "16/4 Mbps Token Ring" */, ARPHRD_IEEE802_TR, TR_ALEN,
+ pr_tr, pr_str, in_tr, NULL
+};
+#endif


#endif /* HAVE_HWTR */
diff -urN net-tools-1.53/version.h net-tools.mlp/version.h
--- net-tools-1.53/version.h Wed Dec 31 19:00:00 1969
+++ net-tools.mlp/version.h Wed Dec 8 13:42:06 1999
@@ -0,0 +1 @@
+#define RELEASE "net-tools 1.53"

--=_732A1750.89E88EC4--

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/