PERFORCE change 51689 for review
Marcel Moolenaar
marcel at FreeBSD.org
Sat Apr 24 21:41:58 PDT 2004
http://perforce.freebsd.org/chv.cgi?CH=51689
Change 51689 by marcel at marcel_nfs on 2004/04/24 21:41:06
IFC @51688
Affected files ...
.. //depot/projects/gdb/lib/msun/src/math.h#3 integrate
.. //depot/projects/gdb/sys/alpha/include/float.h#3 integrate
.. //depot/projects/gdb/sys/amd64/include/float.h#3 integrate
.. //depot/projects/gdb/sys/conf/NOTES#16 integrate
.. //depot/projects/gdb/sys/conf/files#19 integrate
.. //depot/projects/gdb/sys/conf/options#15 integrate
.. //depot/projects/gdb/sys/dev/uart/uart_dev_sab82532.c#2 integrate
.. //depot/projects/gdb/sys/dev/vinum/vinumio.c#4 integrate
.. //depot/projects/gdb/sys/i386/include/float.h#3 integrate
.. //depot/projects/gdb/sys/ia64/include/float.h#3 integrate
.. //depot/projects/gdb/sys/isa/fd.c#6 integrate
.. //depot/projects/gdb/sys/kern/kern_timeout.c#5 integrate
.. //depot/projects/gdb/sys/net/bridge.c#4 integrate
.. //depot/projects/gdb/sys/net/if.c#8 integrate
.. //depot/projects/gdb/sys/net/if_ethersubr.c#9 integrate
.. //depot/projects/gdb/sys/net/if_fddisubr.c#6 integrate
.. //depot/projects/gdb/sys/net/if_iso88025subr.c#5 integrate
.. //depot/projects/gdb/sys/net/if_vlan.c#2 integrate
.. //depot/projects/gdb/sys/net/route.c#8 integrate
.. //depot/projects/gdb/sys/net/route.h#7 integrate
.. //depot/projects/gdb/sys/powerpc/include/float.h#4 integrate
.. //depot/projects/gdb/sys/sparc64/include/float.h#3 integrate
.. //depot/projects/gdb/sys/sparc64/pci/psycho.c#3 integrate
.. //depot/projects/gdb/sys/sparc64/pci/psychoreg.h#2 integrate
.. //depot/projects/gdb/sys/sparc64/pci/psychovar.h#2 integrate
.. //depot/projects/gdb/sys/sparc64/sparc64/iommu.c#4 integrate
.. //depot/projects/gdb/sys/vm/phys_pager.c#2 integrate
Differences ...
==== //depot/projects/gdb/lib/msun/src/math.h#3 (text+ko) ====
@@ -11,7 +11,7 @@
/*
* from: @(#)fdlibm.h 5.1 93/09/24
- * $FreeBSD: src/lib/msun/src/math.h,v 1.29 2004/03/12 12:05:38 bde Exp $
+ * $FreeBSD: src/lib/msun/src/math.h,v 1.31 2004/04/25 02:35:42 das Exp $
*/
#ifndef _MATH_H_
@@ -32,19 +32,19 @@
float __uf;
} __nan;
+#define HUGE_VAL (__infinity.__ud)
+
+#if __ISO_C_VISIBLE >= 1999
#define FP_ILOGB0 (-0x7fffffff - 1) /* INT_MIN */
#define FP_ILOGBNAN 0x7fffffff /* INT_MAX */
-#define HUGE_VAL (__infinity.__ud)
#define HUGE_VALF (float)HUGE_VAL
#define HUGE_VALL (long double)HUGE_VAL
#define INFINITY HUGE_VALF
#define NAN (__nan.__uf)
-#if __ISO_C_VISIBLE >= 1999
#define MATH_ERRNO 1
#define MATH_ERREXCEPT 2
#define math_errhandling 0
-#endif
/* Symbolic constants to classify floating point numbers. */
#define FP_INFINITE 0x01
@@ -60,7 +60,6 @@
#define isfinite(x) ((fpclassify(x) & (FP_INFINITE|FP_NAN)) == 0)
#define isinf(x) (fpclassify(x) == FP_INFINITE)
#define isnan(x) (fpclassify(x) == FP_NAN)
-#define isnanf(x) isnan(x)
#define isnormal(x) (fpclassify(x) == FP_NORMAL)
#define isgreater(x, y) (!isunordered((x), (y)) && (x) > (y))
@@ -75,11 +74,12 @@
typedef __double_t double_t;
typedef __float_t float_t;
+#endif /* __ISO_C_VISIBLE >= 1999 */
/*
* XOPEN/SVID
*/
-#if !defined(_ANSI_SOURCE) && !defined(_POSIX_SOURCE)
+#if __BSD_VISIBLE || __XSI_VISIBLE
#define M_E 2.7182818284590452354 /* e */
#define M_LOG2E 1.4426950408889634074 /* log 2e */
#define M_LOG10E 0.43429448190325182765 /* log 10e */
@@ -96,8 +96,9 @@
#define MAXFLOAT ((float)3.40282346638528860e+38)
extern int signgam;
+#endif /* __BSD_VISIBLE || __XSI_VISIBLE */
-#if !defined(_XOPEN_SOURCE)
+#if __BSD_VISIBLE
enum fdversion {fdlibm_ieee = -1, fdlibm_svid, fdlibm_xopen, fdlibm_posix};
#define _LIB_VERSION_TYPE enum fdversion
@@ -129,6 +130,8 @@
};
#endif
+#define isnanf(x) isnan(x)
+
#if 0
/* Old value from 4.4BSD-Lite math.h; this is probably better. */
#define HUGE HUGE_VAL
@@ -136,13 +139,8 @@
#define HUGE MAXFLOAT
#endif
-/*
- * set X_TLOSS = pi*2**52, which is possibly defined in <values.h>
- * (one may replace the following line by "#include <values.h>")
- */
+#define X_TLOSS 1.41484755040568800000e+16 /* pi*2**52 */
-#define X_TLOSS 1.41484755040568800000e+16
-
#define DOMAIN 1
#define SING 2
#define OVERFLOW 3
@@ -150,8 +148,7 @@
#define TLOSS 5
#define PLOSS 6
-#endif /* !_XOPEN_SOURCE */
-#endif /* !_ANSI_SOURCE && !_POSIX_SOURCE */
+#endif /* __BSD_VISIBLE */
#include <sys/cdefs.h>
@@ -202,65 +199,70 @@
* These functions are not in C90 so they can be "right". The ones that
* never set errno in lib/msun are declared as __pure2.
*/
-#if !defined(_ANSI_SOURCE) && !defined(_POSIX_SOURCE)
+#if __BSD_VISIBLE || __ISO_C_VISIBLE >= 1999 || __XSI_VISIBLE
+double acosh(double);
+double asinh(double);
+double atanh(double);
+double cbrt(double) __pure2;
double erf(double);
double erfc(double) __pure2;
-int finite(double) __pure2;
-double gamma(double);
+double expm1(double) __pure2;
double hypot(double, double);
+int ilogb(double);
+double lgamma(double);
+double log1p(double) __pure2;
+double logb(double) __pure2;
+double nextafter(double, double);
+double remainder(double, double);
+double rint(double) __pure2;
+#endif /* __BSD_VISIBLE || __ISO_C_VISIBLE >= 1999 || __XSI_VISIBLE */
+
+#if __BSD_VISIBLE || __XSI_VISIBLE
double j0(double);
double j1(double);
double jn(int, double);
-double lgamma(double);
+double scalb(double, double);
double y0(double);
double y1(double);
double yn(int, double);
-#if !defined(_XOPEN_SOURCE)
-double acosh(double);
-double asinh(double);
-double atanh(double);
-double cbrt(double) __pure2;
-double logb(double) __pure2;
-double nextafter(double, double);
-double remainder(double, double);
-double scalb(double, double);
-double tgamma(double);
-
-#ifndef __cplusplus
-int matherr(struct exception *);
+#if __XSI_VISIBLE <= 500 || __BSD_VISIBLE
+double gamma(double);
#endif
+#endif /* __BSD_VISIBLE || __XSI_VISIBLE */
-/*
- * IEEE Test Vector
- */
-double significand(double);
-
-/*
- * Functions callable from C, intended to support IEEE arithmetic.
- */
+#if __BSD_VISIBLE || __ISO_C_VISIBLE >= 1999
double copysign(double, double) __pure2;
-int ilogb(double);
-double rint(double) __pure2;
double scalbn(double, int);
+double tgamma(double);
+#endif
/*
* BSD math library entry points
*/
+#if __BSD_VISIBLE
double drem(double, double);
-double expm1(double) __pure2;
-double log1p(double) __pure2;
+int finite(double) __pure2;
/*
* Reentrant version of gamma & lgamma; passes signgam back by reference
* as the second argument; user must allocate space for signgam.
*/
-#if __BSD_VISIBLE
double gamma_r(double, int *);
double lgamma_r(double, int *);
+
+/*
+ * IEEE Test Vector
+ */
+double significand(double);
+
+#ifndef __cplusplus
+int matherr(struct exception *);
+#endif
#endif /* __BSD_VISIBLE */
/* float versions of ANSI/POSIX functions */
+#if __ISO_C_VISIBLE >= 1999
float acosf(float);
float asinf(float);
float atanf(float);
@@ -274,10 +276,13 @@
float tanhf(float);
float expf(float);
+float expm1f(float) __pure2;
float frexpf(float, int *); /* fundamentally !__pure2 */
+int ilogbf(float);
float ldexpf(float, int);
+float log10f(float);
+float log1pf(float) __pure2;
float logf(float);
-float log10f(float);
float modff(float, float *); /* fundamentally !__pure2 */
float powf(float, float);
@@ -290,60 +295,54 @@
float erff(float);
float erfcf(float) __pure2;
-int finitef(float) __pure2;
-float gammaf(float);
float hypotf(float, float) __pure2;
-float j0f(float);
-float j1f(float);
-float jnf(int, float);
float lgammaf(float);
-float y0f(float);
-float y1f(float);
-float ynf(int, float);
float acoshf(float);
float asinhf(float);
float atanhf(float);
float cbrtf(float) __pure2;
float logbf(float) __pure2;
+float copysignf(float, float) __pure2;
float nextafterf(float, float);
float remainderf(float, float);
-float scalbf(float, float);
-
-/*
- * float version of IEEE Test Vector
- */
-float significandf(float);
-
-/*
- * Float versions of functions callable from C, intended to support
- * IEEE arithmetic.
- */
-float copysignf(float, float) __pure2;
-int ilogbf(float);
float rintf(float);
float scalbnf(float, int);
+#endif
/*
* float versions of BSD math library entry points
*/
+#if __BSD_VISIBLE
float dremf(float, float);
-float expm1f(float) __pure2;
-float log1pf(float) __pure2;
+int finitef(float) __pure2;
+float gammaf(float);
+float j0f(float);
+float j1f(float);
+float jnf(int, float);
+float scalbf(float, float);
+float y0f(float);
+float y1f(float);
+float ynf(int, float);
/*
* Float versions of reentrant version of gamma & lgamma; passes
* signgam back by reference as the second argument; user must
* allocate space for signgam.
*/
-#if __BSD_VISIBLE
float gammaf_r(float, int *);
float lgammaf_r(float, int *);
+
+/*
+ * float version of IEEE Test Vector
+ */
+float significandf(float);
#endif /* __BSD_VISIBLE */
/*
* long double versions of ISO/POSIX math functions
*/
+#if __ISO_C_VISIBLE >= 1999
#if 0
long double acoshl(long double);
long double acosl(long double);
@@ -408,8 +407,7 @@
long double truncl(long double);
#endif
-#endif /* !_XOPEN_SOURCE */
-#endif /* !_ANSI_SOURCE && !_POSIX_SOURCE */
+#endif /* __ISO_C_VISIBLE >= 1999 */
__END_DECLS
#endif /* !_MATH_H_ */
==== //depot/projects/gdb/sys/alpha/include/float.h#3 (text+ko) ====
@@ -1,4 +1,4 @@
-/* $FreeBSD: src/sys/alpha/include/float.h,v 1.5 2004/04/05 21:00:50 imp Exp $ */
+/* $FreeBSD: src/sys/alpha/include/float.h,v 1.6 2004/04/25 02:36:28 das Exp $ */
/* From: NetBSD: float.h,v 1.6 1997/07/17 21:36:03 thorpej Exp */
/*
@@ -41,8 +41,10 @@
#define FLT_RADIX 2 /* b */
#define FLT_ROUNDS __flt_rounds()
+#if __ISO_C_VISIBLE >= 1999
#define FLT_EVAL_METHOD 0 /* no promotions */
#define DECIMAL_DIG 17 /* max precision in decimal digits */
+#endif
#define FLT_MANT_DIG 24 /* p */
#define FLT_EPSILON 1.19209290E-07F /* b**(1-p) */
==== //depot/projects/gdb/sys/amd64/include/float.h#3 (text+ko) ====
@@ -27,16 +27,20 @@
* SUCH DAMAGE.
*
* from: @(#)float.h 7.1 (Berkeley) 5/8/90
- * $FreeBSD: src/sys/amd64/include/float.h,v 1.11 2004/04/05 21:25:51 imp Exp $
+ * $FreeBSD: src/sys/amd64/include/float.h,v 1.12 2004/04/25 02:36:28 das Exp $
*/
#ifndef _MACHINE_FLOAT_H_
#define _MACHINE_FLOAT_H_ 1
+#include <sys/cdefs.h>
+
#define FLT_RADIX 2 /* b */
#define FLT_ROUNDS 1 /* FP addition rounds to nearest */
+#if __ISO_C_VISIBLE >= 1999
#define FLT_EVAL_METHOD (-1) /* i387 semantics are...interesting */
#define DECIMAL_DIG 21 /* max precision in decimal digits */
+#endif
#define FLT_MANT_DIG 24 /* p */
#define FLT_EPSILON 1.19209290E-07F /* b**(1-p) */
==== //depot/projects/gdb/sys/conf/NOTES#16 (text+ko) ====
@@ -1,4 +1,4 @@
-# $FreeBSD: src/sys/conf/NOTES,v 1.1220 2004/04/23 19:48:43 emax Exp $
+# $FreeBSD: src/sys/conf/NOTES,v 1.1221 2004/04/24 22:03:01 rik Exp $
#
# NOTES -- Lines that can be cut/pasted into kernel and hints configs.
#
@@ -427,6 +427,7 @@
options NETGRAPH_RFC1490
options NETGRAPH_SOCKET
options NETGRAPH_SPLIT
+options NETGRAPH_SPPP
options NETGRAPH_TEE
options NETGRAPH_TTY
options NETGRAPH_UI
==== //depot/projects/gdb/sys/conf/files#19 (text+ko) ====
@@ -1,4 +1,4 @@
-# $FreeBSD: src/sys/conf/files,v 1.889 2004/04/23 19:48:43 emax Exp $
+# $FreeBSD: src/sys/conf/files,v 1.890 2004/04/24 22:03:02 rik Exp $
#
# The long compile-with and dependency lines are required because of
# limitations in config: backslash-newline doesn't work in strings, and
@@ -1408,6 +1408,7 @@
netgraph/ng_rfc1490.c optional netgraph_rfc1490
netgraph/ng_socket.c optional netgraph_socket
netgraph/ng_split.c optional netgraph_split
+netgraph/ng_sppp.c optional netgraph_sppp
netgraph/ng_tee.c optional netgraph_tee
netgraph/ng_tty.c optional netgraph_tty
netgraph/ng_vjc.c optional netgraph_vjc
==== //depot/projects/gdb/sys/conf/options#15 (text+ko) ====
@@ -1,4 +1,4 @@
-# $FreeBSD: src/sys/conf/options,v 1.443 2004/04/23 19:48:43 emax Exp $
+# $FreeBSD: src/sys/conf/options,v 1.444 2004/04/24 22:03:02 rik Exp $
#
# On the handling of kernel options
#
@@ -377,6 +377,7 @@
NETGRAPH_RFC1490 opt_netgraph.h
NETGRAPH_SOCKET opt_netgraph.h
NETGRAPH_SPLIT opt_netgraph.h
+NETGRAPH_SPPP opt_netgraph.h
NETGRAPH_TEE opt_netgraph.h
NETGRAPH_TTY opt_netgraph.h
NETGRAPH_UI opt_netgraph.h
==== //depot/projects/gdb/sys/dev/uart/uart_dev_sab82532.c#2 (text+ko) ====
@@ -25,7 +25,7 @@
*/
#include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/dev/uart/uart_dev_sab82532.c,v 1.5 2003/09/26 05:14:56 marcel Exp $");
+__FBSDID("$FreeBSD: src/sys/dev/uart/uart_dev_sab82532.c,v 1.6 2004/04/25 04:30:40 marcel Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@@ -252,7 +252,7 @@
sab82532_param(bas, baudrate, databits, stopbits, parity);
/* Clear interrupts. */
- uart_setreg(bas, SAB_IMR0, 0xff);
+ uart_setreg(bas, SAB_IMR0, (unsigned char)~SAB_IMR0_TCD);
uart_setreg(bas, SAB_IMR1, 0xff);
uart_barrier(bas);
uart_getreg(bas, SAB_ISR0);
==== //depot/projects/gdb/sys/dev/vinum/vinumio.c#4 (text+ko) ====
@@ -34,7 +34,7 @@
* advised of the possibility of such damage.
*
* $Id: vinumio.c,v 1.39 2003/05/23 00:59:53 grog Exp grog $
- * $FreeBSD: src/sys/dev/vinum/vinumio.c,v 1.97 2004/03/11 14:11:08 le Exp $
+ * $FreeBSD: src/sys/dev/vinum/vinumio.c,v 1.98 2004/04/24 23:41:21 le Exp $
*/
#include <dev/vinum/vinumhdr.h>
@@ -878,6 +878,7 @@
drive->flags |= VF_CONFIGURED; /* this drive's configuration is complete */
}
+ Free(config_line);
Free(config_text);
Free(drivelist);
vinum_conf.flags &= ~VF_READING_CONFIG; /* no longer reading from disk */
==== //depot/projects/gdb/sys/i386/include/float.h#3 (text+ko) ====
@@ -27,16 +27,20 @@
* SUCH DAMAGE.
*
* from: @(#)float.h 7.1 (Berkeley) 5/8/90
- * $FreeBSD: src/sys/i386/include/float.h,v 1.11 2004/04/07 20:46:05 imp Exp $
+ * $FreeBSD: src/sys/i386/include/float.h,v 1.12 2004/04/25 02:36:28 das Exp $
*/
#ifndef _MACHINE_FLOAT_H_
#define _MACHINE_FLOAT_H_ 1
+#include <sys/cdefs.h>
+
#define FLT_RADIX 2 /* b */
#define FLT_ROUNDS 1 /* FP addition rounds to nearest */
+#if __ISO_C_VISIBLE >= 1999
#define FLT_EVAL_METHOD (-1) /* i387 semantics are...interesting */
#define DECIMAL_DIG 21 /* max precision in decimal digits */
+#endif
#define FLT_MANT_DIG 24 /* p */
#define FLT_EPSILON 1.19209290E-07F /* b**(1-p) */
==== //depot/projects/gdb/sys/ia64/include/float.h#3 (text+ko) ====
@@ -1,4 +1,4 @@
-/* $FreeBSD: src/sys/ia64/include/float.h,v 1.5 2004/04/07 20:46:07 imp Exp $ */
+/* $FreeBSD: src/sys/ia64/include/float.h,v 1.6 2004/04/25 02:36:29 das Exp $ */
/* From: NetBSD: float.h,v 1.6 1997/07/17 21:36:03 thorpej Exp */
/*
@@ -37,8 +37,10 @@
#define FLT_RADIX 2 /* b */
#define FLT_ROUNDS 1 /* FP addition rounds to nearest */
+#if __ISO_C_VISIBLE >= 1999
#define FLT_EVAL_METHOD 0 /* no promotions */
#define DECIMAL_DIG 35 /* max precision in decimal digits */
+#endif
#define FLT_MANT_DIG 24 /* p */
#define FLT_EPSILON 1.19209290E-07F /* b**(1-p) */
==== //depot/projects/gdb/sys/isa/fd.c#6 (text+ko) ====
@@ -49,7 +49,7 @@
*/
#include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/isa/fd.c,v 1.269 2004/04/07 20:46:08 imp Exp $");
+__FBSDID("$FreeBSD: src/sys/isa/fd.c,v 1.270 2004/04/25 04:33:56 bde Exp $");
#include "opt_fdc.h"
#include "card.h"
@@ -2600,9 +2600,16 @@
return (0);
case FD_STYPE: /* set drive type */
- if (suser(td) != 0)
- return (EPERM);
+ /*
+ * Allow setting drive type temporarily iff
+ * currently unset. Used for fdformat so any
+ * user can set it, and then start formatting.
+ */
+ if (fd->ft)
+ return (EINVAL); /* already set */
fd->fts[0] = *(struct fd_type *)addr;
+ fd->ft = &fd->fts[0];
+ fd->flags |= FD_UA;
return (0);
case FD_GOPTS: /* get drive options */
==== //depot/projects/gdb/sys/kern/kern_timeout.c#5 (text+ko) ====
@@ -35,7 +35,7 @@
*/
#include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/kern/kern_timeout.c,v 1.88 2004/04/20 15:49:30 cperciva Exp $");
+__FBSDID("$FreeBSD: src/sys/kern/kern_timeout.c,v 1.89 2004/04/25 04:10:17 hmp Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@@ -160,7 +160,7 @@
* George Varghese, published in a technical report entitled "Redesigning
* the BSD Callout and Timer Facilities" and modified slightly for inclusion
* in FreeBSD by Justin T. Gibbs. The original work on the data structures
- * used in this implementation was published by G.Varghese and A. Lauck in
+ * used in this implementation was published by G. Varghese and T. Lauck in
* the paper "Hashed and Hierarchical Timing Wheels: Data Structures for
* the Efficient Implementation of a Timer Facility" in the Proceedings of
* the 11th ACM Annual Symposium on Operating Systems Principles,
==== //depot/projects/gdb/sys/net/bridge.c#4 (text+ko) ====
@@ -24,7 +24,7 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
- * $FreeBSD: src/sys/net/bridge.c,v 1.76 2004/02/25 19:55:27 mlaier Exp $
+ * $FreeBSD: src/sys/net/bridge.c,v 1.77 2004/04/24 22:11:13 luigi Exp $
*/
/*
@@ -99,15 +99,16 @@
#include <sys/kernel.h>
#include <sys/sysctl.h>
+#include <net/ethernet.h>
#include <net/if.h>
+#include <net/if_arp.h> /* for struct arpcom */
#include <net/if_types.h>
#include <net/if_var.h>
-#include <netinet/in.h> /* for struct arpcom */
+#include <netinet/in.h>
#include <netinet/in_systm.h>
#include <netinet/in_var.h>
#include <netinet/ip.h>
-#include <netinet/if_ether.h> /* for struct arpcom */
#ifdef PFIL_HOOKS
#include <net/pfil.h>
@@ -299,7 +300,7 @@
* updating pointers in ifp2sc.
*/
static struct cluster_softc *
-add_cluster(u_int16_t cluster_id, struct arpcom *ac)
+add_cluster(u_int16_t cluster_id, struct ifnet *ifp)
{
struct cluster_softc *c = NULL;
int i;
@@ -353,7 +354,7 @@
n_clusters++;
found:
c = clusters + i; /* the right cluster ... */
- ETHER_ADDR_COPY(c->my_macs[c->ports].etheraddr, ac->ac_enaddr);
+ ETHER_ADDR_COPY(c->my_macs[c->ports].etheraddr, IFP2AC(ifp)->ac_enaddr);
c->ports++;
return c;
bad:
@@ -532,7 +533,7 @@
printf("%s already used, skipping\n", ifp->if_xname);
break;
}
- b->cluster = add_cluster(htons(cluster), (struct arpcom *)ifp);
+ b->cluster = add_cluster(htons(cluster), ifp);
b->flags |= IFF_USED ;
snprintf(bdg_stats.s[ifp->if_index].name,
sizeof(bdg_stats.s[ifp->if_index].name),
==== //depot/projects/gdb/sys/net/if.c#8 (text+ko) ====
@@ -27,7 +27,7 @@
* SUCH DAMAGE.
*
* @(#)if.c 8.5 (Berkeley) 1/9/95
- * $FreeBSD: src/sys/net/if.c,v 1.190 2004/04/19 17:28:15 luigi Exp $
+ * $FreeBSD: src/sys/net/if.c,v 1.191 2004/04/24 22:24:48 luigi Exp $
*/
#include "opt_compat.h"
@@ -319,7 +319,7 @@
case IFT_ISO88025:
case IFT_L2VLAN:
snprintf(eaddr, 18, "%6D",
- ((struct arpcom *)ifp->if_softc)->ac_enaddr, ":");
+ IFP2AC(ifp)->ac_enaddr, ":");
break;
default:
eaddr[0] = '\0';
@@ -1979,7 +1979,7 @@
case IFT_XETHER:
case IFT_ISO88025:
case IFT_L2VLAN:
- bcopy(lladdr, ((struct arpcom *)ifp->if_softc)->ac_enaddr, len);
+ bcopy(lladdr, IFP2AC(ifp)->ac_enaddr, len);
/*
* XXX We also need to store the lladdr in LLADDR(sdl),
* which is done below. This is a pain because we must
==== //depot/projects/gdb/sys/net/if_ethersubr.c#9 (text+ko) ====
@@ -27,7 +27,7 @@
* SUCH DAMAGE.
*
* @(#)if_ethersubr.c 8.1 (Berkeley) 6/10/93
- * $FreeBSD: src/sys/net/if_ethersubr.c,v 1.167 2004/04/18 11:01:15 luigi Exp $
+ * $FreeBSD: src/sys/net/if_ethersubr.c,v 1.168 2004/04/24 21:59:41 luigi Exp $
*/
#include "opt_atalk.h"
@@ -138,7 +138,6 @@
struct ether_header *eh;
int loop_copy = 0;
int hlen; /* link layer header length */
- struct arpcom *ac = IFP2AC(ifp);
#ifdef MAC
error = mac_check_ifnet_transmit(ifp, m);
@@ -193,7 +192,7 @@
#endif
#ifdef INET6
case AF_INET6:
- if (!nd6_storelladdr(&ac->ac_if, rt, m, dst, (u_char *)edst)) {
+ if (!nd6_storelladdr(ifp, rt, m, dst, (u_char *)edst)) {
/* Something bad happened */
return(0);
}
@@ -220,7 +219,7 @@
if ((aa = at_ifawithnet((struct sockaddr_at *)dst)) == NULL) {
goto bad;
}
- if (!aarpresolve(ac, m, (struct sockaddr_at *)dst, edst))
+ if (!aarpresolve(IFP2AC(ifp), m, (struct sockaddr_at *)dst, edst))
return (0);
/*
* In the phase 2 case, need to prepend an mbuf for the llc header.
@@ -280,7 +279,7 @@
(void)memcpy(eh->ether_shost, esrc,
sizeof(eh->ether_shost));
else
- (void)memcpy(eh->ether_shost, ac->ac_enaddr,
+ (void)memcpy(eh->ether_shost, IFP2AC(ifp)->ac_enaddr,
sizeof(eh->ether_shost));
/*
==== //depot/projects/gdb/sys/net/if_fddisubr.c#6 (text+ko) ====
@@ -33,7 +33,7 @@
* SUCH DAMAGE.
*
* from: if_ethersubr.c,v 1.5 1994/12/13 22:31:45 wollman Exp
- * $FreeBSD: src/sys/net/if_fddisubr.c,v 1.92 2004/04/18 11:01:15 luigi Exp $
+ * $FreeBSD: src/sys/net/if_fddisubr.c,v 1.93 2004/04/24 21:59:41 luigi Exp $
*/
#include "opt_atalk.h"
@@ -119,7 +119,6 @@
u_char esrc[FDDI_ADDR_LEN], edst[FDDI_ADDR_LEN];
struct rtentry *rt;
struct fddi_header *fh;
- struct arpcom *ac = IFP2AC(ifp);
#ifdef MAC
error = mac_check_ifnet_transmit(ifp, m);
@@ -192,7 +191,7 @@
#ifdef NETATALK
case AF_APPLETALK: {
struct at_ifaddr *aa;
- if (!aarpresolve(ac, m, (struct sockaddr_at *)dst, edst))
+ if (!aarpresolve(IFP2AC(ifp), m, (struct sockaddr_at *)dst, edst))
return (0);
/*
* ifaddr is the first thing in at_ifaddr
@@ -314,7 +313,7 @@
if (hdrcmplt)
bcopy((caddr_t)esrc, (caddr_t)fh->fddi_shost, FDDI_ADDR_LEN);
else
- bcopy((caddr_t)ac->ac_enaddr, (caddr_t)fh->fddi_shost,
+ bcopy(IFP2AC(ifp)->ac_enaddr, (caddr_t)fh->fddi_shost,
FDDI_ADDR_LEN);
/*
==== //depot/projects/gdb/sys/net/if_iso88025subr.c#5 (text+ko) ====
@@ -30,7 +30,7 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
- * $FreeBSD: src/sys/net/if_iso88025subr.c,v 1.62 2004/04/18 01:15:32 luigi Exp $
+ * $FreeBSD: src/sys/net/if_iso88025subr.c,v 1.63 2004/04/24 21:59:41 luigi Exp $
*
*/
@@ -246,7 +246,6 @@
struct iso88025_header gen_th;
struct sockaddr_dl *sdl = NULL;
struct rtentry *rt;
- struct arpcom *ac = IFP2AC(ifp);
#ifdef MAC
error = mac_check_ifnet_transmit(ifp, m);
@@ -272,7 +271,7 @@
/* Generate a generic 802.5 header for the packet */
gen_th.ac = TR_AC;
gen_th.fc = TR_LLC_FRAME;
- (void)memcpy((caddr_t)gen_th.iso88025_shost, (caddr_t)ac->ac_enaddr,
+ (void)memcpy((caddr_t)gen_th.iso88025_shost, IFP2AC(ifp)->ac_enaddr,
ISO88025_ADDR_LEN);
if (rif_len) {
gen_th.iso88025_shost[0] |= TR_RII;
@@ -321,7 +320,7 @@
#endif /* INET */
#ifdef INET6
case AF_INET6:
- if (!nd6_storelladdr(&ac->ac_if, rt, m, dst, (u_char *)edst)) {
+ if (!nd6_storelladdr(ifp, rt, m, dst, (u_char *)edst)) {
/* Something bad happened */
return(0);
}
==== //depot/projects/gdb/sys/net/if_vlan.c#2 (text+ko) ====
@@ -26,7 +26,7 @@
* OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
- * $FreeBSD: src/sys/net/if_vlan.c,v 1.57 2004/01/03 03:33:39 sam Exp $
+ * $FreeBSD: src/sys/net/if_vlan.c,v 1.58 2004/04/24 22:24:48 luigi Exp $
*/
/*
@@ -691,7 +691,7 @@
struct sockaddr *sa;
sa = (struct sockaddr *) &ifr->ifr_data;
- bcopy(((struct arpcom *)ifp->if_softc)->ac_enaddr,
+ bcopy(IFP2AC(ifp)->ac_enaddr,
(caddr_t) sa->sa_data, ETHER_ADDR_LEN);
}
break;
==== //depot/projects/gdb/sys/net/route.c#8 (text+ko) ====
@@ -27,7 +27,7 @@
* SUCH DAMAGE.
*
* @(#)route.c 8.3.1.1 (Berkeley) 2/23/95
- * $FreeBSD: src/sys/net/route.c,v 1.102 2004/04/21 15:16:08 luigi Exp $
+ * $FreeBSD: src/sys/net/route.c,v 1.104 2004/04/25 01:39:00 luigi Exp $
*/
#include "opt_inet.h"
@@ -1207,17 +1207,36 @@
}
/*
- * Validate the route rt0 to the specified destination. If the
- * route is marked down try to find a new route. If the route
+ * rt_check() is invoked on each layer 2 output path, prior to
+ * encapsulating outbound packets.
+ *
+ * The function is mostly used to find a routing entry for the gateway,
+ * which in some protocol families could also point to the link-level
+ * address for the gateway itself (the side effect of revalidating the
+ * route to the destination is rather pointless at this stage, we did it
+ * already a moment before in the pr_output() routine to locate the ifp
+ * and gateway to use).
+ *
+ * When we remove the layer-3 to layer-2 mapping tables from the
+ * routing table, this function can be removed.
+ *
+ * === On input ===
+ * *dst is the address of the NEXT HOP (which coincides with the
+ * final destination if directly reachable);
+ * *lrt0 points to the cached route to the final destination;
+ * *lrt is not meaningful;
+ *
+ * === Operation ===
+ * If the route is marked down try to find a new route. If the route
* to the gateway is gone, try to setup a new route. Otherwise,
* if the route is marked for packets to be rejected, enforce that.
*
- * On return lrt contains the route to the destination and lrt0
- * contains the route to the next hop. Their values are meaningul
- * ONLY if no error is returned.
+ * === On return ===
+ * *dst is unchanged;
+ * *lrt0 points to the (possibly new) route to the final destination
+ * *lrt points to the route to the next hop
*
- * This routine is invoked on each layer 2 output path, prior to
- * encapsulating outbound packets.
+ * Their values are meaningful ONLY if no error is returned.
*/
int
rt_check(struct rtentry **lrt, struct rtentry **lrt0, struct sockaddr *dst)
==== //depot/projects/gdb/sys/net/route.h#7 (text+ko) ====
@@ -27,7 +27,7 @@
* SUCH DAMAGE.
*
* @(#)route.h 8.4 (Berkeley) 1/9/95
- * $FreeBSD: src/sys/net/route.h,v 1.59 2004/04/20 07:03:30 luigi Exp $
+ * $FreeBSD: src/sys/net/route.h,v 1.60 2004/04/24 23:34:04 luigi Exp $
*/
#ifndef _NET_ROUTE_H_
@@ -324,10 +324,22 @@
void rt_missmsg(int, struct rt_addrinfo *, int, int);
void rt_newaddrmsg(int, struct ifaddr *, int, struct rtentry *);
void rt_newmaddrmsg(int, struct ifmultiaddr *);
-void rtalloc(struct route *);
int rt_setgate(struct rtentry *, struct sockaddr *, struct sockaddr *);
-void rtalloc_ign(struct route *, u_long);
-/* NB: the rtentry is returned locked */
+
+/*
+ * Note the following locking behavior:
+ *
+ * rtalloc_ign() and rtalloc() return ro->ro_rt unlocked
+ *
+ * rtalloc1() returns a locked rtentry
+ *
+ * rtfree() and RTFREE_LOCKED() require a locked rtentry
+ *
+ * RTFREE() uses an unlocked entry.
+ */
+
+void rtalloc_ign(struct route *ro, u_long ignflags);
+void rtalloc(struct route *ro); /* XXX deprecated, use rtalloc_ign(ro, 0) */
struct rtentry *rtalloc1(struct sockaddr *, int, u_long);
int rtexpunge(struct rtentry *);
void rtfree(struct rtentry *);
==== //depot/projects/gdb/sys/powerpc/include/float.h#4 (text+ko) ====
@@ -28,16 +28,20 @@
*
* from: @(#)float.h 7.1 (Berkeley) 5/8/90
* from: FreeBSD: src/sys/i386/include/float.h,v 1.8 1999/08/28 00:44:11
- * $FreeBSD: src/sys/powerpc/include/float.h,v 1.4 2004/04/07 04:59:59 imp Exp $
+ * $FreeBSD: src/sys/powerpc/include/float.h,v 1.5 2004/04/25 02:36:29 das Exp $
*/
#ifndef _MACHINE_FLOAT_H_
#define _MACHINE_FLOAT_H_ 1
+#include <sys/cdefs.h>
+
#define FLT_RADIX 2 /* b */
#define FLT_ROUNDS 1 /* FP addition rounds to nearest */
+#if __ISO_C_VISIBLE >= 1999
#define FLT_EVAL_METHOD 1 /* operands promoted to double */
#define DECIMAL_DIG 35 /* max precision in decimal digits */
+#endif
#define FLT_MANT_DIG 24 /* p */
#define FLT_EPSILON 1.19209290E-07F /* b**(1-p) */
==== //depot/projects/gdb/sys/sparc64/include/float.h#3 (text+ko) ====
@@ -32,7 +32,7 @@
*
* @(#)float.h 8.1 (Berkeley) 6/11/93
* from: NetBSD: float.h,v 1.3 2001/09/21 20:48:02 eeh Exp
- * $FreeBSD: src/sys/sparc64/include/float.h,v 1.4 2004/04/07 05:00:00 imp Exp $
+ * $FreeBSD: src/sys/sparc64/include/float.h,v 1.5 2004/04/25 02:36:29 das Exp $
*/
#ifndef _MACHINE_FLOAT_H_
@@ -46,8 +46,10 @@
#define FLT_RADIX 2 /* b */
#define FLT_ROUNDS __flt_rounds()
+#if __ISO_C_VISIBLE >= 1999
#define FLT_EVAL_METHOD 0 /* no promotion */
#define DECIMAL_DIG 35 /* max precision in decimal digits */
+#endif
#define FLT_MANT_DIG 24 /* p */
#define FLT_EPSILON 1.19209290E-7F /* b**(1-p) */
==== //depot/projects/gdb/sys/sparc64/pci/psycho.c#3 (text+ko) ====
@@ -28,7 +28,7 @@
*
* from: NetBSD: psycho.c,v 1.39 2001/10/07 20:30:41 eeh Exp
*
- * $FreeBSD: src/sys/sparc64/pci/psycho.c,v 1.45 2003/12/26 14:04:19 obrien Exp $
+ * $FreeBSD: src/sys/sparc64/pci/psycho.c,v 1.46 2004/04/25 00:30:28 tmm Exp $
*/
/*
@@ -75,7 +75,6 @@
#include "pcib_if.h"
-static void psycho_get_ranges(phandle_t, struct upa_ranges **, int *);
static void psycho_set_intr(struct psycho_softc *, int, device_t, bus_addr_t,
int, driver_intr_t);
static int psycho_find_intrmap(struct psycho_softc *, int, bus_addr_t *,
@@ -202,8 +201,8 @@
* the IIi. The APB let's the IIi handle two independednt PCI buses, and
* appears as two "simba"'s underneath the sabre.
*
- * "psycho" and "psycho+" is a dual UPA to PCI bridge. It sits on the UPA bus
- * and manages two PCI buses. "psycho" has two 64-bit 33MHz buses, while
+ * "psycho" and "psycho+" are dual UPA to PCI bridges. They sit on the UPA bus
+ * and manage two PCI buses. "psycho" has two 64-bit 33MHz buses, while
* "psycho+" controls both a 64-bit 33Mhz and a 64-bit 66Mhz PCI bus. You
* will usually find a "psycho+" since I don't think the original "psycho"
* ever shipped, and if it did it would be in the U30.
@@ -219,17 +218,6 @@
*
* On UltraII machines, there can be any number of "psycho+" ICs, each
* providing two PCI buses.
- *
- *
- * XXXX The psycho/sabre node has an `interrupts' attribute. They contain
- * the values of the following interrupts in this order:
- *
- * PCI Bus Error (30)
- * DMA UE (2e)
- * DMA CE (2f)
- * Power Fail (25)
- *
- * We really should attach handlers for each.
*/
#ifdef DEBUGGER_ON_POWERFAIL
#define PSYCHO_PWRFAIL_INT_FLAGS INTR_FAST
@@ -303,18 +291,6 @@
>>> TRUNCATED FOR MAIL (1000 lines) <<<
More information about the p4-projects
mailing list