From owner-freebsd-hackers Tue Jul 4 19:51:46 1995 Return-Path: hackers-owner Received: (from majordom@localhost) by freefall.cdrom.com (8.6.10/8.6.6) id TAA28577 for hackers-outgoing; Tue, 4 Jul 1995 19:51:46 -0700 Received: from Root.COM (implode.Root.COM [198.145.90.1]) by freefall.cdrom.com (8.6.10/8.6.6) with ESMTP id TAA28571 for ; Tue, 4 Jul 1995 19:51:43 -0700 Received: from corbin.Root.COM (corbin [198.145.90.18]) by Root.COM (8.6.11/8.6.5) with ESMTP id TAA07198; Tue, 4 Jul 1995 19:51:24 -0700 Received: from localhost (localhost [127.0.0.1]) by corbin.Root.COM (8.6.11/8.6.5) with SMTP id TAA10682; Tue, 4 Jul 1995 19:52:08 -0700 Message-Id: <199507050252.TAA10682@corbin.Root.COM> To: "Jonathan M. Bresler" cc: hackers@freebsd.org Subject: Re: splnet and if_ep.c In-reply-to: Your message of "Tue, 04 Jul 95 20:07:43 EDT." From: David Greenman Reply-To: davidg@Root.COM Date: Tue, 04 Jul 1995 19:52:07 -0700 Sender: hackers-owner@freebsd.org Precedence: bulk >the 3c509 is reported to be buggy. though i have not had any problems >with it. however, if writing smcioctl() for the smc91c92 chip, i see >that if_ze.c:ze_ioctl() calls splnet() at entry. if_ep.c:ep_ioctl() does >not. anybody seen any problems with the ix or zp drivers? from grep's >it appears that splnet is a higher priority than splimp. In general, the ioctl routines of the drivers should be protected with splimp(). This is because they often write to device registers or modify the board state in some other way that must not be interrupted. >if_ep.c -- The 'ep' driver appears to be safe in all cases except one. The case of it setting the interface down (via ep_stop) [when IFF_UP is cleared], is not protected yet it modifies several important device registers. This means that if a packet interrupt arrives while you are doing this, you'll likely lose. In all the other cases, the routines that each of the ioctl's call are themselves protected with splimp(). I haven't looked at the other drivers (yet?). Someone definately should. -DG