diff -u --recursive --new-file zftape-1.06/fdc-io.c zftape-1.06a/fdc-io.c --- zftape-1.06/fdc-io.c Mon Jul 22 15:26:16 1996 +++ zftape-1.06a/fdc-io.c Wed Sep 11 23:40:28 1996 @@ -18,15 +18,15 @@ $Source: /homes/cvs/zftape/fdc-io.c,v $ $Author: claus $ * - $Revision: 1.17 $ - $Date: 1996/07/22 13:26:16 $ + $Revision: 1.19 $ + $Date: 1996/09/11 21:40:28 $ $State: Exp $ * * This file contains the low-level floppy disk interface code * for the QIC-40/80 tape streamer device driver. */ -static char RCSid[] = "$Id: fdc-io.c,v 1.17 1996/07/22 13:26:16 claus Exp $"; +static char RCSid[] = "$Id: fdc-io.c,v 1.19 1996/09/11 21:40:28 claus Exp $"; #include "ftape.h" #include @@ -322,7 +322,11 @@ int current_blocked = current->blocked; static int resetting = 0; +#if LINUX_VERSION_CODE >= KERNEL_VER(2,0,16) + if (waitqueue_active(&wait_intr)) { +#else if (wait_intr) { +#endif TRACE(1, "error: nested call"); return -EIO; /* return error... */ } diff -u --recursive --new-file zftape-1.06/fdc-isr.c zftape-1.06a/fdc-isr.c --- zftape-1.06/fdc-isr.c Sun Mar 17 14:37:38 1996 +++ zftape-1.06a/fdc-isr.c Wed Sep 11 23:40:29 1996 @@ -18,15 +18,15 @@ $Source: /homes/cvs/zftape/fdc-isr.c,v $ $Author: claus $ * - $Revision: 1.7 $ - $Date: 1996/03/17 13:37:38 $ + $Revision: 1.10 $ + $Date: 1996/09/11 21:40:29 $ $State: Exp $ * * This file contains the interrupt service routine and associated * code for the QIC-40/80 tape streamer device driver. */ -static char RCSid[] = "$Id: fdc-isr.c,v 1.7 1996/03/17 13:37:38 claus Exp $"; +static char RCSid[] = "$Id: fdc-isr.c,v 1.10 1996/09/11 21:40:29 claus Exp $"; #include "ftape.h" #include @@ -805,8 +805,12 @@ } seek_completed = 1; fdc_mode = fdc_idle; +#if LINUX_VERSION_CODE >= KERNEL_VER(2,0,16) + } else if (!waitqueue_active(&wait_intr)) { +#else } else if (!wait_intr) { - if (expected_stray_interrupts == 0) { +#endif + if (expected_stray_interrupts == 0) { TRACE( 2, "unexpected stray interrupt"); } else { TRACE( 5, "expected stray interrupt"); @@ -831,11 +835,21 @@ */ if (!hide_interrupt) { ++interrupt_seen; +#if LINUX_VERSION_CODE >= KERNEL_VER(2,0,16) + if (waitqueue_active(&wait_intr)) { +#else if (wait_intr) { +#endif wake_up_interruptible( &wait_intr); } } else { - TRACEx1( 5, "hiding interrupt while %s", wait_intr ? "waiting" : "active"); +#if LINUX_VERSION_CODE >= KERNEL_VER(2,0,16) + TRACEx1(5, "hiding interrupt while %s", + waitqueue_active(&wait_intr) ? "waiting" : "active"); +#else + TRACEx1(5, "hiding interrupt while %s", + wait_intr ? "waiting" : "active"); +#endif } t0 = timediff( t0, timestamp()); if (t0 >= 1000) { /* only tell us about long calls */