linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] 2.5.41: cpqarray compile fixes
@ 2002-10-07 23:36 Adam Kropelin
  2002-10-07 23:39 ` Alexander Viro
  0 siblings, 1 reply; 3+ messages in thread
From: Adam Kropelin @ 2002-10-07 23:36 UTC (permalink / raw)
  To: viro, torvalds; +Cc: linux-kernel

cpqarray in 2.5.41 needs the patch below to compile. 

--Adam

--- linux-2.5.41/drivers/block/cpqarray.c	Mon Oct  7 18:26:32 2002
+++ linux-2.5.41-fix/drivers/block/cpqarray.c	Mon Oct  7 19:25:48 2002
@@ -355,7 +355,7 @@
 		}
 		num_cntlrs_reg++;
 		for (j=0; j<NWD; j++) {
-			ida_gendisk[i][j] = disk_alloc();
+			ida_gendisk[i][j] = alloc_disk();
 			if (!ida_gendisk[i][j])
 				goto Enomem2;
 		}
@@ -437,7 +437,6 @@
 	}
 	return 0;
 }
-}
 
 /*
  * Find the controller and initialize it


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] 2.5.41: cpqarray compile fixes
  2002-10-07 23:36 [PATCH] 2.5.41: cpqarray compile fixes Adam Kropelin
@ 2002-10-07 23:39 ` Alexander Viro
  2002-10-08  0:49   ` Adam Kropelin
  0 siblings, 1 reply; 3+ messages in thread
From: Alexander Viro @ 2002-10-07 23:39 UTC (permalink / raw)
  To: Adam Kropelin; +Cc: Linus Torvalds, linux-kernel



On Mon, 7 Oct 2002, Adam Kropelin wrote:

> cpqarray in 2.5.41 needs the patch below to compile. 

Yeah, and more than that.  Same typo is in cciss, rd.c sets ->first_minor to
0 for all units and HD_IRQ definition is needed if CONFIG_BLK_DEV_HD is
defined.

diff -urN C41-rd/drivers/block/cciss.c C41-disk_add/drivers/block/cciss.c
--- C41-rd/drivers/block/cciss.c	Mon Oct  7 15:55:57 2002
+++ C41-disk_add/drivers/block/cciss.c	Mon Oct  7 16:45:41 2002
@@ -2274,7 +2274,7 @@
 	struct gendisk *disk[NWD];
 	int i, n;
 	for (n = 0; n < NWD; n++) {
-		disk[n] = disk_alloc();
+		disk[n] = alloc_disk();
 		if (!disk[n])
 			goto out;
 	}
diff -urN C41-rd/drivers/block/cpqarray.c C41-disk_add/drivers/block/cpqarray.c
--- C41-rd/drivers/block/cpqarray.c	Mon Oct  7 15:55:57 2002
+++ C41-disk_add/drivers/block/cpqarray.c	Mon Oct  7 16:45:29 2002
@@ -355,7 +355,7 @@
 		}
 		num_cntlrs_reg++;
 		for (j=0; j<NWD; j++) {
-			ida_gendisk[i][j] = disk_alloc();
+			ida_gendisk[i][j] = alloc_disk();
 			if (!ida_gendisk[i][j])
 				goto Enomem2;
 		}
diff -urN C41-HD_IRQ/drivers/block/rd.c C41-rd/drivers/block/rd.c
--- C41-HD_IRQ/drivers/block/rd.c	Mon Oct  7 15:55:57 2002
+++ C41-rd/drivers/block/rd.c	Mon Oct  7 16:40:43 2002
@@ -459,7 +459,7 @@
 		/* rd_size is given in kB */
 		rd_length[i] = rd_size << 10;
 		disk->major = MAJOR_NR;
-		disk->first_minor = 0;
+		disk->first_minor = i;
 		disk->minor_shift = 0;
 		disk->fops = &rd_bd_op;
 		sprintf(disk->disk_name, "rd%d", i);
diff -urN C41-0/drivers/ide/legacy/hd.c C41-HD_IRQ/drivers/ide/legacy/hd.c
--- C41-0/drivers/ide/legacy/hd.c	Mon Oct  7 15:55:58 2002
+++ C41-HD_IRQ/drivers/ide/legacy/hd.c	Mon Oct  7 16:35:19 2002
@@ -50,8 +50,6 @@
 #define DEVICE_NR(device) (minor(device)>>6)
 #include <linux/blk.h>
 
-#define HD_IRQ 14	/* the standard disk interrupt */
-
 #ifdef __arm__
 #undef  HD_IRQ
 #endif
diff -urN C41-0/include/linux/hdreg.h C41-HD_IRQ/include/linux/hdreg.h
--- C41-0/include/linux/hdreg.h	Wed Sep 18 00:52:23 2002
+++ C41-HD_IRQ/include/linux/hdreg.h	Mon Oct  7 16:35:19 2002
@@ -8,6 +8,8 @@
 
 /* ide.c has its own port definitions in "ide.h" */
 
+#define HD_IRQ		14
+
 /* Hd controller regs. Ref: IBM AT Bios-listing */
 #define HD_DATA		0x1f0		/* _CTL when writing */
 #define HD_ERROR	0x1f1		/* see err-bits */


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] 2.5.41: cpqarray compile fixes
  2002-10-07 23:39 ` Alexander Viro
@ 2002-10-08  0:49   ` Adam Kropelin
  0 siblings, 0 replies; 3+ messages in thread
From: Adam Kropelin @ 2002-10-08  0:49 UTC (permalink / raw)
  To: Alexander Viro; +Cc: Linus Torvalds, linux-kernel

On Mon, Oct 07, 2002 at 07:39:46PM -0400, Alexander Viro wrote:
>
> On Mon, 7 Oct 2002, Adam Kropelin wrote:
> > cpqarray in 2.5.41 needs the patch below to compile. 
>
> Yeah, and more than that.  Same typo is in cciss, rd.c sets ->first_minor to
> 0 for all units and HD_IRQ definition is needed if CONFIG_BLK_DEV_HD is
> defined.

Don't forget the second part of that patch ;) Also I've verified cpqarray still
needs the queue plugging fixed in order to not deadlock here. The stopgap patch
I sent you the other day still works for now. I'll work up a better fix soon.

--Adam


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2002-10-08  0:44 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2002-10-07 23:36 [PATCH] 2.5.41: cpqarray compile fixes Adam Kropelin
2002-10-07 23:39 ` Alexander Viro
2002-10-08  0:49   ` Adam Kropelin

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).