patch-2.2.13 linux/drivers/isdn/hisax/isurf.c

Next file: linux/drivers/isdn/hisax/jade.c
Previous file: linux/drivers/isdn/hisax/isdnl3.c
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v2.2.12/linux/drivers/isdn/hisax/isurf.c linux/drivers/isdn/hisax/isurf.c
@@ -1,10 +1,23 @@
-/* $Id: isurf.c,v 1.3 1999/07/12 21:05:18 keil Exp $
+/* $Id: isurf.c,v 1.6 1999/09/04 06:20:06 keil Exp $
 
  * isurf.c  low level stuff for Siemens I-Surf/I-Talk cards
  *
  * Author     Karsten Keil (keil@isdn4linux.de)
  *
  * $Log: isurf.c,v $
+ * Revision 1.6  1999/09/04 06:20:06  keil
+ * Changes from kernel set_current_state()
+ *
+ * Revision 1.5  1999/08/25 17:00:02  keil
+ * Make ISAR V32bis modem running
+ * Make LL->HL interface open for additional commands
+ *
+ * Revision 1.4  1999/08/22 20:27:09  calle
+ * backported changes from kernel 2.3.14:
+ * - several #include "config.h" gone, others come.
+ * - "struct device" changed to "struct net_device" in 2.3.14, added a
+ *   define in isdn_compat.h for older kernel versions.
+ *
  * Revision 1.3  1999/07/12 21:05:18  keil
  * fix race in IRQ handling
  * added watchdog for lost IRQs
@@ -17,7 +30,6 @@
  */
 
 #define __NO_VERSION__
-#include <linux/config.h>
 #include "hisax.h"
 #include "isac.h"
 #include "isar.h"
@@ -25,7 +37,7 @@
 
 extern const char *CardType[];
 
-static const char *ISurf_revision = "$Revision: 1.3 $";
+static const char *ISurf_revision = "$Revision: 1.6 $";
 
 #define byteout(addr,val) outb(val,addr)
 #define bytein(addr) inb(addr)
@@ -175,18 +187,26 @@
 			return(0);
 		case CARD_TEST:
 			return(0);
-		case CARD_LOAD_FIRM:
-			if (isar_load_firmware(cs, arg))
-				return(1);
-			ll_run(cs);
+	}
+	return(0);
+}
+
+static int
+isurf_auxcmd(struct IsdnCardState *cs, isdn_ctrl *ic) {
+	int ret;
+
+	if ((ic->command == ISDN_CMD_IOCTL) && (ic->arg == 9)) {
+		ret = isar_auxcmd(cs, ic);
+		if (!ret) {
 			reset_isurf(cs, ISURF_ISAR_EA | ISURF_ISAC_RESET |
 				ISURF_ARCOFI_RESET);
 			initisac(cs);
 			cs->writeisac(cs, ISAC_MASK, 0);
 			cs->writeisac(cs, ISAC_CMDR, 0x41);
-			return(0);
+		}
+		return(ret);
 	}
-	return(0);
+	return(isar_auxcmd(cs, ic));
 }
 
 __initfunc(int
@@ -229,6 +249,7 @@
 
 	cs->cardmsg = &ISurf_card_msg;
 	cs->irq_func = &isurf_interrupt;
+	cs->auxcmd = &isurf_auxcmd;
 	cs->readisac = &ReadISAC;
 	cs->writeisac = &WriteISAC;
 	cs->readisacfifo = &ReadISACfifo;

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)