diff options
author | 2008-11-21 22:46:36 +0100 | |
---|---|---|
committer | 2009-06-28 20:37:33 +0200 | |
commit | cac66e09707752906215511e69ef1141d56bd2c4 (patch) | |
tree | f414f837483a702ada87001cea5fad12487f9c82 /defaults | |
parent | Apply fix to deference links for gentoo bug #269603 (diff) | |
download | genkernel-cac66e09707752906215511e69ef1141d56bd2c4.tar.gz genkernel-cac66e09707752906215511e69ef1141d56bd2c4.tar.bz2 genkernel-cac66e09707752906215511e69ef1141d56bd2c4.zip |
iSCSI patch for genkernel
Diffstat (limited to 'defaults')
-rwxr-xr-x | defaults/initrd.defaults | 2 | ||||
-rwxr-xr-x | defaults/initrd.scripts | 11 | ||||
-rwxr-xr-x | defaults/linuxrc | 14 | ||||
-rw-r--r-- | defaults/modules_load | 3 |
4 files changed, 29 insertions, 1 deletions
diff --git a/defaults/initrd.defaults b/defaults/initrd.defaults index a417144..db5cb25 100755 --- a/defaults/initrd.defaults +++ b/defaults/initrd.defaults @@ -78,4 +78,4 @@ LOOPS='/livecd.loop /zisofs /livecd.squashfs /image.squashfs /livecd.gcloop' # Only sections that are in by default or those that # are not module groups need to be defined here... HWOPTS='keymap cache modules pata sata scsi usb firewire waitscan slowusb evms lvm dmraid mdadm fs net' -MY_HWOPTS='modules pata sata scsi usb firewire waitscan dmraid mdadm fs net' +MY_HWOPTS='modules pata sata scsi usb firewire waitscan dmraid mdadm fs net iscsi' diff --git a/defaults/initrd.scripts b/defaults/initrd.scripts index b63568d..1ccab59 100755 --- a/defaults/initrd.scripts +++ b/defaults/initrd.scripts @@ -628,6 +628,17 @@ startVolumes() { fi } +startiscsi() { + + if [ -n "${ISCSI_I}" ] && [ -n "${ISCSI_T}" ] && [ -n "${ISCSI_A}" ] + then + good_msg "Activating ISCSI" + iscsistart -i "${ISCSI_I}" -t "${ISCSI_T}" -g 1 -a ${ISCSI_A} + fi + +} + + # Open a LUKS device # It is either the root or a swap, other devices are supported in the scripts provided with sys-fs/cryptsetup-luks # $1 - root/swap diff --git a/defaults/linuxrc b/defaults/linuxrc index 3fac6ad..c3d5239 100755 --- a/defaults/linuxrc +++ b/defaults/linuxrc @@ -149,6 +149,17 @@ do nfsroot\=*) NFSROOT=`parse_opt "${x}"` ;; + # ISCSI + iscsi_i\=*) + ISCSI_I=`parse_opt "${x}"` + ;; + iscsi_t\=*) + ISCSI_T=`parse_opt "${x}"` + ;; + iscsi_a\=*) + ISCSI_A=`parse_opt "${x}"` + ;; + # Crypto crypt_root\=*) CRYPT_ROOT=`parse_opt "${x}"` ;; @@ -263,6 +274,9 @@ setup_md_device # Scan volumes startVolumes +# Start ISCSI +startiscsi + setup_keymap # Initialize LUKS root device except for livecd's diff --git a/defaults/modules_load b/defaults/modules_load index 2e93dce..f54dd7b 100644 --- a/defaults/modules_load +++ b/defaults/modules_load @@ -16,6 +16,9 @@ MODULES_WAITSCAN="scsi_wait_scan" # Hardware (Network) MODULES_NET="e1000 tg3" +# iSCSI support +MODULES_ISCSI="scsi_transport_iscsi libiscsi iscsi_tcp" + # Hardware (Pluggable) MODULES_FIREWIRE="ieee1394 ohci1394 sbp2" MODULES_PCMCIA="pcmcia pcmcia_core yenta_socket pd6729 i82092 i82365 tcic ds ide-cs firmware_class" |