From c3c6f70ceaf52de1089b57bcd6948f842829a8cb Mon Sep 17 00:00:00 2001 From: mycroft Date: Fri, 30 Apr 1993 23:44:03 +0000 Subject: [PATCH] Move bpfattach() call into hpattach(). --- sys/arch/i386/isa/if_hp.c | 17 ++--------------- sys/dev/isa/if_hp.c | 17 ++--------------- 2 files changed, 4 insertions(+), 30 deletions(-) diff --git a/sys/arch/i386/isa/if_hp.c b/sys/arch/i386/isa/if_hp.c index 843c403470de..492c4daf0957 100644 --- a/sys/arch/i386/isa/if_hp.c +++ b/sys/arch/i386/isa/if_hp.c @@ -115,9 +115,6 @@ struct hp_softc #define ns_addr ns_ac.ac_enaddr /* hardware Ethernet address */ int ns_flags; #define DSF_LOCK 1 /* block re-entering enstart */ -#if NBPFILTER > 0 -#define DSF_ATTACHED 2 -#endif int ns_oactive; int ns_mask; struct prhdr ns_ph; /* hardware header of incoming packet*/ @@ -417,9 +414,8 @@ hpattach (dvp) ifp->if_watchdog = 0; if_attach (ifp); -#if NBPFILTER > 0 - ns->ns_flags &= ~DSF_ATTACHED; -#endif + bpfattach (&ns->ns_bpf, ifp, DLT_EN10MB, + sizeof (struct ether_header)); } /* @@ -436,15 +432,6 @@ hpinit (unit) char *cp; register hpc = ns->ns_port; -#if NBPFILTER > 0 - if ((ns->ns_flags & DSF_ATTACHED) == 0) - { - bpfattach (&ns->ns_bpf, ifp, DLT_EN10MB, - sizeof (struct ether_header)); - ns->ns_flags |= DSF_ATTACHED; - } -#endif - if (ifp->if_addrlist == (struct ifaddr *) 0) return; if (ifp->if_flags & IFF_RUNNING) diff --git a/sys/dev/isa/if_hp.c b/sys/dev/isa/if_hp.c index 843c403470de..492c4daf0957 100644 --- a/sys/dev/isa/if_hp.c +++ b/sys/dev/isa/if_hp.c @@ -115,9 +115,6 @@ struct hp_softc #define ns_addr ns_ac.ac_enaddr /* hardware Ethernet address */ int ns_flags; #define DSF_LOCK 1 /* block re-entering enstart */ -#if NBPFILTER > 0 -#define DSF_ATTACHED 2 -#endif int ns_oactive; int ns_mask; struct prhdr ns_ph; /* hardware header of incoming packet*/ @@ -417,9 +414,8 @@ hpattach (dvp) ifp->if_watchdog = 0; if_attach (ifp); -#if NBPFILTER > 0 - ns->ns_flags &= ~DSF_ATTACHED; -#endif + bpfattach (&ns->ns_bpf, ifp, DLT_EN10MB, + sizeof (struct ether_header)); } /* @@ -436,15 +432,6 @@ hpinit (unit) char *cp; register hpc = ns->ns_port; -#if NBPFILTER > 0 - if ((ns->ns_flags & DSF_ATTACHED) == 0) - { - bpfattach (&ns->ns_bpf, ifp, DLT_EN10MB, - sizeof (struct ether_header)); - ns->ns_flags |= DSF_ATTACHED; - } -#endif - if (ifp->if_addrlist == (struct ifaddr *) 0) return; if (ifp->if_flags & IFF_RUNNING)