From owner-freebsd-hackers Sat Feb 4 01:57:54 1995 Return-Path: hackers-owner Received: (from root@localhost) by freefall.cdrom.com (8.6.9/8.6.6) id BAA13354 for hackers-outgoing; Sat, 4 Feb 1995 01:57:54 -0800 Received: from sbstark.cs.sunysb.edu (sbstark.cs.sunysb.edu [130.245.1.47]) by freefall.cdrom.com (8.6.9/8.6.6) with ESMTP id BAA13347 for ; Sat, 4 Feb 1995 01:57:52 -0800 Received: from starkhome.UUCP (root@localhost) by sbstark.cs.sunysb.edu (8.6.9/8.6.9) with UUCP id EAA06769 for hackers@freebsd.org; Sat, 4 Feb 1995 04:55:02 -0500 Received: by starkhome.cs.sunysb.edu (8.6.9/1.34) id EAA04655; Sat, 4 Feb 1995 04:54:49 -0500 Date: Sat, 4 Feb 1995 04:54:49 -0500 From: starkhome!gene@sbstark.cs.sunysb.edu (Gene Stark) Message-Id: <199502040954.EAA04655@starkhome.cs.sunysb.edu> To: Mark Tinguely Cc: hackers@FreeBSD.org In-reply-to: Mark Tinguely's message of Fri, 3 Feb 1995 20:24:58 -0600 Subject: longjump in kernel Sender: hackers-owner@FreeBSD.org Precedence: bulk > stupid question time. I have a video board that requires the camera to > supply vertical sync, and I need to wait for starts/stops of the vertical > syncs in the driver. if the camera is turned off and someone reads from the > camera, then my driver will hang forever (I guess this could be said for a > disk drive, but more users will shut their camera off when they would not > shut off their disk drive). > > am I correct in think there is nothing that can be done in this situation? > (a user process can set a timer and long jump out, but I can imagine this > is leagal in a device driver). Have a look at /sys/i386/isa/tw.c, which syncs to zero crossings of the AC power line. You should be able to use similar techniques to solve your problem. - Gene Stark