-------------------------------------------------------------------------------         
               Copyright (c) 2002-2005 VIA Technologies Inc.             
                                                                         
             VIA RAID Mandriva 2006 Driver Software Package README
                                                                        
    This README file is to provide the information of VIA RAID Linux Driver
    Package. VIA Technologies assumes no responsibility for any errors in
    this document and no part of this document may be reproduced, transmitted,
    or translated into any language,or in any form without the prior written 
    permission of VIA Technologies Incorporated.
  
              Package Version 2.10 / README Version 2.10                                                          
-------------------------------------------------------------------------------


 0) Introduction

    This RAID driver can support 5 kinds of VIA RAID Controllers, including 
        VT6410,
        VT6420/8237,
        VT6421,
        VT8251,
        VT8337.
    And supports the following RAID type:
        RAID0, 
        RAID1, 
        RAID0+1, 
        RAID5(needs at least 3 hard disks), 
        SPAN(needs 4 hard disks).

    VIA VT6410 is a ATA RAID controller, supports up to four ATA hard disks.
    VIA VT6420/8237 is a SATA RAID controller.
    VIA VT6421 supports two SATA and two ATA hard disks.
    VIA VT8251 is AHCI controller.
    This Package provides Driver Disk which are needed when using the above 
VIA RAID Controllers.

 1) System Requirements

    You should have at least one VIA RAID controller.

    System BIOS must integrates VIA RAID BIOS if you want to install OS
    on RAID Controller.

    Supporting up to four hard disk drives, which all support LBA address.

    Supporting the following Operating Systems:
      Mandriva 2006

 2) Software Package Contents 
 
    The following files are in the package: 

        README                      :This file
        driverdisk/viamraid.ko      :Driver disk floppy image
        MDK2006_2.6.12-12mdk.patch  :Patch file

 3) Install Operating System Mandriva 2006 on the RAID controller

    1. Prepare the driver disk
        viamraid.ko is the driver for Mandriva 2006 driverdisk.

        
    2. Boot from the Mandriva 2006 install CD, press 'F1', when it prompt "boot:", type
        linux updatemodules acpi=off
        
       (Don't insert any usb device at this time. )

    3. Choose the driver disk to load viamraid.ko.

    4. The RAID devices will be recognized as sda, sdb, etc. And the system 
       will be installed in these devices.
       
    5. Choose the install method "cdrom".

    6. Please choose GRUB-graphic for config bootloader.(default is lilo)
    
    7. Finish install process.
    
    8. Boot from the Mandriva 2006 install CD, press 'F1', when it prompt "boot:", type
       linux rescue updatemodules acpi=off
       
    9. Load the driver disk and enter to the rescue mode, choose
       Mount your partitions under /mnt
       
    10.Choose "go to console" and type 
       chroot /mnt
       
    11.Install the kernel source code.
       #rpm -ivh kernel-source-2.6-2.6.12-12mdk.i586.rpm
       
       and
       #cd /usr/src/linux
       #cp /mnt/floppy/MDK2006_2.6.12-12mdk.patch ./
       #patch -p1 < MDK2006_2.6.12-12mdk.patch
       #cp /boot/config-2.6.12-12mdksmp ./
       
    12.Modify Makefile  
       #vi Makefile
       
       And modify the line to 
       EXTRAVERSION = -12mdk-i586-up-1GB
     
    13.Modify your kernel configuration.   
       #make mrproper
       #make menuconfig
       		    Processor  type and features --->
       	    					    Processor family (586/K%/5x86/6x86/6x86MX)--->
        And disable	
               	    [ ] Symmetric multi-processing support	
    14.Start to rebuild kernel.
       #make
       #make modules_install
       
    15.Buile the module dependence.
       #cp /mnt/floppy/viamraid.ko /lib/modules/2.6.12-12mdk-i586-up-1GB/kernel/drivers/scsi/
       #depmod -a
       
    16.Modify bootloader. (Don't use the command: make install)
       #cp /usr/src/linux/arch/i386/boot/bzImage /boot/
       #rmmod sata_via
       #modprobe viamraid
       #mkinitrd /boot/newinitrd.img 'uname -r' --preload scsi_mod --preload viamraid
       
    17.Add the line in /boot/grub/menu.lst like this
       
       title test
       kernel (hd0,0)/boot/bzImage root=/dev/sda1 resume=/dev/sda5 splash=silent vga=791 acpi=off
       initrd (hd0,0)/boot/newinitrd.img
       
    18.Reboot and use 'test' enter to the OS.
    
    
    
    
 4) Install driver on an existing Mandriva 2006 system

    1. Find the driver module file and copy it to proper place.
       And run the command:

        # depmod -a

       to update the module dependency.

    2. Testing the driver:

       # modprobe viamraid
       
       If found the SCSI disk devices /dev/sda, etc., the driver work find.

    3. Configuration the system to load the driver when booting:

          Modify /etc/modprobe.conf: add the line with the content:
            "scsi_hostadapter viamraid"

    NOTE: If you are using VT8237/VT6420, this driver may conflict with the 
          system's default driver: sata_via, so please disable the sata_via 
          firstly:

          # rmmod sata_via         (uninstall sata_via from running system)
            And
          Modify /etc/modprobe.conf: delete the line which contains "sata_via"
          Modify /etc/hotplug/blacklist: add line with the content: "sata_via"
                   at the end of the file
     
