patch-2.3.9 linux/drivers/sgi/char/sgiserial.h

Next file: linux/drivers/sgi/char/shmiq.c
Previous file: linux/drivers/sgi/char/sgiserial.c
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v2.3.8/linux/drivers/sgi/char/sgiserial.h linux/drivers/sgi/char/sgiserial.h
@@ -412,7 +412,8 @@
 
 	udelay(2);
 	channel->control = ERR_RES;
-	junk = ioc_icontrol->istat0;
+	if (ioc_icontrol)
+		junk = ioc_icontrol->istat0;
 }
 
 extern inline void ZS_CLEARFIFO(struct sgi_zschannel *channel)
@@ -421,11 +422,17 @@
 
 	udelay(2);
 	junk = channel->data;
-	udelay(2); junk = ioc_icontrol->istat0;
+	udelay(2);
+	if (ioc_icontrol)
+		junk = ioc_icontrol->istat0;
 	junk = channel->data;
-	udelay(2); junk = ioc_icontrol->istat0;
+	udelay(2);
+	if (ioc_icontrol)
+		junk = ioc_icontrol->istat0;
 	junk = channel->data;
-	udelay(2); junk = ioc_icontrol->istat0;
+	udelay(2);
+	if (ioc_icontrol)
+		junk = ioc_icontrol->istat0;
 }
 
 #if 0

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