lint
authorMike Karels <karels@ucbvax.Berkeley.EDU>
Tue, 3 Jun 1986 05:48:47 +0000 (21:48 -0800)
committerMike Karels <karels@ucbvax.Berkeley.EDU>
Tue, 3 Jun 1986 05:48:47 +0000 (21:48 -0800)
SCCS-vsn: sys/netinet/in_var.h 6.5
SCCS-vsn: sys/netinet/ip_input.c 6.23
SCCS-vsn: sys/vax/vax/Locore.c 6.10
SCCS-vsn: sys/vax/vax/machdep.c 6.30
SCCS-vsn: sys/kern/kern_clock.c 6.17
SCCS-vsn: sys/kern/uipc_usrreq.c 6.23
SCCS-vsn: sys/vax/if/if_ddn.c 6.6
SCCS-vsn: sys/vax/if/if_dmc.c 6.13
SCCS-vsn: sys/vax/if/if_hdh.c 6.7
SCCS-vsn: sys/vax/if/if_pcl.c 6.8
SCCS-vsn: sys/vax/if/if_qe.c 6.3
SCCS-vsn: sys/vax/if/if_vv.c 6.21
SCCS-vsn: sys/vax/uba/ct.c 6.6
SCCS-vsn: sys/netns/ns.h 6.12
SCCS-vsn: sys/netns/ns_error.c 6.8
SCCS-vsn: sys/netns/ns_if.h 6.4
SCCS-vsn: sys/netns/ns_input.c 6.13
SCCS-vsn: sys/netns/ns_pcb.c 6.8
SCCS-vsn: sys/netns/ns_pcb.h 6.6

19 files changed:
usr/src/sys/kern/kern_clock.c
usr/src/sys/kern/uipc_usrreq.c
usr/src/sys/netinet/in_var.h
usr/src/sys/netinet/ip_input.c
usr/src/sys/netns/ns.h
usr/src/sys/netns/ns_error.c
usr/src/sys/netns/ns_if.h
usr/src/sys/netns/ns_input.c
usr/src/sys/netns/ns_pcb.c
usr/src/sys/netns/ns_pcb.h
usr/src/sys/vax/if/if_ddn.c
usr/src/sys/vax/if/if_dmc.c
usr/src/sys/vax/if/if_hdh.c
usr/src/sys/vax/if/if_pcl.c
usr/src/sys/vax/if/if_qe.c
usr/src/sys/vax/if/if_vv.c
usr/src/sys/vax/uba/ct.c
usr/src/sys/vax/vax/Locore.c
usr/src/sys/vax/vax/machdep.c

index 33fe91c..74af543 100644 (file)
@@ -3,7 +3,7 @@
  * All rights reserved.  The Berkeley software License Agreement
  * specifies the terms and conditions for redistribution.
  *
  * All rights reserved.  The Berkeley software License Agreement
  * specifies the terms and conditions for redistribution.
  *
- *     @(#)kern_clock.c        6.16 (Berkeley) %G%
+ *     @(#)kern_clock.c        6.17 (Berkeley) %G%
  */
 
 #include "../machine/reg.h"
  */
 
 #include "../machine/reg.h"
index 2f82475..435bd08 100644 (file)
@@ -3,7 +3,7 @@
  * All rights reserved.  The Berkeley software License Agreement
  * specifies the terms and conditions for redistribution.
  *
  * All rights reserved.  The Berkeley software License Agreement
  * specifies the terms and conditions for redistribution.
  *
- *     @(#)uipc_usrreq.c       6.22 (Berkeley) %G%
+ *     @(#)uipc_usrreq.c       6.23 (Berkeley) %G%
  */
 
 #include "param.h"
  */
 
 #include "param.h"
@@ -244,7 +244,7 @@ uipc_usrreq(so, req, m, nam, rights)
                if (unp->unp_conn && unp->unp_conn->unp_addr) {
                        nam->m_len = unp->unp_conn->unp_addr->m_len;
                        bcopy(mtod(unp->unp_conn->unp_addr, caddr_t),
                if (unp->unp_conn && unp->unp_conn->unp_addr) {
                        nam->m_len = unp->unp_conn->unp_addr->m_len;
                        bcopy(mtod(unp->unp_conn->unp_addr, caddr_t),
-                           mtod(m, caddr_t), m->m_len);
+                           mtod(m, caddr_t), (unsigned)m->m_len);
                }
                break;
 
                }
                break;
 
index e5fb108..14b2f6f 100644 (file)
@@ -1,14 +1,14 @@
 /*
 /*
- * Copyright (c) 1982 Regents of the University of California.
+ * Copyright (c) 1985 Regents of the University of California.
  * All rights reserved.  The Berkeley software License Agreement
  * specifies the terms and conditions for redistribution.
  *
  * All rights reserved.  The Berkeley software License Agreement
  * specifies the terms and conditions for redistribution.
  *
- *     @(#)in_var.h    6.4 (Berkeley) %G%
+ *     @(#)in_var.h    6.5 (Berkeley) %G%
  */
 
 /*
  */
 
 /*
- * Interface address, internet version.  One of these structures
- * is allocated for each interface with an internet address.
+ * Interface address, Internet version.  One of these structures
+ * is allocated for each interface with an Internet address.
  * The ifaddr structure contains the protocol-independent part
  * of the structure and is assumed to be first.
  */
  * The ifaddr structure contains the protocol-independent part
  * of the structure and is assumed to be first.
  */
@@ -37,6 +37,7 @@ struct in_ifaddr {
 #define        IFA_ROUTE       0x01            /* routing entry installed */
 
 #ifdef KERNEL
 #define        IFA_ROUTE       0x01            /* routing entry installed */
 
 #ifdef KERNEL
-struct in_ifaddr *in_ifaddr;
-struct in_ifaddr *in_iaonnetof();
+struct in_ifaddr *in_ifaddr;
+struct in_ifaddr *in_iaonnetof();
+struct ifqueue ipintrq;                /* ip packet input queue */
 #endif
 #endif
index e72574f..53f47f8 100644 (file)
@@ -3,7 +3,7 @@
  * All rights reserved.  The Berkeley software License Agreement
  * specifies the terms and conditions for redistribution.
  *
  * All rights reserved.  The Berkeley software License Agreement
  * specifies the terms and conditions for redistribution.
  *
- *     @(#)ip_input.c  6.22 (Berkeley) %G%
+ *     @(#)ip_input.c  6.23 (Berkeley) %G%
  */
 
 #include "param.h"
  */
 
 #include "param.h"
@@ -849,7 +849,7 @@ ip_forward(ip, ifp)
         * Save at most 64 bytes of the packet in case
         * we need to generate an ICMP message to the src.
         */
         * Save at most 64 bytes of the packet in case
         * we need to generate an ICMP message to the src.
         */
-       mcopy = m_copy(dtom(ip), 0, imin(ip->ip_len, 64));
+       mcopy = m_copy(dtom(ip), 0, imin((int)ip->ip_len, 64));
 
        sin = (struct sockaddr_in *)&ipforward_rt.ro_dst;
        if (ipforward_rt.ro_rt == 0 ||
 
        sin = (struct sockaddr_in *)&ipforward_rt.ro_dst;
        if (ipforward_rt.ro_rt == 0 ||
index 4e64794..a94191d 100644 (file)
@@ -3,7 +3,7 @@
  * All rights reserved.  The Berkeley software License Agreement
  * specifies the terms and conditions for redistribution.
  *
  * All rights reserved.  The Berkeley software License Agreement
  * specifies the terms and conditions for redistribution.
  *
- *     @(#)ns.h        6.11 (Berkeley) %G%
+ *     @(#)ns.h        6.12 (Berkeley) %G%
  */
 
 /*
  */
 
 /*
@@ -103,8 +103,7 @@ struct sockaddr_ns {
 #define ns_nullhost(x) (((x).x_host.s_host[0]==0) && \
        ((x).x_host.s_host[1]==0) && ((x).x_host.s_host[2]==0))
 
 #define ns_nullhost(x) (((x).x_host.s_host[0]==0) && \
        ((x).x_host.s_host[1]==0) && ((x).x_host.s_host[2]==0))
 
-#if !defined(vax)
-#if !defined(INET)
+#if !defined(vax) && !defined(ntohl) && !defined(lint)
 /*
  * Macros for number representation conversion.
  */
 /*
  * Macros for number representation conversion.
  */
@@ -113,14 +112,18 @@ struct sockaddr_ns {
 #define        htonl(x)        (x)
 #define        htons(x)        (x)
 #endif
 #define        htonl(x)        (x)
 #define        htons(x)        (x)
 #endif
+
+#if !defined(ntohl) && (defined(vax) || defined(lint))
+u_short        ntohs(), htons();
+u_long ntohl(), htonl();
 #endif
 
 #ifdef KERNEL
 extern struct domain nsdomain;
 #endif
 
 #ifdef KERNEL
 extern struct domain nsdomain;
-extern union ns_host ns_thishost;
-extern union ns_host ns_zerohost;
-extern union ns_host ns_broadhost;
-extern union ns_net ns_zeronet;
-extern union ns_net ns_broadnet;
+union ns_host ns_thishost;
+union ns_host ns_zerohost;
+union ns_host ns_broadhost;
+union ns_net ns_zeronet;
+union ns_net ns_broadnet;
 u_short ns_cksum();
 #endif
 u_short ns_cksum();
 #endif
index 4fbd684..e5b1c3e 100644 (file)
@@ -3,7 +3,7 @@
  * All rights reserved.  The Berkeley software License Agreement
  * specifies the terms and conditions for redistribution.
  *
  * All rights reserved.  The Berkeley software License Agreement
  * specifies the terms and conditions for redistribution.
  *
- *     @(#)ns_error.c  6.7 (Berkeley) %G%
+ *     @(#)ns_error.c  6.8 (Berkeley) %G%
  */
 
 #include "param.h"
  */
 
 #include "param.h"
@@ -233,6 +233,7 @@ free:
        m_freem(m);
 }
 
        m_freem(m);
 }
 
+#ifdef notdef
 u_long
 nstime()
 {
 u_long
 nstime()
 {
@@ -243,6 +244,7 @@ nstime()
        splx(s);
        return (htonl(t));
 }
        splx(s);
        return (htonl(t));
 }
+#endif
 
 ns_echo(idp)
 register struct idp *idp;
 
 ns_echo(idp)
 register struct idp *idp;
@@ -265,7 +267,8 @@ register struct idp *idp;
 
        if (idp->idp_sum != 0xffff) {
                idp->idp_sum = 0;
 
        if (idp->idp_sum != 0xffff) {
                idp->idp_sum = 0;
-               idp->idp_sum = ns_cksum(m, (((ntohs(idp->idp_len) - 1)|1)+1));
+               idp->idp_sum = ns_cksum(m,
+                   (int)(((ntohs(idp->idp_len) - 1)|1)+1));
        }
        (void) ns_output(m, (struct route *)0, NS_FORWARDING);
        return(0);
        }
        (void) ns_output(m, (struct route *)0, NS_FORWARDING);
        return(0);
index 0a0f794..c96721f 100644 (file)
@@ -3,7 +3,7 @@
  * All rights reserved.  The Berkeley software License Agreement
  * specifies the terms and conditions for redistribution.
  *
  * All rights reserved.  The Berkeley software License Agreement
  * specifies the terms and conditions for redistribution.
  *
- *     @(#)ns_if.h     6.3 (Berkeley) %G%
+ *     @(#)ns_if.h     6.4 (Berkeley) %G%
  */
 
 /*
  */
 
 /*
@@ -47,7 +47,7 @@ struct nsip_req {
 #endif
 
 #ifdef KERNEL
 #endif
 
 #ifdef KERNEL
-extern struct ns_ifaddr *ns_ifaddr;
-extern struct ns_ifaddr *ns_iaonnetof();
-extern struct ifqueue  nsintrq;        /* XNS input packet queue */
+struct ns_ifaddr *ns_ifaddr;
+struct ns_ifaddr *ns_iaonnetof();
+struct ifqueue nsintrq;        /* XNS input packet queue */
 #endif
 #endif
index fd3c970..3a2e41d 100644 (file)
@@ -3,7 +3,7 @@
  * All rights reserved.  The Berkeley software License Agreement
  * specifies the terms and conditions for redistribution.
  *
  * All rights reserved.  The Berkeley software License Agreement
  * specifies the terms and conditions for redistribution.
  *
- *     @(#)ns_input.c  6.12 (Berkeley) %G%
+ *     @(#)ns_input.c  6.13 (Berkeley) %G%
  */
 
 #include "param.h"
  */
 
 #include "param.h"
@@ -311,7 +311,7 @@ idp_forward(idp)
         * Save at most 42 bytes of the packet in case
         * we need to generate an NS error message to the src.
         */
         * Save at most 42 bytes of the packet in case
         * we need to generate an NS error message to the src.
         */
-       mcopy = m_copy(dtom(idp), 0, imin(ntohs(idp->idp_len), 42));
+       mcopy = m_copy(dtom(idp), 0, imin((int)ntohs(idp->idp_len), 42));
 
        if ((ok_there = idp_do_route(&idp->idp_dna,&idp_droute))==0) {
                type = NS_ERR_UNREACH_HOST, code = 0;
 
        if ((ok_there = idp_do_route(&idp->idp_dna,&idp_droute))==0) {
                type = NS_ERR_UNREACH_HOST, code = 0;
index 5dcc195..d3d026e 100644 (file)
@@ -3,7 +3,7 @@
  * All rights reserved.  The Berkeley software License Agreement
  * specifies the terms and conditions for redistribution.
  *
  * All rights reserved.  The Berkeley software License Agreement
  * specifies the terms and conditions for redistribution.
  *
- *     @(#)ns_pcb.c    6.7 (Berkeley) %G%
+ *     @(#)ns_pcb.c    6.8 (Berkeley) %G%
  */
 
 #include "param.h"
  */
 
 #include "param.h"
@@ -263,6 +263,7 @@ ns_pcbnotify(dst, errno, notify, param)
        splx(s);
 }
 
        splx(s);
 }
 
+#ifdef notdef
 /*
  * After a routing change, flush old routing
  * and allocate a (hopefully) better one.
 /*
  * After a routing change, flush old routing
  * and allocate a (hopefully) better one.
@@ -280,6 +281,7 @@ ns_rtchange(nsp)
        }
        /* SHOULD NOTIFY HIGHER-LEVEL PROTOCOLS */
 }
        }
        /* SHOULD NOTIFY HIGHER-LEVEL PROTOCOLS */
 }
+#endif
 
 struct nspcb *
 ns_pcblookup(faddr, lport, wildp)
 
 struct nspcb *
 ns_pcblookup(faddr, lport, wildp)
index 9a43c09..dd361e0 100644 (file)
@@ -3,7 +3,7 @@
  * All rights reserved.  The Berkeley software License Agreement
  * specifies the terms and conditions for redistribution.
  *
  * All rights reserved.  The Berkeley software License Agreement
  * specifies the terms and conditions for redistribution.
  *
- *     @(#)ns_pcb.h    6.5 (Berkeley) %G%
+ *     @(#)ns_pcb.h    6.6 (Berkeley) %G%
  */
 
 /*
  */
 
 /*
@@ -48,6 +48,6 @@ struct nspcb {
 
 
 #ifdef KERNEL
 
 
 #ifdef KERNEL
-extern struct nspcb nspcb;                     /* head of list */
-extern struct nspcb *ns_pcblookup();
+struct nspcb nspcb;                    /* head of list */
+struct nspcb *ns_pcblookup();
 #endif
 #endif
index b1d0f10..ad16d46 100644 (file)
@@ -1,4 +1,4 @@
-/*     @(#)if_ddn.c    6.5 (Berkeley) %G% */
+/*     @(#)if_ddn.c    6.6 (Berkeley) %G% */
 
 
 /************************************************************************\
 
 
 /************************************************************************\
@@ -274,7 +274,7 @@ caddr_t reg;
     register int delay_time;
 
 #ifdef lint
     register int delay_time;
 
 #ifdef lint
-    br = 0; cvec = br; br = cvec;
+    br = 0; cvec = br; br = cvec; ddnintr(0);
 #endif
 
     cvec = savevec = (uba_hd[numuba].uh_lastiv -= 4);  /* return vector */
 #endif
 
     cvec = savevec = (uba_hd[numuba].uh_lastiv -= 4);  /* return vector */
@@ -1018,7 +1018,7 @@ register struct ddn_cb *dc;
 
     cb = mtod(m_callbfr, caddr_t);
 
 
     cb = mtod(m_callbfr, caddr_t);
 
-    convert_ip_addr(ds->ddn_ipaddr, cb_calling_addr);
+    (void)convert_ip_addr(ds->ddn_ipaddr, cb_calling_addr);
 
     cb_protocol[0] = 4;
     cb_protocol[1] = X25_PROTO_IP;     /* protocol = IP */
 
     cb_protocol[0] = 4;
     cb_protocol[1] = X25_PROTO_IP;     /* protocol = IP */
@@ -1419,11 +1419,11 @@ printf("\n");
            dc->dc_inaddr.s_addr = convert_x25_addr(cb_calling_addr);
            dc->dc_state = LC_DATA_IDLE;  /* set state */
            dc->dc_timer = TMO_DATA_IDLE; /* start timer */
            dc->dc_inaddr.s_addr = convert_x25_addr(cb_calling_addr);
            dc->dc_state = LC_DATA_IDLE;  /* set state */
            dc->dc_timer = TMO_DATA_IDLE; /* start timer */
-           send_supr(ds, ANSWER, lcn * 2, p[2]); /* send answer */
+           send_supr(ds, ANSWER, lcn * 2, (int)p[2]); /* send answer */
          }
        else                            /* if no free LCN's */
          {
          }
        else                            /* if no free LCN's */
          {
-           send_supr(ds, CLEARVC, p[2], 0); /* clear call */
+           send_supr(ds, CLEARVC, (int)p[2], 0); /* clear call */
          }
        break;
 
          }
        break;
 
@@ -1432,7 +1432,7 @@ printf("\n");
        dc = &(ds->ddn_cb[lcn]);
        if (dc->dc_state != LC_CLR_PENDING) /* if no clear pending */
          {
        dc = &(ds->ddn_cb[lcn]);
        if (dc->dc_state != LC_CLR_PENDING) /* if no clear pending */
          {
-           send_supr(ds, CLEARLC, p[1], 0);      /*   ack the clear */
+           send_supr(ds, CLEARLC, (int)p[1], 0);      /*   ack the clear */
          }
        dc->dc_state = LC_IDLE; /* set state */
        dc->dc_timer = TMO_OFF; /* stop timer */
          }
        dc->dc_state = LC_IDLE; /* set state */
        dc->dc_timer = TMO_OFF; /* stop timer */
@@ -1445,11 +1445,11 @@ printf("\n");
        break;
 
     case CLEARVC:                      /* clear by VCN */
        break;
 
     case CLEARVC:                      /* clear by VCN */
-       send_supr(ds, CLEARVC, p[1], 0); /* send clear ack */
+       send_supr(ds, CLEARVC, (int)p[1], 0); /* send clear ack */
        break;
 
     case RESET:                                /* X25 reset */
        break;
 
     case RESET:                                /* X25 reset */
-       send_supr(ds, RESET_ACK, p[1], 0); /* send reset ack */
+       send_supr(ds, RESET_ACK, (int)p[1], 0); /* send reset ack */
        printf("X25 RESET on lcn = %d\n", p[1] / 2); /* log it */
        break;
 
        printf("X25 RESET on lcn = %d\n", p[1] / 2); /* log it */
        break;
 
@@ -1493,25 +1493,25 @@ printf("decode_ring()\n");
     /* called address */
     if ((cnt = *p + 1) > 16)   /* is called addr len legal? */
        return(0);              /*   return false if not */
     /* called address */
     if ((cnt = *p + 1) > 16)   /* is called addr len legal? */
        return(0);              /*   return false if not */
-    bcopy(p, cb_called_addr, cnt); /* copy field */
+    bcopy((caddr_t)p, (caddr_t)cb_called_addr, (unsigned)cnt); /* copy field */
     p += cnt;
 
     /* calling address */
     if ((cnt = *p + 1) > 16)   /* is calling addr len legal? */
        return(0);              /*   return false if not */
     p += cnt;
 
     /* calling address */
     if ((cnt = *p + 1) > 16)   /* is calling addr len legal? */
        return(0);              /*   return false if not */
-    bcopy(p, cb_calling_addr, cnt); /* copy field */
+    bcopy((caddr_t)p, (caddr_t)cb_calling_addr, (unsigned)cnt); /* copy field */
     p += cnt;
 
     /* protocol part of user data */
     if ((cnt = *p + 1) > 5)    /* is protocol len legal? */
        return(0);              /*   return false if not */
     p += cnt;
 
     /* protocol part of user data */
     if ((cnt = *p + 1) > 5)    /* is protocol len legal? */
        return(0);              /*   return false if not */
-    bcopy(p, cb_protocol, cnt); /* copy field */
+    bcopy((caddr_t)p, (caddr_t)cb_protocol, (unsigned)cnt); /* copy field */
     p += cnt;
 
     /* facilities */
     if ((cnt = *p + 1) > 64)   /* is facilities len legal? */
        return(0);              /*   return false if not */
     p += cnt;
 
     /* facilities */
     if ((cnt = *p + 1) > 64)   /* is facilities len legal? */
        return(0);              /*   return false if not */
-    bcopy(p, cb_facilities, cnt); /* copy field */
+    bcopy((caddr_t)p, (caddr_t)cb_facilities, (unsigned)cnt); /* copy field */
     p += cnt;
 
     /* ignore rest of user data for now */
     p += cnt;
 
     /* ignore rest of user data for now */
@@ -1553,7 +1553,7 @@ printf("clear_lcn(%d)\n", dc->dc_lcn);
        IF_DEQUEUE(&dc->dc_oq, m);
        m_freem(m);
       }
        IF_DEQUEUE(&dc->dc_oq, m);
        m_freem(m);
       }
-    send_supr(ds, CLEARLC, dc->dc_lcn * 2, 0);    /* send clear msg */
+    send_supr(ds, CLEARLC, (int)dc->dc_lcn * 2, 0);    /* send clear msg */
   }
 \f
 
   }
 \f
 
index 12505af..fc94f97 100644 (file)
@@ -3,7 +3,7 @@
  * All rights reserved.  The Berkeley software License Agreement
  * specifies the terms and conditions for redistribution.
  *
  * All rights reserved.  The Berkeley software License Agreement
  * specifies the terms and conditions for redistribution.
  *
- *     @(#)if_dmc.c    6.12 (Berkeley) %G%
+ *     @(#)if_dmc.c    6.13 (Berkeley) %G%
  */
 
 #include "dmc.h"
  */
 
 #include "dmc.h"
@@ -42,6 +42,7 @@
 #ifdef INET
 #include "../netinet/in.h"
 #include "../netinet/in_systm.h"
 #ifdef INET
 #include "../netinet/in.h"
 #include "../netinet/in_systm.h"
+#include "../netinet/in_var.h"
 #include "../netinet/ip.h"
 #endif
 
 #include "../netinet/ip.h"
 #endif
 
index e424ff4..f900b23 100644 (file)
@@ -1,4 +1,4 @@
-/*     @(#)if_hdh.c    6.6 (Berkeley) %G% */
+/*     @(#)if_hdh.c    6.7 (Berkeley) %G% */
 
 
 /************************************************************************\
 
 
 /************************************************************************\
@@ -664,7 +664,7 @@ char *msg;
 
        if ((m = m_get(M_DONTWAIT, MT_DATA)) == NULL) {
                printf("hdh%d: cannot get supervisor cmnd buffer\n", unit);
 
        if ((m = m_get(M_DONTWAIT, MT_DATA)) == NULL) {
                printf("hdh%d: cannot get supervisor cmnd buffer\n", unit);
-                       return(0);
+                       return;
        }
 
        cnt = len;
        }
 
        cnt = len;
@@ -676,7 +676,5 @@ char *msg;
        cnt = if_wubaput(&sc->hdh_ifuba[SUPR], m);
 
        hdh_iorq(unit, HDHSUPW, cnt, HDHWRT+HDHEOS);
        cnt = if_wubaput(&sc->hdh_ifuba[SUPR], m);
 
        hdh_iorq(unit, HDHSUPW, cnt, HDHWRT+HDHEOS);
-
-       return(1);
 }
 #endif NHDH
 }
 #endif NHDH
index fa9f5a6..81018db 100644 (file)
@@ -3,7 +3,7 @@
  * All rights reserved.  The Berkeley software License Agreement
  * specifies the terms and conditions for redistribution.
  *
  * All rights reserved.  The Berkeley software License Agreement
  * specifies the terms and conditions for redistribution.
  *
- *     @(#)if_pcl.c    6.7 (Berkeley) %G%
+ *     @(#)if_pcl.c    6.8 (Berkeley) %G%
  */
 
 #include "pcl.h"
  */
 
 #include "pcl.h"
 #include "../net/netisr.h"
 #include "../net/route.h"
 
 #include "../net/netisr.h"
 #include "../net/route.h"
 
+#ifdef INET
 #include "../netinet/in.h"
 #include "../netinet/in_systm.h"
 #include "../netinet/in.h"
 #include "../netinet/in_systm.h"
+#include "../netinet/in_var.h"
 #include "../netinet/ip.h"
 #include "../netinet/ip.h"
+#endif
 
 #include "../vax/cpu.h"
 #include "../vax/mtpr.h"
 
 #include "../vax/cpu.h"
 #include "../vax/mtpr.h"
index 13862f2..4f6b0ce 100644 (file)
@@ -1,4 +1,4 @@
-/*     @(#)if_qe.c     6.2 (Berkeley) %G% */
+/*     @(#)if_qe.c     6.3 (Berkeley) %G% */
 
 /* from  @(#)if_qe.c   1.15    (ULTRIX)        4/16/86 */
  
 
 /* from  @(#)if_qe.c   1.15    (ULTRIX)        4/16/86 */
  
@@ -191,7 +191,7 @@ struct      uba_device *qeinfo[NQE];
 extern struct timeval time;
 extern timeout();
  
 extern struct timeval time;
 extern timeout();
  
-int    qeprobe(), qeattach(), qeint(), qewatch();
+int    qeprobe(), qeattach(), qeintr(), qewatch();
 int    qeinit(),qeoutput(),qeioctl(),qereset(),qewatch();
  
 u_short qestd[] = { 0 };
 int    qeinit(),qeoutput(),qeioctl(),qereset(),qewatch();
  
 u_short qestd[] = { 0 };
@@ -225,7 +225,7 @@ qeprobe(reg)
  
 #ifdef lint
        br = 0; cvec = br; br = cvec;
  
 #ifdef lint
        br = 0; cvec = br; br = cvec;
-       qeintr(i);
+       qeintr(0);
 #endif
        /*
         * Set the address mask for the particular cpu
 #endif
        /*
         * Set the address mask for the particular cpu
@@ -243,9 +243,9 @@ qeprobe(reg)
         * Map the communications area and the setup packet.
         */
        sc->setupaddr =
         * Map the communications area and the setup packet.
         */
        sc->setupaddr =
-               uballoc(0, sc->setup_pkt, sizeof(sc->setup_pkt), 0);
-       sc->rringaddr = (struct qe_ring *)
-               uballoc(0, sc->rring, sizeof(struct qe_ring) * (NTOT+2), 0);
+               uballoc(0, (caddr_t)sc->setup_pkt, sizeof(sc->setup_pkt), 0);
+       sc->rringaddr = (struct qe_ring *) uballoc(0, (caddr_t)sc->rring,
+               sizeof(struct qe_ring) * (NTOT+2), 0);
        prp = (struct qe_ring *)((int)sc->rringaddr & mask);
  
        /*
        prp = (struct qe_ring *)((int)sc->rringaddr & mask);
  
        /*
@@ -254,8 +254,10 @@ qeprobe(reg)
         * receive & transmit ring descriptors and link the setup packet
         * to them.
         */
         * receive & transmit ring descriptors and link the setup packet
         * to them.
         */
-       qeinitdesc( sc->tring, sc->setupaddr & mask, sizeof(sc->setup_pkt));
-       qeinitdesc( sc->rring, sc->setupaddr & mask, sizeof(sc->setup_pkt));
+       qeinitdesc(sc->tring, (caddr_t)(sc->setupaddr & mask),
+           sizeof(sc->setup_pkt));
+       qeinitdesc(sc->rring, (caddr_t)(sc->setupaddr & mask),
+           sizeof(sc->setup_pkt));
  
        rp = (struct qe_ring *)sc->tring;
        rp->qe_setup = 1;
  
        rp = (struct qe_ring *)sc->tring;
        rp->qe_setup = 1;
@@ -291,7 +293,7 @@ qeprobe(reg)
         * All done with the bus resources.
         */
        ubarelse(0, &sc->setupaddr);
         * All done with the bus resources.
         */
        ubarelse(0, &sc->setupaddr);
-       ubarelse(0, &sc->rringaddr);
+       ubarelse(0, (int *)&sc->rringaddr);
        if( cvec == j ) 
                return 0;               /* didn't interrupt     */
  
        if( cvec == j ) 
                return 0;               /* didn't interrupt     */
  
@@ -375,10 +377,11 @@ qeinit(unit)
                /*
                 * map the communications area onto the device 
                 */
                /*
                 * map the communications area onto the device 
                 */
-               sc->rringaddr = (struct qe_ring *)((int)uballoc(0, sc->rring,
+               sc->rringaddr = (struct qe_ring *)
+                   ((int) uballoc(0, (caddr_t)sc->rring,
                    sizeof(struct qe_ring) * (NTOT+2), 0) & mask);
                sc->tringaddr = sc->rringaddr + NRCV + 1;
                    sizeof(struct qe_ring) * (NTOT+2), 0) & mask);
                sc->tringaddr = sc->rringaddr + NRCV + 1;
-               sc->setupaddr = uballoc(0, sc->setup_pkt,
+               sc->setupaddr = uballoc(0, (caddr_t)sc->setup_pkt,
                    sizeof(sc->setup_pkt), 0) & mask;
                /*
                 * init buffers and maps
                    sizeof(sc->setup_pkt), 0) & mask;
                /*
                 * init buffers and maps
@@ -397,11 +400,11 @@ qeinit(unit)
         */
        for (i = 0; i < NRCV; i++) {
                qeinitdesc( &sc->rring[i],
         */
        for (i = 0; i < NRCV; i++) {
                qeinitdesc( &sc->rring[i],
-                       sc->qe_ifr[i].ifrw_info & mask, MAXPACKETSIZE);
+                   (caddr_t)(sc->qe_ifr[i].ifrw_info & mask), MAXPACKETSIZE);
                sc->rring[i].qe_flag = sc->rring[i].qe_status1 = QE_NOTYET;
                sc->rring[i].qe_valid = 1;
        }
                sc->rring[i].qe_flag = sc->rring[i].qe_status1 = QE_NOTYET;
                sc->rring[i].qe_valid = 1;
        }
-       qeinitdesc( &sc->rring[i], NULL, 0 );
+       qeinitdesc(&sc->rring[i], (caddr_t)NULL, 0);
  
        sc->rring[i].qe_addr_lo = (short)sc->rringaddr;
        sc->rring[i].qe_addr_hi = (short)((int)sc->rringaddr >> 16);
  
        sc->rring[i].qe_addr_lo = (short)sc->rringaddr;
        sc->rring[i].qe_addr_hi = (short)((int)sc->rringaddr >> 16);
@@ -410,7 +413,7 @@ qeinit(unit)
        sc->rring[i].qe_valid = 1;
  
        for( i = 0 ; i <= NXMT ; i++ )
        sc->rring[i].qe_valid = 1;
  
        for( i = 0 ; i <= NXMT ; i++ )
-               qeinitdesc( &sc->tring[i], NULL, 0 );
+               qeinitdesc(&sc->tring[i], (caddr_t)NULL, 0);
        i--;
  
        sc->tring[i].qe_addr_lo = (short)sc->tringaddr;
        i--;
  
        sc->tring[i].qe_addr_lo = (short)sc->tringaddr;
@@ -510,8 +513,10 @@ qestart(dev)
                 * If the watchdog time isn't running kick it.
                 */
                sc->timeout=1;
                 * If the watchdog time isn't running kick it.
                 */
                sc->timeout=1;
-               if( !qewatchrun++ ) 
-                       timeout(qewatch,0,QE_TIMEO);
+               if (qewatchrun == 0) { 
+                       qewatchrun++; 
+                       timeout(qewatch, (caddr_t)0, QE_TIMEO);
+               }
                        
                /*
                 * See if the xmit list is invalid.
                        
                /*
                 * See if the xmit list is invalid.
@@ -574,7 +579,6 @@ qetint(unit)
                 */
                rp = &sc->tring[sc->otindex];
                status1 = rp->qe_status1;
                 */
                rp = &sc->tring[sc->otindex];
                status1 = rp->qe_status1;
-               status2 = rp->qe_status2;
                setupflag = rp->qe_setup;
                len = (-rp->qe_buf_len) * 2;
                if( rp->qe_odd_end )
                setupflag = rp->qe_setup;
                len = (-rp->qe_buf_len) * 2;
                if( rp->qe_odd_end )
@@ -582,7 +586,7 @@ qetint(unit)
                /*
                 * Init the buffer descriptor
                 */
                /*
                 * Init the buffer descriptor
                 */
-               bzero( rp, sizeof(struct qe_ring));
+               bzero((caddr_t)rp, sizeof(struct qe_ring));
                if( --sc->nxmit == 0 )
                        sc->timeout = 0;
                if( !setupflag ) {
                if( --sc->nxmit == 0 )
                        sc->timeout = 0;
                if( !setupflag ) {
@@ -644,7 +648,7 @@ qerint(unit)
                rp = &sc->rring[sc->rindex];
                status1 = rp->qe_status1;
                status2 = rp->qe_status2;
                rp = &sc->rring[sc->rindex];
                status1 = rp->qe_status1;
                status2 = rp->qe_status2;
-               bzero( rp, sizeof(struct qe_ring));
+               bzero((caddr_t)rp, sizeof(struct qe_ring));
                if( (status1 & QE_MASK) == QE_MASK )
                        panic("qe: chained packet");
                len = ((status1 & QE_RBL_HI) | (status2 & QE_RBL_LO)) + 60;
                if( (status1 & QE_MASK) == QE_MASK )
                        panic("qe: chained packet");
                len = ((status1 & QE_RBL_HI) | (status2 & QE_RBL_LO)) + 60;
@@ -846,7 +850,7 @@ qeioctl(ifp, cmd, data)
                        sc->qe_flags &= ~QEF_RUNNING;
                } else if (ifp->if_flags & IFF_UP &&
                    (sc->qe_flags & QEF_RUNNING) == 0)
                        sc->qe_flags &= ~QEF_RUNNING;
                } else if (ifp->if_flags & IFF_UP &&
                    (sc->qe_flags & QEF_RUNNING) == 0)
-                       qerestart(ifp->if_unit);
+                       qerestart(sc);
                break;
 
        default:
                break;
 
        default:
@@ -865,8 +869,6 @@ qe_setaddr(physaddr, unit)
        int unit;
 {
        register struct qe_softc *sc = &qe_softc[unit];
        int unit;
 {
        register struct qe_softc *sc = &qe_softc[unit];
-       struct uba_device *ui = qeinfo[unit];
-       struct qedevice *addr = (struct qedevice *)ui->ui_addr;
        register int i;
 
        for (i = 0; i < 6; i++)
        register int i;
 
        for (i = 0; i < 6; i++)
@@ -881,15 +883,15 @@ qe_setaddr(physaddr, unit)
 /*
  * Initialize a ring descriptor with mbuf allocation side effects
  */
 /*
  * Initialize a ring descriptor with mbuf allocation side effects
  */
-qeinitdesc( rp, buf, len )
+qeinitdesc(rp, addr, len)
        register struct qe_ring *rp;
        register struct qe_ring *rp;
-       char *addr;                     /* mapped address       */
+       caddr_t addr;                   /* mapped address */
        int len;
 {
        /*
         * clear the entire descriptor
         */
        int len;
 {
        /*
         * clear the entire descriptor
         */
-       bzero( rp, sizeof(struct qe_ring));
+       bzero((caddr_t)rp, sizeof(struct qe_ring));
  
        if( len ) {
                rp->qe_buf_len = -(len/2);
  
        if( len ) {
                rp->qe_buf_len = -(len/2);
@@ -915,7 +917,7 @@ struct qe_softc *sc;
        /*
         * Duplicate the first half.
         */
        /*
         * Duplicate the first half.
         */
-       bcopy(sc->setup_pkt, sc->setup_pkt[8], 64);
+       bcopy((caddr_t)sc->setup_pkt[0], (caddr_t)sc->setup_pkt[8], 64);
        /*
         * Fill in the broadcast address.
         */
        /*
         * Fill in the broadcast address.
         */
@@ -1036,8 +1038,8 @@ qewatch()
                        } else
                                inprogress++;
        }
                        } else
                                inprogress++;
        }
-       if( inprogress ){
-               timeout(qewatch, 0, QE_TIMEO);
+       if (inprogress) {
+               timeout(qewatch, (caddr_t)0, QE_TIMEO);
                qewatchrun++;
        } else
                qewatchrun=0;
                qewatchrun++;
        } else
                qewatchrun=0;
index 049a8eb..0d5e9b1 100644 (file)
@@ -3,7 +3,7 @@
  * All rights reserved.  The Berkeley software License Agreement
  * specifies the terms and conditions for redistribution.
  *
  * All rights reserved.  The Berkeley software License Agreement
  * specifies the terms and conditions for redistribution.
  *
- *     @(#)if_vv.c     6.20 (Berkeley) %G%
+ *     @(#)if_vv.c     6.21 (Berkeley) %G%
  */
 
 #include "vv.h"
  */
 
 #include "vv.h"
@@ -709,7 +709,7 @@ len = %d, vvicsr = %b\n",
 
 #define        vvdataaddr(vv, off, type)       ((type)(((caddr_t)((vv)+1)+(off))))
        if (vv->vh_type == RING_TRAILER ) {
 
 #define        vvdataaddr(vv, off, type)       ((type)(((caddr_t)((vv)+1)+(off))))
        if (vv->vh_type == RING_TRAILER ) {
-               off = ntohs(vv->vh_info);
+               off = ntohs((u_short)vv->vh_info);
                if (off > VVMTU) {
                        vvprintf("vv%d: off > VVMTU, off = %d, vvicsr = %b\n",
                                    unit, off, 0xffff&(addr->vvicsr), VV_IBITS);
                if (off > VVMTU) {
                        vvprintf("vv%d: off > VVMTU, off = %d, vvicsr = %b\n",
                                    unit, off, 0xffff&(addr->vvicsr), VV_IBITS);
@@ -867,8 +867,8 @@ vvoutput(ifp, m0, dst)
                        type = RING_TRAILER;
                        m->m_off -= 2 * sizeof (u_short);
                        m->m_len += 2 * sizeof (u_short);
                        type = RING_TRAILER;
                        m->m_off -= 2 * sizeof (u_short);
                        m->m_len += 2 * sizeof (u_short);
-                       *mtod(m, u_short *) = htons(RING_IP);
-                       *(mtod(m, u_short *) + 1) = htons(m->m_len);
+                       *mtod(m, u_short *) = htons((short)RING_IP);
+                       *(mtod(m, u_short *) + 1) = htons((u_short)m->m_len);
                        goto gottrailertype;
                }
                type = RING_IP;
                        goto gottrailertype;
                }
                type = RING_IP;
@@ -916,7 +916,7 @@ gottype:
        vv->vh_dhost = dest;
        vv->vh_version = RING_VERSION;
        vv->vh_type = type;
        vv->vh_dhost = dest;
        vv->vh_version = RING_VERSION;
        vv->vh_type = type;
-       vv->vh_info = htons(off);
+       vv->vh_info = htons((u_short)off);
        vvtracehdr("vo", vv);
 
        /*
        vvtracehdr("vo", vv);
 
        /*
index 314767c..e82d7eb 100644 (file)
@@ -3,7 +3,7 @@
  * All rights reserved.  The Berkeley software License Agreement
  * specifies the terms and conditions for redistribution.
  *
  * All rights reserved.  The Berkeley software License Agreement
  * specifies the terms and conditions for redistribution.
  *
- *     @(#)ct.c        6.5 (Berkeley) %G%
+ *     @(#)ct.c        6.6 (Berkeley) %G%
  */
 
 #include "ct.h"
  */
 
 #include "ct.h"
@@ -93,7 +93,7 @@ ctprobe(reg)
 
 /*ARGSUSED*/
 ctattach(ui)
 
 /*ARGSUSED*/
 ctattach(ui)
-       register struct uba_device *ui;
+       struct uba_device *ui;
 {
 }
 
 {
 }
 
@@ -175,7 +175,7 @@ ctintr(dev)
                        ctaddr->ctcsr |= CSR1;  /* APSu5 - raise strobe */
                        sc->sc_state |= CT_RUNNING;
                        if (sc->sc_oq.c_cc==0 || sc->sc_oq.c_cc==CATLOWAT)
                        ctaddr->ctcsr |= CSR1;  /* APSu5 - raise strobe */
                        sc->sc_state |= CT_RUNNING;
                        if (sc->sc_oq.c_cc==0 || sc->sc_oq.c_cc==CATLOWAT)
-                               wakeup(&sc->sc_oq);
+                               wakeup((caddr_t)&sc->sc_oq);
                } else if (sc->sc_state == 0) {
                                ctaddr->ctcsr = 0;
                } else
                } else if (sc->sc_state == 0) {
                                ctaddr->ctcsr = 0;
                } else
index b3263d7..5be66d0 100644 (file)
@@ -3,7 +3,7 @@
  * All rights reserved.  The Berkeley software License Agreement
  * specifies the terms and conditions for redistribution.
  *
  * All rights reserved.  The Berkeley software License Agreement
  * specifies the terms and conditions for redistribution.
  *
- *     @(#)Locore.c    6.9 (Berkeley) %G%
+ *     @(#)Locore.c    6.10 (Berkeley) %G%
  */
 
 #include "dz.h"
  */
 
 #include "dz.h"
@@ -302,10 +302,18 @@ addupc(pc, prof, counts) int pc; struct uprof *prof; int counts; { }
  * Routines expanded by inline.
  */
 spl0() { }
  * Routines expanded by inline.
  */
 spl0() { }
+splsoftclock() { return (0); }
+splnet() { return (0); }
 spl4() { return (0); }
 spl5() { return (0); }
 spl4() { return (0); }
 spl5() { return (0); }
-spl6() { return (0); }
+splbio() { return (0); }
+spltty() { return (0); }
+#ifdef notdef
+spl6() { return (0); }         /* not currently used */
+#endif
+splclock() { return (0); }
 spl7() { return (0); }
 spl7() { return (0); }
+splhigh() { return (0); }
 
 /*ARGSUSED*/
 splx(s) int s; { }
 
 /*ARGSUSED*/
 splx(s) int s; { }
index 6d783bc..ef4d084 100644 (file)
@@ -3,7 +3,7 @@
  * All rights reserved.  The Berkeley software License Agreement
  * specifies the terms and conditions for redistribution.
  *
  * All rights reserved.  The Berkeley software License Agreement
  * specifies the terms and conditions for redistribution.
  *
- *     @(#)machdep.c   6.29 (Berkeley) %G%
+ *     @(#)machdep.c   6.30 (Berkeley) %G%
  */
 
 #include "reg.h"
  */
 
 #include "reg.h"
@@ -1161,7 +1161,6 @@ microtime(tvp)
        register struct timeval *tvp;
 {
        int s = splhigh();
        register struct timeval *tvp;
 {
        int s = splhigh();
-       extern int adjtimedelta, tickadj;
        static struct timeval lasttime;
        register long t;
 
        static struct timeval lasttime;
        register long t;