* [parisc-linux] mkraid doesnt work on L2000 with 64-bit kernel
@ 2002-04-30 5:58 James Braid
2002-04-30 23:57 ` Paul Bame
2002-05-01 0:42 ` Grant Grundler
0 siblings, 2 replies; 11+ messages in thread
From: James Braid @ 2002-04-30 5:58 UTC (permalink / raw)
To: parisc-linux
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
I have a dual CPU L2000 and have installed the 0.9.3 release of
PA-RISC Linux and dist-upgraded to the latest unstable Debian
packages. I am running kernel 2.4.9-64, but this problem also occurs
with 2.4.17-64-smp and non-smp, and 2.4.18-64-smp and non-smp.
When I attempt to make a software RAID0 array on 3 1Gb partitions on
3 18.2gb internal SCSI disks, I get this error:
hypo:~# mkraid /dev/md0
handling MD device /dev/md0
analyzing super-block
disk 0: /dev/sdb1, 976880kB, raid superblock at 976768kB
disk 1: /dev/sdc1, 976880kB, raid superblock at 976768kB
disk 2: /dev/sdd1, 976880kB, raid superblock at 976768kB
mkraid: aborted, see the syslog and /proc/mdstat for potential clues.
Syslog says:
hypo:~# tail /var/log/syslog
Apr 30 05:36:34 hypo kernel: sys32_ioctl: Unknown cmd fd(3)
cmd(400c0910) arg(00028a44)
Apr 30 05:36:34 hypo kernel: sys32_ioctl: Unknown cmd fd(4)
cmd(400c0910) arg(bff00350)
Apr 30 05:36:34 hypo kernel: sys32_ioctl: Unknown cmd fd(4)
cmd(80480923) arg(00029390)
/proc/mdstat says:
hypo:~# cat /proc/mdstat
Personalities : [raid0]
read_ahead not set
unused devices: <none>
I've had a look through the archives and found a few posts about
32-bit to 64-bit IOCTLs but nothing seemed to specifically mention
the RAID stuff.
I also had a look in arch/parisc/kernel/ioctl32.c and there were a
couple of lines commented out with comments like "new RAID code is
half merged". Is RAID on 64-bit PA-RISC a work in progress?
Also, I have noticed that the 2nd CPU in the L2000 is always disabled
when I boot with a SMP kernel, errors like SMP: CPU3 is stuck appear
near the start of bootup. (Sorry I don't have any more detail on
these, but I can provide it if needed)
Any ideas/help would be greatly appreciated. I can provide more
details if needed.
Cheers, James
BTW: Great job on the port to PA-RISC :)
-----BEGIN PGP SIGNATURE-----
Version: PGP 7.1.1
iQA/AwUBPM4yo1W+bhIOiSqWEQJSZQCguc5h0mrXQ7pD352VuLeZDeSJ7PkAnjdl
P8k6Y/oUEcFa8kS95ISO+xQz
=2axk
-----END PGP SIGNATURE-----
^ permalink raw reply [flat|nested] 11+ messages in thread
* Re: [parisc-linux] mkraid doesnt work on L2000 with 64-bit kernel
2002-04-30 5:58 [parisc-linux] mkraid doesnt work on L2000 with 64-bit kernel James Braid
@ 2002-04-30 23:57 ` Paul Bame
2002-05-01 0:42 ` Grant Grundler
1 sibling, 0 replies; 11+ messages in thread
From: Paul Bame @ 2002-04-30 23:57 UTC (permalink / raw)
To: James Braid; +Cc: parisc-linux
> I also had a look in arch/parisc/kernel/ioctl32.c and there were a
> couple of lines commented out with comments like "new RAID code is
> half merged". Is RAID on 64-bit PA-RISC a work in progress?
Yeah, if you're doing it :-> If you'd like to post a patch for
translating those ioctl calls that would be great! I think proper
translation of the relevent ioctls is all that's needed.
-P
^ permalink raw reply [flat|nested] 11+ messages in thread
* Re: [parisc-linux] mkraid doesnt work on L2000 with 64-bit kernel
2002-04-30 5:58 [parisc-linux] mkraid doesnt work on L2000 with 64-bit kernel James Braid
2002-04-30 23:57 ` Paul Bame
@ 2002-05-01 0:42 ` Grant Grundler
2002-05-01 1:15 ` James Braid
2002-05-01 1:25 ` James Braid
1 sibling, 2 replies; 11+ messages in thread
From: Grant Grundler @ 2002-05-01 0:42 UTC (permalink / raw)
To: James Braid; +Cc: parisc-linux
"James Braid" wrote:
> When I attempt to make a software RAID0 array on 3 1Gb partitions on
> 3 18.2gb internal SCSI disks, I get this error:
I just wanted to provide confirmation this is only a problem of
the ioctl wrappers missing which are needed by 64-bit kernels.
L2000 requires 64-bit kernel.
I currently have a (hardly used) md0 on my B180:
debian:~# df
Filesystem 1k-blocks Used Available Use% Mounted on
/dev/sde3 1451376 689608 688040 51% /
/dev/sde4 6784352 3743488 2696240 59% /home
/dev/md0 65832516 32836 65130848 1% /var/www
debian:~# cat /etc/raidtab
raiddev /dev/md0
raid-level 0
nr-raid-disks 8
persistent-superblock 1
chunk-size 8
device /dev/sda
raid-disk 0
device /dev/sdb
raid-disk 1
...
grant
^ permalink raw reply [flat|nested] 11+ messages in thread* RE: [parisc-linux] mkraid doesnt work on L2000 with 64-bit kernel
2002-05-01 0:42 ` Grant Grundler
@ 2002-05-01 1:15 ` James Braid
2002-05-01 1:25 ` James Braid
1 sibling, 0 replies; 11+ messages in thread
From: James Braid @ 2002-05-01 1:15 UTC (permalink / raw)
To: 'Grant Grundler'; +Cc: parisc-linux
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Cool. I have sort of brute forced the ioctl things from sparc64 in,
and the kernel compiles, and I will reboot shortly to test it.
Thanks, James
> I just wanted to provide confirmation this is only a problem of
> the ioctl wrappers missing which are needed by 64-bit kernels.
> L2000 requires 64-bit kernel.
>
> I currently have a (hardly used) md0 on my B180:
> debian:~# df
> Filesystem 1k-blocks Used Available Use% Mounted on
> /dev/sde3 1451376 689608 688040 51% /
> /dev/sde4 6784352 3743488 2696240 59% /home
> /dev/md0 65832516 32836 65130848 1% /var/www
> debian:~# cat /etc/raidtab
> raiddev /dev/md0
> raid-level 0
> nr-raid-disks 8
> persistent-superblock 1
> chunk-size 8
>
> device /dev/sda
> raid-disk 0
> device /dev/sdb
> raid-disk 1
> ...
>
>
> grant
-----BEGIN PGP SIGNATURE-----
Version: PGP 7.1.1
iQA/AwUBPM9BwFW+bhIOiSqWEQJWhACfSpCPShEd/If0CC9Gzjprt0feQIwAn2NQ
ssVQmGnA3jC3vCvFv0wsaMJ/
=L0iG
-----END PGP SIGNATURE-----
^ permalink raw reply [flat|nested] 11+ messages in thread
* RE: [parisc-linux] mkraid doesnt work on L2000 with 64-bit kernel
2002-05-01 0:42 ` Grant Grundler
2002-05-01 1:15 ` James Braid
@ 2002-05-01 1:25 ` James Braid
2002-05-01 2:08 ` Matthew Wilcox
2002-05-01 3:42 ` Grant Grundler
1 sibling, 2 replies; 11+ messages in thread
From: James Braid @ 2002-05-01 1:25 UTC (permalink / raw)
To: parisc-linux
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Woohoo! Just rebooted the L2000 and RAID is now working on it :)
How do I go about submitting a patch (sorry, I am a complete newbie
to kernel stuff).
Basically all I have done is copy the RAID section from the sparc64
ioctl32.c into the parisc ioctl32.c file, and fix up the md.h
include.
Just some output:
hypo:/raid# cat /proc/mdstat
Personalities : [linear] [raid0] [raid1] [raid5]
read_ahead 1024 sectors
md0 : active raid0 sdd1[2] sdc1[1] sdb1[0]
2930640 blocks 16k chunks
unused devices: <none>
hypo:/raid# df -k
Filesystem 1k-blocks Used Available Use% Mounted on
/dev/sda4 15458288 848292 13824744 6% /
/dev/sda2 60485 13835 43527 25% /boot
/dev/md0 2884592 32836 2705224 2% /raid
Cheers, James
-----BEGIN PGP SIGNATURE-----
Version: PGP 7.1.1
iQA/AwUBPM9D/FW+bhIOiSqWEQKeaQCeN5cXOfXz4Z0Pi1Jed9k0lGpldfAAn1G3
RrlNIJ0T8Gr/X11uUkblt/7h
=xtyl
-----END PGP SIGNATURE-----
^ permalink raw reply [flat|nested] 11+ messages in thread* Re: [parisc-linux] mkraid doesnt work on L2000 with 64-bit kernel
2002-05-01 1:25 ` James Braid
@ 2002-05-01 2:08 ` Matthew Wilcox
2002-05-01 3:42 ` Grant Grundler
1 sibling, 0 replies; 11+ messages in thread
From: Matthew Wilcox @ 2002-05-01 2:08 UTC (permalink / raw)
To: James Braid; +Cc: parisc-linux
On Wed, May 01, 2002 at 01:25:17PM +1200, James Braid wrote:
> Woohoo! Just rebooted the L2000 and RAID is now working on it :)
Yay! Apply for your "I hacked the PA/Linux kernel" badge at the office ;-)
> How do I go about submitting a patch (sorry, I am a complete newbie
> to kernel stuff).
If it's small (say <20k), post it here. If larger, put it on a
website and send a URL.
> Basically all I have done is copy the RAID section from the sparc64
> ioctl32.c into the parisc ioctl32.c file, and fix up the md.h
> include.
Cool. That works for us ;-)
--
Revolutions do not require corporate support.
^ permalink raw reply [flat|nested] 11+ messages in thread
* Re: [parisc-linux] mkraid doesnt work on L2000 with 64-bit kernel
2002-05-01 1:25 ` James Braid
2002-05-01 2:08 ` Matthew Wilcox
@ 2002-05-01 3:42 ` Grant Grundler
2002-05-01 4:23 ` James Braid
1 sibling, 1 reply; 11+ messages in thread
From: Grant Grundler @ 2002-05-01 3:42 UTC (permalink / raw)
To: James Braid; +Cc: parisc-linux
"James Braid" wrote:
> How do I go about submitting a patch (sorry, I am a complete newbie
> to kernel stuff).
grab the cvsrc from
http://cvs.parisc-linux.org/build-tools/cvsrc?rev=1.2&content-type=text/vnd.viewcvs-markup
and drop that in your ~/.cvsrc.
How-to use anonymous CVS is described on http://cvs.parisc-linux.org/
Basically a patch is the "cvs diff" output of all modified files.
grant
^ permalink raw reply [flat|nested] 11+ messages in thread
* RE: [parisc-linux] mkraid doesnt work on L2000 with 64-bit kernel
2002-05-01 3:42 ` Grant Grundler
@ 2002-05-01 4:23 ` James Braid
2002-05-01 4:30 ` James Braid
2002-05-01 4:31 ` James Braid
0 siblings, 2 replies; 11+ messages in thread
From: James Braid @ 2002-05-01 4:23 UTC (permalink / raw)
To: parisc-linux
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Okay, well here's my patch for RAID on 64-bit Linux/PA-RISC. This is
the diff of the two files before and after:
8<---- START ----8<
- --- kernel-source-2.4.17-hppa/arch/parisc/kernel/ioctl32.c Fri
Nov 2 18:54:54 2001
+++ kernel-source-2.4.17-hppa-patch/arch/parisc/kernel/ioctl32.c
Wed May 1 03:46:28 2002
@@ -19,9 +19,7 @@
#include <linux/if.h>
#include <linux/slab.h>
#include <linux/hdreg.h>
- -#if 0 /* New RAID code is half-merged... -DaveM */
- -#include <linux/md.h>
- -#endif
+#include <linux/raid/md.h>
#include <linux/kd.h>
#include <linux/route.h>
#include <linux/skbuff.h>
@@ -2880,16 +2878,26 @@ COMPATIBLE_IOCTL(BLKFRASET)
COMPATIBLE_IOCTL(BLKSECTSET)
COMPATIBLE_IOCTL(BLKSSZGET)
- -#if 0
- - /* New RAID code is being merged, fix up to handle
- - * new RAID ioctls when fully merged in 2.3.x -DaveM
- - */
- -/* 0x09 */
- -COMPATIBLE_IOCTL(REGISTER_DEV)
- -COMPATIBLE_IOCTL(REGISTER_DEV_NEW)
- -COMPATIBLE_IOCTL(START_MD)
- -COMPATIBLE_IOCTL(STOP_MD)
- -#endif
+/* RAID */
+COMPATIBLE_IOCTL(RAID_VERSION)
+COMPATIBLE_IOCTL(GET_ARRAY_INFO)
+COMPATIBLE_IOCTL(GET_DISK_INFO)
+COMPATIBLE_IOCTL(PRINT_RAID_DEBUG)
+COMPATIBLE_IOCTL(CLEAR_ARRAY)
+COMPATIBLE_IOCTL(ADD_NEW_DISK)
+COMPATIBLE_IOCTL(HOT_REMOVE_DISK)
+COMPATIBLE_IOCTL(SET_ARRAY_INFO)
+COMPATIBLE_IOCTL(SET_DISK_INFO)
+COMPATIBLE_IOCTL(WRITE_RAID_INFO)
+COMPATIBLE_IOCTL(UNPROTECT_ARRAY)
+COMPATIBLE_IOCTL(PROTECT_ARRAY)
+COMPATIBLE_IOCTL(HOT_ADD_DISK)
+COMPATIBLE_IOCTL(SET_DISK_FAULTY)
+COMPATIBLE_IOCTL(RUN_ARRAY)
+COMPATIBLE_IOCTL(START_ARRAY)
+COMPATIBLE_IOCTL(STOP_ARRAY)
+COMPATIBLE_IOCTL(STOP_ARRAY_RO)
+COMPATIBLE_IOCTL(RESTART_ARRAY_RW)
/* Big K */
COMPATIBLE_IOCTL(PIO_FONT)
8<---- END ----8<
Hopefully this is the right format and everything. I have been
testing it for a few hours and it seems to work fine.
Cheers, James
-----BEGIN PGP SIGNATURE-----
Version: PGP 7.1.1
iQA/AwUBPM9trVW+bhIOiSqWEQLElwCfV0rBq2eNinQrDa+C4iP4/oLDr7oAnRUa
laoVuvja3MPuH3rH9qVAXGCp
=qIsc
-----END PGP SIGNATURE-----
^ permalink raw reply [flat|nested] 11+ messages in thread
* RE: [parisc-linux] mkraid doesnt work on L2000 with 64-bit kernel
2002-05-01 4:23 ` James Braid
@ 2002-05-01 4:30 ` James Braid
2002-05-01 4:31 ` James Braid
1 sibling, 0 replies; 11+ messages in thread
From: James Braid @ 2002-05-01 4:30 UTC (permalink / raw)
To: parisc-linux
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Damnit, Outlook screwed up the patch. Lets try again:
- --- kernel-source-2.4.17-hppa/arch/parisc/kernel/ioctl32.c Fri
Nov 2 18:54:54 2001
+++ kernel-source-2.4.17-hppa-patch/arch/parisc/kernel/ioctl32.c
Wed May 1 03:46:28 2002
@@ -19,9 +19,7 @@
#include <linux/if.h>
#include <linux/slab.h>
#include <linux/hdreg.h>
- -#if 0 /* New RAID code is half-merged... -DaveM */
- -#include <linux/md.h>
- -#endif
+#include <linux/raid/md.h>
#include <linux/kd.h>
#include <linux/route.h>
#include <linux/skbuff.h>
@@ -2880,16 +2878,26 @@ COMPATIBLE_IOCTL(BLKFRASET)
COMPATIBLE_IOCTL(BLKSECTSET)
COMPATIBLE_IOCTL(BLKSSZGET)
- -#if 0
- - /* New RAID code is being merged, fix up to handle
- - * new RAID ioctls when fully merged in 2.3.x -DaveM
- - */
- -/* 0x09 */
- -COMPATIBLE_IOCTL(REGISTER_DEV)
- -COMPATIBLE_IOCTL(REGISTER_DEV_NEW)
- -COMPATIBLE_IOCTL(START_MD)
- -COMPATIBLE_IOCTL(STOP_MD)
- -#endif
+/* RAID */
+COMPATIBLE_IOCTL(RAID_VERSION)
+COMPATIBLE_IOCTL(GET_ARRAY_INFO)
+COMPATIBLE_IOCTL(GET_DISK_INFO)
+COMPATIBLE_IOCTL(PRINT_RAID_DEBUG)
+COMPATIBLE_IOCTL(CLEAR_ARRAY)
+COMPATIBLE_IOCTL(ADD_NEW_DISK)
+COMPATIBLE_IOCTL(HOT_REMOVE_DISK)
+COMPATIBLE_IOCTL(SET_ARRAY_INFO)
+COMPATIBLE_IOCTL(SET_DISK_INFO)
+COMPATIBLE_IOCTL(WRITE_RAID_INFO)
+COMPATIBLE_IOCTL(UNPROTECT_ARRAY)
+COMPATIBLE_IOCTL(PROTECT_ARRAY)
+COMPATIBLE_IOCTL(HOT_ADD_DISK)
+COMPATIBLE_IOCTL(SET_DISK_FAULTY)
+COMPATIBLE_IOCTL(RUN_ARRAY)
+COMPATIBLE_IOCTL(START_ARRAY)
+COMPATIBLE_IOCTL(STOP_ARRAY)
+COMPATIBLE_IOCTL(STOP_ARRAY_RO)
+COMPATIBLE_IOCTL(RESTART_ARRAY_RW)
/* Big K */
COMPATIBLE_IOCTL(PIO_FONT)
-----BEGIN PGP SIGNATURE-----
Version: PGP 7.1.1
iQA/AwUBPM9valW+bhIOiSqWEQJbowCfez+Sb6Men2Z8T/ljnWjjW+smEtAAoPAu
Vjzu9ywhCGI84WvC1scXkfgP
=QUrJ
-----END PGP SIGNATURE-----
^ permalink raw reply [flat|nested] 11+ messages in thread
* RE: [parisc-linux] mkraid doesnt work on L2000 with 64-bit kernel
2002-05-01 4:23 ` James Braid
2002-05-01 4:30 ` James Braid
@ 2002-05-01 4:31 ` James Braid
2002-05-01 5:10 ` Randolph Chung
1 sibling, 1 reply; 11+ messages in thread
From: James Braid @ 2002-05-01 4:31 UTC (permalink / raw)
To: parisc-linux
Arrrgh, sorry for this. Take 3:
--- kernel-source-2.4.17-hppa/arch/parisc/kernel/ioctl32.c Fri Nov
2 18:54:54 2001
+++ kernel-source-2.4.17-hppa-patch/arch/parisc/kernel/ioctl32.c
Wed May 1 03:46:28 2002
@@ -19,9 +19,7 @@
#include <linux/if.h>
#include <linux/slab.h>
#include <linux/hdreg.h>
-#if 0 /* New RAID code is half-merged... -DaveM */
-#include <linux/md.h>
-#endif
+#include <linux/raid/md.h>
#include <linux/kd.h>
#include <linux/route.h>
#include <linux/skbuff.h>
@@ -2880,16 +2878,26 @@ COMPATIBLE_IOCTL(BLKFRASET)
COMPATIBLE_IOCTL(BLKSECTSET)
COMPATIBLE_IOCTL(BLKSSZGET)
-#if 0
- /* New RAID code is being merged, fix up to handle
- * new RAID ioctls when fully merged in 2.3.x -DaveM
- */
-/* 0x09 */
-COMPATIBLE_IOCTL(REGISTER_DEV)
-COMPATIBLE_IOCTL(REGISTER_DEV_NEW)
-COMPATIBLE_IOCTL(START_MD)
-COMPATIBLE_IOCTL(STOP_MD)
-#endif
+/* RAID */
+COMPATIBLE_IOCTL(RAID_VERSION)
+COMPATIBLE_IOCTL(GET_ARRAY_INFO)
+COMPATIBLE_IOCTL(GET_DISK_INFO)
+COMPATIBLE_IOCTL(PRINT_RAID_DEBUG)
+COMPATIBLE_IOCTL(CLEAR_ARRAY)
+COMPATIBLE_IOCTL(ADD_NEW_DISK)
+COMPATIBLE_IOCTL(HOT_REMOVE_DISK)
+COMPATIBLE_IOCTL(SET_ARRAY_INFO)
+COMPATIBLE_IOCTL(SET_DISK_INFO)
+COMPATIBLE_IOCTL(WRITE_RAID_INFO)
+COMPATIBLE_IOCTL(UNPROTECT_ARRAY)
+COMPATIBLE_IOCTL(PROTECT_ARRAY)
+COMPATIBLE_IOCTL(HOT_ADD_DISK)
+COMPATIBLE_IOCTL(SET_DISK_FAULTY)
+COMPATIBLE_IOCTL(RUN_ARRAY)
+COMPATIBLE_IOCTL(START_ARRAY)
+COMPATIBLE_IOCTL(STOP_ARRAY)
+COMPATIBLE_IOCTL(STOP_ARRAY_RO)
+COMPATIBLE_IOCTL(RESTART_ARRAY_RW)
/* Big K */
COMPATIBLE_IOCTL(PIO_FONT)
^ permalink raw reply [flat|nested] 11+ messages in thread
end of thread, other threads:[~2002-05-01 5:06 UTC | newest]
Thread overview: 11+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2002-04-30 5:58 [parisc-linux] mkraid doesnt work on L2000 with 64-bit kernel James Braid
2002-04-30 23:57 ` Paul Bame
2002-05-01 0:42 ` Grant Grundler
2002-05-01 1:15 ` James Braid
2002-05-01 1:25 ` James Braid
2002-05-01 2:08 ` Matthew Wilcox
2002-05-01 3:42 ` Grant Grundler
2002-05-01 4:23 ` James Braid
2002-05-01 4:30 ` James Braid
2002-05-01 4:31 ` James Braid
2002-05-01 5:10 ` Randolph Chung
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox