diff options
| author | Jamie Lenehan <lenehan@twibble.org> | 2006-07-03 03:29:47 +0000 |
|---|---|---|
| committer | OpenEmbedded Project <openembedded-devel@lists.openembedded.org> | 2006-07-03 03:29:47 +0000 |
| commit | 314731d7c422279c41de7b7c1921497226237498 (patch) | |
| tree | 057785a345ea444287c21562de5110695589ba01 | |
| parent | 0634f7bc2185bf1c2caac4eee98473af8b569048 (diff) | |
| parent | 660a0feb66e64979ec74a6e58d0b8d190bd4e5eb (diff) | |
merge of 975b96916690358f4a6cab8fbb7308fce112d311
and b97ad46b88a01ddecefed222491f15a9b1ba45c9
52 files changed, 5791 insertions, 553 deletions
diff --git a/conf/distro/jlime-donkey.conf b/conf/distro/jlime-donkey.conf index a103ddaf7c..89a10705ca 100644 --- a/conf/distro/jlime-donkey.conf +++ b/conf/distro/jlime-donkey.conf @@ -78,7 +78,7 @@ BOOTSTRAP_EXTRA_DEPENDS += "pcmciautils ncurses nano wireless-tools console-too #<> #<>What Opie version should we use. #<> -OPIE_VERSION = "1.2.2" +OPIE_VERSION = "1.2.3" include conf/distro/preferred-opie-versions.inc #<> diff --git a/packages/opie-appearance/opie-appearance-1.2.1/.mtn2git_empty b/packages/lilo-sh/.mtn2git_empty index e69de29bb2..e69de29bb2 100644 --- a/packages/opie-appearance/opie-appearance-1.2.1/.mtn2git_empty +++ b/packages/lilo-sh/.mtn2git_empty diff --git a/packages/opie-backup/opie-backup-1.2.1/.mtn2git_empty b/packages/lilo-sh/files/.mtn2git_empty index e69de29bb2..e69de29bb2 100644 --- a/packages/opie-backup/opie-backup-1.2.1/.mtn2git_empty +++ b/packages/lilo-sh/files/.mtn2git_empty diff --git a/packages/lilo-sh/files/lilo-0.21-1.1.patch b/packages/lilo-sh/files/lilo-0.21-1.1.patch new file mode 100644 index 0000000000..dfbab2a82c --- /dev/null +++ b/packages/lilo-sh/files/lilo-0.21-1.1.patch @@ -0,0 +1,35 @@ +--- lilo/Makefile- Fri Dec 4 15:35:07 1998 ++++ lilo/Makefile Wed Mar 17 01:04:07 1999 +@@ -24,7 +24,7 @@ + # VARSETUP Enables use of variable-size setup segments. + # XL_SECS=n Support for extra large (non-standard) floppies. + +-CONFIG=-DIGNORECASE -DVARSETUP -DREWRITE_TABLE ++CONFIG=-DIGNORECASE -DVARSETUP -DREWRITE_TABLE -DLARGE_EBDA -DONE_SHOT + + # End of configuration variables + +--- lilo/second.S- Fri Dec 4 15:20:07 1998 ++++ lilo/second.S Wed Mar 17 01:03:53 1999 +@@ -830,9 +830,20 @@ + call load1 + seg es + mov CL_MAGIC_ADDR,#CL_MAGIC ! set magic number ++#ifndef LCF_LARGE_EBDA + seg es + mov word ptr CL_OFFSET,#PARMLINE+SECOND_SS + ! set parameter line offset ++#else ++ mov di,#0x8000 ++ mov si,#PARMLINE ++ mov cx,#CL_LENGTH ++ rep ++ movsb ++ seg es ++ mov word ptr CL_OFFSET,#0x8000 ++ ! set parameter line offset ++#endif + pop si ! restore SI + lodsw ! get flags bit map + mov bx,ax + diff --git a/packages/lilo-sh/files/lilo-0.21-include.patch b/packages/lilo-sh/files/lilo-0.21-include.patch new file mode 100644 index 0000000000..61e298013c --- /dev/null +++ b/packages/lilo-sh/files/lilo-0.21-include.patch @@ -0,0 +1,10 @@ +--- lilo.orig/common.h Wed Oct 14 17:44:28 1998 ++++ lilo/common.h Mon Dec 7 18:05:17 1998 +@@ -7,6 +7,7 @@ + #define COMMON_H + + #include <sys/stat.h> ++#include <asm/types.h> + #include <linux/genhd.h> + + #include "lilo.h" diff --git a/packages/lilo-sh/files/lilo-0.21-loopdev.patch b/packages/lilo-sh/files/lilo-0.21-loopdev.patch new file mode 100644 index 0000000000..e739c5b104 --- /dev/null +++ b/packages/lilo-sh/files/lilo-0.21-loopdev.patch @@ -0,0 +1,11 @@ +--- lilo/device.c.oot Mon Jan 10 09:37:00 2000 ++++ lilo/device.c Mon Jan 10 09:37:37 2000 +@@ -192,4 +192,8 @@ + sprintf(tmp,"/dev/sdb%d",i); + cache_add(tmp,0x810+i); + } ++ for (i = 0; i <= 7; i++) { ++ sprintf(tmp,"/dev/loop%d",i); ++ cache_add(tmp,0x700+i); ++ } + } diff --git a/packages/lilo-sh/files/lilo-0.21-second.patch b/packages/lilo-sh/files/lilo-0.21-second.patch new file mode 100644 index 0000000000..12a9af04c7 --- /dev/null +++ b/packages/lilo-sh/files/lilo-0.21-second.patch @@ -0,0 +1,36 @@ +I have a problem to report with lilo, and the fix for it. I am not sure +whether this is the right place for it though, I am also CCing the lilo +maintainer Werner Almesberger. + +When lilo gets control from the bios (whether lilo is on disk, or on the +floppy), it is checking the wrong location when it tries to parse the +parameter line construction area to determine whether it needs to clean +up extra blank spaces. This is causing lilo to eat up the last character(s) +of the command line that it passes to the kernel. + +Specifically, the code + +cpcodn: cmp byte ptr (di-1),#32 ! last was space ? + +is using the memory contents of ds:di-1 for the compare. It should +really be using es:di-1. I checked, ds=0x0b00 around here, so the +code ended up checking 0x0b00:(di-1) instead of 0x9000:(di-1). It +is quite possible that the memory that lilo checks has garbage, +causing it to make wrong decision. A "seg es" just before the cmp +fixes the problem. I am attaching the patch below. + +Kanoj + +--- second.0 Mon Sep 20 13:52:01 1999 ++++ second.S Tue Sep 28 10:20:54 1999 +@@ -816,7 +816,8 @@ + je cpcodsp ! yes -> discard next + lodsb ! get next byte + jmp cpcolp +-cpcodn: cmp byte ptr (di-1),#32 ! last was space ? ++cpcodn: seg es ++ cmp byte ptr (di-1),#32 ! last was space ? + jne nocopt ! no -> go on + dec di ! discard it + nocopt: mov si,options ! append variable options + diff --git a/packages/lilo-sh/files/lilo-linkgear.patch b/packages/lilo-sh/files/lilo-linkgear.patch new file mode 100644 index 0000000000..598a92a7af --- /dev/null +++ b/packages/lilo-sh/files/lilo-linkgear.patch @@ -0,0 +1,1039 @@ +diff -Naur --exclude=CVS --exclude='*.orig' lilo/Makefile lilosh/Makefile +--- lilo/Makefile 2006-02-01 21:16:29.000000000 +0000 ++++ lilosh/Makefile 2006-02-01 21:23:37.000000000 +0000 +@@ -40,7 +40,6 @@ + + SHELL=/bin/sh + +-CROSS_COMPILE = sh3-linux- + CC =$(CROSS_COMPILE)gcc + LD =$(CROSS_COMPILE)ld + OBJCOPY =$(CROSS_COMPILE)objcopy +@@ -72,10 +71,10 @@ + $(OBJCOPY) -R .comment -S second.exe -O binary second.bin + + first.exe: first.o +- $(LD) -EL -e start first.o -o first.exe -Ttext 0x8c200000 ++ $(LD) -EL -e start first.o -o first.exe -Ttext 0x88a00000 + + second.exe: second.o string.o +- $(LD) -T second.lds -EL second.o string.o -o second.exe -Ttext 0x8c201000 ++ $(LD) -T second.lds -EL second.o string.o -o second.exe -Ttext 0x88a01000 + + first.o: first.S + $(CC) $(CFLAGS) -c first.S +diff -Naur --exclude=CVS --exclude='*.orig' lilo/boot.c lilosh/boot.c +--- lilo/boot.c 1997-06-20 12:48:28.000000000 +0000 ++++ lilosh/boot.c 2006-01-31 19:46:21.000000000 +0000 +@@ -11,6 +11,7 @@ + #include <errno.h> + #include <a.out.h> + #include <sys/stat.h> ++#include <asm/page.h> + + #include "config.h" + #include "common.h" +@@ -70,6 +71,7 @@ + geo_close(&geo); + if (verbose > 1) + printf("Mapped %d sector%s.\n",sectors,sectors == 1 ? "" : "s"); ++ memset(&descr->initrd, 0, sizeof(descr->initrd)); + if ((initrd = cfg_get_strg(cf_kernel,"initrd")) || (initrd = cfg_get_strg( + cf_options,"initrd"))) { + if (!modern_kernel) die("Kernel doesn't support initial RAM disks"); +diff -Naur --exclude=CVS --exclude='*.orig' lilo/bsect.c lilosh/bsect.c +--- lilo/bsect.c 1998-10-14 20:30:32.000000000 +0000 ++++ lilosh/bsect.c 2004-10-01 19:05:58.000000000 +0000 +@@ -189,11 +189,11 @@ + } + } + bsect.par_1.prompt = cfg_get_flag(cf_options,"prompt"); +- if (delay*100/55 > 0xffff) die("Maximum delay is one hour."); +- else bsect.par_1.delay = delay*100/55; ++ if (delay >= 36000) die("Maximum delay is one hour."); ++ else bsect.par_1.delay = delay; + if (timeout == -1) bsect.par_1.timeout = 0xffff; +- else if (timeout*100/55 >= 0xffff) die("Maximum timeout is one hour."); +- else bsect.par_1.timeout = timeout*100/55; ++ else if (timeout >= 36000) die("Maximum timeout is one hour."); ++ else bsect.par_1.timeout = timeout; + if (!(keytable = cfg_get_strg(cf_options,"keytable"))) { + int i; + +diff -Naur --exclude=CVS --exclude='*.orig' lilo/defs.h lilosh/defs.h +--- lilo/defs.h 2006-02-01 21:16:29.000000000 +0000 ++++ lilosh/defs.h 2004-05-19 16:39:08.000000000 +0000 +@@ -1,2 +1,3 @@ + extern void *memcpy (void *__dest, const void *__src, unsigned int __n); + extern int strlen (__const char *__s); ++extern void *memset(void *s, int c, unsigned int n); +diff -Naur --exclude=CVS --exclude='*.orig' lilo/first.S lilosh/first.S +--- lilo/first.S 2006-02-01 21:16:29.000000000 +0000 ++++ lilosh/first.S 2006-02-01 22:02:02.000000000 +0000 +@@ -1,4 +1,4 @@ +-/* $Id: first.S,v 1.16 2000/11/26 07:11:58 gniibe Exp $ ++/* $Id: first.S,v 1.1.1.1 2002/05/15 06:44:39 bmann Exp $ + * + * Primary boot loader + * +@@ -54,7 +54,7 @@ + ! /* ^--- Minor Version*/ + #endif + +-/* x86 LILO parameters (Not used for SuperH... yet) */ ++/* x86 LILO parameters (port and sparam not used for SuperH... yet) */ + timeout:.word 0 ! input timeout + delay: .word 0 ! boot delay + port: .byte 0 ! COM port (0 = unused, 1 = COM1, etc.) +@@ -67,11 +67,13 @@ + d1_cx: .word 0 + d1_dx: .word 0 + d1_al: .byte 0 ++ .byte 0 ! align next .word + + /* Second descripter sector (Filled by LILO command) */ + d2_cx: .word 0 + d2_dx: .word 0 + d2_al: .byte 0 ++ .byte 0 ! align next .word + + /* Default command-line sector (Filled by LILO command) */ + dc_cx: .word 0 +@@ -87,11 +89,13 @@ + ms_cx: .word 0 + ms_dx: .word 0 + ms_al: .byte 0 ++ .byte 0 ! align next .word + + /* Second descripter sector (Filled by LILO command) */ + kt_cx: .word 0 ! keyboard translation table + kt_dx: .word 0 + kt_al: .byte 0 ++ .byte 0 ! align next .long + + d_addr: ! second stage sector addresses + +diff -Naur --exclude=CVS --exclude='*.orig' lilo/geometry.c lilosh/geometry.c +--- lilo/geometry.c 2006-02-01 21:15:51.000000000 +0000 ++++ lilosh/geometry.c 2006-02-01 22:13:05.000000000 +0000 +@@ -16,6 +16,7 @@ + #include <linux/fs.h> + #include <linux/fd.h> + #include <linux/hdreg.h> ++#include <linux/kdev_t.h> + + #include "config.h" + #include "lilo.h" +@@ -37,7 +38,7 @@ + + + DT_ENTRY *disktab = NULL; +-int old_disktab = 0; ++static int old_disktab = 0; + + + void geo_init(char *name) +@@ -297,6 +298,7 @@ + case MAJOR_ESDI: + /* fall through */ + case MAJOR_XT: ++ /* fall through */ + geo->device = 0x80+(MINOR(device) >> 6)+(MAJOR(device) == MAJOR_HD ? + 0 : last_dev(MAJOR_HD,64)); + if (ioctl(fd,HDIO_GETGEO,&hdprm) < 0) +@@ -353,6 +355,17 @@ + geo->sectors = hdprm.sectors; + geo->start = hdprm.start; + break; ++ case MAJOR_NAND: ++ /* fall through */ ++ geo->device = 0x80+(MINOR(device)); ++ if (ioctl(fd,HDIO_GETGEO,&hdprm) < 0) ++ die("geo_query_dev HDIO_GETGEO (dev 0x%04x): %s",device, ++ strerror(errno)); ++ geo->heads = hdprm.heads; ++ geo->cylinders = hdprm.cylinders; ++ geo->sectors = hdprm.sectors; ++ geo->start = hdprm.start; ++ break; + + default: + die("Sorry, don't know how to handle device 0x%04x",device); +diff -Naur --exclude=CVS --exclude='*.orig' lilo/geometry.h lilosh/geometry.h +--- lilo/geometry.h 2006-02-01 21:15:51.000000000 +0000 ++++ lilosh/geometry.h 2006-02-01 22:14:07.000000000 +0000 +@@ -8,7 +8,6 @@ + + #include "lilo.h" + +- + typedef struct { + int device,heads; + int cylinders,sectors; +@@ -29,6 +28,7 @@ + + extern DT_ENTRY *disktab; + ++ + void geo_init(char *name); + + /* Loads the disk geometry table. */ +diff -Naur --exclude=CVS --exclude='*.orig' lilo/lilo.c lilosh/lilo.c +--- lilo/lilo.c 2006-02-01 21:15:51.000000000 +0000 ++++ lilosh/lilo.c 2006-02-01 21:56:56.000000000 +0000 +@@ -85,11 +85,11 @@ + if (verbose > 0) { + bsect_read(cfg_get_strg(cf_options,"boot"),&boot); + printf("Global settings:\n"); +- tsecs = (boot.par_1.delay*55+50)/100; ++ tsecs = boot.par_1.delay; + printf(" Delay before booting: %d.%d seconds\n",tsecs/10,tsecs % 10); + if (boot.par_1.timeout == 0xffff) printf(" No command-line timeout\n"); + else { +- tsecs = (boot.par_1.timeout*55+50)/100; ++ tsecs = boot.par_1.timeout; + printf(" Command-line timeout: %d.%d seconds\n",tsecs/10, + tsecs % 10); + } +@@ -411,11 +411,11 @@ + else if (st.st_mode & (S_IWGRP | S_IWOTH)) + fprintf(stderr,"Warning: %s should be writable only for " + "root\n",config_file); +- else if ((cfg_get_strg(cf_all,"password") || cfg_get_strg( +- cf_options,"password")) && (st.st_mode & (S_IRGRP | +- S_IROTH))) +- fprintf(stderr,"Warning: %s should be readable only " +- "for root if using PASSWORD\n",config_file); ++ else if ((cfg_get_strg(cf_all,"password") || cfg_get_strg( ++ cf_options,"password")) && (st.st_mode & (S_IRGRP | ++ S_IROTH))) ++ fprintf(stderr,"Warning: %s should be readable only " ++ "for root if using PASSWORD\n",config_file); + } + } + preload_dev_cache(); +@@ -491,7 +491,7 @@ + md_disk.cylinders = geo.cylinders; + md_disk.start = geo.start; + } +- ++ + pass++; + if (uninstall) + bsect_uninstall(uninst_dev ? uninst_dev : cfg_get_strg(cf_options, +@@ -517,8 +517,8 @@ + cf_options,"delay")) : 0,cfg_get_strg(cf_options,"timeout") ? + to_number(cfg_get_strg(cf_options,"timeout")) : -1); + if (more) { +- cfg_init(cf_top); +- if (cfg_parse(cf_top)) cfg_error("Syntax error"); ++ cfg_init(cf_top); ++ if (cfg_parse(cf_top)) cfg_error("Syntax error"); + } + if (!bsect_number()) die("No images have been defined."); + check_fallback(); +diff -Naur --exclude=CVS --exclude='*.orig' lilo/lilo.h lilosh/lilo.h +--- lilo/lilo.h 2006-02-01 21:15:44.000000000 +0000 ++++ lilosh/lilo.h 2006-02-01 21:28:33.000000000 +0000 +@@ -39,6 +39,7 @@ + #define MAJOR_DAC960 48 /* First Mylex DAC960 PCI RAID controller */ + #define MAJOR_IDE5 55 /* IDE on fifth interface */ + #define MAJOR_IDE6 57 /* IDE on sixth interface */ ++#define MAJOR_NAND 240 /* proprietary (board-level) nand flash block device */ + #define COMPAQ_SMART2_MAJOR 72 /* First Smart/2 Major */ + + #define MAX_IMAGES ((SECTOR_SIZE*2-2)/sizeof(IMAGE_DESCR)) +diff -Naur --exclude=CVS --exclude='*.orig' lilo/md-int.h lilosh/md-int.h +--- lilo/md-int.h 2006-02-01 21:15:51.000000000 +0000 ++++ lilosh/md-int.h 2006-02-01 22:11:13.000000000 +0000 +@@ -287,4 +287,4 @@ + #define RAID5_ALGORITHM_LEFT_SYMMETRIC 2 + #define RAID5_ALGORITHM_RIGHT_SYMMETRIC 3 + +-#endif _MD_H ++#endif /* _MD_H */ +diff -Naur --exclude=CVS --exclude='*.orig' lilo/md-int.h~ lilosh/md-int.h~ +--- lilo/md-int.h~ 1970-01-01 00:00:00.000000000 +0000 ++++ lilosh/md-int.h~ 2006-02-01 21:15:51.000000000 +0000 +@@ -0,0 +1,290 @@ ++/* ++ md.h : Multiple Devices driver for Linux ++ Copyright (C) 1994-96 Marc ZYNGIER ++ <zyngier@ufr-info-p7.ibp.fr> or ++ <maz@gloups.fdn.fr> ++ ++ This program is free software; you can redistribute it and/or modify ++ it under the terms of the GNU General Public License as published by ++ the Free Software Foundation; either version 2, or (at your option) ++ any later version. ++ ++ You should have received a copy of the GNU General Public License ++ (for example /usr/src/linux/COPYING); if not, write to the Free ++ Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. ++*/ ++ ++#ifndef MD_INT_H ++#define MD_INT_H ++ ++/* don't include the kernel RAID header! */ ++#define _MD_H ++ ++typedef unsigned int md_u32; ++typedef unsigned short md_u16; ++typedef unsigned char md_u8; ++ ++#include <linux/major.h> ++#include <sys/ioctl.h> ++ ++/* ++ * Different major versions are not compatible. ++ * Different minor versions are only downward compatible. ++ * Different patchlevel versions are downward and upward compatible. ++ */ ++ ++struct md_version { ++ int major; ++ int minor; ++ int patchlevel; ++}; ++ ++/* ++ * default readahead ++ */ ++#define MD_READAHEAD (256 * 1024) ++ ++/* These are the ioctls for md versions < 0.50 */ ++#define REGISTER_MD_DEV _IO (MD_MAJOR, 1) ++#define START_MD _IO (MD_MAJOR, 2) ++#define STOP_MD _IO (MD_MAJOR, 3) ++ ++/* status */ ++#define RAID_VERSION _IOR (MD_MAJOR, 0x10, struct md_version) ++#define GET_ARRAY_INFO _IOR (MD_MAJOR, 0x11, md_array_info_t) ++#define GET_DISK_INFO _IOR (MD_MAJOR, 0x12, md_disk_info_t) ++#define PRINT_RAID_DEBUG _IO (MD_MAJOR, 0x13) ++ ++/* configuration */ ++#define CLEAR_ARRAY _IO (MD_MAJOR, 0x20) ++#define ADD_NEW_DISK _IOW (MD_MAJOR, 0x21, md_disk_info_t) ++#define HOT_REMOVE_DISK _IO (MD_MAJOR, 0x22) ++#define SET_ARRAY_INFO _IOW (MD_MAJOR, 0x23, md_array_info_t) ++#define SET_DISK_INFO _IO (MD_MAJOR, 0x24) ++#define WRITE_RAID_INFO _IO (MD_MAJOR, 0x25) ++#define UNPROTECT_ARRAY _IO (MD_MAJOR, 0x26) ++#define PROTECT_ARRAY _IO (MD_MAJOR, 0x27) ++#define HOT_ADD_DISK _IO (MD_MAJOR, 0x28) ++ ++/* usage */ ++#define RUN_ARRAY _IOW (MD_MAJOR, 0x30, struct md_param) ++#define START_ARRAY _IO (MD_MAJOR, 0x31) ++#define STOP_ARRAY _IO (MD_MAJOR, 0x32) ++#define STOP_ARRAY_RO _IO (MD_MAJOR, 0x33) ++#define RESTART_ARRAY_RW _IO (MD_MAJOR, 0x34) ++ ++ ++/* for raid < 0.50 only */ ++#define MD_PERSONALITY_SHIFT 16 ++ ++#define MD_RESERVED 0UL ++#define LINEAR 1UL ++#define STRIPED 2UL ++#define RAID0 STRIPED ++#define RAID1 3UL ++#define RAID5 4UL ++#define TRANSLUCENT 5UL ++#define LVM 6UL ++#define MAX_PERSONALITY 7UL ++ ++/* ++ * MD superblock. ++ * ++ * The MD superblock maintains some statistics on each MD configuration. ++ * Each real device in the MD set contains it near the end of the device. ++ * Some of the ideas are copied from the ext2fs implementation. ++ * ++ * We currently use 4096 bytes as follows: ++ * ++ * word offset function ++ * ++ * 0 - 31 Constant generic MD device information. ++ * 32 - 63 Generic state information. ++ * 64 - 127 Personality specific information. ++ * 128 - 511 12 32-words descriptors of the disks in the raid set. ++ * 512 - 911 Reserved. ++ * 912 - 1023 Disk specific descriptor. ++ */ ++ ++/* ++ * If x is the real device size in bytes, we return an apparent size of: ++ * ++ * y = (x & ~(MD_RESERVED_BYTES - 1)) - MD_RESERVED_BYTES ++ * ++ * and place the 4kB superblock at offset y. ++ */ ++#define MD_RESERVED_BYTES (64 * 1024) ++#define MD_RESERVED_SECTORS (MD_RESERVED_BYTES / 512) ++#define MD_RESERVED_BLOCKS (MD_RESERVED_BYTES / BLOCK_SIZE) ++ ++#define MD_NEW_SIZE_SECTORS(x) ((x & ~(MD_RESERVED_SECTORS - 1)) - MD_RESERVED_SECTORS) ++#define MD_NEW_SIZE_BLOCKS(x) ((x & ~(MD_RESERVED_BLOCKS - 1)) - MD_RESERVED_BLOCKS) ++ ++#define MD_SB_BYTES 4096 ++#define MD_SB_WORDS (MD_SB_BYTES / 4) ++#define MD_SB_BLOCKS (MD_SB_BYTES / BLOCK_SIZE) ++#define MD_SB_SECTORS (MD_SB_BYTES / 512) ++ ++/* ++ * The following are counted in 32-bit words ++ */ ++#define MD_SB_GENERIC_OFFSET 0 ++#define MD_SB_PERSONALITY_OFFSET 64 ++#define MD_SB_DISKS_OFFSET 128 ++#define MD_SB_DESCRIPTOR_OFFSET 992 ++ ++#define MD_SB_GENERIC_CONSTANT_WORDS 32 ++#define MD_SB_GENERIC_STATE_WORDS 32 ++#define MD_SB_GENERIC_WORDS (MD_SB_GENERIC_CONSTANT_WORDS + MD_SB_GENERIC_STATE_WORDS) ++#define MD_SB_PERSONALITY_WORDS 64 ++#define MD_SB_DISKS_WORDS 384 ++#define MD_SB_DESCRIPTOR_WORDS 32 ++#define MD_SB_RESERVED_WORDS (1024 - MD_SB_GENERIC_WORDS - MD_SB_PERSONALITY_WORDS - MD_SB_DISKS_WORDS - MD_SB_DESCRIPTOR_WORDS) ++#define MD_SB_EQUAL_WORDS (MD_SB_GENERIC_WORDS + MD_SB_PERSONALITY_WORDS + MD_SB_DISKS_WORDS) ++#define MD_SB_DISKS (MD_SB_DISKS_WORDS / MD_SB_DESCRIPTOR_WORDS) ++ ++/* ++ * Device "operational" state bits ++ */ ++#define MD_DISK_FAULTY 0 /* disk is faulty / operational */ ++#define MD_DISK_ACTIVE 1 /* disk is running or spare disk */ ++#define MD_DISK_SYNC 2 /* disk is in sync with the raid set */ ++ ++typedef struct md_device_descriptor_s { ++ md_u32 number; /* 0 Device number in the entire set */ ++ md_u32 major; /* 1 Device major number */ ++ md_u32 minor; /* 2 Devi |
