Update of /cvsroot/leaf/src/bering-uclibc4/source/initrd
In directory sfp-cvsdas-2.v30.ch3.sourceforge.com:/tmp/cvs-serv30783
Modified Files:
buildtool.cfg buildtool.mk root.linuxrc
Log Message:
Hardware autodetection; single image
Index: root.linuxrc
===================================================================
RCS file: /cvsroot/leaf/src/bering-uclibc4/source/initrd/root.linuxrc,v
retrieving revision 1.6
retrieving revision 1.7
diff -C2 -d -r1.6 -r1.7
*** root.linuxrc 18 Jun 2010 13:48:23 -0000 1.6
--- root.linuxrc 18 Jun 2010 15:28:13 -0000 1.7
***************
*** 38,41 ****
--- 38,44 ----
Lecho () { echo "LINUXRC: $@"; }
+ lsalias () { for i in $@; do
+ cat /sys/bus/$i/devices/*/modalias 2>/dev/null;
+ done; }
PFX=/var/lib/lrpkg
***************
*** 60,69 ****
# Load any modules required to boot
ln -s /lib/modules /lib/modules/`uname -r`
! depmod
#---------mdev------------
echo /sbin/mdev > /proc/sys/kernel/hotplug
! mdev -s
! lsmod
if [ -r $BPFX/etc/modules ] ; then
--- 63,71 ----
# Load any modules required to boot
ln -s /lib/modules /lib/modules/`uname -r`
! /sbin/depmod
#---------mdev------------
echo /sbin/mdev > /proc/sys/kernel/hotplug
! /sbin/mdev -s
if [ -r $BPFX/etc/modules ] ; then
***************
*** 81,87 ****
--- 83,99 ----
fi
+ #load device drivers
+ for i in `lsalias pnp pci pci_express acpi platform serio`; do
+ /sbin/modprobe $i 2>/dev/null
+ done
+
# wait for USB drive
sleep $usb_wait
+ #load scsi drivers (SATA/IDE drives, flash)
+ for i in `lsalias scsi`; do
+ /sbin/modprobe $i 2>/dev/null
+ done
+
# Process kernel command line and assign values to variables
[ "$VERBOSE" ] && Lecho "Parsing kernel command line..."
Index: buildtool.cfg
===================================================================
RCS file: /cvsroot/leaf/src/bering-uclibc4/source/initrd/buildtool.cfg,v
retrieving revision 1.5
retrieving revision 1.6
diff -C2 -d -r1.5 -r1.6
*** buildtool.cfg 12 Jun 2010 16:31:51 -0000 1.5
--- buildtool.cfg 18 Jun 2010 15:28:13 -0000 1.6
***************
*** 23,32 ****
</File>
- #<File root2.linuxrc>
- # Server = cvs4-sourceforge
- # Revision = HEAD
- # Directory = initrd
- #</File>
-
<File README>
Server = cvs4-sourceforge
--- 23,26 ----
***************
*** 44,55 ****
<initrd>
packagetype = initrd
! initrdsize = 1500
packagename = initrd
Version = 4.0.0
! Revision = 7
Help <<EOF
! LEAF Bering-uClibc initial filesystem
This is not an ordinary *.LRP package !
--- 38,49 ----
<initrd>
packagetype = initrd
! # initrdsize = 1500
packagename = initrd
Version = 4.0.0
! Revision = 8
Help <<EOF
! LEAF Bering-uClibc initial filesystem (floppy + IDE/SATA + USB)
This is not an ordinary *.LRP package !
***************
*** 70,74 ****
#include <common.cfg>
<File>
! Source = boot/etc/modules.floppy
Filename = boot/etc/modules
Type = binary
--- 64,68 ----
#include <common.cfg>
<File>
! Source = boot/etc/modules
Filename = boot/etc/modules
Type = binary
***************
*** 76,195 ****
Permissions = 644
</File>
! #include <files.floppy>
</Contents>
</initrd>
- <initrd_ide>
- packagetype = initrd
- initrdsize = 1500
- packagename = initrd
-
- Version = 4.0.0
- Revision = 7
-
- Help <<EOF
- LEAF Bering-uClibc initial filesystem
-
- This is not an ordinary *.LRP package !
- LEAF package by __PACKAGER__, __BUILDDATE__
- EOF
-
- <Permissions>
- Files = 644
- Directories = 755
- </Permissions>
-
- <Owner>
- Files = root:root
- Directories = root:root
- </Owner>
-
- <Contents>
- #include <common.cfg>
- <File>
- Source = boot/etc/modules.ide
- Filename = boot/etc/modules
- Type = binary
- Description = Modules to load before any
other package
- Permissions = 644
- </File>
- #include <files.ide>
- </Contents>
- </initrd_ide>
-
- <initrd_ide_cd>
- packagetype = initrd
- initrdsize = 2048
- packagename = initrd
-
- Version = 4.0.0
- Revision = 7
-
- Help <<EOF
- LEAF Bering-uClibc initial filesystem
-
- This is not an ordinary *.LRP package !
- LEAF package by __PACKAGER__, __BUILDDATE__
- EOF
-
- <Permissions>
- Files = 644
- Directories = 755
- </Permissions>
-
- <Owner>
- Files = root:root
- Directories = root:root
- </Owner>
-
- <Contents>
- #include <common.cfg>
- <File>
- Source = boot/etc/modules.cd
- Filename = boot/etc/modules
- Type = binary
- Description = Modules to load before any
other package
- Permissions = 644
- </File>
- #include <files.cd>
- </Contents>
- </initrd_ide_cd>
-
- <initrd_usb>
- packagetype = initrd
- initrdsize = 1500
- packagename = initrd
-
- Version = 4.0.0
- Revision = 7
-
- Help <<EOF
- LEAF Bering-uClibc initial filesystem
-
- This is not an ordinary *.LRP package !
- LEAF package by __PACKAGER__, __BUILDDATE__
- EOF
-
- <Permissions>
- Files = 644
- Directories = 755
- </Permissions>
-
- <Owner>
- Files = root:root
- Directories = root:root
- </Owner>
-
- <Contents>
- #include <common.cfg>
- <File>
- Source = boot/etc/modules.usb
- Filename = boot/etc/modules
- Type = binary
- Description = Modules to load before any
other package
- Permissions = 644
- </File>
- #include <files.usb>
- </Contents>
- </initrd_usb>
</Package>
--- 70,76 ----
Permissions = 644
</File>
! #include <files>
</Contents>
</initrd>
</Package>
Index: buildtool.mk
===================================================================
RCS file: /cvsroot/leaf/src/bering-uclibc4/source/initrd/buildtool.mk,v
retrieving revision 1.7
retrieving revision 1.8
diff -C2 -d -r1.7 -r1.8
*** buildtool.mk 12 Jun 2010 16:31:51 -0000 1.7
--- buildtool.mk 18 Jun 2010 15:28:13 -0000 1.8
***************
*** 4,8 ****
INITRD_DIR=.
INITRD_TARGET_DIR:=$(BT_BUILD_DIR)/config
! BT_KERNEL_VER=`ls $(BT_STAGING_DIR)/lib/modules/|grep
$(BT_KERNEL_RELEASE)|sort -r -V|head -n 1`
$(INITRD_DIR)/.source:
--- 4,8 ----
INITRD_DIR=.
INITRD_TARGET_DIR:=$(BT_BUILD_DIR)/config
! BT_KERNEL_VER=$(shell ls $(BT_STAGING_DIR)/lib/modules/|grep
$(BT_KERNEL_RELEASE)|sort -r -V|head -n 1)
$(INITRD_DIR)/.source:
***************
*** 18,52 ****
mkdir -p $(INITRD_TARGET_DIR)/var/lib/lrpkg
mkdir -p $(INITRD_TARGET_DIR)/boot/etc
- BT_STAGING_DIR=$(BT_STAGING_DIR) BT_KERNEL_RELEASE=$(BT_KERNEL_VER) \
- sh $(BT_TOOLS_DIR)/getdep.sh floppy fat>mod.floppy
- cat mod.floppy|sed 's/[a-z]*\/[a-z_/-]*\///g; s/\.ko//g; s/
/\n/g'>$(INITRD_TARGET_DIR)/boot/etc/modules.floppy
- -rm -f files.floppy
- (BT_KERNEL_RELEASE=$(BT_KERNEL_VER); for i in `cat mod.floppy`; do echo
-e "<File>\n\tSource\t= lib/modules/$$BT_KERNEL_RELEASE/$$i\n\t\
- Filename\t= lib/modules/$$(echo $$i|sed 's/[a-z]*\/[a-z_/-]*\///g')\n\t\
- Type\t= binary\n\tType\t= module\n\tPermissions\t=
644\n</File>">>files.floppy; done)
BT_STAGING_DIR=$(BT_STAGING_DIR) BT_KERNEL_RELEASE=$(BT_KERNEL_VER) \
! sh $(BT_TOOLS_DIR)/getdep.sh "ata_.*" ahci sd_mod
vfat>mod.ide
! cat mod.ide|sed 's/[a-z]*\/[a-z_/-]*\///g; s/\.ko//g; s/
/\n/g'>$(INITRD_TARGET_DIR)/boot/etc/modules.ide
! -rm -f files.ide
! (BT_KERNEL_RELEASE=$(BT_KERNEL_VER); for i in `cat mod.ide`; do echo -e
"<File>\n\tSource\t= lib/modules/$$BT_KERNEL_RELEASE/$$i\n\t\
! Filename\t= lib/modules/$$(echo $$i|sed 's/[a-z]*\/[a-z_/-]*\///g')\n\t\
! Type\t= binary\n\tType\t= module\n\tPermissions\t=
644\n</File>">>files.ide; done)
!
! BT_STAGING_DIR=$(BT_STAGING_DIR) BT_KERNEL_RELEASE=$(BT_KERNEL_VER) \
! sh $(BT_TOOLS_DIR)/getdep.sh "ata_.*" ahci sd_mod sr_mod
isofs vfat floppy>mod.cd
! cat mod.cd|sed 's/[a-z]*\/[a-z_/-]*\///g; s/\.ko//g; s/
/\n/g'>$(INITRD_TARGET_DIR)/boot/etc/modules.cd
! -rm -f files.cd
! (BT_KERNEL_RELEASE=$(BT_KERNEL_VER); for i in `cat mod.cd`; do echo -e
"<File>\n\tSource\t= lib/modules/$$BT_KERNEL_RELEASE/$$i\n\t\
! Filename\t= lib/modules/$$(echo $$i|sed 's/[a-z]*\/[a-z_/-]*\///g')\n\t\
! Type\t= binary\n\tType\t= module\n\tPermissions\t=
644\n</File>">>files.cd; done)
!
! BT_STAGING_DIR=$(BT_STAGING_DIR) BT_KERNEL_RELEASE=$(BT_KERNEL_VER) \
! sh $(BT_TOOLS_DIR)/getdep.sh ehci-hcd uhci-hcd ohci-hcd
usb-storage sd_mod vfat>mod.usb
! cat mod.cd|sed 's/[a-z]*\/[a-z_/-]*\///g; s/\.ko//g; s/
/\n/g'>$(INITRD_TARGET_DIR)/boot/etc/modules.usb
! -rm -f files.usb
! (BT_KERNEL_RELEASE=$(BT_KERNEL_VER); for i in `cat mod.usb`; do echo -e
"<File>\n\tSource\t= lib/modules/$$BT_KERNEL_RELEASE/$$i\n\t\
Filename\t= lib/modules/$$(echo $$i|sed 's/[a-z]*\/[a-z_/-]*\///g')\n\t\
! Type\t= binary\n\tType\t= module\n\tPermissions\t=
644\n</File>">>files.usb; done)
cp -a README $(INITRD_TARGET_DIR)/boot/etc
--- 18,31 ----
mkdir -p $(INITRD_TARGET_DIR)/var/lib/lrpkg
mkdir -p $(INITRD_TARGET_DIR)/boot/etc
BT_STAGING_DIR=$(BT_STAGING_DIR) BT_KERNEL_RELEASE=$(BT_KERNEL_VER) \
! sh $(BT_TOOLS_DIR)/getdep.sh "ata_.*" ahci ehci-hcd
uhci-hcd \
! ohci-hcd usb-storage sd_mod sr_mod isofs vfat floppy >mod
! #cat mod|sed 's/[a-z]*\/[a-z_/-]*\///g; s/\.ko//g; s/
/\n/g'>$(INITRD_TARGET_DIR)/boot/etc/modules
! echo -e "isofs\nvfat">$(INITRD_TARGET_DIR)/boot/etc/modules
! -rm -f files
! (BT_KERNEL_RELEASE=$(BT_KERNEL_VER); for i in `cat mod`; do echo -e
"<File>\n\tSource\t= lib/modules/$$BT_KERNEL_RELEASE/$$i\n\t\
Filename\t= lib/modules/$$(echo $$i|sed 's/[a-z]*\/[a-z_/-]*\///g')\n\t\
! Type\t= binary\n\tType\t= module\n\tPermissions\t=
644\n</File>">>files; done)
cp -a README $(INITRD_TARGET_DIR)/boot/etc
------------------------------------------------------------------------------
ThinkGeek and WIRED's GeekDad team up for the Ultimate
GeekDad Father's Day Giveaway. ONE MASSIVE PRIZE to the
lucky parental unit. See the prize list and enter to win:
http://p.sf.net/sfu/thinkgeek-promo
_______________________________________________
leaf-cvs-commits mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/leaf-cvs-commits