patch-2.0.21-2.1.0 linux/drivers/net/dgrs.c

Next file: linux/drivers/net/dgrs_driver.c
Previous file: linux/drivers/net/bsd_comp.c
Back to the patch index
Back to the overall index

diff -u --recursive --new-file lx2.0/v2.0.21/linux/drivers/net/dgrs.c linux/drivers/net/dgrs.c
@@ -225,10 +225,10 @@
 	/*
 	 *	Now map the DMA registers into our virtual space
 	 */
-	priv->vplxdma = (ulong *) vremap (priv->plxdma, 256);
+	priv->vplxdma = (ulong *) ioremap (priv->plxdma, 256);
 	if (!priv->vplxdma)
 	{
-		printk("%s: can't vremap() the DMA regs", dev->name);
+		printk("%s: can't ioremap() the DMA regs", dev->name);
 		return (0);
 	}
 
@@ -835,7 +835,7 @@
 	/*
 	 * Map in the dual port memory
 	 */
-	priv->vmem = vremap(dev->mem_start, 2048*1024);
+	priv->vmem = ioremap(dev->mem_start, 2048*1024);
 	if (!priv->vmem)
 	{
 		printk("%s: cannot map in board memory\n", dev->name);
@@ -882,7 +882,7 @@
 	memcpy(priv->vmem, dgrs_code, dgrs_ncode);	/* Load code */
 	if (memcmp(priv->vmem, dgrs_code, dgrs_ncode))
 	{
-		vfree(priv->vmem);
+		iounmap(priv->vmem);
 		priv->vmem = NULL;
 		printk("%s: download compare failed\n", dev->name);
 		return -ENXIO;
@@ -1330,9 +1330,9 @@
 		proc_reset(dgrs_root_dev, 1);
 
 		if (priv->vmem)
-			vfree(priv->vmem);
+			iounmap(priv->vmem);
 		if (priv->vplxdma)
-			vfree((uchar *) priv->vplxdma);
+			iounmap((uchar *) priv->vplxdma);
 
 		release_region(dgrs_root_dev->base_addr, 256);
 

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen, slshen@lbl.gov