## Automatically generated incremental diff
## From:   linux-2.2.21-pre1
## To:     linux-2.2.21-pre2
## Robot:  $Id: make-incremental-diff,v 1.9 2001/12/10 00:06:56 hpa Exp $

diff -urN linux-2.2.21-pre1/Documentation/isdn/INTERFACE linux/Documentation/isdn/INTERFACE
--- linux-2.2.21-pre1/Documentation/isdn/INTERFACE	Fri Nov  2 08:39:05 2001
+++ linux/Documentation/isdn/INTERFACE	Wed Jan  2 03:55:23 2002
@@ -1,4 +1,4 @@
-$Id: INTERFACE,v 1.15.8.2 2001/03/13 16:17:07 kai Exp $
+$Id: INTERFACE,v 1.1 2001/05/26 11:47:14 armin Exp $
 
 Description of the Interface between Linklevel and Hardwarelevel
   of isdn4linux:
diff -urN linux-2.2.21-pre1/Documentation/isdn/INTERFACE.fax linux/Documentation/isdn/INTERFACE.fax
--- linux-2.2.21-pre1/Documentation/isdn/INTERFACE.fax	Sun Mar 25 08:31:58 2001
+++ linux/Documentation/isdn/INTERFACE.fax	Wed Jan  2 03:55:23 2002
@@ -1,4 +1,4 @@
-$Id: INTERFACE.fax,v 1.2 2000/08/06 09:22:50 armin Exp $
+$Id: INTERFACE.fax,v 1.1 2001/05/26 11:47:14 armin Exp $
 
 
 Description of the fax-subinterface between linklevel and hardwarelevel of 
diff -urN linux-2.2.21-pre1/Documentation/isdn/README.act2000 linux/Documentation/isdn/README.act2000
--- linux-2.2.21-pre1/Documentation/isdn/README.act2000	Sun Mar 25 08:31:58 2001
+++ linux/Documentation/isdn/README.act2000	Wed Jan  2 03:55:23 2002
@@ -1,4 +1,4 @@
-$Id: README.act2000,v 1.3 2000/08/06 09:22:51 armin Exp $
+$Id: README.act2000,v 1.1 2001/05/26 11:47:16 armin Exp $
 
 This document describes the ACT2000 driver for the
 IBM Active 2000 ISDN card.
diff -urN linux-2.2.21-pre1/Documentation/isdn/README.audio linux/Documentation/isdn/README.audio
--- linux-2.2.21-pre1/Documentation/isdn/README.audio	Sun Mar 25 08:31:58 2001
+++ linux/Documentation/isdn/README.audio	Wed Jan  2 03:55:23 2002
@@ -1,4 +1,4 @@
-$Id: README.audio,v 1.8 1999/07/11 17:17:29 armin Exp $
+$Id: README.audio,v 1.1 2001/05/26 11:47:17 armin Exp $
 
 ISDN subsystem for Linux.
   Description of audio mode.
diff -urN linux-2.2.21-pre1/Documentation/isdn/README.concap linux/Documentation/isdn/README.concap
--- linux-2.2.21-pre1/Documentation/isdn/README.concap	Sun Mar 25 08:31:58 2001
+++ linux/Documentation/isdn/README.concap	Wed Jan  2 03:55:23 2002
@@ -118,7 +118,7 @@
 	   or when the device driver resets the interface. All services of the
 	   encapsulation protocol may be used after this*/
 	int (*restart)(struct concap_proto *cprot, 
-		       struct net_device *ndev,
+		       struct device *ndev,
 		       struct concap_device_ops *dops);
 
 	/* deactivate an encapsulation protocol instance. The encapsulation
@@ -174,7 +174,7 @@
 
 An encapsulation protocol itself is actually the
 struct concap_proto{
-	struct net_device *net_dev;		/* net device using our service  */
+	struct device *net_dev;		/* net device using our service  */
 	struct concap_device_ops *dops; /* callbacks provided by device */
  	struct concap_proto_ops  *pops; /* callbacks provided by us */
 	int flags;
@@ -199,7 +199,7 @@
 encapsulation services could look like this:
 
 struct concap_device{
-	struct net_device net_dev;
+	struct device net_dev;
 	struct my_priv  /* device->local stuff */
 			/* the my_priv struct might contain a 
 			   struct concap_device_ops *dops;
@@ -225,9 +225,9 @@
 
 
 If general linux network interfaces explicitly supported concap
-protocols (e.g. by a member struct concap_proto* in struct net_device)
+protocols (e.g. by a member struct concap_proto* in struct device)
 then the interface of the service function could be changed
-by passing a pointer of type (struct net_device*) instead of
+by passing a pointer of type (struct device*) instead of
 type (struct concap_proto*). Doing so would make many of the service
 functions compatible to network device support functions.
 
@@ -237,7 +237,7 @@
 
 we could have
 
-  int (*encap_and_xmit)(struct net_device *ndev, struct sk_buff *skb);
+  int (*encap_and_xmit)(struct device *ndev, struct sk_buff *skb);
 
 As this is compatible to the dev->hard_start_xmit() method, the device
 driver could directly register the concap protocol's encap_and_xmit()
@@ -247,7 +247,7 @@
 
 The device's data request function could also be defined as
  
-  int (*data_req)(struct net_device *ndev, struct sk_buff *skb);
+  int (*data_req)(struct device *ndev, struct sk_buff *skb);
 
 This might even allow for some protocol stacking. And the network
 interface might even register the same data_req() function directly
diff -urN linux-2.2.21-pre1/Documentation/isdn/README.eicon linux/Documentation/isdn/README.eicon
--- linux-2.2.21-pre1/Documentation/isdn/README.eicon	Fri Nov  2 08:39:05 2001
+++ linux/Documentation/isdn/README.eicon	Wed Jan  2 03:55:23 2002
@@ -1,4 +1,4 @@
-$Id: README.eicon,v 1.10.6.1 2001/02/19 10:04:59 armin Exp $
+$Id: README.eicon,v 1.1 2001/05/26 11:47:18 armin Exp $
 
 (c) 1999,2000 Armin Schindler (mac@melware.de)
 (c) 1999,2000 Cytronics & Melware (info@melware.de)
diff -urN linux-2.2.21-pre1/Documentation/isdn/README.hysdn linux/Documentation/isdn/README.hysdn
--- linux-2.2.21-pre1/Documentation/isdn/README.hysdn	Sun Mar 25 08:37:29 2001
+++ linux/Documentation/isdn/README.hysdn	Wed Jan  2 03:55:23 2002
@@ -1,4 +1,4 @@
-$Id: README.hysdn,v 1.3.6.1 2001/02/10 14:41:19 kai Exp $
+$Id: README.hysdn,v 1.1 2001/05/26 11:47:18 armin Exp $
 The hysdn driver has been written by
 by Werner Cornelius (werner@isdn4linux.de or werner@titro.de) 
 for Hypercope GmbH Aachen Germany. Hypercope agreed to publish this driver
diff -urN linux-2.2.21-pre1/Documentation/isdn/README.icn linux/Documentation/isdn/README.icn
--- linux-2.2.21-pre1/Documentation/isdn/README.icn	Sun Mar 25 08:31:58 2001
+++ linux/Documentation/isdn/README.icn	Wed Jan  2 03:55:23 2002
@@ -1,4 +1,4 @@
-$Id: README.icn,v 1.7 2000/08/06 09:22:51 armin Exp $
+$Id: README.icn,v 1.1 2001/05/26 11:47:18 armin Exp $
 
 You can get the ICN-ISDN-card from:
 
diff -urN linux-2.2.21-pre1/Makefile linux/Makefile
--- linux-2.2.21-pre1/Makefile	Wed Jan  2 03:55:22 2002
+++ linux/Makefile	Wed Jan  2 03:55:23 2002
@@ -1,7 +1,7 @@
 VERSION = 2
 PATCHLEVEL = 2
 SUBLEVEL = 21
-EXTRAVERSION = pre1
+EXTRAVERSION = pre2
 
 ARCH := $(shell uname -m | sed -e s/i.86/i386/ -e s/sun4u/sparc64/ -e s/arm.*/arm/ -e s/sa110/arm/)
 
diff -urN linux-2.2.21-pre1/arch/i386/kernel/bluesmoke.c linux/arch/i386/kernel/bluesmoke.c
--- linux-2.2.21-pre1/arch/i386/kernel/bluesmoke.c	Fri Nov  2 08:39:05 2001
+++ linux/arch/i386/kernel/bluesmoke.c	Wed Jan  2 03:55:23 2002
@@ -1,17 +1,18 @@
-/*
- *	Machine Check Handler For PII/PIII
- */
 
-#include <linux/config.h>
+#include <linux/init.h>
 #include <linux/types.h>
 #include <linux/kernel.h>
 #include <linux/sched.h>
 #include <asm/processor.h> 
 #include <asm/msr.h>
 
-static int banks = 0;
+/*
+ *	Machine Check Handler For PII/PIII
+ */
+
+static int banks;
 
-void mcheck_fault(void)
+static void intel_machine_check(struct pt_regs * regs, long error_code)
 {
 	int recover=1;
 	u32 alow, ahigh, high, low;
@@ -37,7 +38,7 @@
 			high&=~(1<<31);
 			if(high&(1<<27))
 			{
-				rdmsr(0x403+i*4, alow, ahigh);
+				rdmsr(0x402+i*4, alow, ahigh);
 				printk("[%08x%08x]", alow, ahigh);
 			}
 			if(high&(1<<26))
@@ -50,7 +51,7 @@
 			/* Clear it */
 			wrmsr(0x401+i*4, 0UL, 0UL);
 			/* Serialize */
-			mb();
+			wmb();
 		}
 	}
 	
@@ -63,31 +64,101 @@
 	wrmsr(0x17a,mcgstl, mcgsth);
 }
 
+/*
+ *	Machine check handler for Pentium class Intel
+ */
+ 
+static void pentium_machine_check(struct pt_regs * regs, long error_code)
+{
+	u32 loaddr, hi, lotype;
+	rdmsr(0x0, loaddr, hi);
+	rdmsr(0x1, lotype, hi);
+	printk(KERN_EMERG "CPU#%d: Machine Check Exception:  0x%8X (type 0x%8X).\n", smp_processor_id(), loaddr, lotype);
+	if(lotype&(1<<5))
+		printk(KERN_EMERG "CPU#%d: Possible thermal failure (CPU on fire ?).\n", smp_processor_id());
+}
 
 /*
- *	This has to be run for each processor
+ *	Machine check handler for WinChip C6
  */
  
-void mcheck_init(void)
+static void winchip_machine_check(struct pt_regs * regs, long error_code)
+{
+	printk(KERN_EMERG "CPU#%d: Machine Check Exception.\n", smp_processor_id());
+}
+
+/*
+ *	Handle unconfigured int18 (should never happen)
+ */
+
+static void unexpected_machine_check(struct pt_regs * regs, long error_code)
+{	
+	printk(KERN_ERR "CPU#%d: Unexpected int18 (Machine Check).\n", smp_processor_id());
+}
+
+/*
+ *	Call the installed machine check handler for this CPU setup.
+ */ 
+ 
+static void (*machine_check_vector)(struct pt_regs *, long error_code) = unexpected_machine_check;
+
+void do_machine_check(struct pt_regs * regs, long error_code)
+{
+	machine_check_vector(regs, error_code);
+}
+
+/*
+ *	Set up machine check reporting for Intel processors
+ */
+
+void __init intel_mcheck_init(struct cpuinfo_x86 *c)
 {
 	u32 l, h;
 	int i;
-	struct cpuinfo_x86 *c;
-	static int done=0;
+	static int done;
+	
+	/*
+	 *	Check for MCE support
+	 */
 
-	c=cpu_data+smp_processor_id();
+	if(!(c->x86_capability&X86_FEATURE_MCE))
+		return;	
 	
-	if(c->x86_vendor!=X86_VENDOR_INTEL)
-		return;
+	/*
+	 *	Pentium machine check
+	 */
 	
-	if(!(c->x86_capability&X86_FEATURE_MCE))
+	if(c->x86 == 5)
+	{
+		machine_check_vector = pentium_machine_check;
+		wmb();
+		/* Read registers before enabling */
+		rdmsr(0x0, l, h);
+		rdmsr(0x1, l, h);
+		if(done==0)
+			printk(KERN_INFO "Intel old style machine check architecture supported.\n");
+		/* Enable MCE */	
+		__asm__ __volatile__ (
+			"movl %%cr4, %%eax\n\t"
+			"orl $0x40, %%eax\n\t"
+			"movl %%eax, %%cr4\n\t" : : : "eax");
+		printk(KERN_INFO "Intel old style machine check reporting enabled on CPU#%d.\n", smp_processor_id());
 		return;
-		
+	}
+	
+
+	/*
+	 *	Check for PPro style MCA
+	 */
+	 		
 	if(!(c->x86_capability&X86_FEATURE_MCA))
 		return;
 		
 	/* Ok machine check is available */
 	
+	machine_check_vector = intel_machine_check;
+	wmb();
+	
 	if(done==0)
 		printk(KERN_INFO "Intel machine check architecture supported.\n");
 	rdmsr(0x179, l, h);
@@ -102,10 +173,69 @@
 	{
 		wrmsr(0x401+4*i, 0x0, 0x0); 
 	}
+	set_in_cr4(X86_CR4_MCE);
+	printk(KERN_INFO "Intel machine check reporting enabled on CPU#%d.\n", smp_processor_id());
+	done=1;
+}
+
+/*
+ *	Set up machine check reporting on the Winchip C6 series
+ */
+ 
+static void __init winchip_mcheck_init(struct cpuinfo_x86 *c)
+{
+	u32 lo, hi;
+	/* Not supported on C3 */
+	if(c->x86 != 5)
+		return;
+	/* Winchip C6 */
+	machine_check_vector = winchip_machine_check;
+	wmb();
+	rdmsr(0x107, lo, hi);
+	lo|= (1<<2);	/* Enable EIERRINT (int 18 MCE) */
+	lo&= ~(1<<4);	/* Enable MCE */
+	wrmsr(0x107, lo, hi);
 	__asm__ __volatile__ (
 		"movl %%cr4, %%eax\n\t"
 		"orl $0x40, %%eax\n\t"
 		"movl %%eax, %%cr4\n\t" : : : "eax");
-	printk(KERN_INFO "Intel machine check reporting enabled on CPU#%d.\n", smp_processor_id());
-	done=1;
+	printk(KERN_INFO "Winchip machine check reporting enabled on CPU#%d.\n", smp_processor_id());
+}
+
+
+/*
+ *	This has to be run for each processor
+ */
+
+
+static int mce_disabled = 0;
+
+void __init mcheck_init(struct cpuinfo_x86 *c)
+{
+	if(mce_disabled)
+		return;
+		
+	switch(c->x86_vendor)
+	{
+		case X86_VENDOR_AMD:
+			/*
+			 *	AMD K7 machine check is Intel like
+			 */
+			if(c->x86 == 6)
+				intel_mcheck_init(c);
+			break;
+		case X86_VENDOR_INTEL:
+			intel_mcheck_init(c);
+			break;
+		case X86_VENDOR_CENTAUR:
+			winchip_mcheck_init(c);
+			break;
+	}
+}
+
+static int __init mcheck_disable(char *str, int *unused)
+{
+	mce_disabled = 1;
+	return 0;
 }
+__setup("nomce", mcheck_disable);
diff -urN linux-2.2.21-pre1/arch/i386/kernel/entry.S linux/arch/i386/kernel/entry.S
--- linux-2.2.21-pre1/arch/i386/kernel/entry.S	Fri Nov  2 08:39:05 2001
+++ linux/arch/i386/kernel/entry.S	Wed Jan  2 03:55:23 2002
@@ -366,7 +366,7 @@
 
 ENTRY(machine_check)
 	pushl $0
-	pushl $ SYMBOL_NAME(mcheck_fault)
+	pushl $ SYMBOL_NAME(do_machine_check)
 	jmp error_code
 
 ENTRY(spurious_interrupt_bug)
diff -urN linux-2.2.21-pre1/arch/i386/kernel/setup.c linux/arch/i386/kernel/setup.c
--- linux-2.2.21-pre1/arch/i386/kernel/setup.c	Sun Mar 25 08:37:29 2001
+++ linux/arch/i386/kernel/setup.c	Wed Jan  2 03:55:23 2002
@@ -36,9 +36,13 @@
  *	Added Cyrix III initial detection code
  *	Alan Cox <alan@redhat.com>, Septembr 2000
  *
- *      Improve cache size calculation
- *      Asit Mallick <asit.k.mallick@intel.com>, October 2000
- *      Andrew Ip <aip@turbolinux.com>, October 2000
+ *	Improve cache size calculation
+ *	Asit Mallick <asit.k.mallick@intel.com>, October 2000
+ *	Andrew Ip <aip@turbolinux.com>, October 2000
+ *
+ *	Backport various workarounds from 2.4.16
+ *	Dave Jones <davej@suse.de>, December 2001
+ *
  */
 
 /*
@@ -114,10 +118,13 @@
 extern int rd_image_start;	/* starting block # of image */
 #endif
 
+extern void mcheck_init(struct cpuinfo_x86 *c);
 extern int root_mountflags;
 extern int _etext, _edata, _end;
 extern unsigned long cpu_khz;
 
+static int disable_x86_serial_nr __initdata = 1;
+
 /*
  * This is set up by the setup-routine at boot-time
  */
@@ -386,8 +393,8 @@
 static char command_line[COMMAND_LINE_SIZE] = { 0, };
        char saved_command_line[COMMAND_LINE_SIZE];
 
-__initfunc(void setup_arch(char **cmdline_p,
-	unsigned long * memory_start_p, unsigned long * memory_end_p))
+void __init setup_arch(char **cmdline_p,
+	unsigned long * memory_start_p, unsigned long * memory_end_p)
 {
 	unsigned long memory_start, memory_end = 0;
 	char c = ' ', *to = command_line, *from = COMMAND_LINE;
@@ -572,49 +579,52 @@
 }
 
 
-__initfunc(static int get_model_name(struct cpuinfo_x86 *c))
+static int __init get_model_name(struct cpuinfo_x86 *c)
 {
-	unsigned int n, dummy, *v;
-
-	/* 
-	 * Actually we must have cpuid or we could never have
-	 * figured out that this was AMD/Centaur/Cyrix/Transmeta
-	 * from the vendor info :-).
-	 */
+	unsigned int *v;
+	char *p, *q;
 
-	cpuid(0x80000000, &n, &dummy, &dummy, &dummy);
-	if (n < 0x80000004)
+	if (cpuid_eax(0x80000000) < 0x80000004)
 		return 0;
-	cpuid(0x80000001, &dummy, &dummy, &dummy, &(c->x86_capability));
 	v = (unsigned int *) c->x86_model_id;
 	cpuid(0x80000002, &v[0], &v[1], &v[2], &v[3]);
 	cpuid(0x80000003, &v[4], &v[5], &v[6], &v[7]);
 	cpuid(0x80000004, &v[8], &v[9], &v[10], &v[11]);
 	c->x86_model_id[48] = 0;
-	
+
+	/* Intel chips right-justify this string for some dumb reason;
+	   undo that brain damage */
+	p = q = &c->x86_model_id[0];
+	while ( *p == ' ' )
+		p++;
+	if ( p != q ) {
+		while ( *p )
+			*q++ = *p++;
+		while ( q <= &c->x86_model_id[48] )
+			*q++ = '\0';  /* Zero-pad the rest */
+	}
 	return 1;
 }
 
 
-__initfunc (static void display_cacheinfo(struct cpuinfo_x86 *c))
+static void __init display_cacheinfo(struct cpuinfo_x86 *c)
 {
-	unsigned int n, dummy, ecx, edx;
+	unsigned int n, dummy, ecx, edx, l2size;
 
-	cpuid(0x80000000, &n, &dummy, &dummy, &dummy);
+	n = cpuid_eax(0x80000000);
 
 	if (n >= 0x80000005){
 		cpuid(0x80000005, &dummy, &dummy, &ecx, &edx);
-		printk("CPU: L1 I Cache: %dK  L1 D Cache: %dK\n",
-			ecx>>24, edx>>24);
+		printk("CPU: L1 I Cache: %dK (%d bytes/line), D cache %dK (%d bytes/line)\n",
+			edx>>24, edx&0xFF, ecx>>24, ecx&0xFF);
 		c->x86_cache_size=(ecx>>24)+(edx>>24);
 	}
 
-	/* Yes this can occur - the CyrixIII just has a large L1 */
-	if (n < 0x80000006)
-		return;	/* No function to get L2 info */
+	if (n < 0x80000006)	/* Some chips just has a large L1. */
+		return;
 
-	cpuid(0x80000006, &dummy, &dummy, &ecx, &edx);
-	c->x86_cache_size = ecx>>16;
+	ecx = cpuid_ecx(0x80000006);
+	l2size = ecx >> 16;
 
 	/* AMD errata T13 (order #21922) */
 	if(boot_cpu_data.x86_vendor == X86_VENDOR_AMD &&
@@ -622,15 +632,20 @@
 		boot_cpu_data.x86_model== 3 &&
 		boot_cpu_data.x86_mask == 0)
 	{
-		c->x86_cache_size = 64;
+		l2size = 64;
 	}
 
-	printk("CPU: L2 Cache: %dK\n", c->x86_cache_size);
-}
+	if (l2size == 0)
+		return;		/* Again, no L2 cache is possible */
 
+	c->x86_cache_size = l2size;
 
+	printk("CPU: L2 Cache: %dK (%d bytes/line)\n",
+		l2size, ecx & 0xFF);
+}
 
-__initfunc(static int amd_model(struct cpuinfo_x86 *c))
+
+static int __init init_amd(struct cpuinfo_x86 *c)
 {
 	u32 l, h;
 	unsigned long flags;
@@ -645,23 +660,24 @@
 	switch(c->x86)
 	{
 		case 5:
-			if( c->x86_model < 6 )
-			{
-				/* Anyone with a K5 want to fill this in */				
+			if( c->x86_model < 6 ) {
+				/* Based on AMD doc 20734R - June 2000 */
+				if ( c->x86_model == 0 ) {
+					c->x86_capability&=~X86_FEATURE_APIC;
+					c->x86_capability|=X86_FEATURE_PGE;
+				}
 				break;
 			}
 
 			/* K6 with old style WHCR */
-			if( c->x86_model < 8 ||
-				(c->x86_model== 8 && c->x86_mask < 8))
-			{
+			if (c->x86_model < 8 ||
+			   (c->x86_model== 8 && c->x86_mask < 8)) {
 				/* We can only write allocate on the low 508Mb */
 				if(mbytes>508)
 					mbytes=508;
-					
+
 				rdmsr(0xC0000082, l, h);
-				if((l&0x0000FFFF)==0)
-				{		
+				if((l&0x0000FFFF)==0) {		
 					l=(1<<0)|((mbytes/4)<<1);
 					save_flags(flags);
 					__cli();
@@ -670,20 +686,19 @@
 					restore_flags(flags);
 					printk(KERN_INFO "Enabling old style K6 write allocation for %d Mb\n",
 						mbytes);
-
 				}
 				break;
 			}
-			if (c->x86_model == 8 || c->x86_model == 9 || c->x86_model == 13)
-			{
+
+			if ((c->x86_model == 8 && c->x86_mask >7) ||
+			     c->x86_model == 9 || c->x86_model == 13) {
 				/* The more serious chips .. */
-				
+
 				if(mbytes>4092)
 					mbytes=4092;
 
 				rdmsr(0xC0000082, l, h);
-				if((l&0xFFFF0000)==0)
-				{
+				if((l&0xFFFF0000)==0) {
 					l=((mbytes>>2)<<22)|(1<<16);
 					save_flags(flags);
 					__cli();
@@ -695,35 +710,21 @@
 				}
 
 				/*  Set MTRR capability flag if appropriate  */
-				if((boot_cpu_data.x86_model == 13) ||
-				   (boot_cpu_data.x86_model == 9) ||
-				  ((boot_cpu_data.x86_model == 8) && 
-				   (boot_cpu_data.x86_mask >= 8)))
+				if (c->x86_model == 13 || c->x86_model == 9 ||
+				   (c->x86_model == 8 && c->x86_mask >= 8))
 					c->x86_capability |= X86_FEATURE_MTRR;
 				break;
 			}
 			break;
 
 		case 6:	/* An Athlon. We can trust the BIOS probably */
-		{
 			break;
-		}
 	}
 
 	display_cacheinfo(c);
 	return r;
 }
 
-__initfunc(static void intel_model(struct cpuinfo_x86 *c))
-{
-	unsigned int *v = (unsigned int *) c->x86_model_id;
-	cpuid(0x80000002, &v[0], &v[1], &v[2], &v[3]);
-	cpuid(0x80000003, &v[4], &v[5], &v[6], &v[7]);
-	cpuid(0x80000004, &v[8], &v[9], &v[10], &v[11]);
-	c->x86_model_id[48] = 0;
-	printk("CPU: %s\n", c->x86_model_id);
-}
-			
 
 /*
  * Read Cyrix DEVID registers (DIR) to get more detailed info. about the CPU
@@ -784,7 +785,7 @@
 static char cyrix_model_mult1[] __initdata = "12??43";
 static char cyrix_model_mult2[] __initdata = "12233445";
 
-__initfunc(static void cyrix_model(struct cpuinfo_x86 *c))
+static void __init init_cyrix(struct cpuinfo_x86 *c)
 {
 	unsigned char dir0, dir0_msn, dir0_lsn, dir1 = 0;
 	char *buf = c->x86_model_id;
@@ -860,6 +861,8 @@
                 isa_dma_bridge_buggy = 2;
                   	                                                                     	        
 #endif
+		c->x86_cache_size=16;   /* Yep 16K integrated cache thats it */
+
 		/* GXm supports extended cpuid levels 'ala' AMD */
 		if (c->cpuid_level == 2) {
 			get_model_name(c);  /* get CPU marketing name */
@@ -875,8 +878,13 @@
 		break;
 
         case 5: /* 6x86MX/M II */
-		if (dir1 > 7) dir0_msn++;  /* M II */
-		else c->coma_bug = 1;      /* 6x86MX, it has the bug. */
+		if (dir1 > 7) {
+			dir0_msn++;  /* M II */
+			/* Enable MMX extensions (App note 108) */
+			setCx86(CX86_CCR7, getCx86(CX86_CCR7)|1);
+		} else {
+			c->coma_bug = 1;      /* 6x86MX, it has the bug. */
+		}
 		tmp = (!(dir0_lsn & 7) || dir0_lsn & 1) ? 2 : 0;
 		Cx86_cb[tmp] = cyrix_model_mult2[dir0_lsn & 7];
 		p = Cx86_cb+tmp;
@@ -897,8 +905,8 @@
 			dir0_msn = 0;
 			p = Cx486S_name[0];
 			break;
-		break;
 		}
+		break;
 
 	default:  /* unknown (shouldn't happen, we know everyone ;-) */
 		dir0_msn = 7;
@@ -909,7 +917,7 @@
 	return;
 }
 
-__initfunc(static void transmeta_model(struct cpuinfo_x86 *c))
+static void __init init_transmeta(struct cpuinfo_x86 *c)
 {
 	unsigned int cap_mask, uk, max, dummy;
 	unsigned int cms_rev1, cms_rev2;
@@ -974,7 +982,31 @@
 }
 
 
-__initfunc(void get_cpu_vendor(struct cpuinfo_x86 *c))
+static void __init init_rise(struct cpuinfo_x86 *c)
+{
+	printk("CPU: Rise iDragon");
+	if (c->x86_model > 2)
+		printk(" II");
+	printk("\n");
+
+	/* Unhide possibly hidden capability flags
+	 * The mp6 iDragon family don't have MSRs
+	 * We switch on extra features with this cpuid weirdness: */
+	__asm__ (
+		"movl $0x6363452a, %%eax\n\t"
+		"movl $0x3231206c, %%ecx\n\t"
+		"movl $0x2a32313a, %%edx\n\t"
+		"cpuid\n\t"
+		"movl $0x63634523, %%eax\n\t"
+		"movl $0x32315f6c, %%ecx\n\t"
+		"movl $0x2333313a, %%edx\n\t"
+		"cpuid\n\t" : : : "eax", "ebx", "ecx", "edx"
+	);
+	c->x86_capability |= X86_FEATURE_CX8;
+}
+
+
+static void __init get_cpu_vendor(struct cpuinfo_x86 *c)
 {
 	char *v = c->x86_vendor_id;
 
@@ -998,9 +1030,211 @@
 		c->x86_vendor = X86_VENDOR_UNKNOWN;
 }
 
+
+static void __init init_centaur(struct cpuinfo_x86 *c)
+{
+	u32 hv,lv;
+	
+	/* Centaur C6 Series */
+	if(c->x86==5)
+	{
+		rdmsr(0x107, lv, hv);
+		printk("Centaur FSR was 0x%X ",lv);
+		lv|=(1<<1 | 1<<2 | 1<<7);
+		/* lv|=(1<<6);	- may help too if the board can cope */
+		printk("now 0x%X\n", lv);
+		wrmsr(0x107, lv, hv);
+		/* Emulate MTRRs using Centaur's MCR. */
+		c->x86_capability |= X86_FEATURE_MTRR;
+
+		/* Disable TSC on C6 as per errata. */
+		if (c->x86_model ==4) {
+			printk ("Disabling bugged TSC.\n");
+			c->x86_capability &= ~X86_FEATURE_TSC;
+		}
+
+		/* Set 3DNow! on Winchip 2 and above. */
+		if (c->x86_model >=8)
+		    c->x86_capability |= X86_FEATURE_AMD3D;
+
+		c->x86_capability |=X86_FEATURE_CX8;
+	}
+	/* Cyrix III 'Samuel' CPU */
+	if(c->x86 == 6 && c->x86_model == 6)
+	{
+		rdmsr(0x1107, lv, hv);
+		lv|=(1<<1);	/* Report CX8 */
+		lv|=(1<<7);	/* PGE enable */
+		wrmsr(0x1107, lv, hv);
+		/* Cyrix III */
+		c->x86_capability |= X86_FEATURE_CX8;
+		
+		/* Check for 3dnow */
+		cpuid(0x80000001, &lv, &lv, &lv, &hv);
+		if(hv&(1<<31))
+			c->x86_capability |= X86_FEATURE_AMD3D;
+	}	
+}
+
+
+static void __init init_intel(struct cpuinfo_x86 *c)
+{
+	char *p;
+	unsigned int l1i = 0, l1d = 0, l2 = 0, l3 = 0; /* Cache sizes */
+
+	if (c->cpuid_level > 1) {
+		/* supports eax=2  call */
+		int i, j, n;
+		int regs[4];
+		unsigned char *dp = (unsigned char *)regs;
+
+		/* Number of times to iterate */
+		n = cpuid_eax(2) & 0xFF;
+
+		for ( i = 0 ; i < n ; i++ ) {
+			cpuid(2, &regs[0], &regs[1], &regs[2], &regs[3]);
+			
+			/* If bit 31 is set, this is an unknown format */
+			for ( j = 0 ; j < 3 ; j++ ) {
+				if ( regs[j] < 0 ) regs[j] = 0;
+			}
+
+			/* Byte 0 is level count, not a descriptor */
+			for ( j = 1 ; j < 16 ; j++ ) {
+				unsigned char des = dp[j];
+				unsigned char dl, dh;
+				unsigned int cs;
+
+				dh = des >> 4;
+				dl = des & 0x0F;
+
+				/* Black magic... */
+
+				switch ( dh )
+				{
+				case 0:
+					switch ( dl ) {
+					case 6:
+						/* L1 I cache */
+						l1i += 8;
+						break;
+					case 8:
+						/* L1 I cache */
+						l1i += 16;
+						break;
+					case 10:
+						/* L1 D cache */
+						l1d += 8;
+						break;
+					case 12:
+						/* L1 D cache */
+						l1d += 16;
+						break;
+					default:;
+						/* TLB, or unknown */
+					}
+					break;
+				case 2:
+					if ( dl ) {
+						/* L3 cache */
+						cs = (dl-1) << 9;
+						l3 += cs;
+					}
+					break;
+				case 4:
+					if ( c->x86 > 6 && dl ) {
+						/* P4 family */
+						/* L3 cache */
+						cs = 128 << (dl-1);
+						l3 += cs;
+						break;
+					}
+					/* else same as 8 - fall through */
+				case 8:
+					if ( dl ) {
+						/* L2 cache */
+						cs = 128 << (dl-1);
+						l2 += cs;
+					}
+					break;
+				case 6:
+					if (dl > 5) {
+						/* L1 D cache */
+						cs = 8<<(dl-6);
+						l1d += cs;
+					}
+					break;
+				case 7:
+					if ( dl >= 8 ) 
+					{
+						/* L2 cache */
+						cs = 64<<(dl-8);
+						l2 += cs;
+					} else {
+						/* L0 I cache, count as L1 */
+						cs = dl ? (16 << (dl-1)) : 12;
+						l1i += cs;
+					}
+					break;
+				default:
+					/* TLB, or something else we don't know about */
+					break;
+				}
+			}
+		}
+		if ( l1i || l1d )
+			printk(KERN_INFO "CPU: L1 I cache: %dK, L1 D cache: %dK\n",
+			       l1i, l1d);
+		if ( l2 )
+			printk(KERN_INFO "CPU: L2 cache: %dK\n", l2);
+		if ( l3 )
+			printk(KERN_INFO "CPU: L3 cache: %dK\n", l3);
+
+		/*
+		 * This assumes the L3 cache is shared; it typically lives in
+		 * the northbridge.  The L1 caches are included by the L2
+		 * cache, and so should not be included for the purpose of
+		 * SMP switching weights.
+		 */
+		c->x86_cache_size = l2 ? l2 : (l1i+l1d);
+	}
+
+	/*
+	 *	Intel finally adopted the AMD/Cyrix extended id naming
+	 *	stuff for the 'Pentium IV'
+	 */
+
+	if (c->x86 == 15) {
+		get_model_name(c);
+		printk("CPU: %s\n", c->x86_model_id);
+		return;
+	}
+
+	/* Names for the Pentium II Celeron processors
+	   detectable only by also checking the cache size */
+    if (c->x86 == 6) { 
+		switch (c->x86_model) {
+			case 5:
+				if (c->x86_cache_size == 0)
+					p = "Celeron (Covington)";
+				if (c->x86_cache_size == 256)
+					p = "Mobile Pentium II (Dixon)";
+				break;
+			case 6:
+				if (c->x86_cache_size == 128)
+					p = "Celeron (Mendocino)";
+				break;
+			case 8:
+				if (c->x86_cache_size == 128)
+					p = "Celeron (Coppermine)";
+				break;
+		}
+	}
+}
+
 struct cpu_model_info {
 	int vendor;
-	int x86;
+	int family;
 	char *model_names[16];
 };
 
@@ -1042,189 +1276,120 @@
 	{ X86_VENDOR_NEXGEN,	5,
 	  { "Nx586", NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL,
 	    NULL, NULL, NULL, NULL, NULL, NULL, NULL }},
+	{ X86_VENDOR_RISE,  5,
+	  { "iDragon", NULL, "iDragon", NULL, NULL, NULL, NULL,
+	    NULL, "iDragon II", "iDragon II", NULL, NULL, NULL, NULL, NULL, NULL }},
 };
 
-__initfunc(void identify_cpu(struct cpuinfo_x86 *c))
+
+static char __init *table_lookup_model(struct cpuinfo_x86 *c)
 {
+	struct cpu_model_info *info = cpu_models;
 	int i;
-	char *p = NULL;
-	extern void mcheck_init(void);
-	
-	c->loops_per_jiffy = loops_per_jiffy;
-	c->x86_cache_size = -1;
 
-	get_cpu_vendor(c);
+	if ( c->x86_model >= 16 )
+		return NULL;	/* Range check */
+
+	for ( i = 0 ; i < sizeof(cpu_models)/sizeof(struct cpu_model_info) ; i++ ) {
+		if ( info->vendor == c->x86_vendor &&
+			info->family == c->x86 ) {
+			return info->model_names[c->x86_model];
+		}
+		info++;
+	}
+	return NULL;	/* Not found */
+}
 
-	if (c->x86_vendor == X86_VENDOR_UNKNOWN &&
-	    c->cpuid_level < 0)
-		return;
 
-	/* It should be possible for the user to override this. */
-	if(c->cpuid_level > 0 && 
-	   (c->x86_vendor == X86_VENDOR_INTEL || c->x86_vendor == X86_VENDOR_TRANSMETA) &&
-	   c->x86_capability&(1<<18)) {
+static void __init squash_the_stupid_serial_number(struct cpuinfo_x86 *c)
+{
+	if (c->x86_capability&(X86_FEATURE_PN) && disable_x86_serial_nr) {
 		/* Disable processor serial number */
 		unsigned long lo,hi;
 		rdmsr(0x119,lo,hi);
 		lo |= 0x200000;
 		wrmsr(0x119,lo,hi);
-		printk(KERN_INFO "CPU serial number disabled.\n");
-	}
-
-	mcheck_init();
-	
-	if (c->x86_vendor == X86_VENDOR_CYRIX) {
-		cyrix_model(c);
-		return;
-	}
-
-	if (c->x86_vendor == X86_VENDOR_AMD && amd_model(c))
-		return;
-		
-	if (c->x86_vendor == X86_VENDOR_TRANSMETA) {
-		transmeta_model(c);
-		return;
-	}
-	
-	if(c->x86_vendor == X86_VENDOR_CENTAUR && c->x86==6)
-	{
-		/* The Cyrix III supports model naming and cache queries */
-		get_model_name(c);
-		display_cacheinfo(c);
-		return;
+		printk(KERN_NOTICE "CPU serial number disabled.\n");
+		c->x86_capability &= ~X86_FEATURE_PN;
+		c->cpuid_level = cpuid_eax(0);
 	}
+}
+int __init x86_serial_nr_setup(char *s)
+{
+	disable_x86_serial_nr = 0;
+	return 1;
+}
+__setup("serialnumber", x86_serial_nr_setup);
 
-	if (c->cpuid_level > 1) {
-		/* supports eax=2  call */
-		int regs[4];
-		int l1c=0, l1d=0, l2=0, l3=0;	/* Cache sizes */
-
-		cpuid(2, &regs[0], &regs[1], &regs[2], &regs[3]);
-
-		/* Least significant byte of eax says how many times
-		 * to call cpuid with value 2 to get cache and TLB
-		 * info.
-		 */
-		if ((regs[0] & 0xFF) != 1 )
-			printk(KERN_WARNING "Multiple cache reports are not supported yet\n");
-
-		c->x86_cache_size = 0;
-
-		for ( i = 0 ; i < 4 ; i++ ) {
-
-			int j;
-
-			if ( regs[i] < 0 )
-				continue; /* no useful data */
-
-			/* look at all the bytes returned */
-
-			for ( j = ( i == 0 ? 8:0 ) ; j < 25 ; j+=8 ) {
-
-				unsigned char rh = regs[i]>>j;
-				unsigned char rl;
-
-				rl = rh & 0x0F;
-				rh >>=4;
-
-				switch(rh) {
-
-					case 2:
-						if(rl) {
-							printk("%dK L3 cache\n", (rl-1)*512);
-							l3 += (rl-1)*512;
-						}
-						break;
-
-					case 4:
-					case 8:
-						if(rl) {
-							printk("%dK L2 cache (%d way)\n",128<<(rl-1), rh);
-							l2 += 128<<(rl-1);
-						}
-						break;
 
-					/*
-					 *	L1 caches do not count for SMP switching weights,
-					 *	they are shadowed by L2.
-					 */
+__initfunc(void identify_cpu(struct cpuinfo_x86 *c))
+{
+	c->loops_per_jiffy = loops_per_jiffy;
+	c->x86_cache_size = -1;
 
-					case 6:
-						if(rh==6 && rl > 5) {
-							printk("%dK L1 data cache\n", 8<<(rl - 6));
-							l1d+=8<<(rl-6);
-						}
-						break;
+	get_cpu_vendor(c);
 
-					case 7:
-						printk("%dK L1 instruction cache\n",
-						rl?(16<<(rl-1)):12);
-						l1c+=rl?(16<<(rl-1)):12;
-						break;
-				}	              
-			}   			
-		}
+	switch (c->x86_vendor) {
+		case X86_VENDOR_UNKNOWN:
+		default:
+			/* Not much we can do here... */
+			/* Check if at least it has cpuid */
+			if (c->cpuid_level == -1) {
+				/* No cpuid. It must be an ancient CPU */
+				if (c->x86 == 4)
+					strcpy(c->x86_model_id, "486");
+				else if (c->x86 == 3)
+					strcpy(c->x86_model_id, "386");
+			}
+			break;
 
-		if(l1c && l1d)
-			printk("CPU: L1 I Cache: %dK  L1 D Cache: %dK\n", l1c, l1d);
-		if(l2)
-			printk("CPU: L2 Cache: %dK\n", l2);
-		if(l3)
-			printk("CPU: L3 Cache: %dK\n", l3);
+		case X86_VENDOR_CYRIX:
+			init_cyrix(c);
+			return;
 
-		/*
-		 *	Assuming L3 is shared. The L1 cache is shadowed by L2
-		 *	so doesn't need to be included.
-		 */
+		case X86_VENDOR_AMD:
+			init_amd(c);
+			return;
 
-		c->x86_cache_size += l2;
-	}
+		case X86_VENDOR_CENTAUR:
+			init_centaur(c);
+			return;
 
-	/*
-	 *	Intel finally adopted the AMD/Cyrix extended id naming
-	 *	stuff for the 'Pentium IV'
-	 */
+		case X86_VENDOR_TRANSMETA:
+			init_transmeta(c);
+			return;
 
-	if(c->x86_vendor ==X86_VENDOR_INTEL && c->x86 == 15)
-	{
-		intel_model(c);
-		return;
-	}
+		case X86_VENDOR_RISE:
+			init_rise(c);
+			break;
 
-	for (i = 0; i < sizeof(cpu_models)/sizeof(struct cpu_model_info); i++) {
-		if (cpu_models[i].vendor == c->x86_vendor &&
-		    cpu_models[i].x86 == c->x86) {
-			if (c->x86_model <= 16)
-				p = cpu_models[i].model_names[c->x86_model];
-
-			/* Names for the Pentium II Celeron processors
-			   detectable only by also checking the cache size */
-			if ((cpu_models[i].vendor == X86_VENDOR_INTEL)
-			    && (cpu_models[i].x86 == 6)){ 
-				if(c->x86_model == 6 && c->x86_cache_size == 128) {
-					p = "Celeron (Mendocino)"; 
-				} else { 
-					if (c->x86_model == 5 && c->x86_cache_size == 0) {
-						p = "Celeron (Covington)";
-					}
-				}
-			}
-		}
+		case X86_VENDOR_INTEL:
+			init_intel(c);
+			break;
 	}
+	
+	squash_the_stupid_serial_number(c);
 
-	if (p) {
-		strcpy(c->x86_model_id, p);
-		return;
+	mcheck_init(c);
+	
+	/* If the model name is still unset, do table lookup. */
+	if ( !c->x86_model_id[0] ) {
+		char *p;
+		p = table_lookup_model(c);
+		if ( p )
+			strcpy(c->x86_model_id, p);
+		else
+			/* Last resort... */
+			sprintf(c->x86_model_id, "%02x/%02x",
+				c->x86_vendor, c->x86_model);
 	}
-
-	sprintf(c->x86_model_id, "%02x/%02x", c->x86_vendor, c->x86_model);
 }
 
 /*
  *	Perform early boot up checks for a valid TSC. See arch/i386/kernel/time.c
  */
  
-__initfunc(void dodgy_tsc(void))
+void __init dodgy_tsc(void)
 {
 	get_cpu_vendor(&boot_cpu_data);
 	
@@ -1232,61 +1397,15 @@
 	{
 		return;
 	}
-	cyrix_model(&boot_cpu_data);
+	init_cyrix(&boot_cpu_data);
 }
 	
-	
 
 static char *cpu_vendor_names[] __initdata = {
 	"Intel", "Cyrix", "AMD", "UMC", "NexGen", "Centaur", "Rise", "Transmeta" };
 
 
-__initfunc(void setup_centaur(struct cpuinfo_x86 *c))
-{
-	u32 hv,lv;
-	
-	/* Centaur C6 Series */
-	if(c->x86==5)
-	{
-		rdmsr(0x107, lv, hv);
-		printk("Centaur FSR was 0x%X ",lv);
-		lv|=(1<<1 | 1<<2 | 1<<7);
-		/* lv|=(1<<6);	- may help too if the board can cope */
-		printk("now 0x%X\n", lv);
-		wrmsr(0x107, lv, hv);
-		/* Emulate MTRRs using Centaur's MCR. */
-		c->x86_capability |= X86_FEATURE_MTRR;
-
-		/* Disable TSC on C6 as per errata. */
-		if (c->x86_model ==4) {
-			printk ("Disabling bugged TSC.\n");
-			c->x86_capability &= ~X86_FEATURE_TSC;
-		}
-
-		/* Set 3DNow! on Winchip 2 and above. */
-		if (c->x86_model >=8)
-		    c->x86_capability |= X86_FEATURE_AMD3D;
-
-		c->x86_capability |=X86_FEATURE_CX8;
-	}
-	/* Cyrix III 'Samuel' CPU */
-	if(c->x86 == 6 && c->x86_model == 6)
-	{
-		rdmsr(0x1107, lv, hv);
-		lv|=(1<<1);	/* Report CX8 */
-		lv|=(1<<7);	/* PGE enable */
-		wrmsr(0x1107, lv, hv);
-		/* Cyrix III */
-		c->x86_capability |= X86_FEATURE_CX8;
-		
-		/* Check for 3dnow */
-		cpuid(0x80000001, &lv, &lv, &lv, &hv);
-		if(hv&(1<<31))
-			c->x86_capability |= X86_FEATURE_AMD3D;
-	}	
-}
-
-__initfunc(void print_cpu_info(struct cpuinfo_x86 *c))
+void __init print_cpu_info(struct cpuinfo_x86 *c)
 {
 	char *vendor = NULL;
 
@@ -1307,12 +1426,9 @@
 		printk(" stepping %02x\n", c->x86_mask);
 	else
 		printk("\n");
-
-	if(c->x86_vendor == X86_VENDOR_CENTAUR) {
-		setup_centaur(c);
-	}
 }
 
+
 /*
  *	Get CPU information for use by the procfs.
  */
@@ -1322,10 +1438,10 @@
 	char *p = buffer;
 	int sep_bug;
 	static char *x86_cap_flags[] = {
-	        "fpu", "vme", "de", "pse", "tsc", "msr", "pae", "mce",
-	        "cx8", "apic", "10", "sep", "mtrr", "pge", "mca", "cmov",
-	        "16", "pse36", "psn", "19", "20", "21", "22", "mmx",
-	        "24", "xmm", "26", "27", "28", "29", "30", "31"
+		"fpu", "vme", "de", "pse", "tsc", "msr", "pae", "mce",
+		"cx8", "apic", "10", "sep", "mtrr", "pge", "mca", "cmov",
+		"pat", "pse36", "pn", "clflush", "20", "dts", "acpi", "mmx",
+		"fxsr", "sse", "sse2", "ss", "28", "tm", "ia64", "31"
 	};
 	struct cpuinfo_x86 *c = cpu_data;
 	int i, n;
diff -urN linux-2.2.21-pre1/arch/i386/mm/init.c linux/arch/i386/mm/init.c
--- linux-2.2.21-pre1/arch/i386/mm/init.c	Sun Mar 25 08:37:30 2001
+++ linux/arch/i386/mm/init.c	Wed Jan  2 03:55:23 2002
@@ -185,33 +185,8 @@
 extern char _text, _etext, _edata, __bss_start, _end;
 extern char __init_begin, __init_end;
 
-#define X86_CR4_VME		0x0001		/* enable vm86 extensions */
-#define X86_CR4_PVI		0x0002		/* virtual interrupts flag enable */
-#define X86_CR4_TSD		0x0004		/* disable time stamp at ipl 3 */
-#define X86_CR4_DE		0x0008		/* enable debugging extensions */
-#define X86_CR4_PSE		0x0010		/* enable page size extensions */
-#define X86_CR4_PAE		0x0020		/* enable physical address extensions */
-#define X86_CR4_MCE		0x0040		/* Machine check enable */
-#define X86_CR4_PGE		0x0080		/* enable global pages */
-#define X86_CR4_PCE		0x0100		/* enable performance counters at ipl 3 */
-
-/*
- * Save the cr4 feature set we're using (ie
- * Pentium 4MB enable and PPro Global page
- * enable), so that any CPU's that boot up
- * after us can get the correct flags.
- */
 unsigned long mmu_cr4_features __initdata = 0;
 
-static inline void set_in_cr4(unsigned long mask)
-{
-	mmu_cr4_features |= mask;
-	__asm__("movl %%cr4,%%eax\n\t"
-		"orl %0,%%eax\n\t"
-		"movl %%eax,%%cr4\n"
-		: : "irg" (mask)
-		:"ax");
-}
 
 /*
  * allocate page table(s) for compile-time fixed mappings
diff -urN linux-2.2.21-pre1/drivers/char/sx.c linux/drivers/char/sx.c
--- linux-2.2.21-pre1/drivers/char/sx.c	Sun Mar 25 08:37:31 2001
+++ linux/drivers/char/sx.c	Wed Jan  2 03:55:23 2002
@@ -1169,7 +1169,8 @@
 				/* DCD went UP */
 				if( (~(port->gs.flags & ASYNC_NORMAL_ACTIVE) || 
 						 ~(port->gs.flags & ASYNC_CALLOUT_ACTIVE)) &&
-						(sx_read_channel_byte(port, hi_hstat) != HS_IDLE_CLOSED)) {
+						(sx_read_channel_byte(port, hi_hstat) != HS_IDLE_CLOSED) &&
+						!(port->gs.tty->termios->c_cflag & CLOCAL) ) {
 					/* Are we blocking in open?*/
 					sx_dprintk (SX_DEBUG_MODEMSIGNALS, "DCD active, unblocking open\n");
 					wake_up_interruptible(&port->gs.open_wait);
@@ -1179,7 +1180,8 @@
 			} else {
 				/* DCD went down! */
 				if (!((port->gs.flags & ASYNC_CALLOUT_ACTIVE) &&
-				      (port->gs.flags & ASYNC_CALLOUT_NOHUP))) {
+				      (port->gs.flags & ASYNC_CALLOUT_NOHUP)) &&
+				    !(port->gs.tty->termios->c_cflag & CLOCAL) ) {
 					sx_dprintk (SX_DEBUG_MODEMSIGNALS, "DCD dropped. hanging up....\n");
 					tty_hangup (port->gs.tty);
 				} else {
diff -urN linux-2.2.21-pre1/drivers/isdn/Config.in linux/drivers/isdn/Config.in
--- linux-2.2.21-pre1/drivers/isdn/Config.in	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/Config.in	Wed Jan  2 03:55:23 2002
@@ -16,9 +16,7 @@
 if [ "$CONFIG_ISDN_AUDIO" != "n" ]; then
    bool '    Support AT-Fax Class 1 and 2 commands' CONFIG_ISDN_TTY_FAX
 fi
-
-#  CONFIG_X25 is defined only when CONFIG_EXPERIMENTAL=y
-if [ "$CONFIG_EXPERIMENTAL" = "y" -a "$CONFIG_X25" != "n" ]; then
+if [ "$CONFIG_X25" != "n" ]; then
    bool '  X.25 PLP on top of ISDN' CONFIG_ISDN_X25
 fi
 
@@ -71,8 +69,8 @@
    bool '  Gazel cards' CONFIG_HISAX_GAZEL
    bool '  HFC PCI-Bus cards' CONFIG_HISAX_HFC_PCI
    bool '  Winbond W6692 based cards' CONFIG_HISAX_W6692
-   bool '  HFC-S+, HFC-SP, HFC-PCMCIA cards' CONFIG_HISAX_HFC_SX
    if [ "$CONFIG_EXPERIMENTAL" != "n" ]; then
+      bool '  HFC-S+, HFC-SP, HFC-PCMCIA cards' CONFIG_HISAX_HFC_SX
 #      bool '  TESTEMULATOR (EXPERIMENTAL)' CONFIG_HISAX_TESTEMU
       if [ "$ARCH" = "sparc" -o "$ARCH" = "sparc64" ]; then
 	 bool '  Am7930' CONFIG_HISAX_AMD7930
@@ -130,7 +128,7 @@
    dep_tristate '  AVM B1 PCI support' CONFIG_ISDN_DRV_AVMB1_B1PCI $CONFIG_ISDN_CAPI $CONFIG_PCI
    dep_mbool    '    AVM B1 PCI V4 support' CONFIG_ISDN_DRV_AVMB1_B1PCIV4 $CONFIG_ISDN_DRV_AVMB1_B1PCI
    dep_tristate '  AVM T1/T1-B ISA support' CONFIG_ISDN_DRV_AVMB1_T1ISA $CONFIG_ISDN_CAPI
-   dep_tristate '  AVM B1/M1/M2 PCMCIA support' CONFIG_ISDN_DRV_AVMB1_B1PCMCIA $CONFIG_ISDN_CAPI $CONFIG_PCMCIA
+   dep_tristate '  AVM B1/M1/M2 PCMCIA support' CONFIG_ISDN_DRV_AVMB1_B1PCMCIA $CONFIG_ISDN_CAPI
    dep_tristate '  AVM T1/T1-B PCI support' CONFIG_ISDN_DRV_AVMB1_T1PCI $CONFIG_ISDN_CAPI $CONFIG_PCI
    dep_tristate '  AVM C4/C2 support' CONFIG_ISDN_DRV_AVMB1_C4 $CONFIG_ISDN_CAPI $CONFIG_PCI
 fi
diff -urN linux-2.2.21-pre1/drivers/isdn/act2000/act2000.h linux/drivers/isdn/act2000/act2000.h
--- linux-2.2.21-pre1/drivers/isdn/act2000/act2000.h	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/act2000/act2000.h	Wed Jan  2 03:55:23 2002
@@ -1,35 +1,19 @@
-/* $Id: act2000.h,v 1.8.6.2 2001/02/16 16:43:23 kai Exp $
+/* $Id: act2000.h,v 1.1.2.1 2001/12/31 13:26:35 kai Exp $
  *
  * ISDN lowlevel-module for the IBM ISDN-S0 Active 2000.
  *
- * Copyright 1998 by Fritz Elfert (fritz@isdn4linux.de)
- * Thanks to Friedemann Baitinger and IBM Germany
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
+ * Author       Fritz Elfert
+ * Copyright    by Fritz Elfert      <fritz@isdn4linux.de>
+ * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. 
+ * Thanks to Friedemann Baitinger and IBM Germany
  *
  */
 
 #ifndef act2000_h
 #define act2000_h
-
-#ifdef __KERNEL__
-/* Kernel includes */
-
-#include <linux/module.h>
-#include <linux/version.h>
-#endif
 
 #define ACT2000_IOCTL_SETPORT    1
 #define ACT2000_IOCTL_GETPORT    2
diff -urN linux-2.2.21-pre1/drivers/isdn/act2000/act2000_isa.c linux/drivers/isdn/act2000/act2000_isa.c
--- linux-2.2.21-pre1/drivers/isdn/act2000/act2000_isa.c	Sun Mar 25 08:37:31 2001
+++ linux/drivers/isdn/act2000/act2000_isa.c	Wed Jan  2 03:55:23 2002
@@ -1,23 +1,14 @@
-/* $Id: act2000_isa.c,v 1.11 2000/11/12 16:32:06 kai Exp $
+/* $Id: act2000_isa.c,v 1.1.2.1 2001/12/31 13:26:37 kai Exp $
  *
  * ISDN lowlevel-module for the IBM ISDN-S0 Active 2000 (ISA-Version).
  *
- * Copyright 1998 by Fritz Elfert (fritz@isdn4linux.de)
- * Thanks to Friedemann Baitinger and IBM Germany
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
+ * Author       Fritz Elfert
+ * Copyright    by Fritz Elfert      <fritz@isdn4linux.de>
+ * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. 
+ * Thanks to Friedemann Baitinger and IBM Germany
  *
  */
 
diff -urN linux-2.2.21-pre1/drivers/isdn/act2000/act2000_isa.h linux/drivers/isdn/act2000/act2000_isa.h
--- linux-2.2.21-pre1/drivers/isdn/act2000/act2000_isa.h	Sun Mar 25 08:37:31 2001
+++ linux/drivers/isdn/act2000/act2000_isa.h	Wed Jan  2 03:55:23 2002
@@ -1,23 +1,14 @@
-/* $Id: act2000_isa.h,v 1.4 2000/11/12 16:32:06 kai Exp $
+/* $Id: act2000_isa.h,v 1.1.2.1 2001/12/31 13:26:38 kai Exp $
  *
  * ISDN lowlevel-module for the IBM ISDN-S0 Active 2000 (ISA-Version).
  *
- * Copyright 1998 by Fritz Elfert (fritz@isdn4linux.de)
- * Thanks to Friedemann Baitinger and IBM Germany
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
+ * Author       Fritz Elfert
+ * Copyright    by Fritz Elfert      <fritz@isdn4linux.de>
+ * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. 
+ * Thanks to Friedemann Baitinger and IBM Germany
  *
  */
 
diff -urN linux-2.2.21-pre1/drivers/isdn/act2000/capi.c linux/drivers/isdn/act2000/capi.c
--- linux-2.2.21-pre1/drivers/isdn/act2000/capi.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/act2000/capi.c	Wed Jan  2 03:55:23 2002
@@ -1,24 +1,15 @@
-/* $Id: capi.c,v 1.9.6.1 2001/02/16 16:43:23 kai Exp $
+/* $Id: capi.c,v 1.1.2.1 2001/12/31 13:26:38 kai Exp $
  *
  * ISDN lowlevel-module for the IBM ISDN-S0 Active 2000.
- *        CAPI encoder/decoder
+ * CAPI encoder/decoder
  *
- * Copyright 1998 by Fritz Elfert (fritz@isdn4linux.de)
- * Thanks to Friedemann Baitinger and IBM Germany
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
+ * Author       Fritz Elfert
+ * Copyright    by Fritz Elfert      <fritz@isdn4linux.de>
+ * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. 
+ * Thanks to Friedemann Baitinger and IBM Germany
  *
  */
 
diff -urN linux-2.2.21-pre1/drivers/isdn/act2000/capi.h linux/drivers/isdn/act2000/capi.h
--- linux-2.2.21-pre1/drivers/isdn/act2000/capi.h	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/act2000/capi.h	Wed Jan  2 03:55:23 2002
@@ -1,23 +1,14 @@
-/* $Id: capi.h,v 1.6.6.1 2001/02/16 16:43:23 kai Exp $
+/* $Id: capi.h,v 1.1.2.1 2001/12/31 13:26:38 kai Exp $
  *
  * ISDN lowlevel-module for the IBM ISDN-S0 Active 2000.
  *
- * Copyright 1998 by Fritz Elfert (fritz@isdn4linux.de)
- * Thanks to Friedemann Baitinger and IBM Germany
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
+ * Author       Fritz Elfert
+ * Copyright    by Fritz Elfert      <fritz@isdn4linux.de>
+ * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. 
+ * Thanks to Friedemann Baitinger and IBM Germany
  *
  */
 
diff -urN linux-2.2.21-pre1/drivers/isdn/act2000/module.c linux/drivers/isdn/act2000/module.c
--- linux-2.2.21-pre1/drivers/isdn/act2000/module.c	Sun Mar 25 08:37:31 2001
+++ linux/drivers/isdn/act2000/module.c	Wed Jan  2 03:55:23 2002
@@ -1,29 +1,21 @@
-/* $Id: module.c,v 1.14.6.2 2000/12/18 22:14:10 kai Exp $
+/* $Id: module.c,v 1.1.2.1 2001/12/31 13:26:38 kai Exp $
  *
  * ISDN lowlevel-module for the IBM ISDN-S0 Active 2000.
  *
- * Copyright 1998 by Fritz Elfert (fritz@isdn4linux.de)
- * Thanks to Friedemann Baitinger and IBM Germany
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
+ * Author       Fritz Elfert
+ * Copyright    by Fritz Elfert      <fritz@isdn4linux.de>
+ * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. 
+ * Thanks to Friedemann Baitinger and IBM Germany
  *
  */
 
 #include "act2000.h"
 #include "act2000_isa.h"
 #include "capi.h"
+#include <linux/module.h>
 #include <linux/init.h>
 
 static unsigned short act2000_isa_ports[] =
@@ -41,9 +33,9 @@
 static int   act_irq  = -1;  /* -1 = Autoselect */
 static char *act_id   = "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0";
 
-MODULE_DESCRIPTION(       "Driver for IBM Active 2000 ISDN card");
+MODULE_DESCRIPTION(       "ISDN4Linux: Driver for IBM Active 2000 ISDN card");
 MODULE_AUTHOR(            "Fritz Elfert");
-MODULE_SUPPORTED_DEVICE(  "ISDN subsystem");
+MODULE_LICENSE(           "GPL");
 MODULE_PARM_DESC(act_bus, "BusType of first card, 1=ISA, 2=MCA, 3=PCMCIA, currently only ISA");
 MODULE_PARM_DESC(membase, "Base port address of first card");
 MODULE_PARM_DESC(act_irq, "IRQ of first card (-1 = grab next free IRQ)");
diff -urN linux-2.2.21-pre1/drivers/isdn/avmb1/Makefile linux/drivers/isdn/avmb1/Makefile
--- linux-2.2.21-pre1/drivers/isdn/avmb1/Makefile	Sun Mar 25 08:37:31 2001
+++ linux/drivers/isdn/avmb1/Makefile	Wed Jan  2 03:55:23 2002
@@ -24,7 +24,6 @@
 obj-$(CONFIG_ISDN_DRV_AVMB1_B1ISA)	+= b1isa.o b1.o
 obj-$(CONFIG_ISDN_DRV_AVMB1_B1PCI)	+= b1pci.o b1.o b1dma.o
 obj-$(CONFIG_ISDN_DRV_AVMB1_B1PCMCIA)	+= b1pcmcia.o b1.o
-obj-$(CONFIG_ISDN_DRV_AVMB1_AVM_CS)	+= avm_cs.o
 obj-$(CONFIG_ISDN_DRV_AVMB1_T1ISA)	+= t1isa.o b1.o
 obj-$(CONFIG_ISDN_DRV_AVMB1_T1PCI)	+= t1pci.o b1.o b1dma.o
 obj-$(CONFIG_ISDN_DRV_AVMB1_C4)		+= c4.o b1.o
diff -urN linux-2.2.21-pre1/drivers/isdn/avmb1/avmcard.h linux/drivers/isdn/avmb1/avmcard.h
--- linux-2.2.21-pre1/drivers/isdn/avmb1/avmcard.h	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/avmb1/avmcard.h	Wed Jan  2 03:55:23 2002
@@ -1,7 +1,9 @@
-/*
- * $Id: avmcard.h,v 1.8.6.3 2001/05/17 21:15:33 kai Exp $
+/* $Id: avmcard.h,v 1.1.2.1 2001/12/31 13:26:39 kai Exp $
  *
- * Copyright 1999 by Carsten Paeth (calle@calle.in-berlin.de)
+ * Copyright 1999 by Carsten Paeth <calle@calle.de>
+ *
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
diff -urN linux-2.2.21-pre1/drivers/isdn/avmb1/b1.c linux/drivers/isdn/avmb1/b1.c
--- linux-2.2.21-pre1/drivers/isdn/avmb1/b1.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/avmb1/b1.c	Wed Jan  2 03:55:23 2002
@@ -1,9 +1,11 @@
-/*
- * $Id: b1.c,v 1.20.6.6 2001/05/17 21:15:33 kai Exp $
+/* $Id: b1.c,v 1.1.2.1 2001/12/31 13:26:39 kai Exp $
  * 
  * Common module for AVM B1 cards.
  * 
- * (c) Copyright 1999 by Carsten Paeth (calle@calle.in-berlin.de)
+ * Copyright 1999 by Carsten Paeth <calle@calle.de>
+ *
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
@@ -26,11 +28,13 @@
 #include "capicmd.h"
 #include "capiutil.h"
 
-static char *revision = "$Revision: 1.20.6.6 $";
+static char *revision = "$Revision: 1.1.2.1 $";
 
 /* ------------------------------------------------------------- */
 
-MODULE_AUTHOR("Carsten Paeth <calle@calle.in-berlin.de>");
+MODULE_DESCRIPTION("CAPI4Linux: Common support for active AVM cards");
+MODULE_AUTHOR("Carsten Paeth");
+MODULE_LICENSE("GPL");
 
 /* ------------------------------------------------------------- */
 
diff -urN linux-2.2.21-pre1/drivers/isdn/avmb1/b1dma.c linux/drivers/isdn/avmb1/b1dma.c
--- linux-2.2.21-pre1/drivers/isdn/avmb1/b1dma.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/avmb1/b1dma.c	Wed Jan  2 03:55:23 2002
@@ -1,10 +1,12 @@
-/*
- * $Id: b1dma.c,v 1.11.6.7 2001/07/18 16:02:15 kai Exp $
+/* $Id: b1dma.c,v 1.1.2.1 2001/12/31 13:26:39 kai Exp $
  * 
  * Common module for AVM B1 cards that support dma with AMCC
  * 
- * (c) Copyright 2000 by Carsten Paeth (calle@calle.in-berlin.de)
+ * Copyright 2000 by Carsten Paeth <calle@calle.de>
  * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
+ *
  */
 
 #include <linux/config.h>
@@ -31,11 +33,13 @@
 #error FIXME: driver requires 32-bit platform
 #endif
 
-static char *revision = "$Revision: 1.11.6.7 $";
+static char *revision = "$Revision: 1.1.2.1 $";
 
 /* ------------------------------------------------------------- */
 
-MODULE_AUTHOR("Carsten Paeth <calle@calle.in-berlin.de>");
+MODULE_DESCRIPTION("CAPI4Linux: DMA support for active AVM cards");
+MODULE_AUTHOR("Carsten Paeth");
+MODULE_LICENSE("GPL");
 
 static int suppress_pollack = 0;
 MODULE_PARM(suppress_pollack, "0-1i");
diff -urN linux-2.2.21-pre1/drivers/isdn/avmb1/b1isa.c linux/drivers/isdn/avmb1/b1isa.c
--- linux-2.2.21-pre1/drivers/isdn/avmb1/b1isa.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/avmb1/b1isa.c	Wed Jan  2 03:55:23 2002
@@ -1,10 +1,12 @@
-/*
- * $Id: b1isa.c,v 1.10.6.5 2001/05/17 20:41:51 kai Exp $
+/* $Id: b1isa.c,v 1.1.2.1 2001/12/31 13:26:39 kai Exp $
  * 
  * Module for AVM B1 ISA-card.
  * 
- * (c) Copyright 1999 by Carsten Paeth (calle@calle.in-berlin.de)
+ * Copyright 1999 by Carsten Paeth <calle@calle.de>
  * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
+ *
  */
 
 #include <linux/module.h>
@@ -23,11 +25,13 @@
 #include "capilli.h"
 #include "avmcard.h"
 
-static char *revision = "$Revision: 1.10.6.5 $";
+static char *revision = "$Revision: 1.1.2.1 $";
 
 /* ------------------------------------------------------------- */
 
-MODULE_AUTHOR("Carsten Paeth <calle@calle.in-berlin.de>");
+MODULE_DESCRIPTION("CAPI4Linux: Driver for AVM B1 ISA card");
+MODULE_AUTHOR("Carsten Paeth");
+MODULE_LICENSE("GPL");
 
 /* ------------------------------------------------------------- */
 
diff -urN linux-2.2.21-pre1/drivers/isdn/avmb1/b1pci.c linux/drivers/isdn/avmb1/b1pci.c
--- linux-2.2.21-pre1/drivers/isdn/avmb1/b1pci.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/avmb1/b1pci.c	Wed Jan  2 03:55:23 2002
@@ -1,10 +1,12 @@
-/*
- * $Id: b1pci.c,v 1.29.6.4 2001/05/17 20:41:51 kai Exp $
+/* $Id: b1pci.c,v 1.1.2.1 2001/12/31 13:26:39 kai Exp $
  * 
  * Module for AVM B1 PCI-card.
  * 
- * (c) Copyright 1999 by Carsten Paeth (calle@calle.in-berlin.de)
+ * Copyright 1999 by Carsten Paeth <calle@calle.de>
  * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
+ *
  */
 
 #include <linux/config.h>
@@ -25,11 +27,13 @@
 #include "capilli.h"
 #include "avmcard.h"
 
-static char *revision = "$Revision: 1.29.6.4 $";
+static char *revision = "$Revision: 1.1.2.1 $";
 
 /* ------------------------------------------------------------- */
 
-MODULE_AUTHOR("Carsten Paeth <calle@calle.in-berlin.de>");
+MODULE_DESCRIPTION("CAPI4Linux: Driver for AVM B1 PCI card");
+MODULE_AUTHOR("Carsten Paeth");
+MODULE_LICENSE("GPL");
 
 /* ------------------------------------------------------------- */
 
diff -urN linux-2.2.21-pre1/drivers/isdn/avmb1/b1pcmcia.c linux/drivers/isdn/avmb1/b1pcmcia.c
--- linux-2.2.21-pre1/drivers/isdn/avmb1/b1pcmcia.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/avmb1/b1pcmcia.c	Wed Jan  2 03:55:23 2002
@@ -1,10 +1,12 @@
-/*
- * $Id: b1pcmcia.c,v 1.12.6.4 2001/05/17 20:41:51 kai Exp $
+/* $Id: b1pcmcia.c,v 1.1.2.1 2001/12/31 13:26:39 kai Exp $
  * 
  * Module for AVM B1/M1/M2 PCMCIA-card.
  * 
- * (c) Copyright 1999 by Carsten Paeth (calle@calle.in-berlin.de)
+ * Copyright 1999 by Carsten Paeth <calle@calle.de>
  * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
+ *
  */
 
 #include <linux/module.h>
@@ -23,11 +25,13 @@
 #include "capilli.h"
 #include "avmcard.h"
 
-static char *revision = "$Revision: 1.12.6.4 $";
+static char *revision = "$Revision: 1.1.2.1 $";
 
 /* ------------------------------------------------------------- */
 
-MODULE_AUTHOR("Carsten Paeth <calle@calle.in-berlin.de>");
+MODULE_DESCRIPTION("CAPI4Linux: Driver for AVM PCMCIA cards");
+MODULE_AUTHOR("Carsten Paeth");
+MODULE_LICENSE("GPL");
 
 /* ------------------------------------------------------------- */
 
diff -urN linux-2.2.21-pre1/drivers/isdn/avmb1/c4.c linux/drivers/isdn/avmb1/c4.c
--- linux-2.2.21-pre1/drivers/isdn/avmb1/c4.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/avmb1/c4.c	Wed Jan  2 03:55:23 2002
@@ -1,9 +1,11 @@
-/*
- * $Id: c4.c,v 1.20.6.10 2001/06/09 15:14:15 kai Exp $
+/* $Id: c4.c,v 1.1.2.1 2001/12/31 13:26:39 kai Exp $
  * 
  * Module for AVM C4 & C2 card.
  * 
- * (c) Copyright 1999 by Carsten Paeth (calle@calle.in-berlin.de)
+ * Copyright 1999 by Carsten Paeth <calle@calle.de>
+ *
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
@@ -28,7 +30,7 @@
 #include "capilli.h"
 #include "avmcard.h"
 
-static char *revision = "$Revision: 1.20.6.10 $";
+static char *revision = "$Revision: 1.1.2.1 $";
 
 #undef CONFIG_C4_DEBUG
 #undef CONFIG_C4_POLLDEBUG
@@ -37,7 +39,9 @@
 
 static int suppress_pollack;
 
-MODULE_AUTHOR("Carsten Paeth <calle@calle.in-berlin.de>");
+MODULE_DESCRIPTION("CAPI4Linux: Driver for AVM C2/C4 cards");
+MODULE_AUTHOR("Carsten Paeth");
+MODULE_LICENSE("GPL");
 MODULE_PARM(suppress_pollack, "0-1i");
 
 /* ------------------------------------------------------------- */
@@ -1362,7 +1366,7 @@
 		MOD_DEC_USE_COUNT;
 		return retval;
 	}
-	retval = search_cards(&c2_driver, 0x1100, 2);
+	retval = search_cards(&c2_driver, PCI_DEVICE_ID_AVM_C2, 2);
 	if (retval && ncards == 0) {
     		detach_capi_driver(&c2_driver);
     		detach_capi_driver(&c4_driver);
diff -urN linux-2.2.21-pre1/drivers/isdn/avmb1/capi.c linux/drivers/isdn/avmb1/capi.c
--- linux-2.2.21-pre1/drivers/isdn/avmb1/capi.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/avmb1/capi.c	Wed Jan  2 03:55:23 2002
@@ -1,9 +1,11 @@
-/*
- * $Id: capi.c,v 1.44.6.12 2001/06/09 15:14:15 kai Exp $
+/* $Id: capi.c,v 1.1.2.1 2001/12/31 13:26:39 kai Exp $
  *
  * CAPI 2.0 Interface for Linux
  *
- * Copyright 1996 by Carsten Paeth (calle@calle.in-berlin.de)
+ * Copyright 1996 by Carsten Paeth <calle@calle.de>
+ *
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
@@ -43,9 +45,11 @@
 #include "capifs.h"
 #endif
 
-static char *revision = "$Revision: 1.44.6.12 $";
+static char *revision = "$Revision: 1.1.2.1 $";
 
-MODULE_AUTHOR("Carsten Paeth (calle@calle.in-berlin.de)");
+MODULE_DESCRIPTION("CAPI4Linux: Userspace /dev/capi20 interface");
+MODULE_AUTHOR("Carsten Paeth");
+MODULE_LICENSE("GPL");
 
 #undef _DEBUG_REFCOUNT		/* alloc/free and open/close debug */
 #undef _DEBUG_TTYFUNCS		/* call to tty_driver */
@@ -83,10 +87,10 @@
 	struct capincci  *nccip;
 	unsigned int      minor;
 
-	__u16		 applid;
-	__u32		 ncci;
-	__u16		 datahandle;
-	__u16		 msgid;
+	u16  		 applid;
+	u32		 ncci;
+	u16		 datahandle;
+	u16		 msgid;
 
 	struct file      *file;
 	struct tty_struct *tty;
@@ -108,7 +112,7 @@
 	/* transmit path */
 	struct datahandle_queue {
 		    struct datahandle_queue *next;
-		    __u16                    datahandle;
+		    u16                      datahandle;
 	} *ackqueue;
 	int nack;
 
@@ -117,7 +121,7 @@
 
 struct capincci {
 	struct capincci *next;
-	__u32		 ncci;
+	u32		 ncci;
 	struct capidev	*cdev;
 #ifdef CONFIG_ISDN_CAPI_MIDDLEWARE
 	struct capiminor *minorp;
@@ -127,8 +131,8 @@
 struct capidev {
 	struct capidev *next;
 	struct file    *file;
-	__u16		applid;
-	__u16		errcode;
+	u16		applid;
+	u16		errcode;
 	unsigned int    minor;
 	unsigned        userflags;
 
@@ -156,7 +160,7 @@
 #ifdef CONFIG_ISDN_CAPI_MIDDLEWARE
 /* -------- datahandles --------------------------------------------- */
 
-int capincci_add_ack(struct capiminor *mp, __u16 datahandle)
+static int capincci_add_ack(struct capiminor *mp, u16 datahandle)
 {
 	struct datahandle_queue *n, **pp;
 
@@ -174,7 +178,7 @@
 	return 0;
 }
 
-int capiminor_del_ack(struct capiminor *mp, __u16 datahandle)
+static int capiminor_del_ack(struct capiminor *mp, u16 datahandle)
 {
 	struct datahandle_queue **pp, *p;
 
@@ -190,7 +194,7 @@
 	return -1;
 }
 
-void capiminor_del_all_ack(struct capiminor *mp)
+static void capiminor_del_all_ack(struct capiminor *mp)
 {
 	struct datahandle_queue **pp, *p;
 
@@ -206,7 +210,7 @@
 
 /* -------- struct capiminor ---------------------------------------- */
 
-struct capiminor *capiminor_alloc(__u16 applid, __u32 ncci)
+static struct capiminor *capiminor_alloc(u16 applid, u32 ncci)
 {
 	struct capiminor *mp, **pp;
         unsigned int minor = 0;
@@ -247,7 +251,7 @@
 	return mp;
 }
 
-void capiminor_free(struct capiminor *mp)
+static void capiminor_free(struct capiminor *mp)
 {
 	struct capiminor **pp;
 
@@ -273,7 +277,7 @@
 	}
 }
 
-struct capiminor *capiminor_find(unsigned int minor)
+static struct capiminor *capiminor_find(unsigned int minor)
 {
 	struct capiminor *p;
 	for (p = minors; p && p->minor != minor; p = p->next)
@@ -284,7 +288,7 @@
 
 /* -------- struct capincci ----------------------------------------- */
 
-static struct capincci *capincci_alloc(struct capidev *cdev, __u32 ncci)
+static struct capincci *capincci_alloc(struct capidev *cdev, u32 ncci)
 {
 	struct capincci *np, **pp;
 #ifdef CONFIG_ISDN_CAPI_MIDDLEWARE
@@ -321,7 +325,7 @@
         return np;
 }
 
-static void capincci_free(struct capidev *cdev, __u32 ncci)
+static void capincci_free(struct capidev *cdev, u32 ncci)
 {
 	struct capincci *np, **pp;
 #ifdef CONFIG_ISDN_CAPI_MIDDLEWARE
@@ -365,7 +369,7 @@
 	}
 }
 
-struct capincci *capincci_find(struct capidev *cdev, __u32 ncci)
+static struct capincci *capincci_find(struct capidev *cdev, u32 ncci)
 {
 	struct capincci *p;
 
@@ -416,7 +420,7 @@
 	kfree(cdev);
 }
 
-static struct capidev *capidev_find(__u16 applid)
+static struct capidev *capidev_find(u16 applid)
 {
 	struct capidev *p;
 	for (p=capidev_openlist; p; p = p->next) {
@@ -429,13 +433,13 @@
 #ifdef CONFIG_ISDN_CAPI_MIDDLEWARE
 /* -------- handle data queue --------------------------------------- */
 
-struct sk_buff *
+static struct sk_buff *
 gen_data_b3_resp_for(struct capiminor *mp, struct sk_buff *skb)
 {
 	struct sk_buff *nskb;
 	nskb = alloc_skb(CAPI_DATA_B3_RESP_LEN, GFP_ATOMIC);
 	if (nskb) {
-		__u16 datahandle = CAPIMSG_U16(skb->data,CAPIMSG_BASELEN+4+4+2);
+		u16 datahandle = CAPIMSG_U16(skb->data,CAPIMSG_BASELEN+4+4+2);
 		unsigned char *s = skb_put(nskb, CAPI_DATA_B3_RESP_LEN);
 		capimsg_setu16(s, 0, CAPI_DATA_B3_RESP_LEN);
 		capimsg_setu16(s, 2, mp->applid);
@@ -448,11 +452,11 @@
 	return nskb;
 }
 
-int handle_recv_skb(struct capiminor *mp, struct sk_buff *skb)
+static int handle_recv_skb(struct capiminor *mp, struct sk_buff *skb)
 {
 	struct sk_buff *nskb;
 	unsigned int datalen;
-	__u16 errcode, datahandle;
+	u16 errcode, datahandle;
 
 	datalen = skb->len - CAPIMSG_LEN(skb->data);
 	if (mp->tty) {
@@ -528,7 +532,7 @@
 	return -1;
 }
 
-void handle_minor_recv(struct capiminor *mp)
+static void handle_minor_recv(struct capiminor *mp)
 {
 	struct sk_buff *skb;
 	while ((skb = skb_dequeue(&mp->inqueue)) != 0) {
@@ -542,13 +546,13 @@
 	}
 }
 
-int handle_minor_send(struct capiminor *mp)
+static int handle_minor_send(struct capiminor *mp)
 {
 	struct sk_buff *skb;
-	__u16 len;
+	u16 len;
 	int count = 0;
-	__u16 errcode;
-	__u16 datahandle;
+	u16 errcode;
+	u16 datahandle;
 
 	if (mp->tty && mp->ttyoutstop) {
 #if defined(_DEBUG_DATAFLOW) || defined(_DEBUG_TTYFUNCS)
@@ -559,7 +563,7 @@
 
 	while ((skb = skb_dequeue(&mp->outqueue)) != 0) {
 		datahandle = mp->datahandle;
-		len = (__u16)skb->len;
+		len = (u16)skb->len;
 		skb_push(skb, CAPI_DATA_B3_REQ_LEN);
 		memset(skb->data, 0, CAPI_DATA_B3_REQ_LEN);
 		capimsg_setu16(skb->data, 0, CAPI_DATA_B3_REQ_LEN);
@@ -568,7 +572,7 @@
 		capimsg_setu8 (skb->data, 5, CAPI_REQ);
 		capimsg_setu16(skb->data, 6, mp->msgid++);
 		capimsg_setu32(skb->data, 8, mp->ncci);	/* NCCI */
-		capimsg_setu32(skb->data, 12, (__u32) skb->data); /* Data32 */
+		capimsg_setu32(skb->data, 12, (u32) skb->data); /* Data32 */
 		capimsg_setu16(skb->data, 16, len);	/* Data length */
 		capimsg_setu16(skb->data, 18, datahandle);
 		capimsg_setu16(skb->data, 20, 0);	/* Flags */
@@ -610,16 +614,16 @@
 #endif /* CONFIG_ISDN_CAPI_MIDDLEWARE */
 /* -------- function called by lower level -------------------------- */
 
-static void capi_signal(__u16 applid, void *param)
+static void capi_signal(u16 applid, void *param)
 {
 	struct capidev *cdev = (struct capidev *)param;
 #ifdef CONFIG_ISDN_CAPI_MIDDLEWARE
 	struct capiminor *mp;
-	__u16 datahandle;
+	u16 datahandle;
 #endif /* CONFIG_ISDN_CAPI_MIDDLEWARE */
 	struct capincci *np;
 	struct sk_buff *skb = 0;
-	__u32 ncci;
+	u32 ncci;
 
 	(void) (*capifuncs->capi_get_message) (applid, &skb);
 	if (!skb) {
@@ -754,7 +758,7 @@
 	struct capidev *cdev = (struct capidev *)file->private_data;
 	struct sk_buff *skb;
 	int retval;
-	__u16 mlen;
+	u16 mlen;
 
         if (ppos != &file->f_pos)
 		return -ESPIPE;
@@ -994,7 +998,7 @@
 						sizeof(ncci));
 			if (retval)
 				return -EFAULT;
-			nccip = capincci_find(cdev, (__u32) ncci);
+			nccip = capincci_find(cdev, (u32) ncci);
 			if (!nccip)
 				return 0;
 #ifdef CONFIG_ISDN_CAPI_MIDDLEWARE
@@ -1019,7 +1023,7 @@
 						sizeof(ncci));
 			if (retval)
 				return -EFAULT;
-			nccip = capincci_find(cdev, (__u32) ncci);
+			nccip = capincci_find(cdev, (u32) ncci);
 			if (!nccip || (mp = nccip->minorp) == 0)
 				return -ESRCH;
 			return mp->minor;
@@ -1272,7 +1276,7 @@
 
 /* -------- tty_operations for capincci ----------------------------- */
 
-int capinc_tty_open(struct tty_struct * tty, struct file * file)
+static int capinc_tty_open(struct tty_struct * tty, struct file * file)
 {
 	struct capiminor *mp;
 
@@ -1300,7 +1304,7 @@
 	return 0;
 }
 
-void capinc_tty_close(struct tty_struct * tty, struct file * file)
+static void capinc_tty_close(struct tty_struct * tty, struct file * file)
 {
 	struct capiminor *mp;
 
@@ -1325,8 +1329,8 @@
 #endif
 }
 
-int capinc_tty_write(struct tty_struct * tty, int from_user,
-		      const unsigned char *buf, int count)
+static int capinc_tty_write(struct tty_struct * tty, int from_user,
+			    const unsigned char *buf, int count)
 {
 	struct capiminor *mp = (struct capiminor *)tty->driver_data;
 	struct sk_buff *skb;
@@ -1377,7 +1381,7 @@
 	return count;
 }
 
-void capinc_tty_put_char(struct tty_struct *tty, unsigned char ch)
+static void capinc_tty_put_char(struct tty_struct *tty, unsigned char ch)
 {
 	struct capiminor *mp = (struct capiminor *)tty->driver_data;
 	struct sk_buff *skb;
@@ -1414,7 +1418,7 @@
 	}
 }
 
-void capinc_tty_flush_chars(struct tty_struct *tty)
+static void capinc_tty_flush_chars(struct tty_struct *tty)
 {
 	struct capiminor *mp = (struct capiminor *)tty->driver_data;
 	struct sk_buff *skb;
@@ -1440,7 +1444,7 @@
 	(void)handle_minor_recv(mp);
 }
 
-int capinc_tty_write_room(struct tty_struct *tty)
+static int capinc_tty_write_room(struct tty_struct *tty)
 {
 	struct capiminor *mp = (struct capiminor *)tty->driver_data;
 	int room;
@@ -1458,7 +1462,7 @@
 	return room;
 }
 
-int capinc_tty_chars_in_buffer(struct tty_struct *tty)
+static int capinc_tty_chars_in_buffer(struct tty_struct *tty)
 {
 	struct capiminor *mp = (struct capiminor *)tty->driver_data;
 	if (!mp || !mp->nccip) {
@@ -1476,7 +1480,7 @@
 	return mp->outbytes;
 }
 
-int capinc_tty_ioctl(struct tty_struct *tty, struct file * file,
+static int capinc_tty_ioctl(struct tty_struct *tty, struct file * file,
 		    unsigned int cmd, unsigned long arg)
 {
 	int error = 0;
@@ -1488,14 +1492,14 @@
 	return error;
 }
 
-void capinc_tty_set_termios(struct tty_struct *tty, struct termios * old)
+static void capinc_tty_set_termios(struct tty_struct *tty, struct termios * old)
 {
 #ifdef _DEBUG_TTYFUNCS
 	printk(KERN_DEBUG "capinc_tty_set_termios\n");
 #endif
 }
 
-void capinc_tty_throttle(struct tty_struct * tty)
+static void capinc_tty_throttle(struct tty_struct * tty)
 {
 	struct capiminor *mp = (struct capiminor *)tty->driver_data;
 #ifdef _DEBUG_TTYFUNCS
@@ -1505,7 +1509,7 @@
 		mp->ttyinstop = 1;
 }
 
-void capinc_tty_unthrottle(struct tty_struct * tty)
+static void capinc_tty_unthrottle(struct tty_struct * tty)
 {
 	struct capiminor *mp = (struct capiminor *)tty->driver_data;
 #ifdef _DEBUG_TTYFUNCS
@@ -1517,7 +1521,7 @@
 	}
 }
 
-void capinc_tty_stop(struct tty_struct *tty)
+static void capinc_tty_stop(struct tty_struct *tty)
 {
 	struct capiminor *mp = (struct capiminor *)tty->driver_data;
 #ifdef _DEBUG_TTYFUNCS
@@ -1528,7 +1532,7 @@
 	}
 }
 
-void capinc_tty_start(struct tty_struct *tty)
+static void capinc_tty_start(struct tty_struct *tty)
 {
 	struct capiminor *mp = (struct capiminor *)tty->driver_data;
 #ifdef _DEBUG_TTYFUNCS
@@ -1540,49 +1544,43 @@
 	}
 }
 
-void capinc_tty_hangup(struct tty_struct *tty)
+static void capinc_tty_hangup(struct tty_struct *tty)
 {
 #ifdef _DEBUG_TTYFUNCS
 	printk(KERN_DEBUG "capinc_tty_hangup\n");
 #endif
 }
 
-void capinc_tty_break_ctl(struct tty_struct *tty, int state)
+static void capinc_tty_break_ctl(struct tty_struct *tty, int state)
 {
 #ifdef _DEBUG_TTYFUNCS
 	printk(KERN_DEBUG "capinc_tty_break_ctl(%d)\n", state);
 #endif
 }
 
-void capinc_tty_flush_buffer(struct tty_struct *tty)
+static void capinc_tty_flush_buffer(struct tty_struct *tty)
 {
 #ifdef _DEBUG_TTYFUNCS
 	printk(KERN_DEBUG "capinc_tty_flush_buffer\n");
 #endif
 }
 
-void capinc_tty_set_ldisc(struct tty_struct *tty)
+static void capinc_tty_set_ldisc(struct tty_struct *tty)
 {
 #ifdef _DEBUG_TTYFUNCS
 	printk(KERN_DEBUG "capinc_tty_set_ldisc\n");
 #endif
 }
 
-void capinc_tty_send_xchar(struct tty_struct *tty, char ch)
+static void capinc_tty_send_xchar(struct tty_struct *tty, char ch)
 {
 #ifdef _DEBUG_TTYFUNCS
 	printk(KERN_DEBUG "capinc_tty_send_xchar(%d)\n", ch);
 #endif
 }
 
-int capinc_tty_read_proc(char *page, char **start, off_t off,
-			  int count, int *eof, void *data)
-{
-	return 0;
-}
-
-int capinc_write_proc(struct file *file, const char *buffer,
-			  unsigned long count, void *data)
+static int capinc_tty_read_proc(char *page, char **start, off_t off,
+				int count, int *eof, void *data)
 {
 	return 0;
 }
@@ -1594,7 +1592,7 @@
 static struct termios *capinc_tty_termios[CAPINC_NR_PORTS];
 static struct termios *capinc_tty_termios_locked[CAPINC_NR_PORTS];
 
-int capinc_tty_init(void)
+static int capinc_tty_init(void)
 {
 	struct tty_driver *drv = &capinc_tty_driver;
 
@@ -1652,7 +1650,7 @@
 	return 0;
 }
 
-void capinc_tty_exit(void)
+static void capinc_tty_exit(void)
 {
 	struct tty_driver *drv = &capinc_tty_driver;
 	int retval;
@@ -1778,7 +1776,7 @@
 /* -------- init function and module interface ---------------------- */
 
 
-static void lower_callback(unsigned int cmd, __u32 contr, void *data)
+static void lower_callback(unsigned int cmd, u32 contr, void *data)
 {
 	struct capi_ncciinfo *np;
 	struct capidev *cdev;
diff -urN linux-2.2.21-pre1/drivers/isdn/avmb1/capicmd.h linux/drivers/isdn/avmb1/capicmd.h
--- linux-2.2.21-pre1/drivers/isdn/avmb1/capicmd.h	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/avmb1/capicmd.h	Wed Jan  2 03:55:23 2002
@@ -1,11 +1,14 @@
-/*
- * $Id: capicmd.h,v 1.2.6.1 2001/05/17 20:41:51 kai Exp $
+/* $Id: capicmd.h,v 1.1.2.1 2001/12/31 13:26:41 kai Exp $
  * 
  * CAPI 2.0 Interface for Linux
  * 
- * Copyright 1997 by Carsten Paeth (calle@calle.in-berlin.de)
+ * Copyright 1997 by Carsten Paeth <calle@calle.de>
  * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
+ *
  */
+
 #ifndef __CAPICMD_H__
 #define __CAPICMD_H__
 
diff -urN linux-2.2.21-pre1/drivers/isdn/avmb1/capidev.h linux/drivers/isdn/avmb1/capidev.h
--- linux-2.2.21-pre1/drivers/isdn/avmb1/capidev.h	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/avmb1/capidev.h	Wed Jan  2 03:55:23 2002
@@ -1,9 +1,11 @@
-/*
- * $Id: capidev.h,v 1.6.6.1 2001/05/17 20:41:51 kai Exp $
+/* $Id: capidev.h,v 1.1.2.1 2001/12/31 13:26:41 kai Exp $
  *
  * CAPI 2.0 Interface for Linux
  *
- * (c) Copyright 1996 by Carsten Paeth (calle@calle.in-berlin.de)
+ * Copyright 1996 by Carsten Paeth <calle@calle.de>
+ *
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
diff -urN linux-2.2.21-pre1/drivers/isdn/avmb1/capidrv.c linux/drivers/isdn/avmb1/capidrv.c
--- linux-2.2.21-pre1/drivers/isdn/avmb1/capidrv.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/avmb1/capidrv.c	Wed Jan  2 03:55:23 2002
@@ -1,9 +1,11 @@
-/*
- * $Id: capidrv.c,v 1.39.6.6 2001/05/17 20:41:51 kai Exp $
+/* $Id: capidrv.c,v 1.1.2.1 2001/12/31 13:26:41 kai Exp $
  *
  * ISDN4Linux Driver, using capi20 interface (kernelcapi)
  *
- * Copyright 1997 by Carsten Paeth (calle@calle.in-berlin.de)
+ * Copyright 1997 by Carsten Paeth <calle@calle.de>
+ *
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
@@ -33,10 +35,12 @@
 #include "capicmd.h"
 #include "capidrv.h"
 
-static char *revision = "$Revision: 1.39.6.6 $";
+static char *revision = "$Revision: 1.1.2.1 $";
 static int debugmode = 0;
 
-MODULE_AUTHOR("Carsten Paeth <calle@calle.in-berlin.de>");
+MODULE_DESCRIPTION("CAPI4Linux: Interface to ISDN4Linux");
+MODULE_AUTHOR("Carsten Paeth");
+MODULE_LICENSE("GPL");
 MODULE_PARM(debugmode, "i");
 
 /* -------- type definitions ----------------------------------------- */
diff -urN linux-2.2.21-pre1/drivers/isdn/avmb1/capidrv.h linux/drivers/isdn/avmb1/capidrv.h
--- linux-2.2.21-pre1/drivers/isdn/avmb1/capidrv.h	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/avmb1/capidrv.h	Wed Jan  2 03:55:23 2002
@@ -1,11 +1,14 @@
-/*
- * $Id: capidrv.h,v 1.2.8.1 2001/05/17 20:41:51 kai Exp $
+/* $Id: capidrv.h,v 1.1.2.1 2001/12/31 13:26:41 kai Exp $
  *
  * ISDN4Linux Driver, using capi20 interface (kernelcapi)
  *
- * Copyright 1997 by Carsten Paeth (calle@calle.in-berlin.de)
+ * Copyright 1997 by Carsten Paeth <calle@calle.de>
+ *
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
+
 #ifndef __CAPIDRV_H__
 #define __CAPIDRV_H__
 
diff -urN linux-2.2.21-pre1/drivers/isdn/avmb1/capifs.c linux/drivers/isdn/avmb1/capifs.c
--- linux-2.2.21-pre1/drivers/isdn/avmb1/capifs.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/avmb1/capifs.c	Wed Jan  2 03:55:23 2002
@@ -1,10 +1,12 @@
-/*
- * $Id: capifs.c,v 1.14.6.7 2001/05/24 08:29:08 kai Exp $
+/* $Id: capifs.c,v 1.1.2.1 2001/12/31 13:26:41 kai Exp $
  * 
- * (c) Copyright 2000 by Carsten Paeth (calle@calle.de)
+ * Copyright 2000 by Carsten Paeth <calle@calle.de>
  *
  * Heavily based on devpts filesystem from H. Peter Anvin
  * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
+ *
  */
 
 #include <linux/version.h>
@@ -27,9 +29,11 @@
 #include <asm/bitops.h>
 #include <asm/uaccess.h>
 
-MODULE_AUTHOR("Carsten Paeth <calle@calle.de>");
+MODULE_DESCRIPTION("CAPI4Linux: /dev/capi/ filesystem");
+MODULE_AUTHOR("Carsten Paeth");
+MODULE_LICENSE("GPL");
 
-static char *revision = "$Revision: 1.14.6.7 $";
+static char *revision = "$Revision: 1.1.2.1 $";
 
 struct capifs_ncci {
 	struct inode *inode;
diff -urN linux-2.2.21-pre1/drivers/isdn/avmb1/capifs.h linux/drivers/isdn/avmb1/capifs.h
--- linux-2.2.21-pre1/drivers/isdn/avmb1/capifs.h	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/avmb1/capifs.h	Wed Jan  2 03:55:23 2002
@@ -1,7 +1,9 @@
-/*
- * $Id: capifs.h,v 1.2.6.1 2001/05/17 20:41:51 kai Exp $
+/* $Id: capifs.h,v 1.1.2.1 2001/12/31 13:26:42 kai Exp $
  * 
- * (c) Copyright 2000 by Carsten Paeth (calle@calle.de)
+ * Copyright 2000 by Carsten Paeth <calle@calle.de>
+ *
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
diff -urN linux-2.2.21-pre1/drivers/isdn/avmb1/capilli.h linux/drivers/isdn/avmb1/capilli.h
--- linux-2.2.21-pre1/drivers/isdn/avmb1/capilli.h	Sun Mar 25 08:31:37 2001
+++ linux/drivers/isdn/avmb1/capilli.h	Wed Jan  2 03:55:23 2002
@@ -1,11 +1,14 @@
-/*
- * $Id: capilli.h,v 1.4 1999/07/23 08:51:05 calle Exp $
+/* $Id: capilli.h,v 1.1.2.1 2001/12/31 13:26:42 kai Exp $
  * 
  * Kernel CAPI 2.0 Driver Interface for Linux
  * 
- * (c) Copyright 1999 by Carsten Paeth (calle@calle.in-berlin.de)
+ * Copyright 1999 by Carsten Paeth <calle@calle.de>
  * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
+ *
  */
+
 #ifndef __CAPILLI_H__
 #define __CAPILLI_H__
 
diff -urN linux-2.2.21-pre1/drivers/isdn/avmb1/capiutil.c linux/drivers/isdn/avmb1/capiutil.c
--- linux-2.2.21-pre1/drivers/isdn/avmb1/capiutil.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/avmb1/capiutil.c	Wed Jan  2 03:55:23 2002
@@ -1,12 +1,15 @@
-/*
- * $Id: capiutil.c,v 1.13.6.3 2001/05/17 20:41:51 kai Exp $
+/* $Id: capiutil.c,v 1.1.2.1 2001/12/31 13:26:42 kai Exp $
  *
  * CAPI 2.0 convert capi message to capi message struct
  *
  * From CAPI 2.0 Development Kit AVM 1995 (msg.c)
- * Rewritten for Linux 1996 by Carsten Paeth (calle@calle.in-berlin.de)
+ * Rewritten for Linux 1996 by Carsten Paeth <calle@calle.de>
+ *
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
+
 #include <linux/module.h>
 #include <linux/string.h>
 #include <linux/ctype.h>
@@ -18,6 +21,10 @@
 #include <linux/config.h>
 #include <linux/isdn_compat.h>
 #include "capiutil.h"
+
+MODULE_DESCRIPTION("CAPI4Linux: CAPI message conversion support");
+MODULE_AUTHOR("Carsten Paeth");
+MODULE_LICENSE("GPL");
 
 /* from CAPI2.0 DDK AVM Berlin GmbH */
 
diff -urN linux-2.2.21-pre1/drivers/isdn/avmb1/capiutil.h linux/drivers/isdn/avmb1/capiutil.h
--- linux-2.2.21-pre1/drivers/isdn/avmb1/capiutil.h	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/avmb1/capiutil.h	Wed Jan  2 03:55:23 2002
@@ -1,12 +1,15 @@
-/*
- * $Id: capiutil.h,v 1.5.6.1 2001/05/17 20:41:51 kai Exp $
- * 
+/* $Id: capiutil.h,v 1.1.2.1 2001/12/31 13:26:43 kai Exp $
+ *
  * CAPI 2.0 defines & types
- * 
- * From CAPI 2.0 Development Kit AVM 1995 (capi20.h)
- * Rewritten for Linux 1996 by Carsten Paeth (calle@calle.in-berlin.de)
- * 
+ *
+ * From CAPI 2.0 Development Kit AVM 1995 (msg.c)
+ * Rewritten for Linux 1996 by Carsten Paeth <calle@calle.de>
+ *
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
+ *
  */
+
 #ifndef __CAPIUTIL_H__
 #define __CAPIUTIL_H__
 
diff -urN linux-2.2.21-pre1/drivers/isdn/avmb1/kcapi.c linux/drivers/isdn/avmb1/kcapi.c
--- linux-2.2.21-pre1/drivers/isdn/avmb1/kcapi.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/avmb1/kcapi.c	Wed Jan  2 03:55:23 2002
@@ -1,11 +1,14 @@
-/*
- * $Id: kcapi.c,v 1.21.6.7 2001/06/09 15:14:15 kai Exp $
+/* $Id: kcapi.c,v 1.1.2.1 2001/12/31 13:26:43 kai Exp $
  * 
  * Kernel CAPI 2.0 Module
  * 
- * (c) Copyright 1999 by Carsten Paeth (calle@calle.in-berlin.de)
+ * Copyright 1999 by Carsten Paeth <calle@calle.de>
  * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
+ *
  */
+
 #define CONFIG_AVMB1_COMPAT
 
 #include <linux/config.h>
@@ -31,7 +34,7 @@
 #include <linux/b1lli.h>
 #endif
 
-static char *revision = "$Revision: 1.21.6.7 $";
+static char *revision = "$Revision: 1.1.2.1 $";
 
 /* ------------------------------------------------------------- */
 
@@ -42,10 +45,12 @@
 
 /* ------------------------------------------------------------- */
 
-int showcapimsgs = 0;
+static int showcapimsgs = 0;
 
-MODULE_AUTHOR("Carsten Paeth <calle@calle.in-berlin.de>");
-MODULE_PARM(showcapimsgs, "0-4i");
+MODULE_DESCRIPTION("CAPI4Linux: kernel CAPI layer");
+MODULE_AUTHOR("Carsten Paeth");
+MODULE_LICENSE("GPL");
+MODULE_PARM(showcapimsgs, "i");
 
 /* ------------------------------------------------------------- */
 
diff -urN linux-2.2.21-pre1/drivers/isdn/avmb1/t1isa.c linux/drivers/isdn/avmb1/t1isa.c
--- linux-2.2.21-pre1/drivers/isdn/avmb1/t1isa.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/avmb1/t1isa.c	Wed Jan  2 03:55:23 2002
@@ -1,10 +1,12 @@
-/*
- * $Id: t1isa.c,v 1.16.6.6 2001/05/17 21:15:33 kai Exp $
+/* $Id: t1isa.c,v 1.1.2.1 2001/12/31 13:26:43 kai Exp $
  * 
  * Module for AVM T1 HEMA-card.
  * 
- * (c) Copyright 1999 by Carsten Paeth (calle@calle.in-berlin.de)
+ * Copyright 1999 by Carsten Paeth <calle@calle.de>
  * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
+ *
  */
 
 #include <linux/module.h>
@@ -24,11 +26,13 @@
 #include "capilli.h"
 #include "avmcard.h"
 
-static char *revision = "$Revision: 1.16.6.6 $";
+static char *revision = "$Revision: 1.1.2.1 $";
 
 /* ------------------------------------------------------------- */
 
-MODULE_AUTHOR("Carsten Paeth <calle@calle.in-berlin.de>");
+MODULE_DESCRIPTION("CAPI4Linux: Driver for AVM T1 HEMA ISA card");
+MODULE_AUTHOR("Carsten Paeth");
+MODULE_LICENSE("GPL");
 
 /* ------------------------------------------------------------- */
 
diff -urN linux-2.2.21-pre1/drivers/isdn/avmb1/t1pci.c linux/drivers/isdn/avmb1/t1pci.c
--- linux-2.2.21-pre1/drivers/isdn/avmb1/t1pci.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/avmb1/t1pci.c	Wed Jan  2 03:55:23 2002
@@ -1,10 +1,12 @@
-/*
- * $Id: t1pci.c,v 1.13.6.5 2001/05/17 20:41:51 kai Exp $
+/* $Id: t1pci.c,v 1.1.2.1 2001/12/31 13:26:43 kai Exp $
  * 
  * Module for AVM T1 PCI-card.
  * 
- * (c) Copyright 1999 by Carsten Paeth (calle@calle.in-berlin.de)
+ * Copyright 1999 by Carsten Paeth <calle@calle.de>
  * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
+ *
  */
 
 #include <linux/config.h>
@@ -25,14 +27,16 @@
 #include "capilli.h"
 #include "avmcard.h"
 
-static char *revision = "$Revision: 1.13.6.5 $";
+static char *revision = "$Revision: 1.1.2.1 $";
 
 #undef CONFIG_T1PCI_DEBUG
 #undef CONFIG_T1PCI_POLLDEBUG
 
 /* ------------------------------------------------------------- */
 
-MODULE_AUTHOR("Carsten Paeth <calle@calle.in-berlin.de>");
+MODULE_DESCRIPTION("CAPI4Linux: Driver for AVM T1 PCI card");
+MODULE_AUTHOR("Carsten Paeth");
+MODULE_LICENSE("GPL");
 
 /* ------------------------------------------------------------- */
 
diff -urN linux-2.2.21-pre1/drivers/isdn/divert/divert_init.c linux/drivers/isdn/divert/divert_init.c
--- linux-2.2.21-pre1/drivers/isdn/divert/divert_init.c	Sun Mar 25 08:37:32 2001
+++ linux/drivers/isdn/divert/divert_init.c	Wed Jan  2 03:55:23 2002
@@ -1,23 +1,11 @@
-/* 
- * $Id: divert_init.c,v 1.5.6.2 2001/01/24 22:18:17 kai Exp $
+/* $Id divert_init.c,v 1.5.6.2 2001/01/24 22:18:17 kai Exp $
  *
  * Module init for DSS1 diversion services for i4l.
  *
  * Copyright 1999       by Werner Cornelius (werner@isdn4linux.de)
  * 
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
@@ -26,6 +14,10 @@
 #include <linux/init.h>
 #include "isdn_divert.h"
 
+MODULE_DESCRIPTION("ISDN4Linux: Call diversion support");
+MODULE_AUTHOR("Werner Cornelius");
+MODULE_LICENSE("GPL");
+
 /********************/
 /* needed externals */
 /********************/
@@ -70,7 +62,7 @@
 /* Module deinit code */
 /**********************/
 static void  divert_exit(void)
-{ int flags;
+{ unsigned long flags;
   int i;
 
   save_flags(flags);
diff -urN linux-2.2.21-pre1/drivers/isdn/divert/divert_procfs.c linux/drivers/isdn/divert/divert_procfs.c
--- linux-2.2.21-pre1/drivers/isdn/divert/divert_procfs.c	Sun Mar 25 08:37:32 2001
+++ linux/drivers/isdn/divert/divert_procfs.c	Wed Jan  2 03:55:23 2002
@@ -1,23 +1,11 @@
-/*
- * $Id: divert_procfs.c,v 1.11 2000/11/25 17:01:00 kai Exp $
+/* $Id: divert_procfs.c,v 1.1.2.1 2001/12/31 13:26:44 kai Exp $
  *
  * Filesystem handling for the diversion supplementary services.
  *
  * Copyright 1998       by Werner Cornelius (werner@isdn4linux.de)
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
@@ -50,7 +38,7 @@
 put_info_buffer(char *cp)
 {
 	struct divert_info *ib;
-	int flags;
+	unsigned long flags;
 
 	if (if_used <= 0)
 		return;
@@ -145,7 +133,7 @@
 static int
 isdn_divert_open(struct inode *ino, struct file *filep)
 {
-	int flags;
+	unsigned long flags;
 
 	MOD_INC_USE_COUNT;
 	save_flags(flags);
@@ -167,7 +155,7 @@
 isdn_divert_close(struct inode *ino, struct file *filep)
 {
 	struct divert_info *inf;
-	int flags;
+	unsigned long flags;
 
 	save_flags(flags);
 	cli();
@@ -196,7 +184,8 @@
 		  uint cmd, ulong arg)
 {
 	divert_ioctl dioctl;
-	int i, flags;
+	int i;
+	unsigned long flags;
 	divert_rule *rulep;
 	char *cp;
 
diff -urN linux-2.2.21-pre1/drivers/isdn/divert/isdn_divert.c linux/drivers/isdn/divert/isdn_divert.c
--- linux-2.2.21-pre1/drivers/isdn/divert/isdn_divert.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/divert/isdn_divert.c	Wed Jan  2 03:55:23 2002
@@ -1,30 +1,14 @@
-/* 
- * $Id: isdn_divert.c,v 1.6.6.2 2001/02/16 16:43:25 kai Exp $
+/* $Id: isdn_divert.c,v 1.1.2.1 2001/12/31 13:26:44 kai Exp $
  *
  * DSS1 main diversion supplementary handling for i4l.
  *
  * Copyright 1999       by Werner Cornelius (werner@isdn4linux.de)
  * 
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
-
-
-#define __NO_VERSION__
-#include <linux/module.h>
 #include <linux/version.h>
 #include <linux/proc_fs.h>
 #include "isdn_divert.h"
@@ -67,7 +51,7 @@
 /* timer callback function */
 /***************************/
 static void deflect_timer_expire(ulong arg)
-{ int flags;
+{ unsigned long flags;
   struct call_struc *cs = (struct call_struc *) arg;
 
   save_flags(flags);
@@ -125,7 +109,8 @@
 int cf_command(int drvid, int mode, 
                u_char proc, char *msn, 
                u_char service, char *fwd_nr, ulong *procid)
-{ int retval,msnlen,flags;
+{ int retval,msnlen;
+  unsigned long flags; 
   int fwd_len;
   char *p,*ielenp,tmp[60];
   struct call_struc *cs;
@@ -220,7 +205,7 @@
 int deflect_extern_action(u_char cmd, ulong callid, char *to_nr)
 { struct call_struc *cs;
   isdn_ctrl ic;
-  int flags;
+  unsigned long flags;
   int i;
 
   if ((cmd & 0x7F) > 2) return(-EINVAL); /* invalid command */
@@ -291,7 +276,7 @@
 /********************************/
 int insertrule(int idx, divert_rule *newrule)
 { struct deflect_struc *ds,*ds1=NULL;
-  int flags;
+  unsigned long flags;
 
   if (!(ds = (struct deflect_struc *) kmalloc(sizeof(struct deflect_struc), 
                                               GFP_KERNEL))) 
@@ -337,7 +322,7 @@
 /***********************************/
 int deleterule(int idx)
 { struct deflect_struc *ds,*ds1;
-  int flags;
+  unsigned long flags;
   
   if (idx < 0) 
    { save_flags(flags);
@@ -405,7 +390,7 @@
 /*************************************************/
 int isdn_divert_icall(isdn_ctrl *ic)
 { int retval = 0;
-  int flags;
+  unsigned long flags;
   struct call_struc *cs = NULL; 
   struct deflect_struc *dv;
   char *p,*p1;
@@ -557,7 +542,7 @@
 
 void deleteprocs(void)
 { struct call_struc *cs, *cs1; 
-  int flags;
+  unsigned long flags;
 
   save_flags(flags);
   cli();
@@ -714,7 +699,8 @@
 /*********************************************/
 int prot_stat_callback(isdn_ctrl *ic)
 { struct call_struc *cs, *cs1;
-  int i,flags;
+  int i;
+  unsigned long flags;
 
   cs = divert_head; /* start of list */
   cs1 = NULL;
@@ -805,7 +791,7 @@
 /***************************/
 int isdn_divert_stat_callback(isdn_ctrl *ic)
 { struct call_struc *cs, *cs1;
-  int flags, retval;
+  unsigned long flags, retval;
 
   retval = -1;
   cs = divert_head; /* start of list */
diff -urN linux-2.2.21-pre1/drivers/isdn/divert/isdn_divert.h linux/drivers/isdn/divert/isdn_divert.h
--- linux-2.2.21-pre1/drivers/isdn/divert/isdn_divert.h	Sun Mar 25 08:37:32 2001
+++ linux/drivers/isdn/divert/isdn_divert.h	Wed Jan  2 03:55:23 2002
@@ -1,26 +1,13 @@
-/* 
- * $Id: isdn_divert.h,v 1.5 2000/11/13 22:51:47 kai Exp $
+/* $Id: isdn_divert.h,v 1.1.2.1 2001/12/31 13:26:44 kai Exp $
  *
  * Header for the diversion supplementary ioctl interface.
  *
  * Copyright 1998       by Werner Cornelius (werner@ikt.de)
  * 
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
-
 
 #include <linux/ioctl.h>
 #include <linux/types.h>
diff -urN linux-2.2.21-pre1/drivers/isdn/eicon/Divas_mod.c linux/drivers/isdn/eicon/Divas_mod.c
--- linux-2.2.21-pre1/drivers/isdn/eicon/Divas_mod.c	Sun Mar 25 08:37:32 2001
+++ linux/drivers/isdn/eicon/Divas_mod.c	Wed Jan  2 03:55:23 2002
@@ -1,23 +1,9 @@
-
 /*
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY OF ANY KIND WHATSOEVER INCLUDING ANY 
- * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  
- * See the GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
-
 #include <linux/config.h>
 #include <linux/init.h>
 #include <linux/fs.h>
@@ -36,6 +22,10 @@
 
 #include <linux/isdn_compat.h>
 
+MODULE_DESCRIPTION("ISDN4Linux: Driver for Eicon Diva Server cards");
+MODULE_AUTHOR("Armin Schindler");
+MODULE_LICENSE("GPL");
+
 #ifdef MODULE
 #include "idi.h"
 void DIVA_DIDD_Write(DESCRIPTOR *, int);
@@ -52,7 +42,6 @@
 	printk(KERN_DEBUG "DIVA Server Driver - initialising\n");
 	
 	printk(KERN_DEBUG "DIVA Server Driver - Version 2.0.16\n");
-
 
 #if !defined(CONFIG_PCI)
 	printk(KERN_WARNING "CONFIG_PCI is not defined!\n");
diff -urN linux-2.2.21-pre1/drivers/isdn/eicon/adapter.h linux/drivers/isdn/eicon/adapter.h
--- linux-2.2.21-pre1/drivers/isdn/eicon/adapter.h	Sun Mar 25 08:37:32 2001
+++ linux/drivers/isdn/eicon/adapter.h	Wed Jan  2 03:55:23 2002
@@ -1,28 +1,14 @@
-
 /*
+ * Main internal include file for Diva Server driver
  *
  * Copyright (C) Eicon Technology Corporation, 2000.
  *
  * Eicon File Revision :    1.7  
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY OF ANY KIND WHATSOEVER INCLUDING ANY 
- * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  
- * See the GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
-
-
-/* Main internal include file for Diva Server driver */
 
 #if !defined(ADAPTER_H)
 #define ADAPTER_H
diff -urN linux-2.2.21-pre1/drivers/isdn/eicon/bri.c linux/drivers/isdn/eicon/bri.c
--- linux-2.2.21-pre1/drivers/isdn/eicon/bri.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/eicon/bri.c	Wed Jan  2 03:55:23 2002
@@ -1,23 +1,10 @@
-
 /*
- *
  * Copyright (C) Eicon Technology Corporation, 2000.
  *
  * Eicon File Revision :    1.8  
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY OF ANY KIND WHATSOEVER INCLUDING ANY 
- * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  
- * See the GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
diff -urN linux-2.2.21-pre1/drivers/isdn/eicon/common.c linux/drivers/isdn/eicon/common.c
--- linux-2.2.21-pre1/drivers/isdn/eicon/common.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/eicon/common.c	Wed Jan  2 03:55:23 2002
@@ -1,27 +1,13 @@
-
 /*
- *
  * Copyright (C) Eicon Technology Corporation, 2000.
  *
  * Eicon File Revision :    1.15  
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY OF ANY KIND WHATSOEVER INCLUDING ANY 
- * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  
- * See the GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
-
 #include "eicon.h"
 #include "sys.h"
 #include "idi.h"
@@ -822,7 +808,9 @@
 	
 	while(i--)
 	{
-		DivaDoCardDpc(card++);
+            if (card->state == DIA_RUNNING)
+		DivaDoCardDpc(card);
+            card++;
 	}
 }
 
diff -urN linux-2.2.21-pre1/drivers/isdn/eicon/constant.h linux/drivers/isdn/eicon/constant.h
--- linux-2.2.21-pre1/drivers/isdn/eicon/constant.h	Sun Mar 25 08:37:32 2001
+++ linux/drivers/isdn/eicon/constant.h	Wed Jan  2 03:55:23 2002
@@ -1,27 +1,12 @@
-
 /*
- *
  * Copyright (C) Eicon Technology Corporation, 2000.
  *
  * Eicon File Revision :    1.0  
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY OF ANY KIND WHATSOEVER INCLUDING ANY 
- * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  
- * See the GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
-
-
 
 /*------------------------------------------------------------------*/
 /* Q.931 information elements maximum length                        */
diff -urN linux-2.2.21-pre1/drivers/isdn/eicon/divalog.h linux/drivers/isdn/eicon/divalog.h
--- linux-2.2.21-pre1/drivers/isdn/eicon/divalog.h	Sun Mar 25 08:37:32 2001
+++ linux/drivers/isdn/eicon/divalog.h	Wed Jan  2 03:55:23 2002
@@ -1,31 +1,15 @@
-
 /*
+ * Include file for defining the kernel loggger messages
+ * These definitions are shared between the klog driver and the
+ * klogd daemon process
  *
  * Copyright (C) Eicon Technology Corporation, 2000.
  *
  * Eicon File Revision :    1.0  
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY OF ANY KIND WHATSOEVER INCLUDING ANY 
- * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  
- * See the GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
- */
-
-
-/*
- * Include file for defining the kernel loggger messages
- * These definitions are shared between the klog driver and the
- * klogd daemon process
  */
 
 #if !defined(_KLOGMSG_H)
diff -urN linux-2.2.21-pre1/drivers/isdn/eicon/divas.h linux/drivers/isdn/eicon/divas.h
--- linux-2.2.21-pre1/drivers/isdn/eicon/divas.h	Sun Mar 25 08:37:32 2001
+++ linux/drivers/isdn/eicon/divas.h	Wed Jan  2 03:55:23 2002
@@ -1,28 +1,14 @@
-
 /*
+ * External Diva Server driver include file
  *
  * Copyright (C) Eicon Technology Corporation, 2000.
  *
  * Eicon File Revision :    1.5  
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY OF ANY KIND WHATSOEVER INCLUDING ANY 
- * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  
- * See the GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
-
-
-/* External Diva Server driver include file */
 
 #if !defined(DIVAS_H)
 #define DIVAS_H
diff -urN linux-2.2.21-pre1/drivers/isdn/eicon/dsp_defs.h linux/drivers/isdn/eicon/dsp_defs.h
--- linux-2.2.21-pre1/drivers/isdn/eicon/dsp_defs.h	Sun Mar 25 08:37:32 2001
+++ linux/drivers/isdn/eicon/dsp_defs.h	Wed Jan  2 03:55:23 2002
@@ -1,26 +1,12 @@
-
 /*
- *
  * Copyright (C) Eicon Technology Corporation, 2000.
  *
  * Eicon File Revision :    1.0  
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY OF ANY KIND WHATSOEVER INCLUDING ANY 
- * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  
- * See the GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
-
 
 #ifndef DSP_DEFS_H_
 #define DSP_DEFS_H_
diff -urN linux-2.2.21-pre1/drivers/isdn/eicon/dspdids.h linux/drivers/isdn/eicon/dspdids.h
--- linux-2.2.21-pre1/drivers/isdn/eicon/dspdids.h	Sun Mar 25 08:37:32 2001
+++ linux/drivers/isdn/eicon/dspdids.h	Wed Jan  2 03:55:23 2002
@@ -1,26 +1,12 @@
-
 /*
- *
  * Copyright (C) Eicon Technology Corporation, 2000.
  *
  * Eicon File Revision :    1.0  
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY OF ANY KIND WHATSOEVER INCLUDING ANY 
- * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  
- * See the GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
-
 
 #ifndef DSPDIDS_H_
 #define DSPDIDS_H_
diff -urN linux-2.2.21-pre1/drivers/isdn/eicon/eicon.h linux/drivers/isdn/eicon/eicon.h
--- linux-2.2.21-pre1/drivers/isdn/eicon/eicon.h	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/eicon/eicon.h	Wed Jan  2 03:55:23 2002
@@ -1,27 +1,15 @@
-/* $Id: eicon.h,v 1.23.6.4 2001/06/09 15:14:16 kai Exp $
+/* $Id: eicon.h,v 1.1.2.1 2001/12/31 13:26:44 kai Exp $
  *
  * ISDN low-level module for Eicon active ISDN-Cards.
  *
- * Copyright 1998    by Fritz Elfert (fritz@isdn4linux.de)
+ * Copyright 1998       by Fritz Elfert (fritz@isdn4linux.de)
  * Copyright 1998-2000  by Armin Schindler (mac@melware.de) 
  * Copyright 1999,2000  Cytronics & Melware (info@melware.de)
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
-
 
 #ifndef eicon_h
 #define eicon_h
diff -urN linux-2.2.21-pre1/drivers/isdn/eicon/eicon_dsp.h linux/drivers/isdn/eicon/eicon_dsp.h
--- linux-2.2.21-pre1/drivers/isdn/eicon/eicon_dsp.h	Sun Mar 25 08:37:32 2001
+++ linux/drivers/isdn/eicon/eicon_dsp.h	Wed Jan  2 03:55:23 2002
@@ -1,25 +1,13 @@
-/* $Id: eicon_dsp.h,v 1.7 2000/05/07 08:51:04 armin Exp $
+/* $Id: eicon_dsp.h,v 1.1.2.1 2001/12/31 13:26:44 kai Exp $
  *
  * ISDN lowlevel-module for Eicon active cards.
- *        DSP definitions
+ * DSP definitions
  *
  * Copyright 1999,2000  by Armin Schindler (mac@melware.de)
  * Copyright 1999,2000  Cytronics & Melware (info@melware.de)
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
- *
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
diff -urN linux-2.2.21-pre1/drivers/isdn/eicon/eicon_idi.c linux/drivers/isdn/eicon/eicon_idi.c
--- linux-2.2.21-pre1/drivers/isdn/eicon/eicon_idi.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/eicon/eicon_idi.c	Wed Jan  2 03:55:23 2002
@@ -1,7 +1,7 @@
-/* $Id: eicon_idi.c,v 1.41.6.1 2001/02/10 14:44:09 kai Exp $
+/* $Id: eicon_idi.c,v 1.1.2.1 2001/12/31 13:26:44 kai Exp $
  *
  * ISDN lowlevel-module for Eicon active cards.
- *        IDI interface 
+ * IDI interface 
  *
  * Copyright 1998-2000  by Armin Schindler (mac@melware.de)
  * Copyright 1999,2000  Cytronics & Melware (info@melware.de)
@@ -11,19 +11,8 @@
  *		capabilities with Diva Server cards.
  *		(dor@deutschemailbox.de)
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
@@ -36,7 +25,7 @@
 
 #undef EICON_FULL_SERVICE_OKTETT
 
-char *eicon_idi_revision = "$Revision: 1.41.6.1 $";
+char *eicon_idi_revision = "$Revision: 1.1.2.1 $";
 
 eicon_manifbuf *manbuf;
 
@@ -3130,8 +3119,8 @@
 			return(ret); 
 		}
 
-	        timeout = jiffies + 50;
-        	while (timeout > jiffies) {
+	        timeout = jiffies + HZ / 2;
+        	while (time_before(jiffies, timeout)) {
 	                if (chan->e.B2Id) break;
         	        SLEEP(10);
 	        }
@@ -3192,8 +3181,8 @@
 
         eicon_schedule_tx(card);
 
-        timeout = jiffies + 50;
-        while (timeout > jiffies) {
+        timeout = jiffies + HZ / 2;
+        while (time_before(jiffies, timeout)) {
                 if (chan->fsm_state) break;
                 SLEEP(10);
         }
diff -urN linux-2.2.21-pre1/drivers/isdn/eicon/eicon_idi.h linux/drivers/isdn/eicon/eicon_idi.h
--- linux-2.2.21-pre1/drivers/isdn/eicon/eicon_idi.h	Sun Mar 25 08:37:32 2001
+++ linux/drivers/isdn/eicon/eicon_idi.h	Wed Jan  2 03:55:23 2002
@@ -1,4 +1,4 @@
-/* $Id: eicon_idi.h,v 1.11 2000/05/07 08:51:04 armin Exp $
+/* $Id: eicon_idi.h,v 1.1.2.1 2001/12/31 13:26:44 kai Exp $
  *
  * ISDN lowlevel-module for the Eicon active cards.
  * IDI-Interface
@@ -6,20 +6,8 @@
  * Copyright 1998-2000  by Armin Schindler (mac@melware.de)
  * Copyright 1999,2000  Cytronics & Melware (info@melware.de)
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. 
- *
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
diff -urN linux-2.2.21-pre1/drivers/isdn/eicon/eicon_io.c linux/drivers/isdn/eicon/eicon_io.c
--- linux-2.2.21-pre1/drivers/isdn/eicon/eicon_io.c	Sun Mar 25 08:37:32 2001
+++ linux/drivers/isdn/eicon/eicon_io.c	Wed Jan  2 03:55:23 2002
@@ -1,4 +1,4 @@
-/* $Id: eicon_io.c,v 1.13.6.1 2001/02/16 09:09:50 armin Exp $
+/* $Id: eicon_io.c,v 1.1.2.1 2001/12/31 13:26:44 kai Exp $
  *
  * ISDN low-level module for Eicon active ISDN-Cards.
  * Code for communicating with hardware.
@@ -6,25 +6,13 @@
  * Copyright 1999,2000  by Armin Schindler (mac@melware.de)
  * Copyright 1999,2000  Cytronics & Melware (info@melware.de)
  *
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
+ *
  * Thanks to	Eicon Networks for 
  *		documents, informations and hardware. 
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. 
- *
  */
-
 
 #include <linux/config.h>
 #include "eicon.h"
diff -urN linux-2.2.21-pre1/drivers/isdn/eicon/eicon_isa.c linux/drivers/isdn/eicon/eicon_isa.c
--- linux-2.2.21-pre1/drivers/isdn/eicon/eicon_isa.c	Sun Mar 25 08:37:32 2001
+++ linux/drivers/isdn/eicon/eicon_isa.c	Wed Jan  2 03:55:23 2002
@@ -1,4 +1,4 @@
-/* $Id: eicon_isa.c,v 1.16 2000/06/12 12:44:02 armin Exp $
+/* $Id: eicon_isa.c,v 1.1.2.1 2001/12/31 13:26:44 kai Exp $
  *
  * ISDN low-level module for Eicon active ISDN-Cards.
  * Hardware-specific code for old ISA cards.
@@ -7,19 +7,8 @@
  * Copyright 1998-2000 by Armin Schindler (mac@melware.de)
  * Copyright 1999,2000 Cytronics & Melware (info@melware.de)
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
@@ -31,7 +20,7 @@
 #define release_shmem release_region
 #define request_shmem request_region
 
-char *eicon_isa_revision = "$Revision: 1.16 $";
+char *eicon_isa_revision = "$Revision: 1.1.2.1 $";
 
 #undef EICON_MCA_DEBUG
 
@@ -239,7 +228,7 @@
 	boot = &card->shmem->boot;
 
 	/* Delay 0.2 sec. */
-	SLEEP(20);
+	SLEEP(HZ / 5);
 
 	/* Start CPU */
 	writeb(cbuf.boot_opt, &boot->ctrl);
@@ -252,10 +241,10 @@
 #endif /* CONFIG_MCA */
 
 	/* Delay 0.2 sec. */
-	SLEEP(20);
+	SLEEP(HZ / 5);
 
 	timeout = jiffies + (HZ * 22);
-	while (timeout > jiffies) {
+	while (time_before(jiffies, timeout)) {
 		if (readb(&boot->ctrl) == 0)
 			break;
 		SLEEP(10);
@@ -370,8 +359,8 @@
 	while (tmp--) {
 		memcpy_toio(&boot->b, p, 256);
 		writeb(1, &boot->ctrl);
-		timeout = jiffies + 10;
-		while (timeout > jiffies) {
+		timeout = jiffies + HZ / 10;
+		while (time_before(jiffies, timeout)) {
 			if (readb(&boot->ctrl) == 0)
 				break;
 			SLEEP(2);
@@ -394,7 +383,7 @@
 	/* Start firmware, wait for signature */
 	writeb(2, &boot->ctrl);
 	timeout = jiffies + (5*HZ);
-	while (timeout > jiffies) {
+	while (time_before(jiffies, timeout)) {
 		if (readw(&boot->signature) == 0x4447)
 			break;
 		SLEEP(2);
@@ -418,8 +407,8 @@
 		tmp = readb(&card->shmem->com.ReadyInt);
 		tmp ++;
 		writeb(tmp, &card->shmem->com.ReadyInt);
-		timeout = jiffies + 20;
-		while (timeout > jiffies) {
+		timeout = jiffies + HZ / 5;
+		while (time_before(jiffies, timeout)) {
 			if (card->irqprobe > 1)
 				break;
 			SLEEP(2);
diff -urN linux-2.2.21-pre1/drivers/isdn/eicon/eicon_isa.h linux/drivers/isdn/eicon/eicon_isa.h
--- linux-2.2.21-pre1/drivers/isdn/eicon/eicon_isa.h	Sun Mar 25 08:37:32 2001
+++ linux/drivers/isdn/eicon/eicon_isa.h	Wed Jan  2 03:55:23 2002
@@ -1,4 +1,4 @@
-/* $Id: eicon_isa.h,v 1.10 2000/05/07 08:51:04 armin Exp $
+/* $Id: eicon_isa.h,v 1.1.2.1 2001/12/31 13:26:44 kai Exp $
  *
  * ISDN low-level module for Eicon active ISDN-Cards.
  *
@@ -6,19 +6,8 @@
  * Copyright 1998-2000 by Armin Schindler (mac@melware.de)
  * Copyright 1999,2000 Cytronics & Melware (info@melware.de)
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
diff -urN linux-2.2.21-pre1/drivers/isdn/eicon/eicon_mod.c linux/drivers/isdn/eicon/eicon_mod.c
--- linux-2.2.21-pre1/drivers/isdn/eicon/eicon_mod.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/eicon/eicon_mod.c	Wed Jan  2 03:55:23 2002
@@ -1,4 +1,4 @@
-/* $Id: eicon_mod.c,v 1.37.6.5 2001/07/17 19:42:31 armin Exp $
+/* $Id: eicon_mod.c,v 1.1.2.1 2001/12/31 13:26:44 kai Exp $
  *
  * ISDN lowlevel-module for Eicon active cards.
  * 
@@ -6,6 +6,9 @@
  * Copyright 1998-2000 by Armin Schindler (mac@melware.de) 
  * Copyright 1999,2000 Cytronics & Melware (info@melware.de)
  * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
+ *
  * Thanks to    Eicon Networks for
  *              documents, informations and hardware.
  *
@@ -14,20 +17,6 @@
  *		capabilities with Diva Server cards.
  *		(dor@deutschemailbox.de)
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. 
- *
  */
 
 #define DRIVERNAME "Eicon active ISDN driver"
@@ -55,7 +44,7 @@
 static eicon_card *cards = (eicon_card *) NULL;   /* glob. var , contains
                                                      start of card-list   */
 
-static char *eicon_revision = "$Revision: 1.37.6.5 $";
+static char *eicon_revision = "$Revision: 1.1.2.1 $";
 
 extern char *eicon_pci_revision;
 extern char *eicon_isa_revision;
@@ -84,9 +73,9 @@
 #endif
 static char *id           = "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0";
 
-MODULE_DESCRIPTION(             "Driver for Eicon active ISDN cards");
+MODULE_DESCRIPTION(             "ISDN4Linux: Driver for Eicon active ISDN cards");
 MODULE_AUTHOR(                  "Armin Schindler");
-MODULE_SUPPORTED_DEVICE(        "ISDN subsystem");
+MODULE_LICENSE(                 "GPL");
 MODULE_PARM_DESC(id,   		"ID-String of first card");
 MODULE_PARM(id,           	"s");
 #ifdef CONFIG_ISDN_DRV_EICON_ISA
@@ -1555,7 +1544,7 @@
             	};
 	};
 	/* all adapter flavors checked without match, finito with:            */
-        return ENODEV;
+        return -ENODEV;
 };
 
 
@@ -1602,14 +1591,14 @@
 				membase = cards_membase;
 			} else {
 				if (membase != cards_membase)
-					return ENODEV;
+					return -ENODEV;
 			};
 			cards_irq=irq_array[((adf_pos0 & 0xC)>>2)];
 			if (irq == -1) { 
 				irq = cards_irq;
 			} else {
 				if (irq != cards_irq)
-					return ENODEV;
+					return -ENODEV;
 			};
 			cards_io= 0xC00 + ((adf_pos0>>4)*0x10);
 			type = EICON_CTYPE_ISAPRI; 
@@ -1621,14 +1610,14 @@
 				membase = cards_membase;
 			} else {
 				if (membase != cards_membase)
-					return ENODEV;
+					return -ENODEV;
 			};
 			cards_irq=irq_array[((adf_pos0 & 0xC)>>2)];
 			if (irq == -1) { 
 				irq = cards_irq;
 			} else {
 				if (irq != cards_irq)
-					return ENODEV;
+					return -ENODEV;
 			};
 
 			cards_io= 0xC00 + ((adf_pos0>>4)*0x10);
@@ -1642,12 +1631,12 @@
 				irq = cards_irq;
 			} else {
 				if (irq != cards_irq)
-					return ENODEV;
+					return -ENODEV;
 			};
 			type = 0; 
 			break;
 		default:
-			return  ENODEV;
+			return -ENODEV;
 	};
 	/* matching membase & irq */
 	if ( 1 == eicon_addcard(type, membase, irq, id, 0)) { 
@@ -1666,7 +1655,7 @@
 			cards->mca_slot+1);
 		return  0 ; /* eicon_addcard added a card */
 	} else {
-		return ENODEV;
+		return -ENODEV;
 	};
 };
 #endif /* CONFIG_MCA */
diff -urN linux-2.2.21-pre1/drivers/isdn/eicon/eicon_pci.c linux/drivers/isdn/eicon/eicon_pci.c
--- linux-2.2.21-pre1/drivers/isdn/eicon/eicon_pci.c	Sun Mar 25 08:37:32 2001
+++ linux/drivers/isdn/eicon/eicon_pci.c	Wed Jan  2 03:55:23 2002
@@ -1,4 +1,4 @@
-/* $Id: eicon_pci.c,v 1.15.6.2 2001/02/16 09:09:50 armin Exp $
+/* $Id: eicon_pci.c,v 1.1.2.1 2001/12/31 13:26:44 kai Exp $
  *
  * ISDN low-level module for Eicon active ISDN-Cards.
  * Hardware-specific code for PCI cards.
@@ -6,23 +6,12 @@
  * Copyright 1998-2000 by Armin Schindler (mac@melware.de)
  * Copyright 1999,2000 Cytronics & Melware (info@melware.de)
  *
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
+ *
  * Thanks to	Eicon Networks for 
  *		documents, informations and hardware. 
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. 
- *
  */
 
 #include <linux/config.h>
@@ -35,7 +24,7 @@
 #include "adapter.h"
 #include "uxio.h"
 
-char *eicon_pci_revision = "$Revision: 1.15.6.2 $";
+char *eicon_pci_revision = "$Revision: 1.1.2.1 $";
 
 #if CONFIG_PCI	         /* intire stuff is only for PCI */
 #ifdef CONFIG_ISDN_DRV_EICON_PCI
diff -urN linux-2.2.21-pre1/drivers/isdn/eicon/eicon_pci.h linux/drivers/isdn/eicon/eicon_pci.h
--- linux-2.2.21-pre1/drivers/isdn/eicon/eicon_pci.h	Sun Mar 25 08:37:32 2001
+++ linux/drivers/isdn/eicon/eicon_pci.h	Wed Jan  2 03:55:23 2002
@@ -1,23 +1,12 @@
-/* $Id: eicon_pci.h,v 1.6 2000/05/07 08:51:04 armin Exp $
+/* $Id: eicon_pci.h,v 1.1.2.1 2001/12/31 13:26:44 kai Exp $
  *
  * ISDN low-level module for Eicon active ISDN-Cards (PCI part).
  *
  * Copyright 1998-2000 by Armin Schindler (mac@melware.de)
  * Copyright 1999,2000 Cytronics & Melware (info@melware.de)
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
diff -urN linux-2.2.21-pre1/drivers/isdn/eicon/fourbri.c linux/drivers/isdn/eicon/fourbri.c
--- linux-2.2.21-pre1/drivers/isdn/eicon/fourbri.c	Sun Mar 25 08:37:32 2001
+++ linux/drivers/isdn/eicon/fourbri.c	Wed Jan  2 03:55:23 2002
@@ -1,28 +1,15 @@
-
 /*
+ * Diva Server 4BRI specific part of initialisation
  *
  * Copyright (C) Eicon Technology Corporation, 2000.
  *
  * Eicon File Revision :    1.7  
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY OF ANY KIND WHATSOEVER INCLUDING ANY 
- * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  
- * See the GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
-
-/* Diva Server 4BRI specific part of initialisation */
 #include "sys.h"
 #include "idi.h"
 #include "divas.h"
diff -urN linux-2.2.21-pre1/drivers/isdn/eicon/fpga.c linux/drivers/isdn/eicon/fpga.c
--- linux-2.2.21-pre1/drivers/isdn/eicon/fpga.c	Sun Mar 25 08:37:32 2001
+++ linux/drivers/isdn/eicon/fpga.c	Wed Jan  2 03:55:23 2002
@@ -1,26 +1,12 @@
-
 /*
- *
  * Copyright (C) Eicon Technology Corporation, 2000.
  *
  * Eicon File Revision :    1.2  
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY OF ANY KIND WHATSOEVER INCLUDING ANY 
- * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  
- * See the GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
-
 
 #include "sys.h"
 #include "idi.h"
diff -urN linux-2.2.21-pre1/drivers/isdn/eicon/idi.c linux/drivers/isdn/eicon/idi.c
--- linux-2.2.21-pre1/drivers/isdn/eicon/idi.c	Sun Mar 25 08:37:32 2001
+++ linux/drivers/isdn/eicon/idi.c	Wed Jan  2 03:55:23 2002
@@ -1,30 +1,14 @@
-
 /*
+ * Core driver for Diva Server cards
+ * Implements the IDI interface
  *
  * Copyright (C) Eicon Technology Corporation, 2000.
  *
  * Eicon File Revision :    1.8  
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY OF ANY KIND WHATSOEVER INCLUDING ANY 
- * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  
- * See the GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
- */
-
-
-/*
- * Core driver for Diva Server cards
- * Implements the IDI interface
  */
 
 #include "idi.h"
diff -urN linux-2.2.21-pre1/drivers/isdn/eicon/idi.h linux/drivers/isdn/eicon/idi.h
--- linux-2.2.21-pre1/drivers/isdn/eicon/idi.h	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/eicon/idi.h	Wed Jan  2 03:55:23 2002
@@ -1,28 +1,14 @@
-
 /*
+ * External IDI interface
  *
  * Copyright (C) Eicon Technology Corporation, 2000.
  *
  * Eicon File Revision :    1.0  
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY OF ANY KIND WHATSOEVER INCLUDING ANY 
- * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  
- * See the GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
-
-
-/* External IDI interface */
 
 #if !defined(IDI_H)
 #define IDI_H
diff -urN linux-2.2.21-pre1/drivers/isdn/eicon/kprintf.c linux/drivers/isdn/eicon/kprintf.c
--- linux-2.2.21-pre1/drivers/isdn/eicon/kprintf.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/eicon/kprintf.c	Wed Jan  2 03:55:23 2002
@@ -1,31 +1,14 @@
-
 /*
+ * Source file for kernel interface to kernel log facility
  *
  * Copyright (C) Eicon Technology Corporation, 2000.
  *
  * Eicon File Revision :    1.3  
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY OF ANY KIND WHATSOEVER INCLUDING ANY 
- * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  
- * See the GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
-
-
-/*
- * Source file for kernel interface to kernel log facility
- */
-
 
 #include "eicon.h"
 #include "sys.h"
diff -urN linux-2.2.21-pre1/drivers/isdn/eicon/lincfg.c linux/drivers/isdn/eicon/lincfg.c
--- linux-2.2.21-pre1/drivers/isdn/eicon/lincfg.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/eicon/lincfg.c	Wed Jan  2 03:55:23 2002
@@ -1,26 +1,12 @@
-
 /*
- *
  * Copyright (C) Eicon Technology Corporation, 2000.
  *
  * Eicon File Revision :    1.9  
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY OF ANY KIND WHATSOEVER INCLUDING ANY 
- * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  
- * See the GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
-
 
 #include <linux/fs.h>
 #undef N_DATA   /* Because we have our own definition */
diff -urN linux-2.2.21-pre1/drivers/isdn/eicon/linchr.c linux/drivers/isdn/eicon/linchr.c
--- linux-2.2.21-pre1/drivers/isdn/eicon/linchr.c	Sun Mar 25 08:37:32 2001
+++ linux/drivers/isdn/eicon/linchr.c	Wed Jan  2 03:55:23 2002
@@ -1,23 +1,10 @@
-
 /*
- *
  * Copyright (C) Eicon Technology Corporation, 2000.
  *
  * Eicon File Revision :    1.12  
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY OF ANY KIND WHATSOEVER INCLUDING ANY 
- * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  
- * See the GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
diff -urN linux-2.2.21-pre1/drivers/isdn/eicon/linio.c linux/drivers/isdn/eicon/linio.c
--- linux-2.2.21-pre1/drivers/isdn/eicon/linio.c	Sun Mar 25 08:37:32 2001
+++ linux/drivers/isdn/eicon/linio.c	Wed Jan  2 03:55:23 2002
@@ -1,26 +1,12 @@
-
 /*
- *
  * Copyright (C) Eicon Technology Corporation, 2000.
  *
  * Eicon File Revision :    1.16  
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY OF ANY KIND WHATSOEVER INCLUDING ANY 
- * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  
- * See the GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
-
 
 #define N_DATA
 
diff -urN linux-2.2.21-pre1/drivers/isdn/eicon/linsys.c linux/drivers/isdn/eicon/linsys.c
--- linux-2.2.21-pre1/drivers/isdn/eicon/linsys.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/eicon/linsys.c	Wed Jan  2 03:55:23 2002
@@ -1,26 +1,12 @@
-
 /*
- *
  * Copyright (C) Eicon Technology Corporation, 2000.
  *
  * Eicon File Revision :    1.10  
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY OF ANY KIND WHATSOEVER INCLUDING ANY 
- * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  
- * See the GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
-
 
 #include <linux/sched.h>
 #undef N_DATA
diff -urN linux-2.2.21-pre1/drivers/isdn/eicon/log.c linux/drivers/isdn/eicon/log.c
--- linux-2.2.21-pre1/drivers/isdn/eicon/log.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/eicon/log.c	Wed Jan  2 03:55:23 2002
@@ -1,29 +1,13 @@
-   
 /*
+ * Source file for diva log facility
  *
  * Copyright (C) Eicon Technology Corporation, 2000.
  *
  * Eicon File Revision :    1.5  
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY OF ANY KIND WHATSOEVER INCLUDING ANY 
- * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  
- * See the GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
- */
-
-
-/*
- * Source file for diva log facility
  */
 
 #include "sys.h"
diff -urN linux-2.2.21-pre1/drivers/isdn/eicon/pc.h linux/drivers/isdn/eicon/pc.h
--- linux-2.2.21-pre1/drivers/isdn/eicon/pc.h	Sun Mar 25 08:37:32 2001
+++ linux/drivers/isdn/eicon/pc.h	Wed Jan  2 03:55:23 2002
@@ -1,26 +1,12 @@
-
 /*
- *
  * Copyright (C) Eicon Technology Corporation, 2000.
  *
  * Eicon File Revision :    1.2  
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY OF ANY KIND WHATSOEVER INCLUDING ANY 
- * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  
- * See the GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
-
 
 #ifndef PC_H_INCLUDED
 #define PC_H_INCLUDED
diff -urN linux-2.2.21-pre1/drivers/isdn/eicon/pc_maint.h linux/drivers/isdn/eicon/pc_maint.h
--- linux-2.2.21-pre1/drivers/isdn/eicon/pc_maint.h	Sun Mar 25 08:37:32 2001
+++ linux/drivers/isdn/eicon/pc_maint.h	Wed Jan  2 03:55:23 2002
@@ -1,26 +1,12 @@
-
 /*
- *
  * Copyright (C) Eicon Technology Corporation, 2000.
  *
  * Eicon File Revision :    1.0  
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY OF ANY KIND WHATSOEVER INCLUDING ANY 
- * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  
- * See the GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
-
 
 #ifndef PC_MAINT_H
 #define PC_MAINT_H
diff -urN linux-2.2.21-pre1/drivers/isdn/eicon/pr_pc.h linux/drivers/isdn/eicon/pr_pc.h
--- linux-2.2.21-pre1/drivers/isdn/eicon/pr_pc.h	Sun Mar 25 08:37:32 2001
+++ linux/drivers/isdn/eicon/pr_pc.h	Wed Jan  2 03:55:23 2002
@@ -1,23 +1,10 @@
-
 /*
- *
  * Copyright (C) Eicon Technology Corporation, 2000.
  *
  * Eicon File Revision :    1.0  
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY OF ANY KIND WHATSOEVER INCLUDING ANY 
- * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  
- * See the GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
diff -urN linux-2.2.21-pre1/drivers/isdn/eicon/pri.c linux/drivers/isdn/eicon/pri.c
--- linux-2.2.21-pre1/drivers/isdn/eicon/pri.c	Sun Mar 25 08:37:32 2001
+++ linux/drivers/isdn/eicon/pri.c	Wed Jan  2 03:55:23 2002
@@ -1,28 +1,15 @@
-
 /*
+ * Diva Server PRI specific part of initialisation
  *
  * Copyright (C) Eicon Technology Corporation, 2000.
  *
  * Eicon File Revision :    1.5  
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY OF ANY KIND WHATSOEVER INCLUDING ANY 
- * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  
- * See the GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
-
-/* Diva Server PRI specific part of initialisation */
 #include "sys.h"
 #include "idi.h"
 #include "divas.h"
diff -urN linux-2.2.21-pre1/drivers/isdn/eicon/sys.h linux/drivers/isdn/eicon/sys.h
--- linux-2.2.21-pre1/drivers/isdn/eicon/sys.h	Sun Mar 25 08:37:32 2001
+++ linux/drivers/isdn/eicon/sys.h	Wed Jan  2 03:55:23 2002
@@ -1,28 +1,14 @@
-
 /*
+ * Environment provided by system and miscellaneous definitions
  *
  * Copyright (C) Eicon Technology Corporation, 2000.
  *
  * Eicon File Revision :    1.2  
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY OF ANY KIND WHATSOEVER INCLUDING ANY 
- * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  
- * See the GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
-
-
-/* Environment provided by system and miscellaneous definitions */
 
 #if !defined(SYS_H)
 #define SYS_H
diff -urN linux-2.2.21-pre1/drivers/isdn/eicon/uxio.h linux/drivers/isdn/eicon/uxio.h
--- linux-2.2.21-pre1/drivers/isdn/eicon/uxio.h	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/eicon/uxio.h	Wed Jan  2 03:55:23 2002
@@ -1,29 +1,13 @@
-
 /*
+ * Interface to Unix specific code for performing card I/O
  *
  * Copyright (C) Eicon Technology Corporation, 2000.
  *
  * Eicon File Revision :    1.6  
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY OF ANY KIND WHATSOEVER INCLUDING ANY 
- * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  
- * See the GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
- */
-
-
-/*
- * Interface to Unix specific code for performing card I/O
  */
 
 #if !defined(UXIO_H)
diff -urN linux-2.2.21-pre1/drivers/isdn/eicon/xlog.c linux/drivers/isdn/eicon/xlog.c
--- linux-2.2.21-pre1/drivers/isdn/eicon/xlog.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/eicon/xlog.c	Wed Jan  2 03:55:23 2002
@@ -1,30 +1,14 @@
-
 /*
+ * Unix Eicon active card driver
+ * XLOG related functions
  *
  * Copyright (C) Eicon Technology Corporation, 2000.
  *
  * Eicon File Revision :    1.2  
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY OF ANY KIND WHATSOEVER INCLUDING ANY 
- * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  
- * See the GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
- */
-
-
-/*
- * Unix Eicon active card driver
- * XLOG related functions
  */
 
 #include "sys.h"
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/amd7930.c linux/drivers/isdn/hisax/amd7930.c
--- linux-2.2.21-pre1/drivers/isdn/hisax/amd7930.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/amd7930.c	Wed Jan  2 03:55:23 2002
@@ -1,8 +1,12 @@
-/* $Id: amd7930.c,v 1.5.6.3 2001/06/11 22:08:37 kai Exp $
+/* $Id: amd7930.c,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
  *
  * HiSax ISDN driver - chip specific routines for AMD 7930
  *
- * Author       Brent Baccala (baccala@FreeSoft.org)
+ * Author       Brent Baccala
+ * Copyright    by Brent Baccala <baccala@FreeSoft.org>
+ *
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  *    - Existing ISDN HiSax driver provides all the smarts
  *    - it compiles, runs, talks to an isolated phone switch, connects
@@ -94,7 +98,7 @@
 #include "rawhdlc.h"
 #include <linux/interrupt.h>
 
-static const char *amd7930_revision = "$Revision: 1.5.6.3 $";
+static const char *amd7930_revision = "$Revision: 1.1.2.1 $";
 
 #define RCV_BUFSIZE	1024	/* Size of raw receive buffer in bytes */
 #define RCV_BUFBLKS	4	/* Number of blocks to divide buffer into
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/arcofi.c linux/drivers/isdn/hisax/arcofi.c
--- linux-2.2.21-pre1/drivers/isdn/hisax/arcofi.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/arcofi.c	Wed Jan  2 03:55:23 2002
@@ -1,10 +1,12 @@
-/* $Id: arcofi.c,v 1.12.6.1 2001/02/16 16:43:25 kai Exp $
+/* $Id: arcofi.c,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
  *
- * arcofi.c   Ansteuerung ARCOFI 2165
+ * Ansteuerung ARCOFI 2165
  *
- * Author     Karsten Keil (keil@isdn4linux.de)
+ * Author       Karsten Keil
+ * Copyright    by Karsten Keil      <keil@isdn4linux.de>
  *
- * This file is (c) under GNU General Public License
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
  
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/arcofi.h linux/drivers/isdn/hisax/arcofi.h
--- linux-2.2.21-pre1/drivers/isdn/hisax/arcofi.h	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/arcofi.h	Wed Jan  2 03:55:23 2002
@@ -1,10 +1,12 @@
-/* $Id: arcofi.h,v 1.6.6.1 2001/02/16 16:43:25 kai Exp $
+/* $Id: arcofi.h,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
  *
- * arcofi.h   Ansteuerung ARCOFI 2165
+ * Ansteuerung ARCOFI 2165
  *
- * Author     Karsten Keil (keil@isdn4linux.de)
+ * Author       Karsten Keil
+ * Copyright    by Karsten Keil      <keil@isdn4linux.de>
  *
- * This file is (c) under GNU General Public License
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
  
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/asuscom.c linux/drivers/isdn/hisax/asuscom.c
--- linux-2.2.21-pre1/drivers/isdn/hisax/asuscom.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/asuscom.c	Wed Jan  2 03:55:23 2002
@@ -1,12 +1,14 @@
-/* $Id: asuscom.c,v 1.11.6.2 2001/07/13 09:20:12 kai Exp $
+/* $Id: asuscom.c,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
  *
- * asuscom.c     low level stuff for ASUSCOM NETWORK INC. ISDNLink cards
+ * low level stuff for ASUSCOM NETWORK INC. ISDNLink cards
  *
- * Author     Karsten Keil (keil@isdn4linux.de)
+ * Author       Karsten Keil
+ * Copyright    by Karsten Keil      <keil@isdn4linux.de>
  *
- * Thanks to  ASUSCOM NETWORK INC. Taiwan and  Dynalink NL for informations
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
- * This file is (c) under GNU General Public License
+ * Thanks to  ASUSCOM NETWORK INC. Taiwan and  Dynalink NL for information
  *
  */
 
@@ -20,7 +22,7 @@
 
 extern const char *CardType[];
 
-const char *Asuscom_revision = "$Revision: 1.11.6.2 $";
+const char *Asuscom_revision = "$Revision: 1.1.2.1 $";
 
 #define byteout(addr,val) outb(val,addr)
 #define bytein(addr) inb(addr)
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/avm_a1.c linux/drivers/isdn/hisax/avm_a1.c
--- linux-2.2.21-pre1/drivers/isdn/hisax/avm_a1.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/avm_a1.c	Wed Jan  2 03:55:23 2002
@@ -1,12 +1,15 @@
-/* $Id: avm_a1.c,v 2.13.6.1 2001/02/16 16:43:25 kai Exp $
+/* $Id: avm_a1.c,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
  *
- * avm_a1.c     low level stuff for AVM A1 (Fritz) isdn cards
+ * low level stuff for AVM A1 (Fritz) isdn cards
  *
- * Author       Karsten Keil (keil@isdn4linux.de)
+ * Author       Karsten Keil
+ * Copyright    by Karsten Keil      <keil@isdn4linux.de>
  *
- * This file is (c) under GNU General Public License
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
+
 #define __NO_VERSION__
 #include <linux/init.h>
 #include "hisax.h"
@@ -15,7 +18,7 @@
 #include "isdnl1.h"
 
 extern const char *CardType[];
-static const char *avm_revision = "$Revision: 2.13.6.1 $";
+static const char *avm_revision = "$Revision: 1.1.2.1 $";
 
 #define	 AVM_A1_STAT_ISAC	0x01
 #define	 AVM_A1_STAT_HSCX	0x02
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/avm_a1p.c linux/drivers/isdn/hisax/avm_a1p.c
--- linux-2.2.21-pre1/drivers/isdn/hisax/avm_a1p.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/avm_a1p.c	Wed Jan  2 03:55:23 2002
@@ -1,14 +1,18 @@
-/* $Id: avm_a1p.c,v 2.7.6.1 2001/02/16 16:43:25 kai Exp $
+/* $Id: avm_a1p.c,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
  *
- * avm_a1p.c    low level stuff for the following AVM cards:
- *              A1 PCMCIA
- *		FRITZ!Card PCMCIA
- *		FRITZ!Card PCMCIA 2.0
+ * low level stuff for the following AVM cards:
+ * A1 PCMCIA
+ * FRITZ!Card PCMCIA
+ * FRITZ!Card PCMCIA 2.0
  *
- * Author       Carsten Paeth (calle@calle.in-berlin.de)
+ * Author       Carsten Paeth
+ * Copyright    by Carsten Paeth     <calle@calle.de>
+ *
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
- *  This file is (c) under GNU General Public License
  */
+
 #define __NO_VERSION__
 #include <linux/init.h>
 #include "hisax.h"
@@ -53,7 +57,7 @@
 #define byteout(addr,val) outb(val,addr)
 #define bytein(addr) inb(addr)
 
-static const char *avm_revision = "$Revision: 2.7.6.1 $";
+static const char *avm_revision = "$Revision: 1.1.2.1 $";
 
 static inline u_char
 ReadISAC(struct IsdnCardState *cs, u_char offset)
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/avm_pci.c linux/drivers/isdn/hisax/avm_pci.c
--- linux-2.2.21-pre1/drivers/isdn/hisax/avm_pci.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/avm_pci.c	Wed Jan  2 03:55:23 2002
@@ -1,13 +1,17 @@
-/* $Id: avm_pci.c,v 1.22.6.5 2001/06/09 15:14:16 kai Exp $
+/* $Id: avm_pci.c,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
  *
- * avm_pci.c    low level stuff for AVM Fritz!PCI and ISA PnP isdn cards
- *              Thanks to AVM, Berlin for informations
+ * low level stuff for AVM Fritz!PCI and ISA PnP isdn cards
  *
- * Author       Karsten Keil (keil@isdn4linux.de)
+ * Author       Karsten Keil
+ * Copyright    by Karsten Keil      <keil@isdn4linux.de>
  *
- * This file is (c) under GNU General Public License
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
+ *
+ * Thanks to AVM, Berlin for information
  *
  */
+
 #define __NO_VERSION__
 #include <linux/config.h>
 #include <linux/init.h>
@@ -19,7 +23,7 @@
 #include <linux/interrupt.h>
 
 extern const char *CardType[];
-static const char *avm_pci_rev = "$Revision: 1.22.6.5 $";
+static const char *avm_pci_rev = "$Revision: 1.1.2.1 $";
 
 #define  AVM_FRITZ_PCI		1
 #define  AVM_FRITZ_PNP		2
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/bkm_a4t.c linux/drivers/isdn/hisax/bkm_a4t.c
--- linux-2.2.21-pre1/drivers/isdn/hisax/bkm_a4t.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/bkm_a4t.c	Wed Jan  2 03:55:23 2002
@@ -1,12 +1,12 @@
-/* $Id: bkm_a4t.c,v 1.13.6.5 2001/07/18 16:02:15 kai Exp $
- * bkm_a4t.c    low level stuff for T-Berkom A4T
- *              derived from the original file sedlbauer.c
- *              derived from the original file niccy.c
- *              derived from the original file netjet.c
+/* $Id: bkm_a4t.c,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
  *
- * Author       Roland Klabunde (R.Klabunde@Berkom.de)
+ * low level stuff for T-Berkom A4T
  *
- * This file is (c) under GNU General Public License
+ * Author       Roland Klabunde
+ * Copyright    by Roland Klabunde   <R.Klabunde@Berkom.de>
+ * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
@@ -25,7 +25,7 @@
 
 extern const char *CardType[];
 
-const char *bkm_a4t_revision = "$Revision: 1.13.6.5 $";
+const char *bkm_a4t_revision = "$Revision: 1.1.2.1 $";
 
 
 static inline u_char
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/bkm_a8.c linux/drivers/isdn/hisax/bkm_a8.c
--- linux-2.2.21-pre1/drivers/isdn/hisax/bkm_a8.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/bkm_a8.c	Wed Jan  2 03:55:23 2002
@@ -1,14 +1,15 @@
-/* $Id: bkm_a8.c,v 1.14.6.6 2001/07/18 16:02:15 kai Exp $
- * bkm_a8.c     low level stuff for Scitel Quadro (4*S0, passive)
- *              derived from the original file sedlbauer.c
- *              derived from the original file niccy.c
- *              derived from the original file netjet.c
+/* $Id: bkm_a8.c,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
  *
- * Author       Roland Klabunde (R.Klabunde@Berkom.de)
+ * low level stuff for Scitel Quadro (4*S0, passive)
  *
- * This file is (c) under GNU General Public License
+ * Author       Roland Klabunde
+ * Copyright    by Roland Klabunde   <R.Klabunde@Berkom.de>
+ * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
+
 #define __NO_VERSION__
 
 #include <linux/config.h>
@@ -28,7 +29,7 @@
 
 extern const char *CardType[];
 
-const char sct_quadro_revision[] = "$Revision: 1.14.6.6 $";
+const char sct_quadro_revision[] = "$Revision: 1.1.2.1 $";
 
 static const char *sct_quadro_subtypes[] =
 {
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/bkm_ax.h linux/drivers/isdn/hisax/bkm_ax.h
--- linux-2.2.21-pre1/drivers/isdn/hisax/bkm_ax.h	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/bkm_ax.h	Wed Jan  2 03:55:23 2002
@@ -1,9 +1,12 @@
-/* $Id: bkm_ax.h,v 1.5.6.2 2001/02/16 16:43:25 kai Exp $
- * bkm_ax.h   low level decls for T-Berkom cards A4T and Scitel Quadro (4*S0, passive)
+/* $Id: bkm_ax.h,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
  *
- * Author     Roland Klabunde (R.Klabunde@Berkom.de)
+ * low level decls for T-Berkom cards A4T and Scitel Quadro (4*S0, passive)
  *
- * This file is (c) under GNU General Public License
+ * Author       Roland Klabunde
+ * Copyright    by Roland Klabunde   <R.Klabunde@Berkom.de>
+ * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/callc.c linux/drivers/isdn/hisax/callc.c
--- linux-2.2.21-pre1/drivers/isdn/hisax/callc.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/callc.c	Wed Jan  2 03:55:23 2002
@@ -1,17 +1,23 @@
-/* $Id: callc.c,v 2.51.6.4 2001/06/09 15:14:17 kai Exp $
+/* $Id: callc.c,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
  *
- * Author       Karsten Keil (keil@isdn4linux.de)
- *              based on the teles driver from Jan den Ouden
+ * Author       Karsten Keil
+ * Copyright    by Karsten Keil      <keil@isdn4linux.de>
+ * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
- *		This file is (c) under GNU General Public License
- *		For changes and modifications please read
- *		../../../Documentation/isdn/HiSax.cert
+ * For changes and modifications please read
+ * ../../../Documentation/isdn/HiSax.cert
+ *
+ * based on the teles driver from Jan den Ouden
  *
  * Thanks to    Jan den Ouden
  *              Fritz Elfert
  *
  */
+
 #define __NO_VERSION__
+#include <linux/module.h>
 #include <linux/init.h>
 #include "hisax.h"
 #include "../avmb1/capicmd.h"  /* this should be moved in a common place */
@@ -20,7 +26,7 @@
 #define MOD_USE_COUNT ( GET_USE_COUNT (&__this_module))
 #endif	/* MODULE */
 
-const char *lli_revision = "$Revision: 2.51.6.4 $";
+const char *lli_revision = "$Revision: 1.1.2.1 $";
 
 extern struct IsdnCard cards[];
 extern int nrcards;
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/cert.c linux/drivers/isdn/hisax/cert.c
--- linux-2.2.21-pre1/drivers/isdn/hisax/cert.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/cert.c	Wed Jan  2 03:55:23 2002
@@ -1,10 +1,13 @@
-/* $Id: cert.c,v 2.3.6.2 2001/07/27 09:08:27 kai Exp $
+/* $Id: cert.c,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
  *
- * Author       Karsten Keil (keil@isdn4linux.de)
+ * Author       Karsten Keil
+ * Copyright    by Karsten Keil      <keil@isdn4linux.de>
+ * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
- *		This file is (c) under GNU General Public License
- *		For changes and modifications please read
- *		../../../Documentation/isdn/HiSax.cert
+ * For changes and modifications please read
+ * ../../../Documentation/isdn/HiSax.cert
  *
  */
  
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/config.c linux/drivers/isdn/hisax/config.c
--- linux-2.2.21-pre1/drivers/isdn/hisax/config.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/config.c	Wed Jan  2 03:55:23 2002
@@ -1,11 +1,19 @@
-/* $Id: config.c,v 2.57.6.16 2001/07/13 09:01:00 kai Exp $
+/* $Id: config.c,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
  *
- * Author       Karsten Keil (keil@isdn4linux.de)
- *              based on the teles driver from Jan den Ouden
+ * Author       Karsten Keil
+ * Copyright    by Karsten Keil      <keil@isdn4linux.de>
+ *              by Kai Germaschewski <kai.germaschewski@gmx.de>
+ * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
- * This file is (c) under GNU General Public License
+ * For changes and modifications please read
+ * ../../../Documentation/isdn/HiSax.cert
+ *
+ * based on the teles driver from Jan den Ouden
  *
  */
+
 #include <linux/types.h>
 #include <linux/stddef.h>
 #include <linux/timer.h>
@@ -364,7 +372,9 @@
 static int mem[8]  = { 0, };
 static char *id  = HiSaxID;
 
+MODULE_DESCRIPTION("ISDN4Linux: Driver for passive ISDN cards");
 MODULE_AUTHOR("Karsten Keil");
+MODULE_LICENSE("GPL");
 MODULE_PARM(type, "1-8i");
 MODULE_PARM(protocol, "1-8i");
 MODULE_PARM(io, "1-8i");
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/diva.c linux/drivers/isdn/hisax/diva.c
--- linux-2.2.21-pre1/drivers/isdn/hisax/diva.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/diva.c	Wed Jan  2 03:55:23 2002
@@ -1,14 +1,17 @@
-/* $Id: diva.c,v 1.25.6.4 2001/02/16 16:43:25 kai Exp $
+/* $Id: diva.c,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
  *
- * diva.c     low level stuff for Eicon.Diehl Diva Family ISDN cards
+ * low level stuff for Eicon.Diehl Diva Family ISDN cards
  *
- * Author     Karsten Keil (keil@isdn4linux.de)
+ * Author       Karsten Keil
+ * Copyright    by Karsten Keil      <keil@isdn4linux.de>
+ * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
- *		This file is (c) under GNU General Public License
- *		For changes and modifications please read
- *		../../../Documentation/isdn/HiSax.cert
+ * For changes and modifications please read
+ * ../../../Documentation/isdn/HiSax.cert
  *
- * Thanks to Eicon Technology for documents and informations
+ * Thanks to Eicon Technology for documents and information
  *
  */
 
@@ -25,7 +28,7 @@
 
 extern const char *CardType[];
 
-const char *Diva_revision = "$Revision: 1.25.6.4 $";
+const char *Diva_revision = "$Revision: 1.1.2.1 $";
 
 #define byteout(addr,val) outb(val,addr)
 #define bytein(addr) inb(addr)
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/elsa.c linux/drivers/isdn/hisax/elsa.c
--- linux-2.2.21-pre1/drivers/isdn/hisax/elsa.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/elsa.c	Wed Jan  2 03:55:23 2002
@@ -1,14 +1,17 @@
-/* $Id: elsa.c,v 2.26.6.5 2001/07/18 16:25:12 kai Exp $
+/* $Id: elsa.c,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
  *
- * elsa.c     low level stuff for Elsa isdn cards
+ * low level stuff for Elsa isdn cards
  *
- * Author     Karsten Keil (keil@isdn4linux.de)
+ * Author       Karsten Keil
+ * Copyright    by Karsten Keil      <keil@isdn4linux.de>
+ * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
- *		This file is (c) under GNU General Public License
- *		For changes and modifications please read
- *		../../../Documentation/isdn/HiSax.cert
+ * For changes and modifications please read
+ * ../../../Documentation/isdn/HiSax.cert
  *
- * Thanks to    Elsa GmbH for documents and informations
+ * Thanks to    Elsa GmbH for documents and information
  *
  *              Klaus Lichtenwalder (Klaus.Lichtenwalder@WebForum.DE)
  *              for ELSA PCMCIA support
@@ -31,7 +34,7 @@
 
 extern const char *CardType[];
 
-const char *Elsa_revision = "$Revision: 2.26.6.5 $";
+const char *Elsa_revision = "$Revision: 1.1.2.1 $";
 const char *Elsa_Types[] =
 {"None", "PC", "PCC-8", "PCC-16", "PCF", "PCF-Pro",
  "PCMCIA", "QS 1000", "QS 3000", "Microlink PCI", "QS 3000 PCI", 
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/elsa_ser.c linux/drivers/isdn/hisax/elsa_ser.c
--- linux-2.2.21-pre1/drivers/isdn/hisax/elsa_ser.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/elsa_ser.c	Wed Jan  2 03:55:23 2002
@@ -1,10 +1,12 @@
-/* $Id: elsa_ser.c,v 2.10.6.2 2001/06/09 15:14:17 kai Exp $
+/* $Id: elsa_ser.c,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
  *
  * stuff for the serial modem on ELSA cards
  *
- * This file is (c) under GNU General Public License
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
+
 #include <linux/config.h>
 #include <linux/serial.h>
 #include <linux/serial_reg.h>
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/fsm.c linux/drivers/isdn/hisax/fsm.c
--- linux-2.2.21-pre1/drivers/isdn/hisax/fsm.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/fsm.c	Wed Jan  2 03:55:23 2002
@@ -1,15 +1,21 @@
-/* $Id: fsm.c,v 1.14.6.2 2001/05/26 15:19:57 kai Exp $
+/* $Id: fsm.c,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
  *
- * Author       Karsten Keil (keil@isdn4linux.de)
- *              based on the teles driver from Jan den Ouden
+ * Finite state machine
+ *
+ * Author       Karsten Keil
+ * Copyright    by Karsten Keil      <keil@isdn4linux.de>
+ *              by Kai Germaschewski <kai.germaschewski@gmx.de>
+ * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  * Thanks to    Jan den Ouden
  *              Fritz Elfert
  *
- * This file is (c) under GNU General Public License
- *
  */
+
 #define __NO_VERSION__
+#include <linux/module.h>
 #include <linux/init.h>
 #include "hisax.h"
 
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/gazel.c linux/drivers/isdn/hisax/gazel.c
--- linux-2.2.21-pre1/drivers/isdn/hisax/gazel.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/gazel.c	Wed Jan  2 03:55:23 2002
@@ -1,13 +1,16 @@
-/* $Id: gazel.c,v 2.11.6.6 2001/06/08 08:48:46 kai Exp $
+/* $Id: gazel.c,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
  *
- * gazel.c     low level stuff for Gazel isdn cards
+ * low level stuff for Gazel isdn cards
  *
  * Author       BeWan Systems
  *              based on source code from Karsten Keil
- *
- * This file is (c) under GNU General Public License
+ * Copyright    by BeWan Systems
+ * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
+
 #include <linux/config.h>
 #include <linux/init.h>
 #define __NO_VERSION__
@@ -20,7 +23,7 @@
 #include <linux/isdn_compat.h>
 
 extern const char *CardType[];
-const char *gazel_revision = "$Revision: 2.11.6.6 $";
+const char *gazel_revision = "$Revision: 1.1.2.1 $";
 
 #define R647      1
 #define R685      2
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/hfc_2bds0.c linux/drivers/isdn/hisax/hfc_2bds0.c
--- linux-2.2.21-pre1/drivers/isdn/hisax/hfc_2bds0.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/hfc_2bds0.c	Wed Jan  2 03:55:23 2002
@@ -1,12 +1,15 @@
-/* $Id: hfc_2bds0.c,v 1.15.6.2 2001/06/09 15:14:17 kai Exp $
+/* $Id: hfc_2bds0.c,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
  *
- *  specific routines for CCD's HFC 2BDS0
+ * specific routines for CCD's HFC 2BDS0
  *
- * Author       Karsten Keil (keil@isdn4linux.de)
- *
- * This file is (c) under GNU General Public License
+ * Author       Karsten Keil
+ * Copyright    by Karsten Keil      <keil@isdn4linux.de>
+ * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
+
 #define __NO_VERSION__
 #include <linux/init.h>
 #include "hisax.h"
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/hfc_2bds0.h linux/drivers/isdn/hisax/hfc_2bds0.h
--- linux-2.2.21-pre1/drivers/isdn/hisax/hfc_2bds0.h	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/hfc_2bds0.h	Wed Jan  2 03:55:23 2002
@@ -1,10 +1,12 @@
-/* $Id: hfc_2bds0.h,v 1.4.6.1 2001/02/16 16:43:27 kai Exp $
+/* $Id: hfc_2bds0.h,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
  *
- *  specific defines for CCD's HFC 2BDS0
+ * specific defines for CCD's HFC 2BDS0
  *
- * Author       Karsten Keil (keil@isdn4linux.de)
- *
- * This file is (c) under GNU General Public License
+ * Author       Karsten Keil
+ * Copyright    by Karsten Keil      <keil@isdn4linux.de>
+ * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/hfc_2bs0.c linux/drivers/isdn/hisax/hfc_2bs0.c
--- linux-2.2.21-pre1/drivers/isdn/hisax/hfc_2bs0.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/hfc_2bs0.c	Wed Jan  2 03:55:23 2002
@@ -1,10 +1,12 @@
-/* $Id: hfc_2bs0.c,v 1.17.6.2 2001/06/09 15:14:17 kai Exp $
+/* $Id: hfc_2bs0.c,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
  *
- *  specific routines for CCD's HFC 2BS0
+ * specific routines for CCD's HFC 2BS0
  *
- * Author       Karsten Keil (keil@isdn4linux.de)
- *
- * This file is (c) under GNU General Public License
+ * Author       Karsten Keil
+ * Copyright    by Karsten Keil      <keil@isdn4linux.de>
+ * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/hfc_2bs0.h linux/drivers/isdn/hisax/hfc_2bs0.h
--- linux-2.2.21-pre1/drivers/isdn/hisax/hfc_2bs0.h	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/hfc_2bs0.h	Wed Jan  2 03:55:23 2002
@@ -1,10 +1,12 @@
-/* $Id: hfc_2bs0.h,v 1.3.6.1 2001/02/16 16:43:27 kai Exp $
+/* $Id: hfc_2bs0.h,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
  *
- *  specific defines for CCD's HFC 2BS0
+ * specific defines for CCD's HFC 2BS0
  *
- * Author       Karsten Keil (keil@isdn4linux.de)
- *
- * This file is (c) under GNU General Public License
+ * Author       Karsten Keil
+ * Copyright    by Karsten Keil      <keil@isdn4linux.de>
+ * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/hfc_pci.c linux/drivers/isdn/hisax/hfc_pci.c
--- linux-2.2.21-pre1/drivers/isdn/hisax/hfc_pci.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/hfc_pci.c	Wed Jan  2 03:55:23 2002
@@ -1,27 +1,17 @@
-/* $Id: hfc_pci.c,v 1.34.6.7 2001/07/27 09:08:27 kai Exp $
-
- * hfc_pci.c     low level driver for CCD´s hfc-pci based cards
- *
- * Author     Werner Cornelius (werner@isdn4linux.de)
- *            based on existing driver for CCD hfc ISA cards
- *            type approval valid for HFC-S PCI A based card 
- *
- * Copyright 1999  by Werner Cornelius (werner@isdn-development.de)
- * Copyright 1999  by Karsten Keil (keil@isdn4linux.de)
+/* $Id: hfc_pci.c,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
+ * low level driver for CCD´s hfc-pci based cards
  *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
+ * Author       Werner Cornelius
+ *              based on existing driver for CCD hfc ISA cards
+ * Copyright    by Werner Cornelius  <werner@isdn4linux.de>
+ *              by Karsten Keil      <keil@isdn4linux.de>
+ * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ * For changes and modifications please read
+ * ../../../Documentation/isdn/HiSax.cert
  *
  */
 
@@ -37,7 +27,7 @@
 
 extern const char *CardType[];
 
-static const char *hfcpci_revision = "$Revision: 1.34.6.7 $";
+static const char *hfcpci_revision = "$Revision: 1.1.2.1 $";
 
 /* table entry in the PCI devices list */
 typedef struct {
@@ -113,7 +103,7 @@
 static void
 reset_hfcpci(struct IsdnCardState *cs)
 {
-	long flags;
+	unsigned long flags;
 
 	save_flags(flags);
 	cli();
@@ -481,7 +471,7 @@
 void
 main_rec_hfcpci(struct BCState *bcs)
 {
-	long flags;
+	unsigned long flags;
 	struct IsdnCardState *cs = bcs->cs;
 	int rcnt, real_fifo;
 	int receive, count = 5;
@@ -558,7 +548,7 @@
 static void
 hfcpci_fill_dfifo(struct IsdnCardState *cs)
 {
-	long flags;
+	unsigned long flags;
 	int fcnt;
 	int count, new_z1, maxlen;
 	dfifo_type *df;
@@ -873,7 +863,7 @@
 static void
 receive_emsg(struct IsdnCardState *cs)
 {
-	long flags;
+	unsigned long flags;
 	int rcnt;
 	int receive, count = 5;
 	bzfifo_type *bz;
@@ -983,7 +973,7 @@
 	u_char exval;
 	struct BCState *bcs;
 	int count = 15;
-	long flags;
+	unsigned long flags;
 	u_char val, stat;
 
 	if (!cs) {
@@ -1439,7 +1429,7 @@
 hfcpci_l2l1(struct PStack *st, int pr, void *arg)
 {
 	struct sk_buff *skb = arg;
-	long flags;
+	unsigned long flags;
 
 	switch (pr) {
 		case (PH_DATA | REQUEST):
@@ -1652,7 +1642,7 @@
 static int
 hfcpci_card_msg(struct IsdnCardState *cs, int mt, void *arg)
 {
-	long flags;
+	unsigned long flags;
 
 	if (cs->debug & L1_DEB_ISAC)
 		debugl1(cs, "HFCPCI: card_msg %x", mt);
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/hfc_pci.h linux/drivers/isdn/hisax/hfc_pci.h
--- linux-2.2.21-pre1/drivers/isdn/hisax/hfc_pci.h	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/hfc_pci.h	Wed Jan  2 03:55:23 2002
@@ -1,24 +1,12 @@
-/* $Id: hfc_pci.h,v 1.8.6.1 2001/04/08 19:32:26 kai Exp $
+/* $Id: hfc_pci.h,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
  *
- *  specific defines for CCD's HFC 2BDS0 PCI chips
+ * specific defines for CCD's HFC 2BDS0 PCI chips
  *
- * Author     Werner Cornelius (werner@isdn4linux.de)      
- *
- * Copyright 1999  by Werner Cornelius (werner@isdn4linux.de)
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ * Author       Werner Cornelius
+ * Copyright    by Werner Cornelius  <werner@isdn4linux.de>
+ * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/hfc_sx.c linux/drivers/isdn/hisax/hfc_sx.c
--- linux-2.2.21-pre1/drivers/isdn/hisax/hfc_sx.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/hfc_sx.c	Wed Jan  2 03:55:23 2002
@@ -1,25 +1,13 @@
-/* $Id: hfc_sx.c,v 1.9.6.2 2001/07/18 16:25:12 kai Exp $
-
- * hfc_sx.c     low level driver for CCD´s hfc-s+/sp based cards
- *
- * Author     Werner Cornelius (werner@isdn4linux.de)
- *            based on existing driver for CCD HFC PCI cards
- *
- * Copyright 1999  by Werner Cornelius (werner@isdn4linux.de)
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
+/* $Id: hfc_sx.c,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
  *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
+ * level driver for CCD´s hfc-s+/sp based cards
  *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ * Author       Werner Cornelius
+ *              based on existing driver for CCD HFC PCI cards
+ * Copyright    by Werner Cornelius  <werner@isdn4linux.de>
+ * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
@@ -32,7 +20,7 @@
 
 extern const char *CardType[];
 
-static const char *hfcsx_revision = "$Revision: 1.9.6.2 $";
+static const char *hfcsx_revision = "$Revision: 1.1.2.1 $";
 
 /***************************************/
 /* IRQ-table for CCDs demo board       */
@@ -382,7 +370,7 @@
 static void
 reset_hfcsx(struct IsdnCardState *cs)
 {
-	long flags;
+	unsigned long flags;
 
 	save_flags(flags);
 	cli();
@@ -539,7 +527,7 @@
 void
 main_rec_hfcsx(struct BCState *bcs)
 {
-	long flags;
+	unsigned long flags;
 	struct IsdnCardState *cs = bcs->cs;
 	int count = 5;
 	struct sk_buff *skb;
@@ -783,7 +771,7 @@
 	u_char exval;
 	struct BCState *bcs;
 	int count = 15;
-	long flags;
+	unsigned long flags;
 	u_char val, stat;
 
 	if (!cs) {
@@ -1228,7 +1216,7 @@
 hfcsx_l2l1(struct PStack *st, int pr, void *arg)
 {
 	struct sk_buff *skb = arg;
-	long flags;
+	unsigned long flags;
 
 	switch (pr) {
 		case (PH_DATA | REQUEST):
@@ -1441,7 +1429,7 @@
 static int
 hfcsx_card_msg(struct IsdnCardState *cs, int mt, void *arg)
 {
-	long flags;
+	unsigned long flags;
 
 	if (cs->debug & L1_DEB_ISAC)
 		debugl1(cs, "HFCSX: card_msg %x", mt);
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/hfc_sx.h linux/drivers/isdn/hisax/hfc_sx.h
--- linux-2.2.21-pre1/drivers/isdn/hisax/hfc_sx.h	Sun Mar 25 08:37:33 2001
+++ linux/drivers/isdn/hisax/hfc_sx.h	Wed Jan  2 03:55:23 2002
@@ -1,24 +1,13 @@
-/* $Id: hfc_sx.h,v 1.2 2000/06/26 08:59:13 keil Exp $
+/* $Id: hfc_sx.h,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
  *
- *  specific defines for CCD's HFC 2BDS0 S+,SP chips
+ * specific defines for CCD's HFC 2BDS0 S+,SP chips
  *
- * Author     Werner Cornelius (werner@isdn4linux.de)      
- *
- * Copyright 1999  by Werner Cornelius (werner@isdn4linux.de)
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ * Author       Werner Cornelius
+ *              based on existing driver for CCD HFC PCI cards
+ * Copyright    by Werner Cornelius  <werner@isdn4linux.de>
+ * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/hfcscard.c linux/drivers/isdn/hisax/hfcscard.c
--- linux-2.2.21-pre1/drivers/isdn/hisax/hfcscard.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/hfcscard.c	Wed Jan  2 03:55:23 2002
@@ -1,10 +1,12 @@
-/* $Id: hfcscard.c,v 1.8.6.1 2001/02/16 16:43:27 kai Exp $
+/* $Id: hfcscard.c,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
  *
- * hfcscard.c     low level stuff for hfcs based cards (Teles3c, ACER P10)
+ * low level stuff for hfcs based cards (Teles3c, ACER P10)
  *
- * Author     Karsten Keil (keil@isdn4linux.de)
- *
- * This file is (c) under GNU General Public License
+ * Author       Karsten Keil
+ * Copyright    by Karsten Keil      <keil@isdn4linux.de>
+ * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
@@ -16,7 +18,7 @@
 
 extern const char *CardType[];
 
-static const char *hfcs_revision = "$Revision: 1.8.6.1 $";
+static const char *hfcs_revision = "$Revision: 1.1.2.1 $";
 
 static void
 hfcs_interrupt(int intno, void *dev_id, struct pt_regs *regs)
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/hisax.h linux/drivers/isdn/hisax/hisax.h
--- linux-2.2.21-pre1/drivers/isdn/hisax/hisax.h	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/hisax.h	Wed Jan  2 03:55:23 2002
@@ -1,13 +1,12 @@
-/* $Id: hisax.h,v 2.52.6.7 2001/07/18 16:02:15 kai Exp $
+/* $Id: hisax.h,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
  *
- *   Basic declarations, defines and prototypes
+ * Basic declarations, defines and prototypes
  *
- * This file is (c) under GNU General Public License
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 #include <linux/config.h>
-#include <linux/module.h>
-#include <linux/version.h>
 #include <linux/errno.h>
 #include <linux/fs.h>
 #include <linux/major.h>
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/hscx.c linux/drivers/isdn/hisax/hscx.c
--- linux-2.2.21-pre1/drivers/isdn/hisax/hscx.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/hscx.c	Wed Jan  2 03:55:23 2002
@@ -1,10 +1,12 @@
-/* $Id: hscx.c,v 1.21.6.2 2001/06/09 15:14:17 kai Exp $
+/* $Id: hscx.c,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
  *
- * hscx.c   HSCX specific routines
+ * HSCX specific routines
  *
- * Author       Karsten Keil (keil@isdn4linux.de)
- *
- * This file is (c) under GNU General Public License
+ * Author       Karsten Keil
+ * Copyright    by Karsten Keil      <keil@isdn4linux.de>
+ * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/hscx.h linux/drivers/isdn/hisax/hscx.h
--- linux-2.2.21-pre1/drivers/isdn/hisax/hscx.h	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/hscx.h	Wed Jan  2 03:55:23 2002
@@ -1,10 +1,12 @@
-/* $Id: hscx.h,v 1.6.6.1 2001/02/16 16:43:27 kai Exp $
+/* $Id: hscx.h,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
  *
- * hscx.h   HSCX specific defines
+ * HSCX specific defines
  *
- * Author       Karsten Keil (keil@isdn4linux.de)
- *
- * This file is (c) under GNU General Public License
+ * Author       Karsten Keil
+ * Copyright    by Karsten Keil      <keil@isdn4linux.de>
+ * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/hscx_irq.c linux/drivers/isdn/hisax/hscx_irq.c
--- linux-2.2.21-pre1/drivers/isdn/hisax/hscx_irq.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/hscx_irq.c	Wed Jan  2 03:55:23 2002
@@ -1,12 +1,14 @@
-/* $Id: hscx_irq.c,v 1.16.6.1 2001/02/16 16:43:27 kai Exp $
+/* $Id: hscx_irq.c,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
  *
- * hscx_irq.c     low level b-channel stuff for Siemens HSCX
+ * low level b-channel stuff for Siemens HSCX
  *
- * Author     Karsten Keil (keil@isdn4linux.de)
+ * Author       Karsten Keil
+ * Copyright    by Karsten Keil      <keil@isdn4linux.de>
+ * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  * This is an include file for fast inline IRQ stuff
- *
- * This file is (c) under GNU General Public License
  *
  */
 
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/icc.c linux/drivers/isdn/hisax/icc.c
--- linux-2.2.21-pre1/drivers/isdn/hisax/icc.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/icc.c	Wed Jan  2 03:55:23 2002
@@ -1,18 +1,18 @@
-// $Id: icc.c,v 1.5.6.3 2001/06/09 15:14:17 kai Exp $
-//-----------------------------------------------------------------------------
-//
-// ICC specific routines
-//
-// Author       Matt Henderson & Guy Ellis - Traverse Tecnologies Pty Ltd
-//              www.traverse.com.au
-//
-// 1999.6.25 Initial implementation of routines for Siemens ISDN
-// Communication Controller PEB 2070 based on the ISAC routines
-// written by Karsten Keil.
-//
-// This file is (c) under GNU General Public License
-//
-//-----------------------------------------------------------------------------
+/* $Id: icc.c,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
+ *
+ * ICC specific routines
+ *
+ * Author       Matt Henderson & Guy Ellis
+ * Copyright    by Traverse Technologies Pty Ltd, www.travers.com.au
+ * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
+ *
+ * 1999.6.25 Initial implementation of routines for Siemens ISDN
+ * Communication Controller PEB 2070 based on the ISAC routines
+ * written by Karsten Keil.
+ *
+ */
 
 #define __NO_VERSION__
 #include <linux/init.h>
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/icc.h linux/drivers/isdn/hisax/icc.h
--- linux-2.2.21-pre1/drivers/isdn/hisax/icc.h	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/icc.h	Wed Jan  2 03:55:23 2002
@@ -1,19 +1,17 @@
-// $Id: icc.h,v 1.2.6.2 2001/03/13 16:17:08 kai Exp $
-//-----------------------------------------------------------------------------
-//
-// ICC specific routines
-//
-// Author       Matt Henderson & Guy Ellis - Traverse Tecnologies Pty Ltd
-//              www.traverse.com.au
-//
-// 1999.7.14 Initial implementation of routines for Siemens ISDN 
-// Communication Controller PEB 2070 based on the ISAC routines 
-// written by Karsten Keil.
-//
-// This file is (c) under GNU General Public License
-//
-//-----------------------------------------------------------------------------
-
+/* $Id: icc.h,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
+ *
+ * ICC specific routines
+ *
+ * Author       Matt Henderson & Guy Ellis
+ * Copyright    by Traverse Technologies Pty Ltd, www.travers.com.au
+ * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
+ *
+ * 1999.7.14 Initial implementation of routines for Siemens ISDN 
+ * Communication Controller PEB 2070 based on the ISAC routines 
+ * written by Karsten Keil.
+ */
 
 /* All Registers original Siemens Spec  */
 
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/ipac.h linux/drivers/isdn/hisax/ipac.h
--- linux-2.2.21-pre1/drivers/isdn/hisax/ipac.h	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/ipac.h	Wed Jan  2 03:55:23 2002
@@ -1,13 +1,14 @@
-/* $Id: ipac.h,v 1.5.6.1 2001/02/16 16:43:27 kai Exp $
+/* $Id: ipac.h,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
  *
- * ipac.h   IPAC specific defines
+ * IPAC specific defines
  *
- * Author       Karsten Keil (keil@isdn4linux.de)
- *
- * This file is (c) under GNU General Public License
+ * Author       Karsten Keil
+ * Copyright    by Karsten Keil      <keil@isdn4linux.de>
+ * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
-
 
 /* All Registers original Siemens Spec  */
 
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/isac.c linux/drivers/isdn/hisax/isac.c
--- linux-2.2.21-pre1/drivers/isdn/hisax/isac.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/isac.c	Wed Jan  2 03:55:23 2002
@@ -1,12 +1,16 @@
-/* $Id: isac.c,v 1.28.6.2 2001/06/09 15:14:17 kai Exp $
+/* $Id: isac.c,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
  *
- * isac.c   ISAC specific routines
+ * ISAC specific routines
  *
- * Author       Karsten Keil (keil@isdn4linux.de)
+ * Author       Karsten Keil
+ * Copyright    by Karsten Keil      <keil@isdn4linux.de>
+ * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
+ *
+ * For changes and modifications please read
+ * ../../../Documentation/isdn/HiSax.cert
  *
- *		This file is (c) under GNU General Public License
- *		For changes and modifications please read
- *		../../../Documentation/isdn/HiSax.cert
  */
 
 #define __NO_VERSION__
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/isac.h linux/drivers/isdn/hisax/isac.h
--- linux-2.2.21-pre1/drivers/isdn/hisax/isac.h	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/isac.h	Wed Jan  2 03:55:23 2002
@@ -1,13 +1,14 @@
-/* $Id: isac.h,v 1.7.6.1 2001/02/16 16:43:27 kai Exp $
+/* $Id: isac.h,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
  *
- * isac.h   ISAC specific defines
+ * ISAC specific defines
  *
- * Author       Karsten Keil (keil@isdn4linux.de)
- *
- * This file is (c) under GNU General Public License
+ * Author       Karsten Keil
+ * Copyright    by Karsten Keil      <keil@isdn4linux.de>
+ * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
-
 
 /* All Registers original Siemens Spec  */
 
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/isar.c linux/drivers/isdn/hisax/isar.c
--- linux-2.2.21-pre1/drivers/isdn/hisax/isar.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/isar.c	Wed Jan  2 03:55:23 2002
@@ -1,4 +1,4 @@
-/* $Id: isar.c,v 1.17.6.3 2001/06/09 15:14:17 kai Exp $
+/* $Id: isar.c,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
  *
  * isar.c   ISAR (Siemens PSB 7110) specific routines
  *
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/isar.h linux/drivers/isdn/hisax/isar.h
--- linux-2.2.21-pre1/drivers/isdn/hisax/isar.h	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/isar.h	Wed Jan  2 03:55:23 2002
@@ -1,10 +1,12 @@
-/* $Id: isar.h,v 1.9.6.1 2001/02/16 16:43:27 kai Exp $
+/* $Id: isar.h,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
  *
- * isar.h   ISAR (Siemens PSB 7110) specific defines
+ * ISAR (Siemens PSB 7110) specific defines
  *
- * Author Karsten Keil (keil@isdn4linux.de)
- *
- * This file is (c) under GNU General Public License
+ * Author       Karsten Keil
+ * Copyright    by Karsten Keil      <keil@isdn4linux.de>
+ * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
  
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/isdnl1.c linux/drivers/isdn/hisax/isdnl1.c
--- linux-2.2.21-pre1/drivers/isdn/hisax/isdnl1.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/isdnl1.c	Wed Jan  2 03:55:23 2002
@@ -1,13 +1,16 @@
-/* $Id: isdnl1.c,v 2.41.6.3 2001/05/26 15:19:57 kai Exp $
+/* $Id: isdnl1.c,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
  *
- * isdnl1.c     common low level stuff for Siemens Chipsetbased isdn cards
- *              based on the teles driver from Jan den Ouden
+ * common low level stuff for Siemens Chipsetbased isdn cards
  *
- * Author       Karsten Keil (keil@isdn4linux.de)
+ * Author       Karsten Keil
+ *              based on the teles driver from Jan den Ouden
+ * Copyright    by Karsten Keil      <keil@isdn4linux.de>
+ * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
- *		This file is (c) under GNU General Public License
- *		For changes and modifications please read
- *		../../../Documentation/isdn/HiSax.cert
+ * For changes and modifications please read
+ * ../../../Documentation/isdn/HiSax.cert
  *
  * Thanks to    Jan den Ouden
  *              Fritz Elfert
@@ -15,7 +18,7 @@
  *
  */
 
-const char *l1_revision = "$Revision: 2.41.6.3 $";
+const char *l1_revision = "$Revision: 1.1.2.1 $";
 
 #define __NO_VERSION__
 #include <linux/init.h>
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/isdnl1.h linux/drivers/isdn/hisax/isdnl1.h
--- linux-2.2.21-pre1/drivers/isdn/hisax/isdnl1.h	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/isdnl1.h	Wed Jan  2 03:55:23 2002
@@ -1,8 +1,9 @@
-/* $Id: isdnl1.h,v 2.9.6.1 2001/02/16 16:43:27 kai Exp $
+/* $Id: isdnl1.h,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
  *
  * Layer 1 defines
  *
- * This file is (c) under GNU General Public License
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/isdnl2.c linux/drivers/isdn/hisax/isdnl2.c
--- linux-2.2.21-pre1/drivers/isdn/hisax/isdnl2.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/isdnl2.c	Wed Jan  2 03:55:23 2002
@@ -1,22 +1,26 @@
-/* $Id: isdnl2.c,v 2.25.6.3 2001/06/09 15:14:17 kai Exp $
+/* $Id: isdnl2.c,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
  *
- * Author       Karsten Keil (keil@isdn4linux.de)
+ * Author       Karsten Keil
  *              based on the teles driver from Jan den Ouden
+ * Copyright    by Karsten Keil      <keil@isdn4linux.de>
+ * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
- *		This file is (c) under GNU General Public License
- *		For changes and modifications please read
- *		../../../Documentation/isdn/HiSax.cert
+ * For changes and modifications please read
+ * ../../../Documentation/isdn/HiSax.cert
  *
  * Thanks to    Jan den Ouden
  *              Fritz Elfert
  *
  */
+
 #define __NO_VERSION__
 #include <linux/init.h>
 #include "hisax.h"
 #include "isdnl2.h"
 
-const char *l2_revision = "$Revision: 2.25.6.3 $";
+const char *l2_revision = "$Revision: 1.1.2.1 $";
 
 static void l2m_debug(struct FsmInst *fi, char *fmt, ...);
 
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/isdnl2.h linux/drivers/isdn/hisax/isdnl2.h
--- linux-2.2.21-pre1/drivers/isdn/hisax/isdnl2.h	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/isdnl2.h	Wed Jan  2 03:55:23 2002
@@ -1,8 +1,9 @@
-/* $Id: isdnl2.h,v 1.3.6.1 2001/02/16 16:43:27 kai Exp $
+/* $Id: isdnl2.h,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
  *
  * Layer 2 defines
  *
- * This file is (c) under GNU General Public License
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/isdnl3.c linux/drivers/isdn/hisax/isdnl3.c
--- linux-2.2.21-pre1/drivers/isdn/hisax/isdnl3.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/isdnl3.c	Wed Jan  2 03:55:23 2002
@@ -1,11 +1,14 @@
-/* $Id: isdnl3.c,v 2.17.6.4 2001/06/09 15:14:17 kai Exp $
+/* $Id: isdnl3.c,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
  *
- * Author       Karsten Keil (keil@isdn4linux.de)
+ * Author       Karsten Keil
  *              based on the teles driver from Jan den Ouden
+ * Copyright    by Karsten Keil      <keil@isdn4linux.de>
+ * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
- *		This file is (c) under GNU General Public License
- *		For changes and modifications please read
- *		../../../Documentation/isdn/HiSax.cert
+ * For changes and modifications please read
+ * ../../../Documentation/isdn/HiSax.cert
  *
  * Thanks to    Jan den Ouden
  *              Fritz Elfert
@@ -18,7 +21,7 @@
 #include "isdnl3.h"
 #include <linux/config.h>
 
-const char *l3_revision = "$Revision: 2.17.6.4 $";
+const char *l3_revision = "$Revision: 1.1.2.1 $";
 
 static struct Fsm l3fsm;
 
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/isdnl3.h linux/drivers/isdn/hisax/isdnl3.h
--- linux-2.2.21-pre1/drivers/isdn/hisax/isdnl3.h	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/isdnl3.h	Wed Jan  2 03:55:23 2002
@@ -1,6 +1,7 @@
-/* $Id: isdnl3.h,v 2.6.6.1 2001/02/16 16:43:27 kai Exp $
+/* $Id: isdnl3.h,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
  *
- * This file is (c) under GNU General Public License
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/isurf.c linux/drivers/isdn/hisax/isurf.c
--- linux-2.2.21-pre1/drivers/isdn/hisax/isurf.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/isurf.c	Wed Jan  2 03:55:23 2002
@@ -1,10 +1,12 @@
-/* $Id: isurf.c,v 1.10.6.1 2001/02/16 16:43:27 kai Exp $
+/* $Id: isurf.c,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
  *
- * isurf.c  low level stuff for Siemens I-Surf/I-Talk cards
+ * low level stuff for Siemens I-Surf/I-Talk cards
  *
- * Author     Karsten Keil (keil@isdn4linux.de)
- *
- * This file is (c) under GNU General Public License
+ * Author       Karsten Keil
+ * Copyright    by Karsten Keil      <keil@isdn4linux.de>
+ * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
@@ -17,7 +19,7 @@
 
 extern const char *CardType[];
 
-static const char *ISurf_revision = "$Revision: 1.10.6.1 $";
+static const char *ISurf_revision = "$Revision: 1.1.2.1 $";
 
 #define byteout(addr,val) outb(val,addr)
 #define bytein(addr) inb(addr)
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/ix1_micro.c linux/drivers/isdn/hisax/ix1_micro.c
--- linux-2.2.21-pre1/drivers/isdn/hisax/ix1_micro.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/ix1_micro.c	Wed Jan  2 03:55:23 2002
@@ -1,47 +1,22 @@
-/* $Id: ix1_micro.c,v 2.10.6.1 2001/02/16 16:43:27 kai Exp $
+/* $Id: ix1_micro.c,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
  *
- * ix1_micro.c  low level stuff for ITK ix1-micro Rev.2 isdn cards
- *              derived from the original file teles3.c from Karsten Keil
+ * low level stuff for ITK ix1-micro Rev.2 isdn cards
+ * derived from the original file teles3.c from Karsten Keil
  *
- * Copyright (C) 1997 Klaus-Peter Nischke (ITK AG) (for the modifications to
- *                                                  the original file teles.c)
- *
- * Thanks to    Jan den Ouden
- *              Fritz Elfert
- *              Beat Doebeli
+ * Author       Klaus-Peter Nischke
+ * Copyright    by Klaus-Peter Nischke, ITK AG
+ *                                   <klaus@nischke.do.eunet.de>
+ *              by Karsten Keil      <keil@isdn4linux.de>
+ * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
+ * Klaus-Peter Nischke
+ * Deusener Str. 287
+ * 44369 Dortmund
+ * Germany
  */
 
-/*
-   For the modification done by the author the following terms and conditions
-   apply (GNU General Public License)
-
-
-   This program is free software; you can redistribute it and/or modify
-   it under the terms of the GNU General Public License as published by
-   the Free Software Foundation; either version 2 of the License, or
-   (at your option) any later version.
-
-   This program is distributed in the hope that it will be useful,
-   but WITHOUT ANY WARRANTY; without even the implied warranty of
-   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-   GNU General Public License for more details.
-
-   You should have received a copy of the GNU General Public License
-   along with this program; if not, write to the Free Software
-   Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
-
-
-   You may contact Klaus-Peter Nischke by email: klaus@nischke.do.eunet.de
-   or by conventional mail:
-
-   Klaus-Peter Nischke
-   Deusener Str. 287
-   44369 Dortmund
-   Germany
- */
-
-
 #define __NO_VERSION__
 #include <linux/init.h>
 #include "hisax.h"
@@ -50,7 +25,7 @@
 #include "isdnl1.h"
 
 extern const char *CardType[];
-const char *ix1_revision = "$Revision: 2.10.6.1 $";
+const char *ix1_revision = "$Revision: 1.1.2.1 $";
 
 #define byteout(addr,val) outb(val,addr)
 #define bytein(addr) inb(addr)
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/jade.c linux/drivers/isdn/hisax/jade.c
--- linux-2.2.21-pre1/drivers/isdn/hisax/jade.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/jade.c	Wed Jan  2 03:55:23 2002
@@ -1,10 +1,12 @@
-/* $Id: jade.c,v 1.6.6.2 2001/06/09 15:14:18 kai Exp $
+/* $Id: jade.c,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
  *
- * jade.c   JADE stuff (derived from original hscx.c)
+ * JADE stuff (derived from original hscx.c)
  *
- * Author   Roland Klabunde (R.Klabunde@Berkom.de)
- *
- * This file is (c) under GNU General Public License
+ * Author       Roland Klabunde
+ * Copyright    by Roland Klabunde   <R.Klabunde@Berkom.de>
+ * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/jade.h linux/drivers/isdn/hisax/jade.h
--- linux-2.2.21-pre1/drivers/isdn/hisax/jade.h	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/jade.h	Wed Jan  2 03:55:23 2002
@@ -1,9 +1,12 @@
-/* $Id: jade.h,v 1.3.6.1 2001/02/16 16:43:27 kai Exp $
- * jade.h   JADE specific defines
+/* $Id: jade.h,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
  *
- * Author   Roland Klabunde (R.Klabunde@Berkom.de)
+ * JADE specific defines
  *
- * This file is (c) under GNU General Public License
+ * Author       Roland Klabunde
+ * Copyright    by Roland Klabunde   <R.Klabunde@Berkom.de>
+ * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/jade_irq.c linux/drivers/isdn/hisax/jade_irq.c
--- linux-2.2.21-pre1/drivers/isdn/hisax/jade_irq.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/jade_irq.c	Wed Jan  2 03:55:23 2002
@@ -1,10 +1,12 @@
-/* $Id: jade_irq.c,v 1.5.6.1 2001/02/16 16:43:27 kai Exp $
+/* $Id: jade_irq.c,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
  *
- * jade_irq.c   Low level JADE IRQ stuff (derived from original hscx_irq.c)
+ * Low level JADE IRQ stuff (derived from original hscx_irq.c)
  *
- * Author   Roland Klabunde (R.Klabunde@Berkom.de)
- *
- * This file is (c) under GNU General Public License
+ * Author       Roland Klabunde
+ * Copyright    by Roland Klabunde   <R.Klabunde@Berkom.de>
+ * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/l3_1tr6.c linux/drivers/isdn/hisax/l3_1tr6.c
--- linux-2.2.21-pre1/drivers/isdn/hisax/l3_1tr6.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/l3_1tr6.c	Wed Jan  2 03:55:23 2002
@@ -1,12 +1,15 @@
-/* $Id: l3_1tr6.c,v 2.13.6.1 2001/02/16 16:43:27 kai Exp $
+/* $Id: l3_1tr6.c,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
  *
- *  German 1TR6 D-channel protocol
+ * German 1TR6 D-channel protocol
  *
- * Author       Karsten Keil (keil@isdn4linux.de)
+ * Author       Karsten Keil
+ * Copyright    by Karsten Keil      <keil@isdn4linux.de>
+ * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
- *		This file is (c) under GNU General Public License
- *		For changes and modifications please read
- *		../../../Documentation/isdn/HiSax.cert
+ * For changes and modifications please read
+ * ../../../Documentation/isdn/HiSax.cert
  *
  */
 
@@ -17,7 +20,7 @@
 #include <linux/ctype.h>
 
 extern char *HiSax_getrev(const char *revision);
-const char *l3_1tr6_revision = "$Revision: 2.13.6.1 $";
+const char *l3_1tr6_revision = "$Revision: 1.1.2.1 $";
 
 #define MsgHead(ptr, cref, mty, dis) \
 	*ptr++ = dis; \
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/l3_1tr6.h linux/drivers/isdn/hisax/l3_1tr6.h
--- linux-2.2.21-pre1/drivers/isdn/hisax/l3_1tr6.h	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/l3_1tr6.h	Wed Jan  2 03:55:23 2002
@@ -1,10 +1,12 @@
-/* $Id: l3_1tr6.h,v 2.2.6.1 2001/02/16 16:43:27 kai Exp $
+/* $Id: l3_1tr6.h,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
  *
- *  German 1TR6 D-channel protocol defines
+ * German 1TR6 D-channel protocol defines
  *
- * This file is (c) under GNU General Public License
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
+
 #ifndef l3_1tr6
 #define l3_1tr6
 
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/l3dss1.c linux/drivers/isdn/hisax/l3dss1.c
--- linux-2.2.21-pre1/drivers/isdn/hisax/l3dss1.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/l3dss1.c	Wed Jan  2 03:55:23 2002
@@ -1,13 +1,18 @@
-/* $Id: l3dss1.c,v 2.30.6.1 2001/02/16 16:43:27 kai Exp $
+/* $Id: l3dss1.c,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
  *
  * EURO/DSS1 D-channel protocol
  *
- * Author       Karsten Keil (keil@isdn4linux.de)
+ * German 1TR6 D-channel protocol
+ *
+ * Author       Karsten Keil
  *              based on the teles driver from Jan den Ouden
+ * Copyright    by Karsten Keil      <keil@isdn4linux.de>
+ * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
- *		This file is (c) under GNU General Public License
- *		For changes and modifications please read
- *		../../../Documentation/isdn/HiSax.cert
+ * For changes and modifications please read
+ * ../../../Documentation/isdn/HiSax.cert
  *
  * Thanks to    Jan den Ouden
  *              Fritz Elfert
@@ -22,7 +27,7 @@
 #include <linux/config.h>
 
 extern char *HiSax_getrev(const char *revision);
-const char *dss1_revision = "$Revision: 2.30.6.1 $";
+const char *dss1_revision = "$Revision: 1.1.2.1 $";
 
 #define EXT_BEARER_CAPS 1
 
@@ -44,7 +49,8 @@
 static unsigned char new_invoke_id(struct PStack *p)
 {
 	unsigned char retval;
-	int flags,i;
+	unsigned long flags;
+	int i;
   
 	i = 32; /* maximum search depth */
 
@@ -72,7 +78,7 @@
 /* free a used invoke id */
 /*************************/
 static void free_invoke_id(struct PStack *p, unsigned char id)
-{ int flags;
+{ unsigned long flags;
 
   if (!id) return; /* 0 = invalid value */
 
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/l3dss1.h linux/drivers/isdn/hisax/l3dss1.h
--- linux-2.2.21-pre1/drivers/isdn/hisax/l3dss1.h	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/l3dss1.h	Wed Jan  2 03:55:23 2002
@@ -1,8 +1,9 @@
-/* $Id: l3dss1.h,v 1.10.6.1 2001/02/16 16:43:28 kai Exp $
+/* $Id: l3dss1.h,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
  *
- *  DSS1 (Euro) D-channel protocol defines
+ * DSS1 (Euro) D-channel protocol defines
  *
- * This file is (c) under GNU General Public License
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/l3ni1.c linux/drivers/isdn/hisax/l3ni1.c
--- linux-2.2.21-pre1/drivers/isdn/hisax/l3ni1.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/l3ni1.c	Wed Jan  2 03:55:23 2002
@@ -1,24 +1,23 @@
-// $Id: l3ni1.c,v 2.5.6.2 2001/02/16 16:43:28 kai Exp $
-//
-//-----------------------------------------------------------------------------
-//
-// NI1 D-channel protocol
-//
-// Authors:
-// Matt Henderson & Guy Ellis - Traverse Tecnologies Pty Ltd
-// www.traverse.com.au
-//
-// 2000.6.6 Initial implementation of routines for US NI1 
-// Layer 3 protocol based on the EURO/DSS1 D-channel protocol 
-// driver written by Karsten Keil et al.  
-// NI-1 Hall of Fame - Thanks to.... 
-// Ragnar Paulson - for some handy code fragments
-// Will Scales - beta tester extraordinaire
-// Brett Whittacre - beta tester and remote devel system in Vegas
-//
-// This file is (c) under GNU General Public License
-//
-//-----------------------------------------------------------------------------
+/* $Id: l3ni1.c,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
+ *
+ * NI1 D-channel protocol
+ *
+ * Author       Matt Henderson & Guy Ellis
+ * Copyright    by Traverse Technologies Pty Ltd, www.travers.com.au
+ * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
+ *
+ * 2000.6.6 Initial implementation of routines for US NI1 
+ * Layer 3 protocol based on the EURO/DSS1 D-channel protocol 
+ * driver written by Karsten Keil et al.  
+ * NI-1 Hall of Fame - Thanks to.... 
+ * Ragnar Paulson - for some handy code fragments
+ * Will Scales - beta tester extraordinaire
+ * Brett Whittacre - beta tester and remote devel system in Vegas
+ *
+ */
+
 #define __NO_VERSION__
 #include "hisax.h"
 #include "isdnl3.h"
@@ -26,7 +25,7 @@
 #include <linux/ctype.h>
 
 extern char *HiSax_getrev(const char *revision);
-const char *ni1_revision = "$Revision: 2.5.6.2 $";
+const char *ni1_revision = "$Revision: 1.1.2.1 $";
 
 #define EXT_BEARER_CAPS 1
 
@@ -48,7 +47,8 @@
 static unsigned char new_invoke_id(struct PStack *p)
 {
 	unsigned char retval;
-	int flags,i;
+	unsigned long flags;
+	int i;
   
 	i = 32; /* maximum search depth */
 
@@ -76,7 +76,7 @@
 /* free a used invoke id */
 /*************************/
 static void free_invoke_id(struct PStack *p, unsigned char id)
-{ int flags;
+{ unsigned long flags;
 
   if (!id) return; /* 0 = invalid value */
 
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/l3ni1.h linux/drivers/isdn/hisax/l3ni1.h
--- linux-2.2.21-pre1/drivers/isdn/hisax/l3ni1.h	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/l3ni1.h	Wed Jan  2 03:55:23 2002
@@ -1,20 +1,19 @@
-// $Id: l3ni1.h,v 2.3.6.1 2001/02/16 16:43:28 kai Exp $
-//-----------------------------------------------------------------------------
-//
-// NI1 D-channel protocol
-//
-// Author       Matt Henderson & Guy Ellis - Traverse Tecnologies Pty Ltd
-//              www.traverse.com.au
-//
-// 2000.6.6 Initial implementation of routines for US NI1 
-// Layer 3 protocol based on the EURO/DSS1 D-channel protocol 
-// driver written by Karsten Keil et al.  Thanks also for the 
-// code provided by Ragnar Paulson.
-//
-//
-// This file is (c) under GNU General Public License
-//
-//-----------------------------------------------------------------------------
+/* $Id: l3ni1.h,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
+ *
+ * NI1 D-channel protocol
+ *
+ * Author       Matt Henderson & Guy Ellis
+ * Copyright    by Traverse Technologies Pty Ltd, www.travers.com.au
+ * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
+ *
+ * 2000.6.6 Initial implementation of routines for US NI1 
+ * Layer 3 protocol based on the EURO/DSS1 D-channel protocol 
+ * driver written by Karsten Keil et al.  Thanks also for the 
+ * code provided by Ragnar Paulson.
+ *
+ */
 
 #ifndef l3ni1_process
 
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/lmgr.c linux/drivers/isdn/hisax/lmgr.c
--- linux-2.2.21-pre1/drivers/isdn/hisax/lmgr.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/lmgr.c	Wed Jan  2 03:55:23 2002
@@ -1,10 +1,12 @@
-/* $Id: lmgr.c,v 1.7.6.1 2001/02/16 16:43:28 kai Exp $
+/* $Id: lmgr.c,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
  *
- * Author       Karsten Keil (keil@isdn4linux.de)
+ * Layermanagement module
  *
- *  Layermanagement module
- *
- * This file is (c) under GNU General Public License
+ * Author       Karsten Keil
+ * Copyright    by Karsten Keil      <keil@isdn4linux.de>
+ * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/mic.c linux/drivers/isdn/hisax/mic.c
--- linux-2.2.21-pre1/drivers/isdn/hisax/mic.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/mic.c	Wed Jan  2 03:55:23 2002
@@ -1,12 +1,12 @@
-/* $Id: mic.c,v 1.10.6.1 2001/02/16 16:43:28 kai Exp $
+/* $Id: mic.c,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
  *
- * mic.c  low level stuff for mic cards
+ * low level stuff for mic cards
  *
- * Copyright (C) 1997 
- *
- * Author  Stephan von Krawczynski <skraw@ithnet.com>
- *
- * This file is (c) under GNU General Public License
+ * Author       Stephan von Krawczynski
+ * Copyright    by Stephan von Krawczynski <skraw@ithnet.com>
+ * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
@@ -19,7 +19,7 @@
 
 extern const char *CardType[];
 
-const char *mic_revision = "$Revision: 1.10.6.1 $";
+const char *mic_revision = "$Revision: 1.1.2.1 $";
 
 #define byteout(addr,val) outb(val,addr)
 #define bytein(addr) inb(addr)
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/netjet.c linux/drivers/isdn/hisax/netjet.c
--- linux-2.2.21-pre1/drivers/isdn/hisax/netjet.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/netjet.c	Wed Jan  2 03:55:23 2002
@@ -1,12 +1,14 @@
-/* $Id: netjet.c,v 1.24.6.5 2001/06/09 15:14:18 kai Exp $
+/* $Id: netjet.c,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
  *
- * netjet.c     low level stuff for Traverse Technologie NETJet ISDN cards
+ * low level stuff for Traverse Technologie NETJet ISDN cards
  *
- * Author     Karsten Keil (keil@isdn4linux.de)
+ * Author       Karsten Keil
+ * Copyright    by Karsten Keil      <keil@isdn4linux.de>
+ * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
- * Thanks to Traverse Technologie Australia for documents and informations
- *
- * This file is (c) under GNU General Public License
+ * Thanks to Traverse Technologie Australia for documents and information
  *
  */
 
@@ -22,7 +24,7 @@
 #include <asm/io.h>
 #include "netjet.h"
 
-const char *NETjet_revision = "$Revision: 1.24.6.5 $";
+const char *NETjet_revision = "$Revision: 1.1.2.1 $";
 
 /* Interface functions */
 
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/netjet.h linux/drivers/isdn/hisax/netjet.h
--- linux-2.2.21-pre1/drivers/isdn/hisax/netjet.h	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/netjet.h	Wed Jan  2 03:55:23 2002
@@ -1,14 +1,16 @@
-// $Id: netjet.h,v 2.5.6.2 2001/02/16 16:43:28 kai Exp $
-//-----------------------------------------------------------------------------
-//
-// NETjet common header file
-//
-// Author       Kerstern Keil repackaged by
-//              Matt Henderson - Traverse Technologies P/L www.traverse.com.au
-//
-// This file is (c) under GNU General Public License
-//
-//-----------------------------------------------------------------------------
+/* $Id: netjet.h,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
+ *
+ * NETjet common header file
+ *
+ * Author       Karsten Keil
+ * Copyright    by Karsten Keil      <keil@isdn4linux.de>
+ *              by Matt Henderson,
+ *                 Traverse Technologies P/L www.traverse.com.au
+ * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
+ *
+ */
 
 extern const char *CardType[];
 
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/niccy.c linux/drivers/isdn/hisax/niccy.c
--- linux-2.2.21-pre1/drivers/isdn/hisax/niccy.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/niccy.c	Wed Jan  2 03:55:23 2002
@@ -1,13 +1,15 @@
-/* $Id: niccy.c,v 1.15.6.4 2001/02/16 16:43:28 kai Exp $
+/* $Id: niccy.c,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
  *
- * niccy.c  low level stuff for Dr. Neuhaus NICCY PnP and NICCY PCI and
- *          compatible (SAGEM cybermodem)
+ * low level stuff for Dr. Neuhaus NICCY PnP and NICCY PCI and
+ * compatible (SAGEM cybermodem)
  *
- * Author   Karsten Keil
+ * Author       Karsten Keil
+ * Copyright    by Karsten Keil      <keil@isdn4linux.de>
  * 
- * Thanks to Dr. Neuhaus and SAGEM for informations
- *
- * This file is (c) under GNU General Public License
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
+ * 
+ * Thanks to Dr. Neuhaus and SAGEM for information
  *
  */
 
@@ -23,7 +25,7 @@
 #include <linux/isdn_compat.h>
 
 extern const char *CardType[];
-const char *niccy_revision = "$Revision: 1.15.6.4 $";
+const char *niccy_revision = "$Revision: 1.1.2.1 $";
 
 #define byteout(addr,val) outb(val,addr)
 #define bytein(addr) inb(addr)
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/nj_s.c linux/drivers/isdn/hisax/nj_s.c
--- linux-2.2.21-pre1/drivers/isdn/hisax/nj_s.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/nj_s.c	Wed Jan  2 03:55:23 2002
@@ -1,7 +1,9 @@
-// $Id: nj_s.c,v 2.7.6.5 2001/07/18 16:25:12 kai Exp $
-//
-// This file is (c) under GNU General Public License
-//
+/* $Id: nj_s.c,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
+ *
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
+ *
+ */
 
 #define __NO_VERSION__
 #include <linux/config.h>
@@ -15,7 +17,7 @@
 #include <linux/ppp_defs.h>
 #include "netjet.h"
 
-const char *NETjet_S_revision = "$Revision: 2.7.6.5 $";
+const char *NETjet_S_revision = "$Revision: 1.1.2.1 $";
 
 static u_char dummyrr(struct IsdnCardState *cs, int chan, u_char off)
 {
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/nj_u.c linux/drivers/isdn/hisax/nj_u.c
--- linux-2.2.21-pre1/drivers/isdn/hisax/nj_u.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/nj_u.c	Wed Jan  2 03:55:23 2002
@@ -1,6 +1,7 @@
-/* $Id: nj_u.c,v 2.8.6.5 2001/07/18 16:25:12 kai Exp $ 
+/* $Id: nj_u.c,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $ 
  *
- * This file is (c) under GNU General Public License
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
@@ -16,7 +17,7 @@
 #include <linux/ppp_defs.h>
 #include "netjet.h"
 
-const char *NETjet_U_revision = "$Revision: 2.8.6.5 $";
+const char *NETjet_U_revision = "$Revision: 1.1.2.1 $";
 
 static u_char dummyrr(struct IsdnCardState *cs, int chan, u_char off)
 {
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/q931.c linux/drivers/isdn/hisax/q931.c
--- linux-2.2.21-pre1/drivers/isdn/hisax/q931.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/q931.c	Wed Jan  2 03:55:23 2002
@@ -1,17 +1,17 @@
-/* $Id: q931.c,v 1.10.6.2 2001/03/13 16:17:08 kai Exp $
+/* $Id: q931.c,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
  *
- * q931.c       code to decode ITU Q.931 call control messages
+ * code to decode ITU Q.931 call control messages
  *
  * Author       Jan den Ouden
+ * Copyright    by Jan den Ouden
  *
- * This file is (c) under GNU General Public License
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
- * Changelog
+ * Changelog:
  *
  * Pauline Middelink    general improvements
- *
  * Beat Doebeli         cause texts, display information element
- *
  * Karsten Keil         cause texts, display information element for 1TR6
  *
  */
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/rawhdlc.c linux/drivers/isdn/hisax/rawhdlc.c
--- linux-2.2.21-pre1/drivers/isdn/hisax/rawhdlc.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/rawhdlc.c	Wed Jan  2 03:55:23 2002
@@ -1,11 +1,14 @@
-/* $Id: rawhdlc.c,v 1.5.6.1 2001/02/16 16:43:28 kai Exp $
+/* $Id: rawhdlc.c,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
  *
- * rawhdlc.c     support routines for cards that don't support HDLC
+ * support routines for cards that don't support HDLC
  *
- * Author     Karsten Keil (keil@isdn4linux.de)
- *            Brent Baccala <baccala@FreeSoft.org>
+ * Author     Brent Baccala
+ * Copyright  by Karsten Keil <keil@isdn4linux.de>
+ *            by Brent Baccala <baccala@FreeSoft.org>
+ *
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
- * This file is (c) under GNU General Public License
  *
  * Some passive ISDN cards, such as the Traverse NETJet and the AMD 7930,
  * don't perform HDLC encapsulation over the B channel.  Drivers for
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/rawhdlc.h linux/drivers/isdn/hisax/rawhdlc.h
--- linux-2.2.21-pre1/drivers/isdn/hisax/rawhdlc.h	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/rawhdlc.h	Wed Jan  2 03:55:23 2002
@@ -1,10 +1,10 @@
-/* $Id: rawhdlc.h,v 1.3.6.1 2001/02/16 16:43:29 kai Exp $
+/* $Id: rawhdlc.h,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
  *
- * rawhdlc.h     support routines for cards that don't support HDLC
+ * Author     Brent Baccala
+ * Copyright  by Brent Baccala <baccala@FreeSoft.org>
  *
- * Author     Brent Baccala <baccala@FreeSoft.org>
- *
- * This file is (c) under GNU General Public License
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/s0box.c linux/drivers/isdn/hisax/s0box.c
--- linux-2.2.21-pre1/drivers/isdn/hisax/s0box.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/s0box.c	Wed Jan  2 03:55:23 2002
@@ -1,12 +1,15 @@
-/* $Id: s0box.c,v 2.4.6.1 2001/02/16 16:43:29 kai Exp $
+/* $Id: s0box.c,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
  *
- * s0box.c      low level stuff for Creatix S0BOX
+ * low level stuff for Creatix S0BOX
  *
- * Author       S0BOX specific stuff: Enrik Berkhan (enrik@starfleet.inka.de)
+ * Author       Enrik Berkhan
+ * Copyright    by Enrik Berkhan <enrik@starfleet.inka.de>
  *
- * This file is (c) under GNU General Public License
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
+
 #define __NO_VERSION__
 #include <linux/init.h>
 #include "hisax.h"
@@ -15,7 +18,7 @@
 #include "isdnl1.h"
 
 extern const char *CardType[];
-const char *s0box_revision = "$Revision: 2.4.6.1 $";
+const char *s0box_revision = "$Revision: 1.1.2.1 $";
 
 static inline void
 writereg(unsigned int padr, signed int addr, u_char off, u_char val) {
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/saphir.c linux/drivers/isdn/hisax/saphir.c
--- linux-2.2.21-pre1/drivers/isdn/hisax/saphir.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/saphir.c	Wed Jan  2 03:55:23 2002
@@ -1,16 +1,17 @@
-/* $Id: saphir.c,v 1.8.6.1 2001/02/16 16:43:29 kai Exp $
+/* $Id: saphir.c,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
  *
- * saphir.c low level stuff for HST Saphir 1
+ * low level stuff for HST Saphir 1
  *
- * Author     Karsten Keil (keil@isdn4linux.de)
+ * Author       Karsten Keil
+ * Copyright    by Karsten Keil      <keil@isdn4linux.de>
+ * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  * Thanks to    HST High Soft Tech GmbH
  *
- * This file is (c) under GNU General Public License
- *
  */
 
-
 #define __NO_VERSION__
 #include <linux/init.h>
 #include "hisax.h"
@@ -19,7 +20,7 @@
 #include "isdnl1.h"
 
 extern const char *CardType[];
-static char *saphir_rev = "$Revision: 1.8.6.1 $";
+static char *saphir_rev = "$Revision: 1.1.2.1 $";
 
 #define byteout(addr,val) outb(val,addr)
 #define bytein(addr) inb(addr)
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/sedlbauer.c linux/drivers/isdn/hisax/sedlbauer.c
--- linux-2.2.21-pre1/drivers/isdn/hisax/sedlbauer.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/sedlbauer.c	Wed Jan  2 03:55:23 2002
@@ -1,23 +1,22 @@
-/* $Id: sedlbauer.c,v 1.25.6.5 2001/07/13 09:20:12 kai Exp $
+/* $Id: sedlbauer.c,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
  *
- * sedlbauer.c  low level stuff for Sedlbauer cards
- *              includes support for the Sedlbauer speed star (speed star II),
- *              support for the Sedlbauer speed fax+,
- *              support for the Sedlbauer ISDN-Controller PC/104 and
- *              support for the Sedlbauer speed pci
- *              derived from the original file asuscom.c from Karsten Keil
- *
- * Copyright (C) 1997,1998 Marcus Niemann (for the modifications to
- *                                         the original file asuscom.c)
- *
- * Author     Marcus Niemann (niemann@www-bib.fh-bielefeld.de)
+ * low level stuff for Sedlbauer cards
+ * includes support for the Sedlbauer speed star (speed star II),
+ * support for the Sedlbauer speed fax+,
+ * support for the Sedlbauer ISDN-Controller PC/104 and
+ * support for the Sedlbauer speed pci
+ * derived from the original file asuscom.c from Karsten Keil
+ *
+ * Author       Marcus Niemann
+ * Copyright    by Marcus Niemann    <niemann@www-bib.fh-bielefeld.de>
+ * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  * Thanks to  Karsten Keil
  *            Sedlbauer AG for informations
  *            Edgar Toernig
  *
- * This file is (c) under GNU General Public License
- *
  */
 
 /* Supported cards:
@@ -53,7 +52,7 @@
 
 extern const char *CardType[];
 
-const char *Sedlbauer_revision = "$Revision: 1.25.6.5 $";
+const char *Sedlbauer_revision = "$Revision: 1.1.2.1 $";
 
 const char *Sedlbauer_Types[] =
 	{"None", "speed card/win", "speed star", "speed fax+",
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/sportster.c linux/drivers/isdn/hisax/sportster.c
--- linux-2.2.21-pre1/drivers/isdn/hisax/sportster.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/sportster.c	Wed Jan  2 03:55:23 2002
@@ -1,12 +1,15 @@
-/* $Id: sportster.c,v 1.14.6.1 2001/02/16 16:43:29 kai Exp $
+/* $Id: sportster.c,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
  *
- * sportster.c     low level stuff for USR Sportster internal TA
+ * low level stuff for USR Sportster internal TA
  *
- * Author       Karsten Keil (keil@isdn4linux.de)
+ * Author       Karsten Keil
+ * Copyright    by Karsten Keil      <keil@isdn4linux.de>
+ * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  * Thanks to Christian "naddy" Weisgerber (3Com, US Robotics) for documentation
  *
- * This file is (c) under GNU General Public License
  *
  */
 #define __NO_VERSION__
@@ -17,7 +20,7 @@
 #include "isdnl1.h"
 
 extern const char *CardType[];
-const char *sportster_revision = "$Revision: 1.14.6.1 $";
+const char *sportster_revision = "$Revision: 1.1.2.1 $";
 
 #define byteout(addr,val) outb(val,addr)
 #define bytein(addr) inb(addr)
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/tei.c linux/drivers/isdn/hisax/tei.c
--- linux-2.2.21-pre1/drivers/isdn/hisax/tei.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/tei.c	Wed Jan  2 03:55:23 2002
@@ -1,23 +1,27 @@
-/* $Id: tei.c,v 2.17.6.2 2001/05/26 15:19:57 kai Exp $
+/* $Id: tei.c,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
  *
- * Author       Karsten Keil (keil@isdn4linux.de)
+ * Author       Karsten Keil
  *              based on the teles driver from Jan den Ouden
+ * Copyright    by Karsten Keil      <keil@isdn4linux.de>
+ * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
- *		This file is (c) under GNU General Public License
- *		For changes and modifications please read
- *		../../../Documentation/isdn/HiSax.cert
+ * For changes and modifications please read
+ * ../../../Documentation/isdn/HiSax.cert
  *
  * Thanks to    Jan den Ouden
  *              Fritz Elfert
  *
  */
+
 #define __NO_VERSION__
 #include "hisax.h"
 #include "isdnl2.h"
 #include <linux/init.h>
 #include <linux/random.h>
 
-const char *tei_revision = "$Revision: 2.17.6.2 $";
+const char *tei_revision = "$Revision: 1.1.2.1 $";
 
 #define ID_REQUEST	1
 #define ID_ASSIGNED	2
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/teleint.c linux/drivers/isdn/hisax/teleint.c
--- linux-2.2.21-pre1/drivers/isdn/hisax/teleint.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/teleint.c	Wed Jan  2 03:55:23 2002
@@ -1,10 +1,12 @@
-/* $Id: teleint.c,v 1.14.6.1 2001/02/16 16:43:29 kai Exp $
+/* $Id: teleint.c,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
  *
- * teleint.c     low level stuff for TeleInt isdn cards
+ * low level stuff for TeleInt isdn cards
  *
- * Author     Karsten Keil (keil@isdn4linux.de)
- *
- * This file is (c) under GNU General Public License
+ * Author       Karsten Keil
+ * Copyright    by Karsten Keil      <keil@isdn4linux.de>
+ * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
@@ -17,7 +19,7 @@
 
 extern const char *CardType[];
 
-const char *TeleInt_revision = "$Revision: 1.14.6.1 $";
+const char *TeleInt_revision = "$Revision: 1.1.2.1 $";
 
 #define byteout(addr,val) outb(val,addr)
 #define bytein(addr) inb(addr)
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/teles0.c linux/drivers/isdn/hisax/teles0.c
--- linux-2.2.21-pre1/drivers/isdn/hisax/teles0.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/teles0.c	Wed Jan  2 03:55:23 2002
@@ -1,17 +1,20 @@
-/* $Id: teles0.c,v 2.13.6.1 2001/02/16 16:43:29 kai Exp $
+/* $Id: teles0.c,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
  *
- * teles0.c     low level stuff for Teles Memory IO isdn cards
- *              based on the teles driver from Jan den Ouden
+ * low level stuff for Teles Memory IO isdn cards
  *
- * Author       Karsten Keil (keil@isdn4linux.de)
+ * Author       Karsten Keil
+ *              based on the teles driver from Jan den Ouden
+ * Copyright    by Karsten Keil      <keil@isdn4linux.de>
+ * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  * Thanks to    Jan den Ouden
  *              Fritz Elfert
  *              Beat Doebeli
  *
- * This file is (c) under GNU General Public License
- *
  */
+
 #define __NO_VERSION__
 #include <linux/init.h>
 #include "hisax.h"
@@ -21,7 +24,7 @@
 
 extern const char *CardType[];
 
-const char *teles0_revision = "$Revision: 2.13.6.1 $";
+const char *teles0_revision = "$Revision: 1.1.2.1 $";
 
 #define TELES_IOMEM_SIZE	0x400
 #define byteout(addr,val) outb(val,addr)
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/teles3.c linux/drivers/isdn/hisax/teles3.c
--- linux-2.2.21-pre1/drivers/isdn/hisax/teles3.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/teles3.c	Wed Jan  2 03:55:23 2002
@@ -1,17 +1,17 @@
-/* $Id: teles3.c,v 2.17.6.1 2001/02/16 16:43:29 kai Exp $
+/* $Id: teles3.c,v 1.1.2.1 2001/12/31 13:26:45 kai Exp $
  *
- * teles3.c     low level stuff for Teles 16.3 & PNP isdn cards
+ * low level stuff for Teles 16.3 & PNP isdn cards
  *
- *              based on the teles driver from Jan den Ouden
- *
- * Author       Karsten Keil (keil@isdn4linux.de)
+ * Author       Karsten Keil
+ * Copyright    by Karsten Keil      <keil@isdn4linux.de>
+ * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  * Thanks to    Jan den Ouden
  *              Fritz Elfert
  *              Beat Doebeli
  *
- * This file is (c) under GNU General Public License
- *
  */
 #define __NO_VERSION__
 #include <linux/init.h>
@@ -21,7 +21,7 @@
 #include "isdnl1.h"
 
 extern const char *CardType[];
-const char *teles3_revision = "$Revision: 2.17.6.1 $";
+const char *teles3_revision = "$Revision: 1.1.2.1 $";
 
 #define byteout(addr,val) outb(val,addr)
 #define bytein(addr) inb(addr)
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/telespci.c linux/drivers/isdn/hisax/telespci.c
--- linux-2.2.21-pre1/drivers/isdn/hisax/telespci.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/telespci.c	Wed Jan  2 03:55:23 2002
@@ -1,13 +1,17 @@
-/* $Id: telespci.c,v 2.16.6.4 2001/02/16 16:43:29 kai Exp $
+/* $Id: telespci.c,v 1.1.2.1 2001/12/31 13:26:46 kai Exp $
  *
- * telespci.c     low level stuff for Teles PCI isdn cards
+ * low level stuff for Teles PCI isdn cards
  *
- * Author       Ton van Rosmalen 
- *              Karsten Keil (keil@isdn4linux.de)
- *
- * This file is (c) under GNU General Public License
+ * Author       Ton van Rosmalen
+ *              Karsten Keil
+ * Copyright    by Ton van Rosmalen
+ *              by Karsten Keil      <keil@isdn4linux.de>
+ * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
+
 #define __NO_VERSION__
 #include <linux/init.h>
 #include <linux/config.h>
@@ -19,7 +23,7 @@
 #include <linux/isdn_compat.h>
 
 extern const char *CardType[];
-const char *telespci_revision = "$Revision: 2.16.6.4 $";
+const char *telespci_revision = "$Revision: 1.1.2.1 $";
 
 #define ZORAN_PO_RQ_PEN	0x02000000
 #define ZORAN_PO_WR	0x00800000
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/w6692.c linux/drivers/isdn/hisax/w6692.c
--- linux-2.2.21-pre1/drivers/isdn/hisax/w6692.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/w6692.c	Wed Jan  2 03:55:23 2002
@@ -1,11 +1,12 @@
-/* $Id: w6692.c,v 1.12.6.5 2001/06/09 15:14:18 kai Exp $
+/* $Id: w6692.c,v 1.1.2.1 2001/12/31 13:26:46 kai Exp $
  *
- * w6692.c   Winbond W6692 specific routines
+ * Winbond W6692 specific routines
  *
- * Author       Petr Novak <petr.novak@i.cz>
- *              (based on HiSax driver by Karsten Keil)
- *
- *              This file is (c) under GNU General Public License
+ * Author       Petr Novak
+ * Copyright    by Petr Novak        <petr.novak@i.cz>
+ * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
@@ -36,7 +37,7 @@
 
 extern const char *CardType[];
 
-const char *w6692_revision = "$Revision: 1.12.6.5 $";
+const char *w6692_revision = "$Revision: 1.1.2.1 $";
 
 #define DBUSY_TIMER_VALUE 80
 
diff -urN linux-2.2.21-pre1/drivers/isdn/hisax/w6692.h linux/drivers/isdn/hisax/w6692.h
--- linux-2.2.21-pre1/drivers/isdn/hisax/w6692.h	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hisax/w6692.h	Wed Jan  2 03:55:23 2002
@@ -1,10 +1,12 @@
-/* $Id: w6692.h,v 1.2.6.1 2001/02/16 16:43:29 kai Exp $
+/* $Id: w6692.h,v 1.1.2.1 2001/12/31 13:26:46 kai Exp $
  *
- * w6692.h   Winbond W6692 specific defines
+ * Winbond W6692 specific defines
  *
- * Author       Petr Novak <petr.novak@i.cz>
- *
- * This file is (c) under GNU General Public License
+ * Author       Petr Novak
+ * Copyright    by Petr Novak        <petr.novak@i.cz>
+ * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
diff -urN linux-2.2.21-pre1/drivers/isdn/hysdn/boardergo.c linux/drivers/isdn/hysdn/boardergo.c
--- linux-2.2.21-pre1/drivers/isdn/hysdn/boardergo.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hysdn/boardergo.c	Wed Jan  2 03:55:23 2002
@@ -1,41 +1,25 @@
-/* $Id: boardergo.c,v 1.5.6.5 2001/07/18 16:02:16 kai Exp $
-
+/* $Id: boardergo.c,v 1.1.2.1 2001/12/31 13:26:46 kai Exp $
+ *
  * Linux driver for HYSDN cards, specific routines for ergo type boards.
  *
+ * Author    Werner Cornelius (werner@titro.de) for Hypercope GmbH
+ * Copyright 1999 by Werner Cornelius (werner@titro.de)
+ *
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
+ *
  * As all Linux supported cards Champ2, Ergo and Metro2/4 use the same
  * DPRAM interface and layout with only minor differences all related
  * stuff is done here, not in separate modules.
  *
- * written by Werner Cornelius (werner@titro.de) for Hypercope GmbH
- *
- * Copyright 1999  by Werner Cornelius (werner@titro.de)
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
- *
  */
 
-#define __NO_VERSION__
 #include <linux/config.h>
-#include <linux/module.h>
-#include <linux/version.h>
-#include <asm/io.h>
 #include <linux/signal.h>
 #include <linux/kernel.h>
 #include <linux/ioport.h>
-#include <linux/interrupt.h>
 #include <linux/vmalloc.h>
+#include <asm/io.h>
 
 #include "hysdn_defs.h"
 #include "boardergo.h"
diff -urN linux-2.2.21-pre1/drivers/isdn/hysdn/boardergo.h linux/drivers/isdn/hysdn/boardergo.h
--- linux-2.2.21-pre1/drivers/isdn/hysdn/boardergo.h	Sun Mar 25 08:37:33 2001
+++ linux/drivers/isdn/hysdn/boardergo.h	Wed Jan  2 03:55:23 2002
@@ -1,23 +1,12 @@
-/* $Id: boardergo.h,v 1.2 2000/11/13 22:51:47 kai Exp $
-
- * Linux driver for HYSDN cards, definitions for ergo type boards (buffers..).
- * written by Werner Cornelius (werner@titro.de) for Hypercope GmbH
- *
- * Copyright 1999  by Werner Cornelius (werner@titro.de)
+/* $Id: boardergo.h,v 1.1.2.1 2001/12/31 13:26:46 kai Exp $
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
+ * Linux driver for HYSDN cards, definitions for ergo type boards (buffers..).
  *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
+ * Author    Werner Cornelius (werner@titro.de) for Hypercope GmbH
+ * Copyright 1999 by Werner Cornelius (werner@titro.de)
  *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
diff -urN linux-2.2.21-pre1/drivers/isdn/hysdn/hycapi.c linux/drivers/isdn/hysdn/hycapi.c
--- linux-2.2.21-pre1/drivers/isdn/hysdn/hycapi.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hysdn/hycapi.c	Wed Jan  2 03:55:23 2002
@@ -1,23 +1,12 @@
-/* $Id: hycapi.c,v 1.8.6.3 2001/05/26 15:19:58 kai Exp $
+/* $Id: hycapi.c,v 1.1.2.1 2001/12/31 13:26:46 kai Exp $
  *
  * Linux driver for HYSDN cards, CAPI2.0-Interface.
- * written by Ulrich Albrecht (u.albrecht@hypercope.de) for Hypercope GmbH
  *
+ * Author    Ulrich Albrecht <u.albrecht@hypercope.de> for Hypercope GmbH
  * Copyright 2000 by Hypercope GmbH
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
@@ -41,7 +30,7 @@
 #include "hysdn_defs.h"
 #include <linux/kernelcapi.h>
 
-static char hycapi_revision[]="$Revision: 1.8.6.3 $";
+static char hycapi_revision[]="$Revision: 1.1.2.1 $";
 
 unsigned int hycapi_enable = 0xffffffff; 
 MODULE_PARM(hycapi_enable, "i");
diff -urN linux-2.2.21-pre1/drivers/isdn/hysdn/hysdn_boot.c linux/drivers/isdn/hysdn/hysdn_boot.c
--- linux-2.2.21-pre1/drivers/isdn/hysdn/hysdn_boot.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hysdn/hysdn_boot.c	Wed Jan  2 03:55:23 2002
@@ -1,30 +1,16 @@
-/* $Id: hysdn_boot.c,v 1.4.6.3 2001/03/13 16:17:09 kai Exp $
-
- * Linux driver for HYSDN cards, specific routines for booting and pof handling.
- *
- * written by Werner Cornelius (werner@titro.de) for Hypercope GmbH
- *
- * Copyright 1999  by Werner Cornelius (werner@titro.de)
+/* $Id: hysdn_boot.c,v 1.1.2.1 2001/12/31 13:26:46 kai Exp $
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
+ * Linux driver for HYSDN cards
+ * specific routines for booting and pof handling
  *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
+ * Author    Werner Cornelius (werner@titro.de) for Hypercope GmbH
+ * Copyright 1999 by Werner Cornelius (werner@titro.de)
  *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
-#define __NO_VERSION__
-#include <linux/module.h>
-#include <linux/version.h>
 #include <linux/vmalloc.h>
 #include <linux/slab.h>
 #include <asm/uaccess.h>
diff -urN linux-2.2.21-pre1/drivers/isdn/hysdn/hysdn_defs.h linux/drivers/isdn/hysdn/hysdn_defs.h
--- linux-2.2.21-pre1/drivers/isdn/hysdn/hysdn_defs.h	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hysdn/hysdn_defs.h	Wed Jan  2 03:55:23 2002
@@ -1,23 +1,13 @@
-/* $Id: hysdn_defs.h,v 1.5.6.2 2001/04/20 02:42:00 keil Exp $
-
- * Linux driver for HYSDN cards, global definitions and exported vars and functions.
- * written by Werner Cornelius (werner@titro.de) for Hypercope GmbH
+/* $Id: hysdn_defs.h,v 1.1.2.1 2001/12/31 13:26:46 kai Exp $
  *
- * Copyright 1999  by Werner Cornelius (werner@titro.de)
+ * Linux driver for HYSDN cards
+ * global definitions and exported vars and functions.
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
+ * Author    Werner Cornelius (werner@titro.de) for Hypercope GmbH
+ * Copyright 1999 by Werner Cornelius (werner@titro.de)
  *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
diff -urN linux-2.2.21-pre1/drivers/isdn/hysdn/hysdn_init.c linux/drivers/isdn/hysdn/hysdn_init.c
--- linux-2.2.21-pre1/drivers/isdn/hysdn/hysdn_init.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hysdn/hysdn_init.c	Wed Jan  2 03:55:23 2002
@@ -1,23 +1,12 @@
-/* $Id: hysdn_init.c,v 1.6.6.5 2001/02/16 16:43:30 kai Exp $
-
- * Linux driver for HYSDN cards, init functions.
- * written by Werner Cornelius (werner@titro.de) for Hypercope GmbH
- *
- * Copyright 1999  by Werner Cornelius (werner@titro.de)
+/* $Id: hysdn_init.c,v 1.1.2.1 2001/12/31 13:26:46 kai Exp $
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
+ * Linux driver for HYSDN cards, init functions.
  *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
+ * Author    Werner Cornelius (werner@titro.de) for Hypercope GmbH
+ * Copyright 1999 by Werner Cornelius (werner@titro.de)
  *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
@@ -32,7 +21,11 @@
 
 #include "hysdn_defs.h"
 
-static char *hysdn_init_revision = "$Revision: 1.6.6.5 $";
+MODULE_DESCRIPTION("ISDN4Linux: Driver for HYSDN cards");
+MODULE_AUTHOR("Werner Cornelius");
+MODULE_LICENSE("GPL");
+
+static char *hysdn_init_revision = "$Revision: 1.1.2.1 $";
 int cardmax;			/* number of found cards */
 hysdn_card *card_root = NULL;	/* pointer to first card */
 
diff -urN linux-2.2.21-pre1/drivers/isdn/hysdn/hysdn_net.c linux/drivers/isdn/hysdn/hysdn_net.c
--- linux-2.2.21-pre1/drivers/isdn/hysdn/hysdn_net.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hysdn/hysdn_net.c	Wed Jan  2 03:55:23 2002
@@ -1,28 +1,16 @@
-/* $Id: hysdn_net.c,v 1.8.6.3 2001/06/05 19:45:37 kai Exp $
-
+/* $Id: hysdn_net.c,v 1.1.2.1 2001/12/31 13:26:46 kai Exp $
+ *
  * Linux driver for HYSDN cards, net (ethernet type) handling routines.
  *
- * written by Werner Cornelius (werner@titro.de) for Hypercope GmbH
+ * Author    Werner Cornelius (werner@titro.de) for Hypercope GmbH
+ * Copyright 1999 by Werner Cornelius (werner@titro.de)
  *
- * Copyright 1999  by Werner Cornelius (werner@titro.de)
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  * This net module has been inspired by the skeleton driver from
  * Donald Becker (becker@CESDIS.gsfc.nasa.gov)
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
- *
  */
 
 #define __NO_VERSION__
@@ -41,7 +29,7 @@
 MODULE_PARM(hynet_enable, "i");
 
 /* store the actual version for log reporting */
-char *hysdn_net_revision = "$Revision: 1.8.6.3 $";
+char *hysdn_net_revision = "$Revision: 1.1.2.1 $";
 
 #define MAX_SKB_BUFFERS 20	/* number of buffers for keeping TX-data */
 
diff -urN linux-2.2.21-pre1/drivers/isdn/hysdn/hysdn_pof.h linux/drivers/isdn/hysdn/hysdn_pof.h
--- linux-2.2.21-pre1/drivers/isdn/hysdn/hysdn_pof.h	Sun Mar 25 08:37:33 2001
+++ linux/drivers/isdn/hysdn/hysdn_pof.h	Wed Jan  2 03:55:23 2002
@@ -1,23 +1,12 @@
-/* $Id: hysdn_pof.h,v 1.2 2000/11/13 22:51:47 kai Exp $
-
- * Linux driver for HYSDN cards, definitions used for handling pof-files.
- * written by Werner Cornelius (werner@titro.de) for Hypercope GmbH
- *
- * Copyright 1999  by Werner Cornelius (werner@titro.de)
+/* $Id: hysdn_pof.h,v 1.1.2.1 2001/12/31 13:26:46 kai Exp $
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
+ * Linux driver for HYSDN cards, definitions used for handling pof-files.
  *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
+ * Author    Werner Cornelius (werner@titro.de) for Hypercope GmbH
+ * Copyright 1999 by Werner Cornelius (werner@titro.de)
  *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
diff -urN linux-2.2.21-pre1/drivers/isdn/hysdn/hysdn_procconf.c linux/drivers/isdn/hysdn/hysdn_procconf.c
--- linux-2.2.21-pre1/drivers/isdn/hysdn/hysdn_procconf.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hysdn/hysdn_procconf.c	Wed Jan  2 03:55:23 2002
@@ -1,23 +1,13 @@
-/* $Id: hysdn_procconf.c,v 1.8.6.3 2001/08/13 07:46:15 kai Exp $
-
+/* $Id: hysdn_procconf.c,v 1.1.2.1 2001/12/31 13:26:46 kai Exp $
+ *
  * Linux driver for HYSDN cards, /proc/net filesystem dir and conf functions.
+ *
  * written by Werner Cornelius (werner@titro.de) for Hypercope GmbH
  *
  * Copyright 1999  by Werner Cornelius (werner@titro.de)
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
@@ -30,7 +20,7 @@
 
 #include "hysdn_defs.h"
 
-static char *hysdn_procconf_revision = "$Revision: 1.8.6.3 $";
+static char *hysdn_procconf_revision = "$Revision: 1.1.2.1 $";
 
 #define INFO_OUT_LEN 80		/* length of info line including lf */
 
@@ -464,4 +454,4 @@
 	}
 
 	remove_proc_entry(PROC_SUBDIR_NAME, proc_net);
-}				/* hysdn_procfs_release */
+}
diff -urN linux-2.2.21-pre1/drivers/isdn/hysdn/hysdn_proclog.c linux/drivers/isdn/hysdn/hysdn_proclog.c
--- linux-2.2.21-pre1/drivers/isdn/hysdn/hysdn_proclog.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hysdn/hysdn_proclog.c	Wed Jan  2 03:55:23 2002
@@ -1,23 +1,12 @@
-/* $Id: hysdn_proclog.c,v 1.9.6.2 2001/08/13 07:46:15 kai Exp $
-
- * Linux driver for HYSDN cards, /proc/net filesystem log functions.
- * written by Werner Cornelius (werner@titro.de) for Hypercope GmbH
- *
- * Copyright 1999  by Werner Cornelius (werner@titro.de)
+/* $Id: hysdn_proclog.c,v 1.1.2.1 2001/12/31 13:26:46 kai Exp $
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
+ * Linux driver for HYSDN cards, /proc/net filesystem log functions.
  *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
+ * Author    Werner Cornelius (werner@titro.de) for Hypercope GmbH
+ * Copyright 1999 by Werner Cornelius (werner@titro.de)
  *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
diff -urN linux-2.2.21-pre1/drivers/isdn/hysdn/hysdn_sched.c linux/drivers/isdn/hysdn/hysdn_sched.c
--- linux-2.2.21-pre1/drivers/isdn/hysdn/hysdn_sched.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/hysdn/hysdn_sched.c	Wed Jan  2 03:55:23 2002
@@ -1,36 +1,21 @@
-/* $Id: hysdn_sched.c,v 1.5.6.2 2001/04/20 02:42:00 keil Exp $
-
- * Linux driver for HYSDN cards, scheduler routines for handling exchange card <-> pc.
- *
- * written by Werner Cornelius (werner@titro.de) for Hypercope GmbH
- *
- * Copyright 1999  by Werner Cornelius (werner@titro.de)
+/* $Id: hysdn_sched.c,v 1.1.2.1 2001/12/31 13:26:46 kai Exp $
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
+ * Linux driver for HYSDN cards
+ * scheduler routines for handling exchange card <-> pc.
  *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
+ * Author    Werner Cornelius (werner@titro.de) for Hypercope GmbH
+ * Copyright 1999 by Werner Cornelius (werner@titro.de)
  *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
-#define __NO_VERSION__
 #include <linux/config.h>
-#include <linux/module.h>
-#include <linux/version.h>
-#include <asm/io.h>
 #include <linux/signal.h>
 #include <linux/kernel.h>
 #include <linux/ioport.h>
-#include <linux/interrupt.h>
+#include <asm/io.h>
 
 #include "hysdn_defs.h"
 
diff -urN linux-2.2.21-pre1/drivers/isdn/hysdn/ince1pc.h linux/drivers/isdn/hysdn/ince1pc.h
--- linux-2.2.21-pre1/drivers/isdn/hysdn/ince1pc.h	Sun Mar 25 08:37:33 2001
+++ linux/drivers/isdn/hysdn/ince1pc.h	Wed Jan  2 03:55:23 2002
@@ -1,17 +1,19 @@
+/*
+ * Linux driver for HYSDN cards
+ * common definitions for both sides of the bus:
+ * - conventions both spoolers must know
+ * - channel numbers agreed upon
+ *
+ * Author    M. Steinkopf
+ * Copyright 1999 by M. Steinkopf
+ *
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
+ *
+ */
+
 #ifndef __INCE1PC_H__
 #define __INCE1PC_H__
-
-/****************************************************************************
-
-    FILE:       ince1pc.h
-
-    AUTHOR:     M.Steinkopf
-
-    PURPOSE:    common definitions for both sides of the bus:
-		- conventions both spoolers must know
-		- channel numbers agreed upon
-
-*****************************************************************************/ 
 
 /*  basic scalar definitions have same meanning,
  *  but their declaration location depends on environment
diff -urN linux-2.2.21-pre1/drivers/isdn/icn/icn.c linux/drivers/isdn/icn/icn.c
--- linux-2.2.21-pre1/drivers/isdn/icn/icn.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/icn/icn.c	Wed Jan  2 03:55:23 2002
@@ -1,28 +1,35 @@
-/* $Id: icn.c,v 1.65.6.5 2001/06/09 15:14:19 kai Exp $
-
+/* $Id: icn.c,v 1.1.2.1 2001/12/31 13:26:47 kai Exp $
+ *
  * ISDN low-level module for the ICN active ISDN-Card.
  *
  * Copyright 1994,95,96 by Fritz Elfert (fritz@isdn4linux.de)
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
 #include "icn.h"
+#include <linux/module.h>
 #include <linux/init.h>
 
+static int portbase = ICN_BASEADDR;
+static unsigned long membase = ICN_MEMADDR;
+static char *icn_id = "\0";
+static char *icn_id2 = "\0";
+
+MODULE_DESCRIPTION("ISDN4Linux: Driver for ICN active ISDN card");
+MODULE_AUTHOR("Fritz Elfert");
+MODULE_LICENSE("GPL");
+MODULE_PARM(portbase, "i");
+MODULE_PARM_DESC(portbase, "Port address of first card");
+MODULE_PARM(membase, "l");
+MODULE_PARM_DESC(membase, "Shared memory address of all cards");
+MODULE_PARM(icn_id, "s");
+MODULE_PARM_DESC(icn_id, "ID-String of first card");
+MODULE_PARM(icn_id2, "s");
+MODULE_PARM_DESC(icn_id2, "ID-String of first card, second S0 (4B only)");
+
 /*
  * Verbose bootcode- and protocol-downloading.
  */
@@ -34,7 +41,7 @@
 #undef MAP_DEBUG
 
 static char
-*revision = "$Revision: 1.65.6.5 $";
+*revision = "$Revision: 1.1.2.1 $";
 
 static int icn_addcard(int, char *, char *);
 
diff -urN linux-2.2.21-pre1/drivers/isdn/icn/icn.h linux/drivers/isdn/icn/icn.h
--- linux-2.2.21-pre1/drivers/isdn/icn/icn.h	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/icn/icn.h	Wed Jan  2 03:55:23 2002
@@ -1,22 +1,11 @@
-/* $Id: icn.h,v 1.30.6.3 2001/04/20 02:42:01 keil Exp $
-
+/* $Id: icn.h,v 1.1.2.1 2001/12/31 13:26:47 kai Exp $
+ *
  * ISDN lowlevel-module for the ICN active ISDN-Card.
  *
  * Copyright 1994 by Fritz Elfert (fritz@isdn4linux.de)
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
@@ -46,7 +35,6 @@
 #ifdef __KERNEL__
 /* Kernel includes */
 
-#include <linux/module.h>
 #include <linux/version.h>
 #include <linux/errno.h>
 #include <linux/fs.h>
@@ -205,27 +193,6 @@
 {0, 4, 8, 12};                  /* for icn_map_channel() */
 
 static icn_dev dev;
-
-/* With modutils >= 1.1.67 Integers can be changed while loading a
- * module. For this reason define the Port-Base an Shmem-Base as
- * integers.
- */
-static int portbase = ICN_BASEADDR;
-static unsigned long membase = ICN_MEMADDR;
-static char *icn_id = "\0";
-static char *icn_id2 = "\0";
-
-#ifdef MODULE
-MODULE_AUTHOR("Fritz Elfert");
-MODULE_PARM(portbase, "i");
-MODULE_PARM_DESC(portbase, "Port address of first card");
-MODULE_PARM(membase, "l");
-MODULE_PARM_DESC(membase, "Shared memory address of all cards");
-MODULE_PARM(icn_id, "s");
-MODULE_PARM_DESC(icn_id, "ID-String of first card");
-MODULE_PARM(icn_id2, "s");
-MODULE_PARM_DESC(icn_id2, "ID-String of first card, second S0 (4B only)");
-#endif
 
 #endif                          /* __KERNEL__ */
 
diff -urN linux-2.2.21-pre1/drivers/isdn/isdn_audio.c linux/drivers/isdn/isdn_audio.c
--- linux-2.2.21-pre1/drivers/isdn/isdn_audio.c	Sun Mar 25 08:31:37 2001
+++ linux/drivers/isdn/isdn_audio.c	Wed Jan  2 03:55:23 2002
@@ -1,34 +1,21 @@
-/* $Id: isdn_audio.c,v 1.21 2000/06/20 18:01:55 keil Exp $
-
+/* $Id: isdn_audio.c,v 1.1.2.1 2001/12/31 13:26:34 kai Exp $
+ *
  * Linux ISDN subsystem, audio conversion and compression (linklevel).
  *
  * Copyright 1994-1999 by Fritz Elfert (fritz@isdn4linux.de)
  * DTMF code (c) 1996 by Christian Mock (cm@kukuruz.ping.at)
  * Silence detection (c) 1998 by Armin Schindler (mac@gismo.telekom.de)
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
-#define __NO_VERSION__
-#include <linux/module.h>
 #include <linux/isdn.h>
 #include "isdn_audio.h"
 #include "isdn_common.h"
 
-char *isdn_audio_revision = "$Revision: 1.21 $";
+char *isdn_audio_revision = "$Revision: 1.1.2.1 $";
 
 /*
  * Misc. lookup-tables.
diff -urN linux-2.2.21-pre1/drivers/isdn/isdn_audio.h linux/drivers/isdn/isdn_audio.h
--- linux-2.2.21-pre1/drivers/isdn/isdn_audio.h	Sun Mar 25 08:31:37 2001
+++ linux/drivers/isdn/isdn_audio.h	Wed Jan  2 03:55:23 2002
@@ -1,22 +1,11 @@
-/* $Id: isdn_audio.h,v 1.9 2000/05/11 22:29:20 kai Exp $
-
+/* $Id: isdn_audio.h,v 1.1.2.1 2001/12/31 13:26:34 kai Exp $
+ *
  * Linux ISDN subsystem, audio conversion and compression (linklevel).
  *
  * Copyright 1994-1999 by Fritz Elfert (fritz@isdn4linux.de)
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
diff -urN linux-2.2.21-pre1/drivers/isdn/isdn_bsdcomp.c linux/drivers/isdn/isdn_bsdcomp.c
--- linux-2.2.21-pre1/drivers/isdn/isdn_bsdcomp.c	Fri Nov  2 08:39:06 2001
+++ linux/drivers/isdn/isdn_bsdcomp.c	Wed Jan  2 03:55:23 2002
@@ -4,8 +4,14 @@
  * Patched version for ISDN syncPPP written 1997/1998 by Michael Hipp
  * The whole module is now SKB based.
  *
- * Compile with:
- *  gcc -O2 -I/usr/src/linux/include -D__KERNEL__ -DMODULE -c isdn_bsdcomp.c
+ */
+
+/*
+ * Update: The Berkeley copyright was changed, and the change 
+ * is retroactive to all "true" BSD software (ie everything
+ * from UCB as opposed to other peoples code that just carried
+ * the same license). The new copyright doesn't clash with the
+ * GPL, so the module-only restriction has been removed..
  */
 
 /*
@@ -82,13 +88,15 @@
 
 #include <linux/isdn.h>
 #include <linux/isdn_ppp.h>
-/* #include <linux/netprotocol.h> */
 #include <linux/ip.h>
 #include <linux/tcp.h>
 #include <linux/if_arp.h>
 #include <linux/ppp-comp.h>
 
 #include "isdn_ppp.h"
+
+MODULE_DESCRIPTION("ISDN4Linux: BSD Compression for PPP over ISDN");
+MODULE_LICENSE("Dual BSD/GPL");
 
 #define BSD_VERSION(x)	((x) >> 5)
 #define BSD_NBITS(x)	((x) & 0x1F)
diff -urN linux-2.2.21-pre1/drivers/isdn/isdn_common.c linux/drivers/isdn/isdn_common.c
--- linux-2.2.21-pre1/drivers/isdn/isdn_common.c	Fri Nov  2 08:39:07 2001
+++ linux/drivers/isdn/isdn_common.c	Wed Jan  2 03:55:23 2002
@@ -1,24 +1,13 @@
-/* $Id: isdn_common.c,v 1.114.6.12 2001/06/09 15:14:15 kai Exp $
-
+/* $Id: isdn_common.c,v 1.1.2.1 2001/12/31 13:26:34 kai Exp $
+ *
  * Linux ISDN subsystem, common used functions (linklevel).
  *
  * Copyright 1994-1999  by Fritz Elfert (fritz@isdn4linux.de)
  * Copyright 1995,96    Thinking Objects Software GmbH Wuerzburg
  * Copyright 1995,96    by Michael Hipp (Michael.Hipp@student.uni-tuebingen.de)
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
@@ -48,9 +37,13 @@
 /* Debugflags */
 #undef ISDN_DEBUG_STATCALLB
 
+MODULE_DESCRIPTION("ISDN4Linux: link layer");
+MODULE_AUTHOR("Fritz Elfert");
+MODULE_LICENSE("GPL");
+
 isdn_dev *dev;
 
-static char *isdn_revision = "$Revision: 1.114.6.12 $";
+static char *isdn_revision = "$Revision: 1.1.2.1 $";
 
 extern char *isdn_net_revision;
 extern char *isdn_tty_revision;
@@ -277,7 +270,7 @@
 	}
 	if (tf) 
 	{
-		int flags;
+		unsigned long flags;
 
 		save_flags(flags);
 		cli();
@@ -289,7 +282,8 @@
 void
 isdn_timer_ctrl(int tf, int onoff)
 {
-	int flags, old_tflags;
+	unsigned long flags;
+	int old_tflags;
 
 	save_flags(flags);
 	cli();
@@ -1644,7 +1638,7 @@
 	if (minor == ISDN_MINOR_STATUS) {
 		infostruct *p;
 
-		if ((p = (infostruct *) kmalloc(sizeof(infostruct), GFP_KERNEL))) {
+		if ((p = kmalloc(sizeof(infostruct), GFP_KERNEL))) {
 			p->next = (char *) dev->infochain;
 			p->private = (char *) &(filep->private_data);
 			dev->infochain = p;
@@ -1996,7 +1990,7 @@
 
 	if ((adding) && (d->rcverr))
 		kfree(d->rcverr);
-	if (!(d->rcverr = (int *) kmalloc(sizeof(int) * m, GFP_KERNEL))) {
+	if (!(d->rcverr = kmalloc(sizeof(int) * m, GFP_KERNEL))) {
 		printk(KERN_WARNING "register_isdn: Could not alloc rcverr\n");
 		return -1;
 	}
@@ -2004,7 +1998,7 @@
 
 	if ((adding) && (d->rcvcount))
 		kfree(d->rcvcount);
-	if (!(d->rcvcount = (int *) kmalloc(sizeof(int) * m, GFP_KERNEL))) {
+	if (!(d->rcvcount = kmalloc(sizeof(int) * m, GFP_KERNEL))) {
 		printk(KERN_WARNING "register_isdn: Could not alloc rcvcount\n");
 		if (!adding) kfree(d->rcverr);
 		return -1;
@@ -2016,8 +2010,7 @@
 			skb_queue_purge(&d->rpqueue[j]);
 		kfree(d->rpqueue);
 	}
-	if (!(d->rpqueue =
-	      (struct sk_buff_head *) kmalloc(sizeof(struct sk_buff_head) * m, GFP_KERNEL))) {
+	if (!(d->rpqueue = kmalloc(sizeof(struct sk_buff_head) * m, GFP_KERNEL))) {
 		printk(KERN_WARNING "register_isdn: Could not alloc rpqueue\n");
 		if (!adding) {
 			kfree(d->rcvcount);
@@ -2031,8 +2024,7 @@
 
 	if ((adding) && (d->rcv_waitq))
 		kfree(d->rcv_waitq);
-	d->rcv_waitq = (wait_queue_head_t *)
-		kmalloc(sizeof(wait_queue_head_t) * 2 * m, GFP_KERNEL);
+	d->rcv_waitq = kmalloc(sizeof(wait_queue_head_t) * 2 * m, GFP_KERNEL);
 	if (!d->rcv_waitq) {
 		printk(KERN_WARNING "register_isdn: Could not alloc rcv_waitq\n");
 		if (!adding) {
@@ -2156,7 +2148,7 @@
 		printk(KERN_WARNING "register_isdn: No write routine given.\n");
 		return 0;
 	}
-	if (!(d = (driver *) kmalloc(sizeof(driver), GFP_KERNEL))) {
+	if (!(d = kmalloc(sizeof(driver), GFP_KERNEL))) {
 		printk(KERN_WARNING "register_isdn: Could not alloc driver-struct\n");
 		return 0;
 	}
@@ -2297,7 +2289,7 @@
  */
 static void  isdn_exit(void)
 {
-	int flags;
+	unsigned long flags;
 	int i;
 
 #ifdef CONFIG_ISDN_PPP
diff -urN linux-2.2.21-pre1/drivers/isdn/isdn_common.h linux/drivers/isdn/isdn_common.h
--- linux-2.2.21-pre1/drivers/isdn/isdn_common.h	Sun Mar 25 08:37:33 2001
+++ linux/drivers/isdn/isdn_common.h	Wed Jan  2 03:55:23 2002
@@ -1,24 +1,14 @@
-/* $Id: isdn_common.h,v 1.21 2000/11/25 17:00:59 kai Exp $
-
- * header for Linux ISDN subsystem, common used functions and debugging-switches (linklevel).
+/* $Id: isdn_common.h,v 1.1.2.1 2001/12/31 13:26:34 kai Exp $
+ *
+ * header for Linux ISDN subsystem
+ * common used functions and debugging-switches (linklevel).
  *
  * Copyright 1994-1999  by Fritz Elfert (fritz@isdn4linux.de)
  * Copyright 1995,96    by Thinking Objects Software GmbH Wuerzburg
  * Copyright 1995,96    by Michael Hipp (Michael.Hipp@student.uni-tuebingen.de)
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
diff -urN linux-2.2.21-pre1/drivers/isdn/isdn_concap.c linux/drivers/isdn/isdn_concap.c
--- linux-2.2.21-pre1/drivers/isdn/isdn_concap.c	Sun Mar 25 08:37:33 2001
+++ linux/drivers/isdn/isdn_concap.c	Wed Jan  2 03:55:23 2002
@@ -1,20 +1,9 @@
-/* $Id: isdn_concap.c,v 1.8 2000/05/11 22:29:20 kai Exp $
- 
+/* $Id: isdn_concap.c,v 1.1.2.1 2001/12/31 13:26:34 kai Exp $
+ * 
  * Linux ISDN subsystem, protocol encapsulation
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
diff -urN linux-2.2.21-pre1/drivers/isdn/isdn_concap.h linux/drivers/isdn/isdn_concap.h
--- linux-2.2.21-pre1/drivers/isdn/isdn_concap.h	Sun Mar 25 08:31:38 2001
+++ linux/drivers/isdn/isdn_concap.h	Wed Jan  2 03:55:23 2002
@@ -1,20 +1,9 @@
-/* $Id: isdn_concap.h,v 1.3 2000/05/11 22:29:20 kai Exp $
+/* $Id: isdn_concap.h,v 1.1.2.1 2001/12/31 13:26:34 kai Exp $
  *
  * Linux ISDN subsystem, protocol encapsulation
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
diff -urN linux-2.2.21-pre1/drivers/isdn/isdn_net.c linux/drivers/isdn/isdn_net.c
--- linux-2.2.21-pre1/drivers/isdn/isdn_net.c	Fri Nov  2 08:39:07 2001
+++ linux/drivers/isdn/isdn_net.c	Wed Jan  2 03:55:23 2002
@@ -1,35 +1,20 @@
-/* $Id: isdn_net.c,v 1.140.6.8 2001/08/14 14:04:21 kai Exp $
-
+/* $Id: isdn_net.c,v 1.1.2.1 2001/12/31 13:26:34 kai Exp $
+ *
  * Linux ISDN subsystem, network interfaces and related functions (linklevel).
  *
  * Copyright 1994-1998  by Fritz Elfert (fritz@isdn4linux.de)
  * Copyright 1995,96    by Thinking Objects Software GmbH Wuerzburg
  * Copyright 1995,96    by Michael Hipp (Michael.Hipp@student.uni-tuebingen.de)
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
- */
-
-/* Jan 2001: fix CISCO HDLC      Bjoern A. Zeeb <i4l@zabbadoz.net>
+ * Jan 2001: fix CISCO HDLC      Bjoern A. Zeeb <i4l@zabbadoz.net>
  *           for info on the protocol, see 
  *           http://i4l.zabbadoz.net/i4l/cisco-hdlc.txt
  */
 
 #include <linux/config.h>
-#define __NO_VERSION__
-#include <linux/module.h>
 #include <linux/isdn.h>
 #include <net/arp.h>
 #include <net/dst.h>
@@ -191,7 +176,7 @@
 static void isdn_net_ciscohdlck_connected(isdn_net_local *lp);
 static void isdn_net_ciscohdlck_disconnected(isdn_net_local *lp);
 
-char *isdn_net_revision = "$Revision: 1.140.6.8 $";
+char *isdn_net_revision = "$Revision: 1.1.2.1 $";
 
  /*
   * Code for raw-networking over ISDN
@@ -301,7 +286,7 @@
 static void
 isdn_net_unbind_channel(isdn_net_local * lp)
 {
-	ulong flags;
+	unsigned long flags;
 
 	save_flags(flags);
 	cli();
@@ -349,7 +334,7 @@
 	anymore = 0;
 	while (p) {
 		isdn_net_local *l = p->local;
-		if ((jiffies - last_jiffies) == 0)
+		if (jiffies == last_jiffies)
 			l->cps = l->transcount;
 		else
 			l->cps = (l->transcount * HZ) / (jiffies - last_jiffies);
@@ -368,9 +353,9 @@
 			{
 				if (l->hupflags & ISDN_MANCHARGE &&
 				    l->hupflags & ISDN_CHARGEHUP) {
-					while (jiffies - l->chargetime > l->chargeint)
+					while (time_after(jiffies, l->chargetime + l->chargeint))
 						l->chargetime += l->chargeint;
-					if (jiffies - l->chargetime >= l->chargeint - 2 * HZ)
+					if (time_after(jiffies, l->chargetime + l->chargeint - 2 * HZ))
 						if (l->outgoing || l->hupflags & ISDN_INHUP)
 							isdn_net_hangup(&p->dev);
 				} else if (l->outgoing) {
@@ -379,7 +364,7 @@
 							printk(KERN_DEBUG "isdn_net: Hupflags of %s are %X\n",
 							       l->name, l->hupflags);
 							isdn_net_hangup(&p->dev);
-						} else if (jiffies - l->chargetime > l->chargeint) {
+						} else if (time_after(jiffies, l->chargetime + l->chargeint)) {
 							printk(KERN_DEBUG
 							       "isdn_net: %s: chtime = %lu, chint = %d\n",
 							       l->name, l->chargetime, l->chargeint);
@@ -584,7 +569,7 @@
 	isdn_net_dev *p = dev->netdev;
 	int anymore = 0;
 	int i;
-	int flags;
+	unsigned long flags;
 	isdn_ctrl cmd;
 
 	while (p) {
@@ -615,7 +600,7 @@
 				anymore = 1;
 
 				if(lp->dialtimeout > 0)
-					if(lp->dialstarted == 0 || jiffies > (lp->dialstarted + lp->dialtimeout + lp->dialwait)) {
+					if(lp->dialstarted == 0 || time_after(jiffies, lp->dialstarted + lp->dialtimeout + lp->dialwait)) {
 						lp->dialstarted = jiffies;
 						lp->dialwait_timer = 0;
 					}
@@ -675,7 +660,7 @@
 					printk(KERN_INFO "%s: Open leased line ...\n", lp->name);
 				} else {
 					if(lp->dialtimeout > 0)
-						if(jiffies > (lp->dialstarted + lp->dialtimeout)) {
+						if (time_after(jiffies, lp->dialstarted + lp->dialtimeout)) {
 							restore_flags(flags);
 							lp->dialwait_timer = jiffies + lp->dialwait;
 							lp->dialstarted = 0;
@@ -1117,7 +1102,7 @@
 				lp->sqfull_stamp = jiffies;
 			} else {
 				/* subsequent overload: if slavedelay exceeded, start dialing */
-				if ((jiffies - lp->sqfull_stamp) > lp->slavedelay) {
+				if (time_after(jiffies, lp->sqfull_stamp + lp->slavedelay)) {
 					slp = lp->slave->priv;
 					if (!(slp->flags & ISDN_NET_CONNECTED)) {
 						isdn_net_force_dial_lp((isdn_net_local *) lp->slave->priv);
@@ -1126,7 +1111,7 @@
 			}
 		}
 	} else {
-		if (lp->sqfull && ((jiffies - lp->sqfull_stamp) > (lp->slavedelay + (10 * HZ)))) {
+		if (lp->sqfull && time_after(jiffies, lp->sqfull_stamp + lp->slavedelay + (10 * HZ))) {
 			lp->sqfull = 0;
 		}
 		/* this is a hack to allow auto-hangup for slaves on moderate loads */
@@ -1227,11 +1212,11 @@
 				cli();
 
 				if(lp->dialwait_timer <= 0)
-					if(lp->dialstarted > 0 && lp->dialtimeout > 0 && jiffies < lp->dialstarted + lp->dialtimeout + lp->dialwait)
+					if(lp->dialstarted > 0 && lp->dialtimeout > 0 && time_before(jiffies, lp->dialstarted + lp->dialtimeout + lp->dialwait))
 						lp->dialwait_timer = lp->dialstarted + lp->dialtimeout + lp->dialwait;
 
 				if(lp->dialwait_timer > 0) {
-					if(jiffies < lp->dialwait_timer) {
+					if(time_before(jiffies, lp->dialwait_timer)) {
 						isdn_net_unreachable(ndev, skb, "dial rejected: retry-time not reached");
 						dev_kfree_skb(skb);
 						restore_flags(flags);
@@ -2775,7 +2760,7 @@
 			chidx = lp->pre_channel;
 		}
 		if (cfg->exclusive > 0) {
-			int flags;
+			unsigned long flags;
 
 			/* If binding is exclusive, try to grab the channel */
 			save_flags(flags);
@@ -3031,7 +3016,7 @@
 	int inout = phone->outgoing & 1;
 	isdn_net_phone *n;
 	isdn_net_phone *m;
-	int flags;
+	unsigned long flags;
 
 	if (p) {
 		save_flags(flags);
@@ -3067,7 +3052,7 @@
 {
 	isdn_net_phone *n;
 	isdn_net_phone *m;
-	int flags;
+	unsigned long flags;
 	int i;
 
 	save_flags(flags);
@@ -3116,7 +3101,7 @@
 static int
 isdn_net_realrm(isdn_net_dev * p, isdn_net_dev * q)
 {
-	int flags;
+	unsigned long flags;
 
 	save_flags(flags);
 	cli();
@@ -3202,7 +3187,7 @@
 int
 isdn_net_rmall(void)
 {
-	int flags;
+	unsigned long flags;
 	int ret;
 
 	/* Walk through netdev-chain */
diff -urN linux-2.2.21-pre1/drivers/isdn/isdn_net.h linux/drivers/isdn/isdn_net.h
--- linux-2.2.21-pre1/drivers/isdn/isdn_net.h	Fri Nov  2 08:39:07 2001
+++ linux/drivers/isdn/isdn_net.h	Wed Jan  2 03:55:23 2002
@@ -1,24 +1,13 @@
-/* $Id: isdn_net.h,v 1.19.6.2 2001/08/14 14:04:21 kai Exp $
-
+/* $Id: isdn_net.h,v 1.1.2.1 2001/12/31 13:26:34 kai Exp $
+ *
  * header for Linux ISDN subsystem, network related functions (linklevel).
  *
  * Copyright 1994-1999  by Fritz Elfert (fritz@isdn4linux.de)
  * Copyright 1995,96    by Thinking Objects Software GmbH Wuerzburg
  * Copyright 1995,96    by Michael Hipp (Michael.Hipp@student.uni-tuebingen.de)
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
diff -urN linux-2.2.21-pre1/drivers/isdn/isdn_ppp.c linux/drivers/isdn/isdn_ppp.c
--- linux-2.2.21-pre1/drivers/isdn/isdn_ppp.c	Fri Nov  2 08:39:07 2001
+++ linux/drivers/isdn/isdn_ppp.c	Wed Jan  2 03:55:23 2002
@@ -1,31 +1,17 @@
-/* $Id: isdn_ppp.c,v 1.85.6.6 2001/07/27 09:08:27 kai Exp $
+/* $Id: isdn_ppp.c,v 1.1.2.1 2001/12/31 13:26:34 kai Exp $
  *
  * Linux ISDN subsystem, functions for synchronous PPP (linklevel).
  *
  * Copyright 1995,96 by Michael Hipp (Michael.Hipp@student.uni-tuebingen.de)
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
 #include <linux/config.h>
-#define __NO_VERSION__
-#include <linux/module.h>
-#include <linux/version.h>
-#include <linux/poll.h>
 #include <linux/isdn.h>
+#include <linux/poll.h>
 #include <linux/isdn_compat.h>
 #include <linux/ppp-comp.h>
 
@@ -84,7 +70,7 @@
 static int isdn_ppp_bundle(struct ippp_struct *, int unit);
 #endif	/* CONFIG_ISDN_MPP */
   
-char *isdn_ppp_revision = "$Revision: 1.85.6.6 $";
+char *isdn_ppp_revision = "$Revision: 1.1.2.1 $";
 
 static struct ippp_struct *ippp_table[ISDN_MAX_CHANNELS];
 
@@ -992,7 +978,7 @@
 		printk(KERN_DEBUG "push, skb %d %04x\n", (int) skb->len, proto);
 		isdn_ppp_frame_log("rpush", skb->data, skb->len, 32,is->unit,lp->ppp_slot);
 	}
-	if (is->compflags & SC_DECOMP_ON) {
+	if (mis->compflags & SC_DECOMP_ON) {
 		skb = isdn_ppp_decompress(skb, is, mis, &proto);
 		if (!skb) // decompression error
   			return;
@@ -1008,6 +994,10 @@
 				printk(KERN_DEBUG "isdn_ppp: IP\n");
 			skb->protocol = htons(ETH_P_IP);
 			break;
+		case PPP_COMP:
+		case PPP_COMPFRAG:
+			printk(KERN_INFO "isdn_ppp: unexpected compressed frame dropped\n");
+			goto drop_packet;
 #ifdef CONFIG_ISDN_PPP_VJ
 		case PPP_VJC_UNCOMP:
 			if (is->debug & 0x20)
@@ -1231,8 +1221,15 @@
 	/*
 	 * normal (single link) or bundle compression
 	 */
-	if(ipts->compflags & SC_COMP_ON)
-		skb = isdn_ppp_compress(skb,&proto,ipt,ipts,0);
+	if(ipts->compflags & SC_COMP_ON) {
+		/* We send compressed only if both down- und upstream
+		   compression is negotiated, that means, CCP is up */
+		if(ipts->compflags & SC_DECOMP_ON) {
+			skb = isdn_ppp_compress(skb,&proto,ipt,ipts,0);
+		} else {
+			printk(KERN_DEBUG "isdn_ppp: CCP not yet up - sending as-is\n");
+		}
+	}
 
 	if (ipt->debug & 0x24)
 		printk(KERN_DEBUG "xmit2 skb, len %d, proto %04x\n", (int) skb->len, proto);
@@ -2096,8 +2093,6 @@
 	}
 	if(rs->ta && rs->state == CCPResetSentReq) {
 		/* We are correct here */
-		printk(KERN_DEBUG "ippp_ccp: CCP Reset timed out for id %d\n",
-		       rs->id);
 		if(!rs->expra) {
 			/* Hmm, there is no Ack really expected. We can clean
 			   up the state now, it will be reallocated if the
@@ -2106,6 +2101,8 @@
 			isdn_ppp_ccp_reset_free_state(rs->is, rs->id);
 			return;
 		}
+		printk(KERN_DEBUG "ippp_ccp: CCP Reset timed out for id %d\n",
+		       rs->id);
 		/* Push it again */
 		isdn_ppp_ccp_xmit_reset(rs->is, PPP_CCP, CCP_RESETREQ, rs->id,
 					rs->data, rs->dlen);
@@ -2332,7 +2329,6 @@
 		if (len <= 0) {
 			switch(len) {
 			case DECOMP_ERROR:
-				ri->pppcfg |= SC_DC_ERROR;
 				printk(KERN_INFO "ippp: decomp wants reset %s params\n",
 				       rsparm.valid ? "with" : "without");
 				
@@ -2467,10 +2463,15 @@
 		/* if we RECEIVE an ackowledge we enable the decompressor */
 		if(is->debug & 0x10)
 			printk(KERN_DEBUG "Enable decompression here!\n");
-		if(proto == PPP_CCP)
+		if(proto == PPP_CCP) {
+			if (!mis->decompressor)
+				break;
 			mis->compflags |= SC_DECOMP_ON;
-		else
+		} else {
+			if (!is->decompressor)
+				break;
 			is->compflags |= SC_LINK_DECOMP_ON;
+		}
 		break;
 
 	case CCP_RESETACK:
@@ -2491,7 +2492,6 @@
 					      len, NULL);
 			/* TODO: This is not easy to decide here */
 			mis->compflags &= ~SC_DECOMP_DISCARD;
-			mis->pppcfg &= ~SC_DC_ERROR;
 		}
 		else {
 			isdn_ppp_ccp_reset_ack_rcvd(is, skb->data[1]);
@@ -2504,7 +2504,6 @@
 					      len, NULL);
 			/* TODO: neither here */
 			is->compflags &= ~SC_LINK_DECOMP_DISCARD;
-			is->pppcfg &= ~SC_DC_ERROR;
 		}
 		break;
 
@@ -2579,6 +2578,15 @@
  * that's too big of a change now. --kai
  */
 
+/* Actually, we might turn this into an advantage: deal with the RFC in
+ * the old tradition of beeing generous on what we accept, but beeing
+ * strict on what we send. Thus we should just
+ * - accept compressed frames as soon as decompression is negotiated
+ * - send compressed frames only when decomp *and* comp are negotiated
+ * - drop rx compressed frames if we cannot decomp (instead of pushing them
+ *   up to ipppd)
+ * and I tried to modify this file according to that. --abp
+ */
 
 static void isdn_ppp_send_ccp(isdn_net_dev *net_dev, isdn_net_local *lp, struct sk_buff *skb)
 {
@@ -2634,10 +2642,15 @@
 		/* if we SEND an ackowledge we can/must enable the compressor */
 		if(is->debug & 0x10)
 			printk(KERN_DEBUG "Enable compression here!\n");
-		if(proto == PPP_CCP)
+		if(proto == PPP_CCP) {
+			if (!is->compressor)
+				break;
 			is->compflags |= SC_COMP_ON;
-		else
+		} else {
+			if (!is->compressor)
+				break;
 			is->compflags |= SC_LINK_COMP_ON;
+		}
 		break;
 	case CCP_RESETACK:
 		/* If we send a ACK we should reset our compressor */
diff -urN linux-2.2.21-pre1/drivers/isdn/isdn_ppp.h linux/drivers/isdn/isdn_ppp.h
--- linux-2.2.21-pre1/drivers/isdn/isdn_ppp.h	Sun Mar 25 08:31:37 2001
+++ linux/drivers/isdn/isdn_ppp.h	Wed Jan  2 03:55:23 2002
@@ -1,27 +1,17 @@
-/* $Id: isdn_ppp.h,v 1.17 2000/08/10 22:52:46 kai Exp $
-
+/* $Id: isdn_ppp.h,v 1.1.2.1 2001/12/31 13:26:34 kai Exp $
+ *
  * header for Linux ISDN subsystem, functions for synchronous PPP (linklevel).
  *
  * Copyright 1995,96 by Michael Hipp (Michael.Hipp@student.uni-tuebingen.de)
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
 #include <linux/ppp_defs.h>     /* for PPP_PROTOCOL */
 #include <linux/isdn_ppp.h>	/* for isdn_ppp info */
+
 extern int isdn_ppp_read(int, struct file *, char *, int);
 extern int isdn_ppp_write(int, struct file *, const char *, int);
 extern int isdn_ppp_open(int, struct file *);
diff -urN linux-2.2.21-pre1/drivers/isdn/isdn_syms.c linux/drivers/isdn/isdn_syms.c
--- linux-2.2.21-pre1/drivers/isdn/isdn_syms.c	Sun Mar 25 08:31:38 2001
+++ linux/drivers/isdn/isdn_syms.c	Wed Dec 31 16:00:00 1969
@@ -1,114 +0,0 @@
-/* $Id: isdn_syms.c,v 1.3.2.1 1999/04/22 21:09:37 werner Exp $
-
- * Linux ISDN subsystem, exported symbols (linklevel).
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
- *
- * $Log: isdn_syms.c,v $
- * Revision 1.3.2.1  1999/04/22 21:09:37  werner
- * Added support for dss1 diversion services
- *
- * Revision 1.3  1997/02/16 01:02:47  fritz
- * Added GPL-Header, Id and Log
- *
- */
-#include <linux/config.h>
-#include <linux/module.h>
-#include <linux/version.h>
-
-#ifndef __GENKSYMS__      /* Don't want genksyms report unneeded structs */
-#include <linux/isdn.h>
-#endif
-#include "isdn_common.h"
-#ifdef CONFIG_ISDN_DIVERSION
-  #include <linux/isdn_divertif.h>
-extern isdn_divert_if *divert_if;
-
-static char *map_drvname(int di)
-{
-  if ((di < 0) || (di >= ISDN_MAX_DRIVERS)) 
-    return(NULL);
-  return(dev->drvid[di]); /* driver name */
-} /* map_drvname */
-
-static int map_namedrv(char *id)
-{  int i;
-
-   for (i = 0; i < ISDN_MAX_DRIVERS; i++)
-    { if (!strcmp(dev->drvid[i],id)) 
-        return(i);
-    }
-   return(-1);
-} /* map_namedrv */
-
-int DIVERT_REG_NAME(isdn_divert_if *i_div)
-{
-  if (i_div->if_magic != DIVERT_IF_MAGIC) 
-    return(DIVERT_VER_ERR);
-  switch (i_div->cmd)
-    {
-      case DIVERT_CMD_REL:
-        if (divert_if != i_div) 
-          return(DIVERT_REL_ERR);
-        divert_if = NULL; /* free interface */
-        MOD_DEC_USE_COUNT;
-        return(DIVERT_NO_ERR);
-
-      case DIVERT_CMD_REG:
-        if (divert_if) 
-          return(DIVERT_REG_ERR);
-        i_div->ll_cmd = isdn_command; /* set command function */
-        i_div->drv_to_name = map_drvname; 
-        i_div->name_to_drv = map_namedrv; 
-        MOD_INC_USE_COUNT;
-        divert_if = i_div; /* remember interface */
-        return(DIVERT_NO_ERR);
-
-      default:
-        return(DIVERT_CMD_ERR);   
-    }
-} /* DIVERT_REG_NAME */
-
-#endif CONFIG_ISDN_DIVERSION
-
-#if (LINUX_VERSION_CODE < 0x020111)
-static int has_exported;
-
-static struct symbol_table isdn_syms = {
-#include <linux/symtab_begin.h>
-        X(register_isdn),
-#ifdef CONFIG_ISDN_DIVERSION
-        X(DIVERT_REG_NAME),
-#endif CONFIG_ISDN_DIVERSION
-#include <linux/symtab_end.h>
-};
-
-void
-isdn_export_syms(void)
-{
-	if (has_exported)
-		return;
-        register_symtab(&isdn_syms);
-        has_exported = 1;
-}
-
-#else
-
-EXPORT_SYMBOL(register_isdn);
-#ifdef CONFIG_ISDN_DIVERSION
-  EXPORT(DIVERT_REG_NAME);
-#endif CONFIG_ISDN_DIVERSION
-
-#endif
diff -urN linux-2.2.21-pre1/drivers/isdn/isdn_tty.c linux/drivers/isdn/isdn_tty.c
--- linux-2.2.21-pre1/drivers/isdn/isdn_tty.c	Fri Nov  2 08:39:07 2001
+++ linux/drivers/isdn/isdn_tty.c	Wed Jan  2 03:55:23 2002
@@ -1,30 +1,17 @@
-/* $Id: isdn_tty.c,v 1.94.6.5 2001/08/14 14:12:18 kai Exp $
-
+/* $Id: isdn_tty.c,v 1.1.2.1 2001/12/31 13:26:34 kai Exp $
+ *
  * Linux ISDN subsystem, tty functions and AT-command emulator (linklevel).
  *
  * Copyright 1994-1999  by Fritz Elfert (fritz@isdn4linux.de)
  * Copyright 1995,96    by Thinking Objects Software GmbH Wuerzburg
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 #undef ISDN_TTY_STAT_DEBUG
 
-#define __NO_VERSION__
 #include <linux/config.h>
-#include <linux/module.h>
 #include <linux/isdn.h>
 #include "isdn_common.h"
 #include "isdn_tty.h"
@@ -66,7 +53,7 @@
 static int si2bit[8] =
 {4, 1, 4, 4, 4, 4, 4, 4};
 
-char *isdn_tty_revision = "$Revision: 1.94.6.5 $";
+char *isdn_tty_revision = "$Revision: 1.1.2.1 $";
 
 
 /* isdn_tty_try_read() is called from within isdn_tty_rcv_skb()
@@ -2598,11 +2585,11 @@
 		if (*(p++) == plus) {
 			if ((*pluscount)++) {
 				/* Time since last '+' > 0.5 sec. ? */
-				if ((jiffies - *lastplus) > PLUSWAIT1)
+				if (time_after(jiffies, *lastplus + PLUSWAIT1))
 					*pluscount = 1;
 			} else {
 				/* Time since last non-'+' < 1.5 sec. ? */
-				if ((jiffies - *lastplus) < PLUSWAIT2)
+				if (time_before(jiffies, *lastplus + PLUSWAIT2))
 					*pluscount = 0;
 			}
 			if ((*pluscount == 3) && (count == 1))
@@ -3976,7 +3963,7 @@
 				if (info->online) {
 					ton = 1;
 					if ((info->emu.pluscount == 3) &&
-					    ((jiffies - info->emu.lastplus) > PLUSWAIT2)) {
+					    time_after(jiffies , info->emu.lastplus + PLUSWAIT2)) {
 						info->emu.pluscount = 0;
 						info->online = 0;
 						isdn_tty_modem_result(RESULT_OK, info);
diff -urN linux-2.2.21-pre1/drivers/isdn/isdn_tty.h linux/drivers/isdn/isdn_tty.h
--- linux-2.2.21-pre1/drivers/isdn/isdn_tty.h	Fri Nov  2 08:39:07 2001
+++ linux/drivers/isdn/isdn_tty.h	Wed Jan  2 03:55:23 2002
@@ -1,23 +1,12 @@
-/* $Id: isdn_tty.h,v 1.22.6.1 2001/08/14 14:12:18 kai Exp $
-
+/* $Id: isdn_tty.h,v 1.1.2.1 2001/12/31 13:26:34 kai Exp $
+ *
  * header for Linux ISDN subsystem, tty related functions (linklevel).
  *
  * Copyright 1994-1999  by Fritz Elfert (fritz@isdn4linux.de)
  * Copyright 1995,96    by Thinking Objects Software GmbH Wuerzburg
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
diff -urN linux-2.2.21-pre1/drivers/isdn/isdn_ttyfax.c linux/drivers/isdn/isdn_ttyfax.c
--- linux-2.2.21-pre1/drivers/isdn/isdn_ttyfax.c	Fri Nov  2 08:39:07 2001
+++ linux/drivers/isdn/isdn_ttyfax.c	Wed Jan  2 03:55:23 2002
@@ -1,39 +1,26 @@
-/* $Id: isdn_ttyfax.c,v 1.7.6.1 2001/08/14 14:12:18 kai Exp $
-
+/* $Id: isdn_ttyfax.c,v 1.1.2.1 2001/12/31 13:26:34 kai Exp $
+ *
  * Linux ISDN subsystem, tty_fax AT-command emulator (linklevel).
  *
  * Copyright 1999    by Armin Schindler (mac@melware.de)
  * Copyright 1999    by Ralf Spachmann (mel@melware.de)
  * Copyright 1999    by Cytronics & Melware
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
 #undef ISDN_TTY_FAX_STAT_DEBUG
 #undef ISDN_TTY_FAX_CMD_DEBUG
 
-#define __NO_VERSION__
-#include <linux/module.h>
 #include <linux/isdn.h>
 #include "isdn_common.h"
 #include "isdn_tty.h"
 #include "isdn_ttyfax.h"
 
 
-static char *isdn_tty_fax_revision = "$Revision: 1.7.6.1 $";
+static char *isdn_tty_fax_revision = "$Revision: 1.1.2.1 $";
 
 #define PARSE_ERROR1 { isdn_tty_fax_modem_result(1, info); return 1; }
 
diff -urN linux-2.2.21-pre1/drivers/isdn/isdn_ttyfax.h linux/drivers/isdn/isdn_ttyfax.h
--- linux-2.2.21-pre1/drivers/isdn/isdn_ttyfax.h	Sun Mar 25 08:31:38 2001
+++ linux/drivers/isdn/isdn_ttyfax.h	Wed Jan  2 03:55:23 2002
@@ -1,24 +1,13 @@
-/* $Id: isdn_ttyfax.h,v 1.2 2000/05/11 22:29:21 kai Exp $
-
+/* $Id: isdn_ttyfax.h,v 1.1.2.1 2001/12/31 13:26:34 kai Exp $
+ *
  * header for Linux ISDN subsystem, tty_fax related functions (linklevel).
  *
  * Copyright 1999   by Armin Schindler (mac@melware.de)
  * Copyright 1999   by Ralf Spachmann (mel@melware.de)
  * Copyright 1999   by Cytronics & Melware
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
diff -urN linux-2.2.21-pre1/drivers/isdn/isdn_v110.c linux/drivers/isdn/isdn_v110.c
--- linux-2.2.21-pre1/drivers/isdn/isdn_v110.c	Fri Nov  2 08:39:07 2001
+++ linux/drivers/isdn/isdn_v110.c	Wed Jan  2 03:55:23 2002
@@ -1,22 +1,11 @@
-/* $Id: isdn_v110.c,v 1.5.6.3 2001/02/16 16:43:23 kai Exp $
-
+/* $Id: isdn_v110.c,v 1.1.2.1 2001/12/31 13:26:34 kai Exp $
+ *
  * Linux ISDN subsystem, V.110 related functions (linklevel).
  *
  * Copyright by Thomas Pfeiffer (pfeiffer@pds.de)
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
@@ -30,7 +19,7 @@
 
 #undef ISDN_V110_DEBUG
 
-char *isdn_v110_revision = "$Revision: 1.5.6.3 $";
+char *isdn_v110_revision = "$Revision: 1.1.2.1 $";
 
 #define V110_38400 255
 #define V110_19200  15
diff -urN linux-2.2.21-pre1/drivers/isdn/isdn_v110.h linux/drivers/isdn/isdn_v110.h
--- linux-2.2.21-pre1/drivers/isdn/isdn_v110.h	Sun Mar 25 08:31:38 2001
+++ linux/drivers/isdn/isdn_v110.h	Wed Jan  2 03:55:23 2002
@@ -1,24 +1,14 @@
-/* $Id: isdn_v110.h,v 1.4 2000/05/11 22:29:21 kai Exp $
-
+/* $Id: isdn_v110.h,v 1.1.2.1 2001/12/31 13:26:34 kai Exp $
+ *
  * Linux ISDN subsystem, V.110 related functions (linklevel).
  *
  * Copyright by Thomas Pfeiffer (pfeiffer@pds.de)
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
+
 #ifndef _isdn_v110_h_
 #define _isdn_v110_h_
 
diff -urN linux-2.2.21-pre1/drivers/isdn/isdn_x25iface.c linux/drivers/isdn/isdn_x25iface.c
--- linux-2.2.21-pre1/drivers/isdn/isdn_x25iface.c	Sun Mar 25 08:31:38 2001
+++ linux/drivers/isdn/isdn_x25iface.c	Wed Jan  2 03:55:23 2002
@@ -1,22 +1,9 @@
-/* $Id: isdn_x25iface.c,v 1.9 2000/05/16 20:52:10 keil Exp $
-
+/* $Id: isdn_x25iface.c,v 1.1.2.1 2001/12/31 13:26:34 kai Exp $
  *
  * Linux ISDN subsystem, X.25 related functions
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
- *
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  * stuff needed to support the Linux X.25 PLP code on top of devices that
  * can provide a lab_b service using the concap_proto mechanism.
diff -urN linux-2.2.21-pre1/drivers/isdn/isdn_x25iface.h linux/drivers/isdn/isdn_x25iface.h
--- linux-2.2.21-pre1/drivers/isdn/isdn_x25iface.h	Sun Mar 25 08:31:38 2001
+++ linux/drivers/isdn/isdn_x25iface.h	Wed Jan  2 03:55:23 2002
@@ -1,20 +1,9 @@
-/* $Id: isdn_x25iface.h,v 1.3 2000/05/11 22:29:21 kai Exp $
-
- * header for Linux ISDN subsystem, x.25 related functions
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
+/* $Id: isdn_x25iface.h,v 1.1.2.1 2001/12/31 13:26:34 kai Exp $
  *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
+ * header for Linux ISDN subsystem, x.25 related functions
  *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
diff -urN linux-2.2.21-pre1/drivers/isdn/isdnloop/isdnloop.c linux/drivers/isdn/isdnloop/isdnloop.c
--- linux-2.2.21-pre1/drivers/isdn/isdnloop/isdnloop.c	Fri Nov  2 08:39:07 2001
+++ linux/drivers/isdn/isdnloop/isdnloop.c	Wed Jan  2 03:55:23 2002
@@ -1,22 +1,11 @@
-/* $Id: isdnloop.c,v 1.11.6.3 2001/06/09 15:14:19 kai Exp $
-
+/* $Id: isdnloop.c,v 1.1.2.1 2001/12/31 13:26:47 kai Exp $
+ *
  * ISDN low-level module implementing a dummy loop driver.
  *
  * Copyright 1997 by Fritz Elfert (fritz@isdn4linux.de)
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
@@ -25,8 +14,14 @@
 #include <linux/init.h>
 #include "isdnloop.h"
 
-static char
-*revision = "$Revision: 1.11.6.3 $";
+static char *revision = "$Revision: 1.1.2.1 $";
+static char *isdnloop_id;
+
+MODULE_DESCRIPTION("ISDN4Linux: Pseudo Driver that simulates an ISDN card");
+MODULE_AUTHOR("Fritz Elfert");
+MODULE_LICENSE("GPL");
+MODULE_PARM(isdnloop_id, "s");
+MODULE_PARM_DESC(isdnloop_id, "ID-String of first card");
 
 static int isdnloop_addcard(char *);
 
diff -urN linux-2.2.21-pre1/drivers/isdn/isdnloop/isdnloop.h linux/drivers/isdn/isdnloop/isdnloop.h
--- linux-2.2.21-pre1/drivers/isdn/isdnloop/isdnloop.h	Sun Mar 25 08:37:34 2001
+++ linux/drivers/isdn/isdnloop/isdnloop.h	Wed Jan  2 03:55:23 2002
@@ -1,22 +1,11 @@
-/* $Id: isdnloop.h,v 1.5.6.1 2001/02/10 14:41:23 kai Exp $
-
+/* $Id: isdnloop.h,v 1.1.2.1 2001/12/31 13:26:47 kai Exp $
+ *
  * Loopback lowlevel module for testing of linklevel.
  *
  * Copyright 1997 by Fritz Elfert (fritz@isdn4linux.de)
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
@@ -44,7 +33,6 @@
 #ifdef __KERNEL__
 /* Kernel includes */
 
-#include <linux/module.h>
 #include <linux/version.h>
 #include <linux/errno.h>
 #include <linux/fs.h>
@@ -115,14 +103,6 @@
  */
 #ifdef __KERNEL__
 static isdnloop_card *cards = (isdnloop_card *) 0;
-static char *isdnloop_id = "\0";
-
-#ifdef MODULE
-MODULE_AUTHOR("Fritz Elfert");
-MODULE_PARM(isdnloop_id, "s");
-MODULE_PARM_DESC(isdnloop_id, "ID-String of first card");
-#endif
-
 #endif                          /* __KERNEL__ */
 
 /* Utility-Macros */
diff -urN linux-2.2.21-pre1/drivers/isdn/pcbit/callbacks.c linux/drivers/isdn/pcbit/callbacks.c
--- linux-2.2.21-pre1/drivers/isdn/pcbit/callbacks.c	Fri Nov  2 08:39:07 2001
+++ linux/drivers/isdn/pcbit/callbacks.c	Wed Jan  2 03:55:23 2002
@@ -1,4 +1,6 @@
 /*
+ * Callbacks for the FSM
+ *
  * Copyright (C) 1996 Universidade de Lisboa
  * 
  * Written by Pedro Roque Marques (roque@di.fc.ul.pt)
@@ -7,20 +9,11 @@
  * the GNU General Public License, incorporated herein by reference.
  */
 
-/*        
- *        callbacks for the FSM
- */
-
 /*
  * Fix: 19981230 - Carlos Morgado <chbm@techie.com>
  * Port of Nelson Escravana's <nelson.escravana@usa.net> fix to CalledPN 
  * NULL pointer dereference in cb_in_1 (originally fixed in 2.0)
  */
-
-
-#define __NO_VERSION__
-
-#include <linux/module.h>
 
 #include <linux/sched.h>
 #include <linux/string.h>
diff -urN linux-2.2.21-pre1/drivers/isdn/pcbit/callbacks.h linux/drivers/isdn/pcbit/callbacks.h
--- linux-2.2.21-pre1/drivers/isdn/pcbit/callbacks.h	Fri Nov  2 08:39:07 2001
+++ linux/drivers/isdn/pcbit/callbacks.h	Wed Jan  2 03:55:23 2002
@@ -1,15 +1,12 @@
 /*
+ * Callbacks prototypes for FSM
+ *
  * Copyright (C) 1996 Universidade de Lisboa
  * 
  * Written by Pedro Roque Marques (roque@di.fc.ul.pt)
  *
  * This software may be used and distributed according to the terms of 
  * the GNU General Public License, incorporated herein by reference.
- */
-
-/*
- *        Callbacks prototypes for FSM
- *
  */
 
 #ifndef CALLBACKS_H
diff -urN linux-2.2.21-pre1/drivers/isdn/pcbit/capi.c linux/drivers/isdn/pcbit/capi.c
--- linux-2.2.21-pre1/drivers/isdn/pcbit/capi.c	Fri Nov  2 08:39:07 2001
+++ linux/drivers/isdn/pcbit/capi.c	Wed Jan  2 03:55:23 2002
@@ -1,17 +1,16 @@
 /*
+ * CAPI encoder/decoder for
+ * Portugal Telecom CAPI 2.0
+ *
  * Copyright (C) 1996 Universidade de Lisboa
  * 
  * Written by Pedro Roque Marques (roque@di.fc.ul.pt)
  *
  * This software may be used and distributed according to the terms of 
  * the GNU General Public License, incorporated herein by reference.
- */
-
-/*        
- *        CAPI encoder/decoder for
- *        Portugal Telecom CAPI 2.0
  *
- *        Not compatible with the AVM Gmbh. CAPI 2.0
+ * Not compatible with the AVM Gmbh. CAPI 2.0
+ *
  */
 
 /*
@@ -27,10 +26,6 @@
  *              for debug purposes mainly
  *              encode our number in CallerPN and ConnectedPN
  */
-
-#define __NO_VERSION__
-
-#include <linux/module.h>
 
 #include <linux/sched.h>
 #include <linux/string.h>
diff -urN linux-2.2.21-pre1/drivers/isdn/pcbit/capi.h linux/drivers/isdn/pcbit/capi.h
--- linux-2.2.21-pre1/drivers/isdn/pcbit/capi.h	Fri Nov  2 08:39:07 2001
+++ linux/drivers/isdn/pcbit/capi.h	Wed Jan  2 03:55:23 2002
@@ -1,14 +1,12 @@
 /*
+ * CAPI encode/decode prototypes and defines
+ *
  * Copyright (C) 1996 Universidade de Lisboa
  * 
  * Written by Pedro Roque Marques (roque@di.fc.ul.pt)
  *
  * This software may be used and distributed according to the terms of 
  * the GNU General Public License, incorporated herein by reference.
- */
-
-/*        
- *        CAPI encode/decode prototypes and defines
  */
 
 #ifndef CAPI_H
diff -urN linux-2.2.21-pre1/drivers/isdn/pcbit/drv.c linux/drivers/isdn/pcbit/drv.c
--- linux-2.2.21-pre1/drivers/isdn/pcbit/drv.c	Fri Nov  2 08:39:07 2001
+++ linux/drivers/isdn/pcbit/drv.c	Wed Jan  2 03:55:23 2002
@@ -1,14 +1,12 @@
 /*
+ * PCBIT-D interface with isdn4linux
+ *
  * Copyright (C) 1996 Universidade de Lisboa
  * 
  * Written by Pedro Roque Marques (roque@di.fc.ul.pt)
  *
  * This software may be used and distributed according to the terms of 
  * the GNU General Public License, incorporated herein by reference.
- */
-
-/*        
- *        PCBIT-D interface with isdn4linux
  */
 
 /*
diff -urN linux-2.2.21-pre1/drivers/isdn/pcbit/edss1.c linux/drivers/isdn/pcbit/edss1.c
--- linux-2.2.21-pre1/drivers/isdn/pcbit/edss1.c	Fri Nov  2 08:39:07 2001
+++ linux/drivers/isdn/pcbit/edss1.c	Wed Jan  2 03:55:23 2002
@@ -1,4 +1,7 @@
 /*
+ * DSS.1 Finite State Machine
+ * base: ITU-T Rec Q.931
+ *
  * Copyright (C) 1996 Universidade de Lisboa
  * 
  * Written by Pedro Roque Marques (roque@di.fc.ul.pt)
@@ -7,19 +10,10 @@
  * the GNU General Public License, incorporated herein by reference.
  */
 
-/*        
- *        DSS.1 Finite State Machine
- *        base: ITU-T Rec Q.931
- */
-
 /*
  *        TODO: complete the FSM
  *              move state/event descriptions to a user space logger
  */
-
-#define __NO_VERSION__
-
-#include <linux/module.h>
 
 #include <linux/sched.h>
 #include <linux/string.h>
diff -urN linux-2.2.21-pre1/drivers/isdn/pcbit/edss1.h linux/drivers/isdn/pcbit/edss1.h
--- linux-2.2.21-pre1/drivers/isdn/pcbit/edss1.h	Fri Nov  2 08:39:07 2001
+++ linux/drivers/isdn/pcbit/edss1.h	Wed Jan  2 03:55:23 2002
@@ -1,14 +1,12 @@
 /*
+ * DSS.1 module definitions
+ *
  * Copyright (C) 1996 Universidade de Lisboa
  * 
  * Written by Pedro Roque Marques (roque@di.fc.ul.pt)
  *
  * This software may be used and distributed according to the terms of 
  * the GNU General Public License, incorporated herein by reference.
- */
-
-/*        
- *        DSS.1 module definitions
  */
 
 #ifndef EDSS1_H
diff -urN linux-2.2.21-pre1/drivers/isdn/pcbit/layer2.c linux/drivers/isdn/pcbit/layer2.c
--- linux-2.2.21-pre1/drivers/isdn/pcbit/layer2.c	Fri Nov  2 08:39:07 2001
+++ linux/drivers/isdn/pcbit/layer2.c	Wed Jan  2 03:55:23 2002
@@ -1,4 +1,6 @@
 /*
+ * PCBIT-D low-layer interface
+ *
  * Copyright (C) 1996 Universidade de Lisboa
  *
  * Written by Pedro Roque Marques (roque@di.fc.ul.pt)
@@ -13,10 +15,6 @@
 */
 
 /*
- *        PCBIT-D low-layer interface
- */
-
-/*
  *        Based on documentation provided by Inesc:
  *        - "Interface com bus do PC para o PCBIT e PCBIT-D", Inesc, Jan 93
  */
@@ -25,16 +23,6 @@
  *        TODO: better handling of errors
  *              re-write/remove debug printks
  */
-
-#define __NO_VERSION__
-
-
-#ifdef MODULE
-#define INCLUDE_INLINE_FUNCS
-#endif
-
-
-#include <linux/module.h>
 
 #include <linux/sched.h>
 #include <linux/string.h>
diff -urN linux-2.2.21-pre1/drivers/isdn/pcbit/layer2.h linux/drivers/isdn/pcbit/layer2.h
--- linux-2.2.21-pre1/drivers/isdn/pcbit/layer2.h	Fri Nov  2 08:39:07 2001
+++ linux/drivers/isdn/pcbit/layer2.h	Wed Jan  2 03:55:23 2002
@@ -1,4 +1,6 @@
 /*
+ * PCBIT-D low-layer interface definitions
+ *
  * Copyright (C) 1996 Universidade de Lisboa
  * 
  * Written by Pedro Roque Marques (roque@di.fc.ul.pt)
@@ -11,10 +13,6 @@
  * 19991203 - Fernando Carvalho - takion@superbofh.org
  * Hacked to compile with egcs and run with current version of isdn modules
 */
-
-/*        
- *        PCBIT-D low-layer interface definitions
- */
 
 #ifndef LAYER2_H
 #define LAYER2_H
diff -urN linux-2.2.21-pre1/drivers/isdn/pcbit/module.c linux/drivers/isdn/pcbit/module.c
--- linux-2.2.21-pre1/drivers/isdn/pcbit/module.c	Fri Nov  2 08:39:07 2001
+++ linux/drivers/isdn/pcbit/module.c	Wed Jan  2 03:55:23 2002
@@ -1,4 +1,6 @@
 /*
+ * PCBIT-D module support
+ *
  * Copyright (C) 1996 Universidade de Lisboa
  * 
  * Written by Pedro Roque Marques (roque@di.fc.ul.pt)
@@ -7,10 +9,6 @@
  * the GNU General Public License, incorporated herein by reference.
  */
 
-/*        
- *        PCBIT-D module support
- */
-
 #include <linux/module.h>
 #include <linux/init.h>
 #include <linux/sched.h>
@@ -22,6 +20,12 @@
 #include <linux/isdnif.h>
 #include "pcbit.h"
 
+MODULE_DESCRIPTION("ISDN4Linux: Driver for PCBIT-T card");
+MODULE_AUTHOR("Pedro Roque Marques");
+MODULE_LICENSE("GPL");
+MODULE_PARM(mem, "1-" __MODULE_STRING(MAX_PCBIT_CARDS) "i");
+MODULE_PARM(irq, "1-" __MODULE_STRING(MAX_PCBIT_CARDS) "i");
+
 static int mem[MAX_PCBIT_CARDS] = {0, };
 static int irq[MAX_PCBIT_CARDS] = {0, };
 
@@ -111,9 +115,6 @@
 	}
 }
 #endif
-
-MODULE_PARM(mem, "1-" __MODULE_STRING(MAX_PCBIT_CARDS) "i");
-MODULE_PARM(irq, "1-" __MODULE_STRING(MAX_PCBIT_CARDS) "i");
 
 module_init(pcbit_init);
 module_exit(pcbit_exit);
diff -urN linux-2.2.21-pre1/drivers/isdn/pcbit/pcbit.h linux/drivers/isdn/pcbit/pcbit.h
--- linux-2.2.21-pre1/drivers/isdn/pcbit/pcbit.h	Fri Nov  2 08:39:07 2001
+++ linux/drivers/isdn/pcbit/pcbit.h	Wed Jan  2 03:55:23 2002
@@ -1,14 +1,12 @@
 /*
+ * PCBIT-D device driver definitions
+ *
  * Copyright (C) 1996 Universidade de Lisboa
  * 
  * Written by Pedro Roque Marques (roque@di.fc.ul.pt)
  *
  * This software may be used and distributed according to the terms of 
  * the GNU General Public License, incorporated herein by reference.
- */
-
-/*        
- *        PCBIT-D device driver definitions
  */
 
 #ifndef PCBIT_H
diff -urN linux-2.2.21-pre1/drivers/isdn/sc/card.h linux/drivers/isdn/sc/card.h
--- linux-2.2.21-pre1/drivers/isdn/sc/card.h	Sun Mar 25 08:31:38 2001
+++ linux/drivers/isdn/sc/card.h	Wed Jan  2 03:55:23 2002
@@ -1,24 +1,13 @@
-/*
- *  $Id: card.h,v 1.1 1996/11/07 13:07:40 fritz Exp $
- *  Copyright (C) 1996  SpellCaster Telecommunications Inc.
+/* $Id: card.h,v 1.1.2.1 2001/12/31 13:26:48 kai Exp $
  *
- *  card.h - Driver parameters for SpellCaster ISA ISDN adapters
+ * Driver parameters for SpellCaster ISA ISDN adapters
  *
- *  This program is free software; you can redistribute it and/or modify
- *  it under the terms of the GNU General Public License as published by
- *  the Free Software Foundation; either version 2 of the License, or
- *  (at your option) any later version.
+ * Copyright (C) 1996  SpellCaster Telecommunications Inc.
  *
- *  This program is distributed in the hope that it will be useful,
- *  but WITHOUT ANY WARRANTY; without even the implied warranty of
- *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- *  GNU General Public License for more details.
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
- *  You should have received a copy of the GNU General Public License
- *  along with this program; if not, write to the Free Software
- *  Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
- *
- *  For more information, please contact gpl-info@spellcast.com or write:
+ * For more information, please contact gpl-info@spellcast.com or write:
  *
  *     SpellCaster Telecommunications Inc.
  *     5621 Finch Avenue East, Unit #3
diff -urN linux-2.2.21-pre1/drivers/isdn/sc/command.c linux/drivers/isdn/sc/command.c
--- linux-2.2.21-pre1/drivers/isdn/sc/command.c	Sun Mar 25 08:31:38 2001
+++ linux/drivers/isdn/sc/command.c	Wed Jan  2 03:55:23 2002
@@ -1,22 +1,11 @@
-/*
- *  $Id: command.c,v 1.4 1997/03/30 16:51:34 calle Exp $
- *  Copyright (C) 1996  SpellCaster Telecommunications Inc.
+/* $Id: command.c,v 1.1.2.1 2001/12/31 13:26:50 kai Exp $
  *
- *  This program is free software; you can redistribute it and/or modify
- *  it under the terms of the GNU General Public License as published by
- *  the Free Software Foundation; either version 2 of the License, or
- *  (at your option) any later version.
+ * Copyright (C) 1996  SpellCaster Telecommunications Inc.
  *
- *  This program is distributed in the hope that it will be useful,
- *  but WITHOUT ANY WARRANTY; without even the implied warranty of
- *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- *  GNU General Public License for more details.
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
- *  You should have received a copy of the GNU General Public License
- *  along with this program; if not, write to the Free Software
- *  Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
- *
- *  For more information, please contact gpl-info@spellcast.com or write:
+ * For more information, please contact gpl-info@spellcast.com or write:
  *
  *     SpellCaster Telecommunications Inc.
  *     5621 Finch Avenue East, Unit #3
@@ -27,6 +16,7 @@
  */
 
 #define __NO_VERSION__
+#include <linux/module.h>
 #include "includes.h"		/* This must be first */
 #include "hardware.h"
 #include "message.h"
diff -urN linux-2.2.21-pre1/drivers/isdn/sc/debug.c linux/drivers/isdn/sc/debug.c
--- linux-2.2.21-pre1/drivers/isdn/sc/debug.c	Sun Mar 25 08:37:34 2001
+++ linux/drivers/isdn/sc/debug.c	Wed Jan  2 03:55:23 2002
@@ -1,22 +1,11 @@
-/*
- *  $Id: debug.c,v 1.5 2000/11/12 15:29:37 kai Exp $
- *  Copyright (C) 1996  SpellCaster Telecommunications Inc.
+/* $Id: debug.c,v 1.1.2.1 2001/12/31 13:26:50 kai Exp $
  *
- *  This program is free software; you can redistribute it and/or modify
- *  it under the terms of the GNU General Public License as published by
- *  the Free Software Foundation; either version 2 of the License, or
- *  (at your option) any later version.
+ * Copyright (C) 1996  SpellCaster Telecommunications Inc.
  *
- *  This program is distributed in the hope that it will be useful,
- *  but WITHOUT ANY WARRANTY; without even the implied warranty of
- *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- *  GNU General Public License for more details.
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
- *  You should have received a copy of the GNU General Public License
- *  along with this program; if not, write to the Free Software
- *  Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
- *
- *  For more information, please contact gpl-info@spellcast.com or write:
+ * For more information, please contact gpl-info@spellcast.com or write:
  *
  *     SpellCaster Telecommunications Inc.
  *     5621 Finch Avenue East, Unit #3
@@ -25,6 +14,7 @@
  *     +1 (416) 297-8565
  *     +1 (416) 297-6433 Facsimile
  */
+
 #include <linux/kernel.h>
 
 inline char *strcpy(char *, const char *);
diff -urN linux-2.2.21-pre1/drivers/isdn/sc/debug.h linux/drivers/isdn/sc/debug.h
--- linux-2.2.21-pre1/drivers/isdn/sc/debug.h	Sun Mar 25 08:37:34 2001
+++ linux/drivers/isdn/sc/debug.h	Wed Jan  2 03:55:23 2002
@@ -1,22 +1,11 @@
-/*
- *  $Id: debug.h,v 1.2 2000/02/26 01:00:53 keil Exp $
- *  Copyright (C) 1996  SpellCaster Telecommunications Inc.
+/* $Id: debug.h,v 1.1.2.1 2001/12/31 13:26:50 kai Exp $
  *
- *  This program is free software; you can redistribute it and/or modify
- *  it under the terms of the GNU General Public License as published by
- *  the Free Software Foundation; either version 2 of the License, or
- *  (at your option) any later version.
+ * Copyright (C) 1996  SpellCaster Telecommunications Inc.
  *
- *  This program is distributed in the hope that it will be useful,
- *  but WITHOUT ANY WARRANTY; without even the implied warranty of
- *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- *  GNU General Public License for more details.
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
- *  You should have received a copy of the GNU General Public License
- *  along with this program; if not, write to the Free Software
- *  Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
- *
- *  For more information, please contact gpl-info@spellcast.com or write:
+ * For more information, please contact gpl-info@spellcast.com or write:
  *
  *     SpellCaster Telecommunications Inc.
  *     5621 Finch Avenue East, Unit #3
diff -urN linux-2.2.21-pre1/drivers/isdn/sc/event.c linux/drivers/isdn/sc/event.c
--- linux-2.2.21-pre1/drivers/isdn/sc/event.c	Sun Mar 25 08:31:38 2001
+++ linux/drivers/isdn/sc/event.c	Wed Jan  2 03:55:23 2002
@@ -1,22 +1,11 @@
-/*
- *  $Id: event.c,v 1.4 1997/10/09 22:30:58 fritz Exp $
- *  Copyright (C) 1996  SpellCaster Telecommunications Inc.
+/* $Id: event.c,v 1.1.2.1 2001/12/31 13:26:50 kai Exp $
  *
- *  This program is free software; you can redistribute it and/or modify
- *  it under the terms of the GNU General Public License as published by
- *  the Free Software Foundation; either version 2 of the License, or
- *  (at your option) any later version.
+ * Copyright (C) 1996  SpellCaster Telecommunications Inc.
  *
- *  This program is distributed in the hope that it will be useful,
- *  but WITHOUT ANY WARRANTY; without even the implied warranty of
- *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- *  GNU General Public License for more details.
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
- *  You should have received a copy of the GNU General Public License
- *  along with this program; if not, write to the Free Software
- *  Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
- *
- *  For more information, please contact gpl-info@spellcast.com or write:
+ * For more information, please contact gpl-info@spellcast.com or write:
  *
  *     SpellCaster Telecommunications Inc.
  *     5621 Finch Avenue East, Unit #3
diff -urN linux-2.2.21-pre1/drivers/isdn/sc/hardware.h linux/drivers/isdn/sc/hardware.h
--- linux-2.2.21-pre1/drivers/isdn/sc/hardware.h	Sun Mar 25 08:31:38 2001
+++ linux/drivers/isdn/sc/hardware.h	Wed Jan  2 03:55:23 2002
@@ -1,5 +1,9 @@
 /*
  * Hardware specific macros, defines and structures
+ *
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
+ *
  */
 
 #ifndef HARDWARE_H
@@ -12,15 +16,7 @@
  */
 
 #define MAX_CARDS	4		/* The maximum number of cards to
-					   control or probe for. If you change
-					   this, you must also change the number
-					   of elements in io, irq, and ram to
-					   match. Initialized in init.c */
-/*
-extern unsigned int io[];
-extern unsigned char irq[];
-extern unsigned long ram[];
-*/
+					   control or probe for. */
 
 #define SIGNATURE	0x87654321	/* Board reset signature */
 #define SIG_OFFSET	0x1004		/* Where to find signature in shared RAM */
diff -urN linux-2.2.21-pre1/drivers/isdn/sc/includes.h linux/drivers/isdn/sc/includes.h
--- linux-2.2.21-pre1/drivers/isdn/sc/includes.h	Sun Mar 25 08:37:34 2001
+++ linux/drivers/isdn/sc/includes.h	Wed Jan  2 03:55:23 2002
@@ -1,4 +1,9 @@
-#include <linux/module.h>
+/*
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
+ *
+ */
+
 #include <linux/version.h>
 #include <linux/errno.h>
 #include <asm/segment.h>
diff -urN linux-2.2.21-pre1/drivers/isdn/sc/init.c linux/drivers/isdn/sc/init.c
--- linux-2.2.21-pre1/drivers/isdn/sc/init.c	Sun Mar 25 08:37:34 2001
+++ linux/drivers/isdn/sc/init.c	Wed Jan  2 03:55:23 2002
@@ -1,9 +1,23 @@
+/*
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
+ *
+ */
+
 #include <linux/module.h>
 #include <linux/init.h>
 #include "includes.h"
 #include "hardware.h"
 #include "card.h"
 
+MODULE_DESCRIPTION("ISDN4Linux: Driver for Spellcaster card");
+MODULE_AUTHOR("Spellcaster Telecommunications Inc.");
+MODULE_LICENSE("GPL");
+MODULE_PARM( io, "1-" __MODULE_STRING(MAX_CARDS) "i");
+MODULE_PARM(irq, "1-" __MODULE_STRING(MAX_CARDS) "i");
+MODULE_PARM(ram, "1-" __MODULE_STRING(MAX_CARDS) "i");
+MODULE_PARM(do_reset, "i");
+
 board *adapter[MAX_CARDS];
 int cinst;
 
@@ -38,11 +52,6 @@
 	}
 	return 0;
 }
-
-MODULE_PARM(io, "1-4i");
-MODULE_PARM(irq, "1-4i");
-MODULE_PARM(ram, "1-4i");
-MODULE_PARM(do_reset, "i");
 
 static int __init sc_init(void)
 {
diff -urN linux-2.2.21-pre1/drivers/isdn/sc/interrupt.c linux/drivers/isdn/sc/interrupt.c
--- linux-2.2.21-pre1/drivers/isdn/sc/interrupt.c	Fri Nov  2 08:39:07 2001
+++ linux/drivers/isdn/sc/interrupt.c	Wed Jan  2 03:55:23 2002
@@ -1,22 +1,11 @@
-/*
- *  $Id: interrupt.c,v 1.4.8.2 2001/04/08 17:51:43 kai Exp $
- *  Copyright (C) 1996  SpellCaster Telecommunications Inc.
+/* $Id: interrupt.c,v 1.1.2.1 2001/12/31 13:26:50 kai Exp $
  *
- *  This program is free software; you can redistribute it and/or modify
- *  it under the terms of the GNU General Public License as published by
- *  the Free Software Foundation; either version 2 of the License, or
- *  (at your option) any later version.
+ * Copyright (C) 1996  SpellCaster Telecommunications Inc.
  *
- *  This program is distributed in the hope that it will be useful,
- *  but WITHOUT ANY WARRANTY; without even the implied warranty of
- *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- *  GNU General Public License for more details.
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
- *  You should have received a copy of the GNU General Public License
- *  along with this program; if not, write to the Free Software
- *  Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
- *
- *  For more information, please contact gpl-info@spellcast.com or write:
+ * For more information, please contact gpl-info@spellcast.com or write:
  *
  *     SpellCaster Telecommunications Inc.
  *     5621 Finch Avenue East, Unit #3
diff -urN linux-2.2.21-pre1/drivers/isdn/sc/ioctl.c linux/drivers/isdn/sc/ioctl.c
--- linux-2.2.21-pre1/drivers/isdn/sc/ioctl.c	Sun Mar 25 08:31:38 2001
+++ linux/drivers/isdn/sc/ioctl.c	Wed Jan  2 03:55:23 2002
@@ -1,3 +1,11 @@
+/*
+ * Copyright (C) 1996  SpellCaster Telecommunications Inc.
+ *
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
+ *
+ */
+
 #define __NO_VERSION__
 #include "includes.h"
 #include "hardware.h"
diff -urN linux-2.2.21-pre1/drivers/isdn/sc/message.c linux/drivers/isdn/sc/message.c
--- linux-2.2.21-pre1/drivers/isdn/sc/message.c	Fri Nov  2 08:39:07 2001
+++ linux/drivers/isdn/sc/message.c	Wed Jan  2 03:55:23 2002
@@ -1,24 +1,13 @@
-/*
- *  $Id: message.c,v 1.5.8.1 2001/04/08 17:51:43 kai Exp $
- *  Copyright (C) 1996  SpellCaster Telecommunications Inc.
+/* $Id: message.c,v 1.1.2.1 2001/12/31 13:26:50 kai Exp $
  *
- *  message.c - functions for sending and receiving control messages
+ * functions for sending and receiving control messages
  *
- *  This program is free software; you can redistribute it and/or modify
- *  it under the terms of the GNU General Public License as published by
- *  the Free Software Foundation; either version 2 of the License, or
- *  (at your option) any later version.
+ * Copyright (C) 1996  SpellCaster Telecommunications Inc.
  *
- *  This program is distributed in the hope that it will be useful,
- *  but WITHOUT ANY WARRANTY; without even the implied warranty of
- *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- *  GNU General Public License for more details.
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
- *  You should have received a copy of the GNU General Public License
- *  along with this program; if not, write to the Free Software
- *  Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
- *
- *  For more information, please contact gpl-info@spellcast.com or write:
+ * For more information, please contact gpl-info@spellcast.com or write:
  *
  *     SpellCaster Telecommunications Inc.
  *     5621 Finch Avenue East, Unit #3
diff -urN linux-2.2.21-pre1/drivers/isdn/sc/message.h linux/drivers/isdn/sc/message.h
--- linux-2.2.21-pre1/drivers/isdn/sc/message.h	Sun Mar 25 08:31:38 2001
+++ linux/drivers/isdn/sc/message.h	Wed Jan  2 03:55:23 2002
@@ -1,25 +1,14 @@
-/*
- *  $Id: message.h,v 1.1 1996/11/07 13:07:47 fritz Exp $
- *  Copyright (C) 1996  SpellCaster Telecommunications Inc.
+/* $Id: message.h,v 1.1.2.1 2001/12/31 13:26:50 kai Exp $
  *
- *  message.h - structures, macros and defines useful for sending
- *              messages to the adapter
+ * Copyright (C) 1996  SpellCaster Telecommunications Inc.
  *
- *  This program is free software; you can redistribute it and/or modify
- *  it under the terms of the GNU General Public License as published by
- *  the Free Software Foundation; either version 2 of the License, or
- *  (at your option) any later version.
+ * structures, macros and defines useful for sending
+ * messages to the adapter
  *
- *  This program is distributed in the hope that it will be useful,
- *  but WITHOUT ANY WARRANTY; without even the implied warranty of
- *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- *  GNU General Public License for more details.
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
- *  You should have received a copy of the GNU General Public License
- *  along with this program; if not, write to the Free Software
- *  Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
- *
- *  For more information, please contact gpl-info@spellcast.com or write:
+ * For more information, please contact gpl-info@spellcast.com or write:
  *
  *     SpellCaster Telecommunications Inc.
  *     5621 Finch Avenue East, Unit #3
diff -urN linux-2.2.21-pre1/drivers/isdn/sc/packet.c linux/drivers/isdn/sc/packet.c
--- linux-2.2.21-pre1/drivers/isdn/sc/packet.c	Sun Mar 25 08:31:38 2001
+++ linux/drivers/isdn/sc/packet.c	Wed Jan  2 03:55:23 2002
@@ -1,22 +1,11 @@
-/*
- *  $Id: packet.c,v 1.5 1999/08/31 11:20:41 paul Exp $
- *  Copyright (C) 1996  SpellCaster Telecommunications Inc.
+/* $Id: packet.c,v 1.1.2.1 2001/12/31 13:26:50 kai Exp $
  *
- *  This program is free software; you can redistribute it and/or modify
- *  it under the terms of the GNU General Public License as published by
- *  the Free Software Foundation; either version 2 of the License, or
- *  (at your option) any later version.
+ * Copyright (C) 1996  SpellCaster Telecommunications Inc.
  *
- *  This program is distributed in the hope that it will be useful,
- *  but WITHOUT ANY WARRANTY; without even the implied warranty of
- *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- *  GNU General Public License for more details.
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
- *  You should have received a copy of the GNU General Public License
- *  along with this program; if not, write to the Free Software
- *  Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
- *
- *  For more information, please contact gpl-info@spellcast.com or write:
+ * For more information, please contact gpl-info@spellcast.com or write:
  *
  *     SpellCaster Telecommunications Inc.
  *     5621 Finch Avenue East, Unit #3
diff -urN linux-2.2.21-pre1/drivers/isdn/sc/scioc.h linux/drivers/isdn/sc/scioc.h
--- linux-2.2.21-pre1/drivers/isdn/sc/scioc.h	Sun Mar 25 08:31:38 2001
+++ linux/drivers/isdn/sc/scioc.h	Wed Jan  2 03:55:23 2002
@@ -1,3 +1,7 @@
+/*
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
+ */
 
 /*
  * IOCTL Command Codes
diff -urN linux-2.2.21-pre1/drivers/isdn/sc/shmem.c linux/drivers/isdn/sc/shmem.c
--- linux-2.2.21-pre1/drivers/isdn/sc/shmem.c	Sun Mar 25 08:31:38 2001
+++ linux/drivers/isdn/sc/shmem.c	Wed Jan  2 03:55:23 2002
@@ -1,24 +1,13 @@
-/*
- *  $Id: shmem.c,v 1.2 1996/11/20 17:49:56 fritz Exp $
- *  Copyright (C) 1996  SpellCaster Telecommunications Inc.
+/* $Id: shmem.c,v 1.1.2.1 2001/12/31 13:26:50 kai Exp $
  *
- *  card.c - Card functions implementing ISDN4Linux functionality
+ * Copyright (C) 1996  SpellCaster Telecommunications Inc.
  *
- *  This program is free software; you can redistribute it and/or modify
- *  it under the terms of the GNU General Public License as published by
- *  the Free Software Foundation; either version 2 of the License, or
- *  (at your option) any later version.
+ * Card functions implementing ISDN4Linux functionality
  *
- *  This program is distributed in the hope that it will be useful,
- *  but WITHOUT ANY WARRANTY; without even the implied warranty of
- *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- *  GNU General Public License for more details.
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
- *  You should have received a copy of the GNU General Public License
- *  along with this program; if not, write to the Free Software
- *  Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
- *
- *  For more information, please contact gpl-info@spellcast.com or write:
+ * For more information, please contact gpl-info@spellcast.com or write:
  *
  *     SpellCaster Telecommunications Inc.
  *     5621 Finch Avenue East, Unit #3
diff -urN linux-2.2.21-pre1/drivers/isdn/sc/timer.c linux/drivers/isdn/sc/timer.c
--- linux-2.2.21-pre1/drivers/isdn/sc/timer.c	Sun Mar 25 08:37:34 2001
+++ linux/drivers/isdn/sc/timer.c	Wed Jan  2 03:55:23 2002
@@ -1,22 +1,11 @@
-/*
- *  $Id: timer.c,v 1.3 2000/05/06 00:52:39 kai Exp $
- *  Copyright (C) 1996  SpellCaster Telecommunications Inc.
+/* $Id: timer.c,v 1.1.2.1 2001/12/31 13:26:50 kai Exp $
  *
- *  This program is free software; you can redistribute it and/or modify
- *  it under the terms of the GNU General Public License as published by
- *  the Free Software Foundation; either version 2 of the License, or
- *  (at your option) any later version.
+ * Copyright (C) 1996  SpellCaster Telecommunications Inc.
  *
- *  This program is distributed in the hope that it will be useful,
- *  but WITHOUT ANY WARRANTY; without even the implied warranty of
- *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- *  GNU General Public License for more details.
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
- *  You should have received a copy of the GNU General Public License
- *  along with this program; if not, write to the Free Software
- *  Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
- *
- *  For more information, please contact gpl-info@spellcast.com or write:
+ * For more information, please contact gpl-info@spellcast.com or write:
  *
  *     SpellCaster Telecommunications Inc.
  *     5621 Finch Avenue East, Unit #3
diff -urN linux-2.2.21-pre1/drivers/pci/oldproc.c linux/drivers/pci/oldproc.c
--- linux-2.2.21-pre1/drivers/pci/oldproc.c	Fri Nov  2 08:39:07 2001
+++ linux/drivers/pci/oldproc.c	Wed Jan  2 03:55:23 2002
@@ -344,11 +344,11 @@
 	DEVICE( VIA,		VIA_82C585,	"VT 82C585 Apollo VP1/VPX"),
 	DEVICE( VIA,		VIA_82C586_0,	"VT 82C586 Apollo ISA"),
 	DEVICE( VIA,		VIA_82C595,	"VT 82C595 Apollo VP2"),
-	DEVICE( VIA,		VIA_82C596_0,	"VT 82C596 Apollo Pro"),
+	DEVICE( VIA,		VIA_82C596,	"VT 82C596 Apollo Pro"),
 	DEVICE( VIA,		VIA_82C597_0,	"VT 82C597 Apollo VP3"),
 	DEVICE( VIA,		VIA_82C598_0,	"VT 82C598 Apollo MVP3"),
 	DEVICE( VIA,		VIA_82C926,	"VT 82C926 Amazon"),
-	DEVICE( VIA,		VIA_82C416,	"VT 82C416MV"),
+	DEVICE( VIA,		VIA_82C576_1,	"VT 82C416MV"),
 	DEVICE( VIA,		VIA_82C595_97,	"VT 82C595 Apollo VP2/97"),
 	DEVICE( VIA,		VIA_82C586_2,	"VT 82C586 Apollo USB"),
 	DEVICE( VIA,		VIA_82C586_3,	"VT 82C586B Apollo ACPI"),
diff -urN linux-2.2.21-pre1/drivers/pci/quirks.c linux/drivers/pci/quirks.c
--- linux-2.2.21-pre1/drivers/pci/quirks.c	Sun Mar 25 08:31:36 2001
+++ linux/drivers/pci/quirks.c	Wed Jan  2 03:55:23 2002
@@ -144,6 +144,96 @@
 	}
 }
 
+/*
+ *	VIA Apollo KT133 needs PCI latency patch
+ *	Made according to a windows driver based patch by George E. Breese
+ *	see PCI Latency Adjust on http://www.viahardware.com/download/viatweak.shtm
+ *      Also see http://home.tiscalinet.de/au-ja/review-kt133a-1-en.html for
+ *      the info on which Mr Breese based his work.
+ *
+ *	Updated based on further information from the site and also on
+ *	information provided by VIA 
+ */
+
+__initfunc(static void quirk_vialatency(struct pci_dev *dev, int arg))
+{
+	struct pci_dev *p;
+	u8 rev;
+	u8 busarb;
+	/* Ok we have a potential problem chipset here. Now see if we have
+	   a buggy southbridge */
+	   
+	p=pci_find_device(PCI_VENDOR_ID_VIA, PCI_DEVICE_ID_VIA_82C686, NULL);
+	if(p!=NULL)
+	{
+		pci_read_config_byte(p, PCI_CLASS_REVISION, &rev);
+		/* 0x40 - 0x4f == 686B, 0x10 - 0x2f == 686A; thanks Dan Hollis */
+		/* Check for buggy part revisions */
+		if (rev < 0x40 || rev > 0x42) 
+			return;
+	}
+	else
+	{
+		p = pci_find_device(PCI_VENDOR_ID_VIA, PCI_DEVICE_ID_VIA_8231, NULL);
+		if(p==NULL)	/* No problem parts */
+			return;
+		pci_read_config_byte(p, PCI_CLASS_REVISION, &rev);
+		/* Check for buggy part revisions */
+		if (rev < 0x10 || rev > 0x12) 
+			return;
+	}
+	
+	/*
+	 *	Ok we have the problem. Now set the PCI master grant to 
+	 *	occur every master grant. The apparent bug is that under high
+	 *	PCI load (quite common in Linux of course) you can get data
+	 *	loss when the CPU is held off the bus for 3 bus master requests
+	 *	This happens to include the IDE controllers....
+	 *
+	 *	VIA only apply this fix when an SB Live! is present but under
+	 *	both Linux and Windows this isnt enough, and we have seen
+	 *	corruption without SB Live! but with things like 3 UDMA IDE
+	 *	controllers. So we ignore that bit of the VIA recommendation..
+	 */
+
+	pci_read_config_byte(dev, 0x76, &busarb);
+	/* Set bit 4 and bi 5 of byte 76 to 0x01 
+	   "Master priority rotation on every PCI master grant */
+	busarb &= ~(1<<5);
+	busarb |= (1<<4);
+	pci_write_config_byte(dev, 0x76, busarb);
+	printk(KERN_INFO "Applying VIA southbridge workaround.\n");
+}
+
+/*
+ * Fix some problems with 'movntq' copies on Athlons. We need to ensure the
+ * non functional memory stuff wasn't enabled by the BIOS (and thus fix
+ * crashes when we use 100% memory bandwidth)
+ *
+ * VIA 8363 chipset:
+ * VIA 8363,8622,8361 Northbridges:
+ *  - bits  5, 6, 7 at offset 0x55 need to be turned off
+ * VIA 8367 (KT266x) Northbridges:
+ *  - bits  5, 6, 7 at offset 0x95 need to be turned off
+ */
+
+__initfunc(static void pci_fixup_via_athlon_bug(struct pci_dev *d, int arg))
+{
+ 	u8 v;
+	int where = 0x55;
+
+	if (d->device == PCI_DEVICE_ID_VIA_8367_0) {
+	        where = 0x95; /* the memory write queue timer register is 
+                                different for the kt266x's: 0x95 not 0x55 */
+	}
+	pci_read_config_byte(d, where, &v);
+	if (v & 0xe0) {
+		printk("Trying to stomp on Athlon bug...\n");
+		v &= 0x1f; /* clear bits 5, 6, 7 */
+		pci_write_config_byte(d, where, v);
+	}
+}
+
 
 typedef void (*quirk_handler)(struct pci_dev *, int);
 
@@ -162,6 +252,7 @@
 #endif
 	{ quirk_passive_release,"Passive release enable" },
 	{ quirk_isa_dma_hangs,	"Work around ISA DMA hangs" },
+	{ pci_fixup_via_athlon_bug, "Athlon/VIA fixup" },
 };
 
 
@@ -201,7 +292,14 @@
 	 * This is the 82C586 variants.
 	 */
 	{ PCI_VENDOR_ID_VIA,	PCI_DEVICE_ID_VIA_82C586_0,	quirk_isa_dma_hangs,	0x00 },
-	{ PCI_VENDOR_ID_VIA,	PCI_DEVICE_ID_VIA_82C596_0,	quirk_isa_dma_hangs,	0x00 },
+	{ PCI_VENDOR_ID_VIA,	PCI_DEVICE_ID_VIA_82C596,	quirk_isa_dma_hangs,	0x00 },
+	{ PCI_VENDOR_ID_VIA,	PCI_DEVICE_ID_VIA_8363_0,	pci_fixup_via_athlon_bug, 0x00 },
+	{ PCI_VENDOR_ID_VIA,	PCI_DEVICE_ID_VIA_8622,	        pci_fixup_via_athlon_bug, 0x00 },
+	{ PCI_VENDOR_ID_VIA,	PCI_DEVICE_ID_VIA_8361,	        pci_fixup_via_athlon_bug, 0x00 },
+	{ PCI_VENDOR_ID_VIA,	PCI_DEVICE_ID_VIA_8367_0,	pci_fixup_via_athlon_bug, 0x00 },
+	{ PCI_VENDOR_ID_VIA,	PCI_DEVICE_ID_VIA_8363_0,	quirk_vialatency, 0x00 },
+	{ PCI_VENDOR_ID_VIA,	PCI_DEVICE_ID_VIA_8371_1,	quirk_vialatency, 0x00 },
+	{ PCI_VENDOR_ID_VIA,	0x3112	/* Not out yet ? */,	quirk_vialatency, 0x00 },
 };
 
 __initfunc(void pci_quirks_init(void))
diff -urN linux-2.2.21-pre1/drivers/scsi/osst.c linux/drivers/scsi/osst.c
--- linux-2.2.21-pre1/drivers/scsi/osst.c	Fri Nov  2 08:39:08 2001
+++ linux/drivers/scsi/osst.c	Wed Jan  2 03:55:23 2002
@@ -16,14 +16,14 @@
   Copyright 1992 - 2000 Kai Makisara
 		 email Kai.Makisara@metla.fi
 
-  $Header: /home/cvsroot/Driver/osst.c,v 1.28.2.25 2001/06/03 21:56:26 riede Exp $
+  $Header: /home/cvsroot/Driver/osst.c,v 1.28.2.27 2001/11/01 21:03:42 riede Exp $
 
   Last modified: Wed Feb  2 22:04:05 2000 by makisara@kai.makisara.local
   Some small formal changes - aeb, 950809
 */
 
-static const char * cvsid = "$Id: osst.c,v 1.28.2.25 2001/06/03 21:56:26 riede Exp $";
-const char * osst_version = "0.8.13";
+static const char * cvsid = "$Id: osst.c,v 1.28.2.27 2001/11/01 21:03:42 riede Exp $";
+const char * osst_version = "0.8.15";
 
 /* The "failure to reconnect" firmware bug */
 #define OSST_FW_NEED_POLL_MIN 10601 /*(107A)*/
@@ -245,11 +245,10 @@
 /* Wakeup from interrupt */
 static void osst_sleep_done (Scsi_Cmnd * SCpnt)
 {
-  unsigned int st_nbr;
+  unsigned int dev = TAPE_NR(SCpnt->request.rq_dev);
   OS_Scsi_Tape * STp;
 
-  if ((st_nbr = TAPE_NR(SCpnt->request.rq_dev)) < osst_template.nr_dev) {
-    STp = os_scsi_tapes[st_nbr];
+  if (os_scsi_tapes && (STp = os_scsi_tapes[dev])) {
     if ((STp->buffer)->writing &&
 	(SCpnt->sense_buffer[0] & 0x70) == 0x70 &&
 	(SCpnt->sense_buffer[2] & 0x40)) {
@@ -271,7 +270,7 @@
   }
 #if DEBUG
   else if (debugging)
-    printk(KERN_ERR "osst?:D: Illegal interrupt device %x\n", st_nbr);
+    printk(KERN_ERR "osst?:D: Illegal interrupt device %x\n", dev);
 #endif
 }
 
@@ -588,8 +587,10 @@
         *aSCpnt = SCpnt;
 	if (!SCpnt) return (-EBUSY);
 
-	while ( SCpnt->sense_buffer[2] == 2 && SCpnt->sense_buffer[12] == 4 &&
-		( SCpnt->sense_buffer[13] == 1 || SCpnt->sense_buffer[13] == 8 ) && 
+	while ((( SCpnt->sense_buffer[2]  == 2 && SCpnt->sense_buffer[12] == 4    &&
+		 (SCpnt->sense_buffer[13] == 1 || SCpnt->sense_buffer[13] == 8)    ) ||
+		( SCpnt->sense_buffer[2]  == 6 && SCpnt->sense_buffer[12] == 0x28 &&
+		  SCpnt->sense_buffer[13] == 0                                     )  ) && 
 		time_before(jiffies, startwait + timeout*HZ) ) {
 #if DEBUG
 	    if (debugging) {
@@ -623,6 +624,65 @@
 	return 0;
 }
 
+/*
+ * Wait for a tape to be inserted in the unit
+ */
+static int osst_wait_for_medium(OS_Scsi_Tape * STp, Scsi_Cmnd ** aSCpnt, unsigned timeout)
+{
+	unsigned char	cmd[MAX_COMMAND_SIZE];
+	Scsi_Cmnd  * SCpnt;
+	long		startwait = jiffies;
+#if DEBUG
+	int		dbg = debugging;
+	int		dev  = TAPE_NR(STp->devt);
+
+	printk(OSST_DEB_MSG "osst%d:D: Reached onstream wait for medium\n", dev);
+#endif
+
+	memset(cmd, 0, MAX_COMMAND_SIZE);
+	cmd[0] = TEST_UNIT_READY;
+
+	SCpnt = osst_do_scsi(*aSCpnt, STp, cmd, 0, STp->timeout, MAX_READY_RETRIES, TRUE);
+	*aSCpnt = SCpnt;
+	if (!SCpnt) return (-EBUSY);
+
+	while ( SCpnt->sense_buffer[2]  == 2 && SCpnt->sense_buffer[12] == 0x3a &&
+	        SCpnt->sense_buffer[13] == 0 && time_before(jiffies, startwait + timeout*HZ) ) {
+#if DEBUG
+	    if (debugging) {
+		printk(OSST_DEB_MSG "osst%d:D: Sleeping in onstream wait medium\n", dev);
+		printk(OSST_DEB_MSG "osst%d:D: Turning off debugging for a while\n", dev);
+		debugging = 0;
+	    }
+#endif
+	    current->state = TASK_INTERRUPTIBLE;
+	    schedule_timeout(HZ / 10);
+
+	    memset(cmd, 0, MAX_COMMAND_SIZE);
+	    cmd[0] = TEST_UNIT_READY;
+
+	    SCpnt = osst_do_scsi(SCpnt, STp, cmd, 0, STp->timeout, MAX_READY_RETRIES, TRUE);
+	}
+	*aSCpnt = SCpnt;
+#if DEBUG
+	debugging = dbg;
+#endif
+	if ( SCpnt->sense_buffer[2]  != 2 &&
+	     SCpnt->sense_buffer[12] != 4 && SCpnt->sense_buffer[13] != 1) {
+#if DEBUG
+	    printk(OSST_DEB_MSG "osst%d:D: Abnormal exit from onstream wait medium\n", dev);
+	    printk(OSST_DEB_MSG "osst%d:D: Result = %d, Sense: 0=%02x, 2=%02x, 12=%02x, 13=%02x\n", dev,
+			SCpnt->result, SCpnt->sense_buffer[0], SCpnt->sense_buffer[2],
+			SCpnt->sense_buffer[12], SCpnt->sense_buffer[13]);
+#endif
+	    return 0;
+	}
+#if DEBUG
+	printk(OSST_DEB_MSG "osst%d:D: Normal exit from onstream wait medium\n", dev);
+#endif
+	return 1;
+}
+
 static int osst_position_tape_and_confirm(OS_Scsi_Tape * STp, Scsi_Cmnd ** aSCpnt, int frame)
 {
 	int           retval;
@@ -661,7 +721,7 @@
 		result = osst_write_error_recovery(STp, aSCpnt, 0);
 
 	result |= osst_wait_ready(STp, aSCpnt, 5 * 60);
-	STp->ps[STp->partition].rw = ST_IDLE;
+	STp->ps[STp->partition].rw = OS_WRITING_COMPLETE;
 	return (result);
 }
 /*
@@ -1583,7 +1643,7 @@
 			       mt_count, last_mark_ppos);
 #endif
 		if (last_mark_ppos > 10 && last_mark_ppos < STp->eod_frame_ppos) {
-			osst_set_frame_position(STp, aSCpnt, last_mark_ppos, 0);
+			osst_position_tape_and_confirm(STp, aSCpnt, last_mark_ppos);
 			if (osst_get_logical_frame(STp, aSCpnt, -1, 0) < 0) {
 #if DEBUG
 				printk(OSST_DEB_MSG
@@ -1615,7 +1675,7 @@
 #if DEBUG
 		printk(OSST_DEB_MSG "osst%d:D: Positioning to last mark at %d\n", dev, last_mark_ppos);
 #endif
-		osst_set_frame_position(STp, aSCpnt, last_mark_ppos, 0);
+		osst_position_tape_and_confirm(STp, aSCpnt, last_mark_ppos);
 		cnt++;
 		if (osst_get_logical_frame(STp, aSCpnt, -1, 0) < 0) {
 #if DEBUG
@@ -1740,7 +1800,7 @@
 #endif
 			return osst_space_over_filemarks_forward_slow(STp, aSCpnt, mt_op, mt_count);
 		} else {
-			osst_set_frame_position(STp, aSCpnt, next_mark_ppos, 0);
+			osst_position_tape_and_confirm(STp, aSCpnt, next_mark_ppos);
 			if (osst_get_logical_frame(STp, aSCpnt, -1, 0) < 0) {
 #if DEBUG
 				printk(OSST_DEB_MSG "osst%d:D: Couldn't get logical blk num in space_filemarks\n",
@@ -1780,7 +1840,7 @@
 #endif
 					return osst_space_over_filemarks_forward_slow(STp, aSCpnt, mt_op, mt_count);
 				}
-				osst_set_frame_position(STp, aSCpnt, STp->first_mark_ppos, 0);
+				osst_position_tape_and_confirm(STp, aSCpnt, STp->first_mark_ppos);
 				if (osst_get_logical_frame(STp, aSCpnt, -1, 0) < 0) {
 #if DEBUG
 					printk(OSST_DEB_MSG
@@ -1812,7 +1872,7 @@
 #if DEBUG
 			else printk(OSST_DEB_MSG "osst%d:D: Positioning to next mark at %d\n", dev, next_mark_ppos);
 #endif
-			osst_set_frame_position(STp, aSCpnt, next_mark_ppos, 0);
+			osst_position_tape_and_confirm(STp, aSCpnt, next_mark_ppos);
 			cnt++;
 			if (osst_get_logical_frame(STp, aSCpnt, -1, 0) < 0) {
 #if DEBUG
@@ -2450,7 +2510,7 @@
 	}
 
 #if DEBUG
-        printk(KERN_INFO "osst%d:D: Block Size changed to 32.5K\n", dev);
+	printk(KERN_INFO "osst%d:D: Drive Block Size changed to 32.5K\n", dev);
          /*
          * In debug mode, we want to see as many errors as possible
          * to test the error recovery mechanism.
@@ -3356,6 +3416,7 @@
       if (transfer)
 	return transfer;
       STps->rw = ST_IDLE;
+      /* FIXME -- this may leave the tape without EOD and up2date headers */
     }
 
     if ((count % STp->block_size) != 0) {
@@ -3762,6 +3823,10 @@
          ioctl_result = osst_flush_write_buffer(STp, &SCpnt);
        else
 	 ioctl_result = 0;
+#if DEBUG
+       if (debugging) 
+	 printk(OSST_DEB_MSG "osst%d:D: Writing %ld filemark(s).\n", dev, arg);
+#endif
        for (i=0; i<arg; i++)
          ioctl_result |= osst_write_filemark(STp, &SCpnt);
        if (fileno >= 0) fileno += arg;
@@ -3781,14 +3846,9 @@
        cmd[4] = arg;
        timeout = STp->timeout;
 #if DEBUG
-       if (debugging) {
-	 if (cmd_in == MTWEOF)
-	    printk(OSST_DEB_MSG "osst%d:D: Writing %d filemarks.\n", dev,
-		  cmd[2] * 65536 + cmd[3] * 256 + cmd[4]);
-	 else
-	    printk(OSST_DEB_MSG "osst%d:D: Writing %d setmarks.\n", dev,
+       if (debugging) 
+	   printk(OSST_DEB_MSG "osst%d:D: Writing %d setmark(s).\n", dev,
 		  cmd[2] * 65536 + cmd[3] * 256 + cmd[4]);
-       }
 #endif
        if (fileno >= 0)
 	 fileno += arg;
@@ -3800,9 +3860,13 @@
      case MTUNLOAD:
      case MTRETEN:
        cmd[0] = START_STOP;
-	 cmd[1] = 1;		/* Don't wait for completion */
-       if (cmd_in == MTLOAD)
-	 cmd[4] = 1;		/* load */
+       cmd[1] = 1;		/* Don't wait for completion */
+       if (cmd_in == MTLOAD) {
+	  if (STp->ready == ST_NO_TAPE)
+	     cmd[4] = 4;		/* open tray */
+	  else
+	     cmd[4] = 1;		/* load */
+       }
        if (cmd_in == MTRETEN)
 	 cmd[4] = 3;		/* retension then mount */
        if (cmd_in == MTOFFL)
@@ -3940,7 +4004,7 @@
       printk(OSST_DEB_MSG "osst%d:D: IOCTL (%d) Result=%d\n", dev, cmd_in, ioctl_result);
 #endif
 
-   if (!ioctl_result) {
+	if (!ioctl_result) {				/* success */
 
       if (cmd_in == MTFSFM) {
 	 fileno--;
@@ -4017,6 +4081,8 @@
       if (cmd_in == MTLOCK)
 	 STp->door_locked = ST_LOCK_FAILS;
 
+      if (cmd_in == MTLOAD && osst_wait_for_medium(STp, &SCpnt, 60))
+	 ioctl_result = osst_wait_ready(STp, &SCpnt, 5 * 60);
    }
    *aSCpnt = SCpnt;
 
@@ -4171,7 +4237,7 @@
 	STp->nbr_partitions = 1;  /* This guess will be updated later if necessary */
       for (i=0; i < ST_NBR_PARTITIONS; i++) {
 	  STps = &(STp->ps[i]);
-	  STps->rw = ST_IDLE;			/* FIXME - seems to be redundant... */
+	  STps->rw = ST_IDLE;		/* FIXME - seems to be redundant... */
 	  STps->eof = ST_NOEOF;
 	  STps->at_sm = 0;
 	  STps->last_block_valid = FALSE;
@@ -4438,8 +4504,7 @@
       if (result != 0 && result != (-ENOSPC))
 	  goto out;
     }
-
-    if ( STps->rw == ST_WRITING && !(STp->device)->was_reset) {
+    if ( STps->rw >= ST_WRITING && !(STp->device)->was_reset) {
 
 #if DEBUG
       if (debugging) {
@@ -4449,15 +4514,17 @@
 	       dev, STp->nbr_waits, STp->nbr_finished);
       }
 #endif
-
-      result = osst_flush_drive_buffer(STp, &SCpnt);
-      if (result < 0) goto out;
-      result = osst_write_filemark(STp, &SCpnt);
-      if (result < 0) goto out;
-
-      if (STps->drv_file >= 0)
-	STps->drv_file++ ;
-      STps->drv_block = 0;
+      if (STp->write_type != OS_WRITE_NEW_MARK) {
+	/* true unless the user wrote the filemark for us */
+	result = osst_flush_drive_buffer(STp, &SCpnt);
+	if (result < 0) goto out;
+	result = osst_write_filemark(STp, &SCpnt);
+	if (result < 0) goto out;
+
+	if (STps->drv_file >= 0)
+	    STps->drv_file++ ;
+	STps->drv_block = 0;
+      }
 //osst_report_stats();
       result = osst_write_eod(STp, &SCpnt);
       osst_write_header(STp, &SCpnt, !(STp->rew_at_close));
@@ -4588,7 +4655,10 @@
 
    cmd_type = _IOC_TYPE(cmd_in);
    cmd_nr   = _IOC_NR(cmd_in);
-
+#if DEBUG
+   printk(OSST_DEB_MSG "osst%d:D: Ioctl %d,%d in %s mode\n", dev,
+			cmd_type, cmd_nr, STp->raw?"raw":"normal");
+#endif
    if (cmd_type == _IOC_TYPE(MTIOCTOP) && cmd_nr == _IOC_NR(MTIOCTOP)) {
      if (_IOC_SIZE(cmd_in) != sizeof(mtc))
        return (-EINVAL);
@@ -4660,8 +4730,8 @@
        }
      }
 
-     if (mtc.mt_op != MTNOP && mtc.mt_op != MTSETBLK &&
-	 mtc.mt_op != MTSETDENSITY && mtc.mt_op != MTWSM &&
+     if (mtc.mt_op != MTNOP && mtc.mt_op != MTWEOF && mtc.mt_op != MTWSM &&
+	 mtc.mt_op != MTSETDENSITY && mtc.mt_op != MTSETBLK &&
 	 mtc.mt_op != MTSETDRVBUFFER && mtc.mt_op != MTSETPART)
        STps->rw = ST_IDLE;  /* Prevent automatic WEOF and fsf */
 
@@ -4703,7 +4773,11 @@
        return 0;
      }
      if (mtc.mt_op == MTSEEK) {
-       i = osst_seek_sector(STp, &SCpnt, mtc.mt_count);
+       if (STp->raw) {
+	 i = osst_set_frame_position(STp, &SCpnt, mtc.mt_count, 0);
+	 STp->header_ok = 0;
+       } else
+	 i = osst_seek_sector(STp, &SCpnt, mtc.mt_count);
        if (SCpnt) scsi_release_command(SCpnt);
        if (!STp->can_partitions)
 	   STp->ps[0].rw = ST_IDLE;
@@ -4796,7 +4870,10 @@
    if (cmd_type == _IOC_TYPE(MTIOCPOS) && cmd_nr == _IOC_NR(MTIOCPOS)) {
      if (_IOC_SIZE(cmd_in) != sizeof(struct mtpos))
        return (-EINVAL);
-     blk = osst_get_sector(STp, &SCpnt);
+     if (STp->raw)
+       blk = osst_get_frame_position(STp, &SCpnt);
+     else
+       blk = osst_get_sector(STp, &SCpnt);
      if (SCpnt) scsi_release_command(SCpnt);
      if (blk < 0)
        return blk;
@@ -5289,6 +5366,7 @@
 
    tpnt->current_mode = 0;
    tpnt->modes[0].defined = TRUE;
+   tpnt->modes[2].defined = TRUE;
 
    tpnt->density_changed = tpnt->compression_changed =
      tpnt->blksize_changed = FALSE;
diff -urN linux-2.2.21-pre1/drivers/scsi/osst.h linux/drivers/scsi/osst.h
--- linux-2.2.21-pre1/drivers/scsi/osst.h	Fri Nov  2 08:39:08 2001
+++ linux/drivers/scsi/osst.h	Wed Jan  2 03:55:23 2002
@@ -1,5 +1,5 @@
 /*
- *	$Header: /home/cvsroot/Driver/osst.h,v 1.5.2.4 2001/01/26 01:30:56 riede Exp $
+ *	$Header: /home/cvsroot/Driver/osst.h,v 1.5.2.5 2001/10/11 00:28:20 riede Exp $
  */
 
 #include <linux/config.h>
@@ -517,3 +517,5 @@
 #define OS_WRITE_HEADER    4
 #define OS_WRITE_FILLER    5
 
+/* Additional rw state */
+#define OS_WRITING_COMPLETE 3
diff -urN linux-2.2.21-pre1/drivers/sound/es1370.c linux/drivers/sound/es1370.c
--- linux-2.2.21-pre1/drivers/sound/es1370.c	Sun Mar 25 08:37:37 2001
+++ linux/drivers/sound/es1370.c	Wed Jan  2 03:55:23 2002
@@ -2436,7 +2436,7 @@
 			if (file->f_flags & O_NONBLOCK) {
 				remove_wait_queue(&s->midi.owait, &wait);
 				set_current_state(TASK_RUNNING);
-				return -EBUSY;
+				break;
 			}
 			tmo = (count * HZ) / 3100;
 			if (!schedule_timeout(tmo ? : 1) && tmo)
diff -urN linux-2.2.21-pre1/drivers/sound/es1371.c linux/drivers/sound/es1371.c
--- linux-2.2.21-pre1/drivers/sound/es1371.c	Sun Mar 25 08:37:37 2001
+++ linux/drivers/sound/es1371.c	Wed Jan  2 03:55:23 2002
@@ -3001,7 +3001,7 @@
 			if (file->f_flags & O_NONBLOCK) {
 				remove_wait_queue(&s->midi.owait, &wait);
 				set_current_state(TASK_RUNNING);
-				return -EBUSY;
+				break;
 			}
 			tmo = (count * HZ) / 3100;
 			if (!schedule_timeout(tmo ? : 1) && tmo)
diff -urN linux-2.2.21-pre1/drivers/sound/sonicvibes.c linux/drivers/sound/sonicvibes.c
--- linux-2.2.21-pre1/drivers/sound/sonicvibes.c	Sun Mar 25 08:37:37 2001
+++ linux/drivers/sound/sonicvibes.c	Wed Jan  2 03:55:23 2002
@@ -2201,7 +2201,7 @@
 			if (file->f_flags & O_NONBLOCK) {
 				remove_wait_queue(&s->midi.owait, &wait);
 				set_current_state(TASK_RUNNING);
-				return -EBUSY;
+				break;
 			}
 			tmo = (count * HZ) / 3100;
 			if (!schedule_timeout(tmo ? : 1) && tmo)
diff -urN linux-2.2.21-pre1/drivers/video/Makefile linux/drivers/video/Makefile
--- linux-2.2.21-pre1/drivers/video/Makefile	Sun Mar 25 08:37:37 2001
+++ linux/drivers/video/Makefile	Wed Jan  2 03:55:23 2002
@@ -102,6 +102,10 @@
 
 ifeq ($(CONFIG_FB_ATY),y)
 L_OBJS += atyfb.o
+else
+  ifeq ($(CONFIG_FB_ATY),m)
+  M_OBJS += atyfb.o
+  endif
 endif
 
 ifeq ($(CONFIG_FB_ATY128),y)
diff -urN linux-2.2.21-pre1/include/asm-i386/processor.h linux/include/asm-i386/processor.h
--- linux-2.2.21-pre1/include/asm-i386/processor.h	Sun Mar 25 08:37:39 2001
+++ linux/include/asm-i386/processor.h	Wed Jan  2 03:55:23 2002
@@ -74,7 +74,7 @@
 #define X86_FEATURE_CMOV	0x00008000	/* CMOV instruction (FCMOVCC and FCOMI too if FPU present) */
 #define X86_FEATURE_PAT	0x00010000	/* Page Attribute Table */
 #define X86_FEATURE_PSE36	0x00020000	/* 36-bit PSEs */
-#define X86_FEATURE_18		0x00040000
+#define X86_FEATURE_PN		0x00040000	/* Processor serial number */
 #define X86_FEATURE_19		0x00080000
 #define X86_FEATURE_20		0x00100000
 #define X86_FEATURE_21		0x00200000
@@ -106,6 +106,27 @@
 extern void dodgy_tsc(void);
 
 /*
+ * EFLAGS bits
+ */
+#define X86_EFLAGS_CF   0x00000001 /* Carry Flag */
+#define X86_EFLAGS_PF   0x00000004 /* Parity Flag */
+#define X86_EFLAGS_AF   0x00000010 /* Auxillary carry Flag */
+#define X86_EFLAGS_ZF   0x00000040 /* Zero Flag */
+#define X86_EFLAGS_SF   0x00000080 /* Sign Flag */
+#define X86_EFLAGS_TF   0x00000100 /* Trap Flag */
+#define X86_EFLAGS_IF   0x00000200 /* Interrupt Flag */
+#define X86_EFLAGS_DF   0x00000400 /* Direction Flag */
+#define X86_EFLAGS_OF   0x00000800 /* Overflow Flag */
+#define X86_EFLAGS_IOPL 0x00003000 /* IOPL mask */
+#define X86_EFLAGS_NT   0x00004000 /* Nested Task */
+#define X86_EFLAGS_RF   0x00010000 /* Resume Flag */
+#define X86_EFLAGS_VM   0x00020000 /* Virtual Mode */
+#define X86_EFLAGS_AC   0x00040000 /* Alignment Check */
+#define X86_EFLAGS_VIF  0x00080000 /* Virtual Interrupt Flag */
+#define X86_EFLAGS_VIP  0x00100000 /* Virtual Interrupt Pending */
+#define X86_EFLAGS_ID   0x00200000 /* CPUID detection flag */
+
+/*
  *	Generic CPUID function
  */
 extern inline void cpuid(int op, int *eax, int *ebx, int *ecx, int *edx)
@@ -120,6 +141,47 @@
 }
 
 /*
+ *  * CPUID functions returning a single datum
+ *   */
+extern inline unsigned int cpuid_eax(unsigned int op)
+{
+	unsigned int eax, ebx, ecx, edx;
+
+	__asm__("cpuid"
+		: "=a" (eax), "=b" (ebx), "=c" (ecx), "=d" (edx)
+		: "a" (op));
+	return eax;
+}
+
+extern inline unsigned int cpuid_ebx(unsigned int op)
+{
+	unsigned int eax, ebx, ecx, edx;
+
+	__asm__("cpuid"
+		: "=a" (eax), "=b" (ebx), "=c" (ecx), "=d" (edx)
+		: "a" (op));
+	return ebx;
+}
+extern inline unsigned int cpuid_ecx(unsigned int op)
+{
+	unsigned int eax, ebx, ecx, edx;
+
+	__asm__("cpuid"
+		: "=a" (eax), "=b" (ebx), "=c" (ecx), "=d" (edx)
+		: "a" (op));
+	return ecx;
+}
+extern inline unsigned int cpuid_edx(unsigned int op)
+{
+	unsigned int eax, ebx, ecx, edx;
+
+	__asm__("cpuid"
+		: "=a" (eax), "=b" (ebx), "=c" (ecx), "=d" (edx)
+		: "a" (op));
+	return edx;
+}
+
+/*
  *      Cyrix CPU configuration register indexes
  */
 #define CX86_CCR0 0xc0
@@ -129,6 +191,7 @@
 #define CX86_CCR4 0xe8
 #define CX86_CCR5 0xe9
 #define CX86_CCR6 0xea
+#define CX86_CCR7 0xeb
 #define CX86_DIR0 0xfe
 #define CX86_DIR1 0xff
 #define CX86_ARR_BASE 0xc4
@@ -144,6 +207,39 @@
 	outb((reg), 0x22); \
 	outb((data), 0x23); \
 } while (0)
+
+/*
+ *  * Intel CPU features in CR4
+ *   */
+#define X86_CR4_VME     0x0001  /* enable vm86 extensions */
+#define X86_CR4_PVI     0x0002  /* virtual interrupts flag enable */
+#define X86_CR4_TSD     0x0004  /* disable time stamp at ipl 3 */
+#define X86_CR4_DE      0x0008  /* enable debugging extensions */
+#define X86_CR4_PSE     0x0010  /* enable page size extensions */
+#define X86_CR4_PAE     0x0020  /* enable physical address extensions */
+#define X86_CR4_MCE     0x0040  /* Machine check enable */
+#define X86_CR4_PGE     0x0080  /* enable global pages */
+#define X86_CR4_PCE     0x0100  /* enable performance counters at ipl 3 */
+#define X86_CR4_OSFXSR      0x0200  /* enable fast FPU save and restore */
+#define X86_CR4_OSXMMEXCPT  0x0400  /* enable unmasked SSE exceptions */
+
+/*
+ * Save the cr4 feature set we're using (ie
+ * Pentium 4MB enable and PPro Global page
+ * enable), so that any CPU's that boot up
+ * after us can get the correct flags.
+ */
+extern unsigned long mmu_cr4_features;
+
+static inline void set_in_cr4 (unsigned long mask)
+{
+	mmu_cr4_features |= mask;
+	__asm__("movl %%cr4,%%eax\n\t"
+		"orl %0,%%eax\n\t"
+		"movl %%eax,%%cr4\n"
+		: : "irg" (mask)
+		:"ax"); 
+}
 
 /*
  * Bus types (default is ISA, but people can check others with these..)
diff -urN linux-2.2.21-pre1/include/linux/b1lli.h linux/include/linux/b1lli.h
--- linux-2.2.21-pre1/include/linux/b1lli.h	Fri Nov  2 08:39:09 2001
+++ linux/include/linux/b1lli.h	Wed Jan  2 03:55:23 2002
@@ -1,8 +1,9 @@
-/*
- * $Id: b1lli.h,v 1.8.8.2 2001/05/17 20:41:52 kai Exp $
+/* $Id: $
  *
  * ISDN lowlevel-module for AVM B1-card.
  *
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  * Copyright 1996 by Carsten Paeth (calle@calle.in-berlin.de)
  *
  */
diff -urN linux-2.2.21-pre1/include/linux/b1pcmcia.h linux/include/linux/b1pcmcia.h
--- linux-2.2.21-pre1/include/linux/b1pcmcia.h	Fri Nov  2 08:39:09 2001
+++ linux/include/linux/b1pcmcia.h	Wed Jan  2 03:55:23 2002
@@ -1,10 +1,12 @@
-/*
- * $Id: b1pcmcia.h,v 1.1.8.1 2001/05/17 20:41:52 kai Exp $
+/* $Id: $
  *
  * Exported functions of module b1pcmcia to be called by
  * avm_cs card services module.
  *
  * Copyright 1999 by Carsten Paeth (calle@calle.in-berlin.de)
+ *
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
diff -urN linux-2.2.21-pre1/include/linux/capi.h linux/include/linux/capi.h
--- linux-2.2.21-pre1/include/linux/capi.h	Sun Mar 25 08:37:40 2001
+++ linux/include/linux/capi.h	Wed Jan  2 03:55:23 2002
@@ -1,10 +1,12 @@
-/*
- * $Id: capi.h,v 1.4 2000/06/12 09:20:20 kai Exp $
+/* $Id: capi.h,v 1.1.2.2 2001/12/31 13:41:12 kai Exp $
  * 
  * CAPI 2.0 Interface for Linux
  * 
  * Copyright 1997 by Carsten Paeth (calle@calle.in-berlin.de)
  * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
+ *
  */
 
 #ifndef __LINUX_CAPI_H__
diff -urN linux-2.2.21-pre1/include/linux/concap.h linux/include/linux/concap.h
--- linux-2.2.21-pre1/include/linux/concap.h	Fri Nov  2 08:39:09 2001
+++ linux/include/linux/concap.h	Wed Jan  2 03:55:23 2002
@@ -1,5 +1,11 @@
-/* $Id: concap.h,v 1.2 1999/08/23 15:54:21 keil Exp $
-*/
+/* $Id: $
+ *
+ * Copyright 1997 by Henner Eisen <eis@baty.hanse.de>
+ *
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
+ */
+
 #ifndef _LINUX_CONCAP_H
 #define _LINUX_CONCAP_H
 #ifdef __KERNEL__
@@ -10,15 +16,12 @@
 /* Stuff to support encapsulation protocols genericly. The encapsulation
    protocol is processed at the uppermost layer of the network interface.
 
-   (c) 1997 by Henner Eisen <eis@baty.hanse.de>
-   This software is subject to the GNU General Public License.
-
    Based on a ideas developed in a 'synchronous device' thread in the
    linux-x25 mailing list contributed by Alan Cox, Thomasz Motylewski
    and Jonathan Naylor.
 
    For more documetation on this refer to Documentation/isdn/README.concap
-   */
+*/
 
 struct concap_proto_ops;
 struct concap_device_ops;
diff -urN linux-2.2.21-pre1/include/linux/hysdn_if.h linux/include/linux/hysdn_if.h
--- linux-2.2.21-pre1/include/linux/hysdn_if.h	Fri Nov  2 08:39:09 2001
+++ linux/include/linux/hysdn_if.h	Wed Jan  2 03:55:23 2002
@@ -1,23 +1,13 @@
-/* $Id: hysdn_if.h,v 1.1.8.2 2001/05/17 20:41:52 kai Exp $
-
- * Linux driver for HYSDN cards, ioctl definitions shared by hynetmgr and driver.
- * written by Werner Cornelius (werner@titro.de) for Hypercope GmbH
+/* $Id: $
  *
- * Copyright 1999  by Werner Cornelius (werner@titro.de)
+ * Linux driver for HYSDN cards
+ * ioctl definitions shared by hynetmgr and driver.
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
+ * Author    Werner Cornelius (werner@titro.de) for Hypercope GmbH
+ * Copyright 1999 by Werner Cornelius (werner@titro.de)
  *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
diff -urN linux-2.2.21-pre1/include/linux/isdn.h linux/include/linux/isdn.h
--- linux-2.2.21-pre1/include/linux/isdn.h	Fri Nov  2 08:39:09 2001
+++ linux/include/linux/isdn.h	Wed Jan  2 03:55:23 2002
@@ -1,74 +1,22 @@
-/* $Id: isdn.h,v 1.111.6.3 2001/02/10 14:44:10 kai Exp $
-
+/* $Id: isdn.h,v 1.1.2.1 2001/12/31 13:26:52 kai Exp $
+ *
  * Main header for the Linux ISDN subsystem (linklevel).
  *
  * Copyright 1994,95,96 by Fritz Elfert (fritz@isdn4linux.de)
  * Copyright 1995,96    by Thinking Objects Software GmbH Wuerzburg
  * Copyright 1995,96    by Michael Hipp (Michael.Hipp@student.uni-tuebingen.de)
  * 
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
-#ifndef isdn_h
-#define isdn_h
+#ifndef __ISDN_H__
+#define __ISDN_H__
 
-#include <linux/config.h>
+#include <linux/isdn_compat.h>
 #include <linux/ioctl.h>
 
-#define ISDN_TTY_MAJOR    43
-#define ISDN_TTYAUX_MAJOR 44
-#define ISDN_MAJOR        45
-
-/* The minor-devicenumbers for Channel 0 and 1 are used as arguments for
- * physical Channel-Mapping, so they MUST NOT be changed without changing
- * the correspondent code in isdn.c
- */
-
-#ifdef CONFIG_COBALT_MICRO_SERVER
-/* Save memory */
-#define ISDN_MAX_DRIVERS    2
-#define ISDN_MAX_CHANNELS   8
-#else
-#define ISDN_MAX_DRIVERS    32
-#define ISDN_MAX_CHANNELS   64
-#endif
-#define ISDN_MINOR_B        0
-#define ISDN_MINOR_BMAX     (ISDN_MAX_CHANNELS-1)
-#define ISDN_MINOR_CTRL     64
-#define ISDN_MINOR_CTRLMAX  (64 + (ISDN_MAX_CHANNELS-1))
-#define ISDN_MINOR_PPP      128
-#define ISDN_MINOR_PPPMAX   (128 + (ISDN_MAX_CHANNELS-1))
-#define ISDN_MINOR_STATUS   255
-
-#undef CONFIG_ISDN_WITH_ABC_CALLB
-#undef CONFIG_ISDN_WITH_ABC_UDP_CHECK
-#undef CONFIG_ISDN_WITH_ABC_UDP_CHECK_HANGUP
-#undef CONFIG_ISDN_WITH_ABC_UDP_CHECK_DIAL
-#undef CONFIG_ISDN_WITH_ABC_OUTGOING_EAZ
-#undef CONFIG_ISDN_WITH_ABC_LCR_SUPPORT
-#undef CONFIG_ISDN_WITH_ABC_IPV4_TCP_KEEPALIVE
-#undef CONFIG_ISDN_WITH_ABC_IPV4_DYNADDR
-#undef CONFIG_ISDN_WITH_ABC_RCV_NO_HUPTIMER
-#undef CONFIG_ISDN_WITH_ABC_ICALL_BIND
-#undef CONFIG_ISDN_WITH_ABC_CH_EXTINUSE
-#undef CONFIG_ISDN_WITH_ABC_CONN_ERROR
-#undef CONFIG_ISDN_WITH_ABC_RAWIPCOMPRESS
-#undef CONFIG_ISDN_WITH_ABC_IPTABLES_NETFILTER
-
-
 /* New ioctl-codes */
 #define IIOCNETAIF  _IO('I',1)
 #define IIOCNETDIF  _IO('I',2)
@@ -120,6 +68,7 @@
 #define ISDN_NET_ENCAP_CISCOHDLCK 6 /* With SLARP and keepalive    */
 #define ISDN_NET_ENCAP_X25IFACE   7 /* Documentation/networking/x25-iface.txt*/
 #define ISDN_NET_ENCAP_MAX_ENCAP  ISDN_NET_ENCAP_X25IFACE
+
 /* Facility which currently uses an ISDN-channel */
 #define ISDN_USAGE_NONE       0
 #define ISDN_USAGE_RAW        1
@@ -148,12 +97,6 @@
 } isdn_ioctl_struct;
 
 typedef struct {
-  unsigned long isdndev;
-  unsigned long atmodem[ISDN_MAX_CHANNELS];
-  unsigned long info[ISDN_MAX_CHANNELS];
-} debugvar_addr;
-
-typedef struct {
   char name[10];
   char phone[ISDN_MSNLEN];
   int  outgoing;
@@ -187,14 +130,15 @@
   int  dialmode;     /* Flag: off / on / auto                 */
 } isdn_net_ioctl_cfg;
 
-#define ISDN_NET_DIALMODE_MASK 0xC0  /* bits for status                   */
-#define  ISDN_NET_DM_OFF	0x00    /* this interface is stopped      */
-#define  ISDN_NET_DM_MANUAL	0x40    /* this interface is on (manual)  */
-#define  ISDN_NET_DM_AUTO	0x80    /* this interface is autodial     */
+#define ISDN_NET_DIALMODE_MASK  0xC0    /* bits for status                */
+#define ISDN_NET_DM_OFF	        0x00    /* this interface is stopped      */
+#define ISDN_NET_DM_MANUAL	0x40    /* this interface is on (manual)  */
+#define ISDN_NET_DM_AUTO	0x80    /* this interface is autodial     */
 #define ISDN_NET_DIALMODE(x) ((&(x))->flags & ISDN_NET_DIALMODE_MASK)
 
 #ifdef __KERNEL__
 
+#include <linux/config.h>
 #include <linux/errno.h>
 #include <linux/fs.h>
 #include <linux/major.h>
@@ -218,6 +162,31 @@
 #include <linux/skbuff.h>
 #include <linux/tcp.h>
 
+#define ISDN_TTY_MAJOR    43
+#define ISDN_TTYAUX_MAJOR 44
+#define ISDN_MAJOR        45
+
+/* The minor-devicenumbers for Channel 0 and 1 are used as arguments for
+ * physical Channel-Mapping, so they MUST NOT be changed without changing
+ * the correspondent code in isdn.c
+ */
+
+#ifdef CONFIG_COBALT_MICRO_SERVER
+/* Save memory */
+#define ISDN_MAX_DRIVERS    2
+#define ISDN_MAX_CHANNELS   8
+#else
+#define ISDN_MAX_DRIVERS    32
+#define ISDN_MAX_CHANNELS   64
+#endif
+#define ISDN_MINOR_B        0
+#define ISDN_MINOR_BMAX     (ISDN_MAX_CHANNELS-1)
+#define ISDN_MINOR_CTRL     64
+#define ISDN_MINOR_CTRLMAX  (64 + (ISDN_MAX_CHANNELS-1))
+#define ISDN_MINOR_PPP      128
+#define ISDN_MINOR_PPPMAX   (128 + (ISDN_MAX_CHANNELS-1))
+#define ISDN_MINOR_STATUS   255
+
 #ifdef CONFIG_ISDN_PPP
 
 #ifdef CONFIG_ISDN_PPP_VJ
@@ -427,7 +396,7 @@
   struct device dev;               /* interface to upper levels        */
 #ifdef CONFIG_ISDN_PPP
   ippp_bundle * pb;		/* pointer to the common bundle structure
-   			         * with the the per-bundle data */
+   			         * with the per-bundle data */
 #endif
 #ifdef CONFIG_ISDN_X25
   struct concap_proto  *cprot; /* connection oriented encapsulation protocol */
@@ -668,4 +637,5 @@
 #define MIN(a,b) ((a<b)?a:b)
 #define MAX(a,b) ((a>b)?a:b)
 #endif /* __KERNEL__ */
-#endif /* isdn_h */
+
+#endif /* __ISDN_H__ */
diff -urN linux-2.2.21-pre1/include/linux/isdn_divertif.h linux/include/linux/isdn_divertif.h
--- linux-2.2.21-pre1/include/linux/isdn_divertif.h	Sun Mar 25 08:31:05 2001
+++ linux/include/linux/isdn_divertif.h	Wed Jan  2 03:55:23 2002
@@ -1,22 +1,12 @@
-/* $Id: isdn_divertif.h,v 1.4 2000/05/11 22:29:22 kai Exp $
-
- * Header for the diversion supplementary interface for i4l.
+/* $Id: isdn_divertif.h,v 1.1.2.1 2001/12/31 13:26:52 kai Exp $
  *
- * Copyright 1998       by Werner Cornelius (werner@isdn4linux.de)
- * 
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
+ * Header for the diversion supplementary interface for i4l.
  *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
+ * Author    Werner Cornelius (werner@titro.de)
+ * Copyright by Werner Cornelius (werner@titro.de)
  *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
diff -urN linux-2.2.21-pre1/include/linux/isdn_ppp.h linux/include/linux/isdn_ppp.h
--- linux-2.2.21-pre1/include/linux/isdn_ppp.h	Fri Nov  2 08:39:09 2001
+++ linux/include/linux/isdn_ppp.h	Wed Jan  2 03:55:23 2002
@@ -1,9 +1,14 @@
-/* -*- mode: c; c-basic-offset: 2 -*- */
+/*
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
+ *
+ */
+
 
 #ifndef _LINUX_ISDN_PPP_H
 #define _LINUX_ISDN_PPP_H
 
-#include <linux/config.h>
+#include <linux/isdn_compat.h>
 
 #define CALLTYPE_INCOMING 0x1
 #define CALLTYPE_OUTGOING 0x2
@@ -47,13 +52,6 @@
 #define SC_LINK_DECOMP_DISCARD	0x40
 #define SC_LINK_COMP_DISCARD	0x80
 
-#define DECOMP_ERR_NOMEM	(-10)
-
-#define MP_END_FRAG    0x40
-#define MP_BEGIN_FRAG  0x80
-
-#define MP_MAX_QUEUE_LEN	16
-
 #define ISDN_PPP_COMP_MAX_OPTIONS 16
 
 #define IPPP_COMP_FLAG_XMIT 0x1
@@ -67,6 +65,17 @@
 };
 
 #ifdef __KERNEL__
+
+
+#include <linux/config.h>
+
+
+#define DECOMP_ERR_NOMEM	(-10)
+
+#define MP_END_FRAG    0x40
+#define MP_BEGIN_FRAG  0x80
+
+#define MP_MAX_QUEUE_LEN	16
 
 /*
  * We need a way for the decompressor to influence the generation of CCP
diff -urN linux-2.2.21-pre1/include/linux/isdnif.h linux/include/linux/isdnif.h
--- linux-2.2.21-pre1/include/linux/isdnif.h	Sun Mar 25 08:37:40 2001
+++ linux/include/linux/isdnif.h	Wed Jan  2 03:55:23 2002
@@ -1,32 +1,20 @@
-/* $Id: isdnif.h,v 1.37 2000/11/19 17:01:54 kai Exp $
-
- * Linux ISDN subsystem
+/* $Id: isdnif.h,v 1.1.2.1 2001/12/31 13:26:52 kai Exp $
  *
+ * Linux ISDN subsystem
  * Definition of the interface between the subsystem and its low-level drivers.
  *
  * Copyright 1994,95,96 by Fritz Elfert (fritz@isdn4linux.de)
  * Copyright 1995,96    Thinking Objects Software GmbH Wuerzburg
  * 
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
  *
  */
 
-#ifndef isdnif_h
-#define isdnif_h
+#ifndef __ISDNIF_H__
+#define __ISDNIF_H__
 
-#include <linux/config.h>
+#include <linux/isdn_compat.h>
 
 /*
  * Values for general protocol-selection
@@ -67,6 +55,7 @@
 
 #ifdef __KERNEL__
 
+#include <linux/config.h>
 #include <linux/skbuff.h>
 
 /***************************************************************************/
@@ -560,4 +549,5 @@
 #include <asm/uaccess.h>
 
 #endif /* __KERNEL__ */
-#endif /* isdnif_h */
+
+#endif /* __ISDNIF_H__ */
diff -urN linux-2.2.21-pre1/include/linux/kernelcapi.h linux/include/linux/kernelcapi.h
--- linux-2.2.21-pre1/include/linux/kernelcapi.h	Sun Mar 25 08:37:40 2001
+++ linux/include/linux/kernelcapi.h	Wed Jan  2 03:55:23 2002
@@ -1,10 +1,12 @@
-/*
- * $Id: kernelcapi.h,v 1.8.6.2 2001/02/07 11:31:31 kai Exp $
+/* $Id: kernelcapi.h,v 1.1.2.2 2001/12/31 13:41:12 kai Exp $
  * 
  * Kernel CAPI 2.0 Interface for Linux
  * 
  * (c) Copyright 1997 by Carsten Paeth (calle@calle.in-berlin.de)
  * 
+ * This software may be used and distributed according to the terms
+ * of the GNU General Public License, incorporated herein by reference.
+ *
  */
 
 #ifndef __KERNELCAPI_H__
diff -urN linux-2.2.21-pre1/include/linux/module.h linux/include/linux/module.h
--- linux-2.2.21-pre1/include/linux/module.h	Fri Nov  2 08:39:09 2001
+++ linux/include/linux/module.h	Wed Jan  2 03:55:23 2002
@@ -181,6 +181,8 @@
 	s	string
 */
 
+#define MODULE_LICENSE(var)
+
 #define MODULE_PARM(var,type)			\
 const char __module_parm_##var[]		\
 __attribute__((section(".modinfo"))) =		\
diff -urN linux-2.2.21-pre1/include/linux/pci.h linux/include/linux/pci.h
--- linux-2.2.21-pre1/include/linux/pci.h	Fri Nov  2 08:39:09 2001
+++ linux/include/linux/pci.h	Wed Jan  2 03:55:23 2002
@@ -830,7 +830,9 @@
 #define PCI_DEVICE_ID_TTI_HPT343	0x0003
 
 #define PCI_VENDOR_ID_VIA		0x1106
-#define PCI_DEVICE_ID_VIA_8371_0        0x0391
+#define PCI_DEVICE_ID_VIA_8363_0	0x0305
+#define PCI_DEVICE_ID_VIA_8371_0	0x0391
+#define PCI_DEVICE_ID_VIA_8501_0	0x0501
 #define PCI_DEVICE_ID_VIA_82C505	0x0505
 #define PCI_DEVICE_ID_VIA_82C561	0x0561
 #define PCI_DEVICE_ID_VIA_82C586_1	0x0571
@@ -838,18 +840,47 @@
 #define PCI_DEVICE_ID_VIA_82C585	0x0585
 #define PCI_DEVICE_ID_VIA_82C586_0	0x0586
 #define PCI_DEVICE_ID_VIA_82C595	0x0595
-#define PCI_DEVICE_ID_VIA_82C596_0	0x0596
+#define PCI_DEVICE_ID_VIA_82C596	0x0596
 #define PCI_DEVICE_ID_VIA_82C597_0	0x0597
-#define PCI_DEVICE_ID_VIA_82C598_0      0x0598
+#define PCI_DEVICE_ID_VIA_82C598_0	0x0598
+#define PCI_DEVICE_ID_VIA_8601_0	0x0601
+#define PCI_DEVICE_ID_VIA_8605_0	0x0605
+#define PCI_DEVICE_ID_VIA_82C680	0x0680
+#define PCI_DEVICE_ID_VIA_82C686	0x0686
+#define PCI_DEVICE_ID_VIA_82C691	0x0691
+#define PCI_DEVICE_ID_VIA_82C693	0x0693
+#define PCI_DEVICE_ID_VIA_82C693_1	0x0698
 #define PCI_DEVICE_ID_VIA_82C926	0x0926
-#define PCI_DEVICE_ID_VIA_82C416	0x1571
+#define PCI_DEVICE_ID_VIA_82C576_1	0x1571
 #define PCI_DEVICE_ID_VIA_82C595_97	0x1595
 #define PCI_DEVICE_ID_VIA_82C586_2	0x3038
 #define PCI_DEVICE_ID_VIA_82C586_3	0x3040
+#define PCI_DEVICE_ID_VIA_6305		0x3044
+#define PCI_DEVICE_ID_VIA_82C596_3	0x3050
+#define PCI_DEVICE_ID_VIA_82C596B_3	0x3051
+#define PCI_DEVICE_ID_VIA_82C686_4	0x3057
 #define PCI_DEVICE_ID_VIA_82C686_5	0x3058
+#define PCI_DEVICE_ID_VIA_8233_5	0x3059
+#define PCI_DEVICE_ID_VIA_8233_7	0x3065
+#define PCI_DEVICE_ID_VIA_82C686_6	0x3068
+#define PCI_DEVICE_ID_VIA_8233_0	0x3074
+#define PCI_DEVICE_ID_VIA_8233C_0	0x3109
+#define PCI_DEVICE_ID_VIA_8633_0	0x3091
+#define PCI_DEVICE_ID_VIA_8367_0	0x3099
+#define PCI_DEVICE_ID_VIA_8622          0x3102
+#define PCI_DEVICE_ID_VIA_8361          0x3112
 #define PCI_DEVICE_ID_VIA_86C100A	0x6100
+#define PCI_DEVICE_ID_VIA_8231		0x8231
+#define PCI_DEVICE_ID_VIA_8231_4	0x8235
+#define PCI_DEVICE_ID_VIA_8365_1	0x8305
+#define PCI_DEVICE_ID_VIA_8371_1	0x8391
+#define PCI_DEVICE_ID_VIA_8501_1	0x8501
 #define PCI_DEVICE_ID_VIA_82C597_1	0x8597
-#define PCI_DEVICE_ID_VIA_82C598_1      0x8598
+#define PCI_DEVICE_ID_VIA_82C598_1	0x8598
+#define PCI_DEVICE_ID_VIA_8601_1	0x8601
+#define PCI_DEVICE_ID_VIA_8505_1	0X8605
+#define PCI_DEVICE_ID_VIA_8633_1	0xB091
+#define PCI_DEVICE_ID_VIA_8367_1	0xB099
 
 #define PCI_VENDOR_ID_SMC2             0x1113
 #define PCI_DEVICE_ID_SMC2_1211TX      0x1211
@@ -1070,6 +1101,7 @@
 #define PCI_DEVICE_ID_AVM_A1		0x0a00
 #define PCI_DEVICE_ID_AVM_B1		0x0700
 #define PCI_DEVICE_ID_AVM_C4		0x0800
+#define PCI_DEVICE_ID_AVM_C2		0x1100
 #define PCI_DEVICE_ID_AVM_T1		0x1200
 
 #define PCI_VENDOR_ID_DIPIX		0x1246
diff -urN linux-2.2.21-pre1/scripts/lxdialog/checklist.c linux/scripts/lxdialog/checklist.c
--- linux-2.2.21-pre1/scripts/lxdialog/checklist.c	Fri Nov  2 08:39:16 2001
+++ linux/scripts/lxdialog/checklist.c	Wed Jan  2 03:55:23 2002
@@ -108,8 +108,8 @@
     print_button (dialog, "Select", y, x, selected == 0);
     print_button (dialog, " Help ", y, x + 14, selected == 1);
 
-    /*    wmove(dialog, y, x+1 + 14*selected);
-    wrefresh (dialog);*/
+    /*    wmove(dialog, y, x+1 + 14*selected);*/
+    wrefresh (dialog);
 }
 
 /*
