patch-2.4.20 linux-2.4.20/drivers/isdn/avmb1/kcapi.c

Next file: linux-2.4.20/drivers/isdn/hisax/Makefile
Previous file: linux-2.4.20/drivers/isdn/avmb1/b1dma.c
Back to the patch index
Back to the overall index

diff -urN linux-2.4.19/drivers/isdn/avmb1/kcapi.c linux-2.4.20/drivers/isdn/avmb1/kcapi.c
@@ -110,7 +110,7 @@
 
 #define VALID_CARD(c)	   ((c) > 0 && (c) <= CAPI_MAXCONTR)
 #define CARD(c)		   (&cards[(c)-1])
-#define CARDNR(cp)	   (((cp)-cards)+1)
+#define CARDNR(cp)	   ((((cp)-cards)+1) & 0xff)
 
 static struct capi_appl applications[CAPI_MAXAPPL];
 static struct capi_ctr cards[CAPI_MAXCONTR];

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