Re: Linux Kernel 3.12.0 Kirkwood package and rootfs (Non Flattened Device Tree) January 25, 2014 10:07AM |
Admin Registered: 13 years ago Posts: 18,821 |
Re: Linux Kernel 3.12.0 Kirkwood package and rootfs (Non Flattened Device Tree) January 25, 2014 10:59AM |
Registered: 13 years ago Posts: 161 |
No. An initrd presents the kernel with small memory resident temporary rootfs that's used to load dynamic kernel modules and run some simple scripts that may be necessary to find and load the true rootfs. The use of it really depends on what has been compiled directly into the kernel, and where the rootfs resides. As a simple example, you need initrd to resolve the rootfs true path when passing a root=LABEL=foo parameter. My suggestion for using the uInitrd earlier was a safety as I didn't inspect the config file to see what was compiled into it.Quote
@kragh3d, isn't intrid just for booting from NAND?
nekitip
Re: Linux Kernel 3.12.0 Kirkwood package and rootfs (Non Flattened Device Tree) January 25, 2014 12:46PM |
that puzzles me also, because, there is no reason that i can fatload image, and then bootm with no problem, but also not being able to boot from that same image (copied from memory to NAND).Quote
kraqh3d
The location of the uImage shouldn't matter other than the uBoot has to be able to load it into memory from there. Once its in memory and it's booted with bootm, it doesn't matter anymore.
Quote
kraqh3d
An initrd presents the kernel with small memory resident temporary rootfs that's used to load dynamic kernel modules and run some simple scripts that may be necessary to find and load the true rootfs.
setenv bootargs 'console=ttyS0,115200 root=/dev/sda4' setenv bootcmd 'ide reset; fatload ide 0 0x800000 /uimage-3.12; bootm 0x800000'This is all I've got, and it boots. (root is on sda4 from before).
my opinion, based on my new experience, is that filesystem access should always be included in kernel.Quote
bodhi
The kernel has ext2, ext3, and ext4 supports loaded as modules.
Re: Linux Kernel 3.12.0 Kirkwood package and rootfs (Non Flattened Device Tree) January 25, 2014 01:27PM |
Admin Registered: 13 years ago Posts: 18,821 |
Re: Linux Kernel 3.12.0 Kirkwood package and rootfs (Non Flattened Device Tree) January 25, 2014 05:48PM |
Registered: 13 years ago Posts: 161 |
nekitip
Re: Linux Kernel 3.12.0 Kirkwood package and rootfs (Non Flattened Device Tree) January 26, 2014 02:06AM |
1) install fatload ide 0 0x800000 uimage-3.12 2) work setenv bootcmd 'ide reset; fatload ide 0 0x800000 /uimage-3.12; bootm 0x800000'---the way it is working with 3.5.1, not with 3.12
1) install fatload ide 0 0x800000 uimage-3.5.1 nand erase 0x4640000 0x300000 nand write.e 0x800000 0x4640000 0x300000 2) work setenv bootcmd 'nand read.e 0x2000000 0x04640000 0x400000; bootm 0x2000000'
1) install fatload ide 0 0x800000 uimage-3.12 nand erase 0x4640000 0x300000 nand write.e 0x800000 0x4640000 0x300000 2) work setenv bootcmd 'nand read.e 0x800000 0x04640000 0x400000; bootm 0x800000'
Re: Linux Kernel 3.12.0 Kirkwood package and rootfs (Non Flattened Device Tree) January 26, 2014 10:34AM |
Admin Registered: 13 years ago Posts: 18,821 |
nekitip
Re: Linux Kernel 3.12.0 Kirkwood package and rootfs (Non Flattened Device Tree) January 26, 2014 04:52PM |
Re: Linux Kernel 3.12.0 Kirkwood package and rootfs (Non Flattened Device Tree) January 27, 2014 04:11AM |
Admin Registered: 13 years ago Posts: 18,821 |
Re: Linux Kernel 3.12.0 Kirkwood package and rootfs (Non Flattened Device Tree) January 27, 2014 07:00AM |
Registered: 10 years ago Posts: 1 |
nekitip
Re: Linux Kernel 3.12.0 Kirkwood package and rootfs (Non Flattened Device Tree) January 27, 2014 10:37AM |
no, using that patch, the kernel will choose color by testing write/read state of sata-disk.Quote
bodhi
And the color of the LEDs should be what you choose to set, not the kernel.
Re: Linux Kernel 3.12.0 Kirkwood package and rootfs (Non Flattened Device Tree) January 27, 2014 10:52AM |
Admin Registered: 13 years ago Posts: 18,821 |
nekitip
Re: Linux Kernel 3.12.0 Kirkwood package and rootfs (Non Flattened Device Tree) January 27, 2014 01:44PM |
Re: Linux Kernel 3.12.0 Kirkwood package and rootfs (Non Flattened Device Tree) January 27, 2014 02:31PM |
Registered: 10 years ago Posts: 44 |
Re: Linux Kernel 3.12.0 Kirkwood package and rootfs (Non Flattened Device Tree) January 27, 2014 03:24PM |
Registered: 11 years ago Posts: 91 |
Re: Linux Kernel 3.12.0 Kirkwood package and rootfs (Non Flattened Device Tree) January 29, 2014 11:30AM |
Registered: 13 years ago Posts: 161 |
Re: Linux Kernel 3.12.0 Kirkwood package and rootfs (Non Flattened Device Tree) January 30, 2014 10:49AM |
Registered: 11 years ago Posts: 19 |
wget --no-check-cert https://dl.dropboxusercontent.com/s/2429qd7cckhi3z8/linux-3.12.0-kirkwood-tld-5-bodhi.tar.bz2
-rwxrwxrwx 1 root root 30057333 Jan 30 16:17 linux-3.12.0-kirkwood-tld-5-bodhi.tar.bz2
root@debian:/# md5sum linux-3.12.0-kirkwood-tld-5-bodhi.tar.bz2 d0fbe64dbe5e4fdbb4842205de77e6a9 linux-3.12.0-kirkwood-tld-5-bodhi.tar.bz2
root@debian:/# tar -xjf linux-3.12.0-kirkwood-tld-5-bodhi.tar.bz2 tar (child): bzip2: Cannot exec: No such file or directory tar (child): Error is not recoverable: exiting now tar: Child returned status 2 tar: Error is not recoverable: exiting now root@debian:/#
nekitp
Re: Linux Kernel 3.12.0 Kirkwood package and rootfs (Non Flattened Device Tree) January 30, 2014 03:30PM |
cd linux-3.13.1 make mrproper make kirkwood_defconfig ARCH=arm (make menuconfig ARCH=arm) if you need drivers like FTDI, prolific... ARCH=arm CROSS_COMPILE=arm-linux-gnueabi- make dtbs modules -j3 (-j3 is just a switch for a number of cores on CPU) ARCH=arm CROSS_COMPILE=arm-linux-gnueabi- make dtbs modules modules_install -j3 cat arch/arm/boot/zImage arch/arm/boot/dts/kirkwood-nsa310.dtb \ > /tmp/zImage-dtb-kirwood mkimage -A arm -O linux -T kernel -C none -a 0x00008000 -e 0x00008000 \ -n Linux-kikrwood-nsa310.dtb -d /tmp/zImage-dtb-kirwood \ /home/build/uImage-3.13.1and there you go. It will work.
nekitip
Re: Linux Kernel 3.12.0 Kirkwood package and rootfs (Non Flattened Device Tree) January 30, 2014 03:39PM |
Re: Linux Kernel 3.12.0 Kirkwood package and rootfs (Non Flattened Device Tree) January 30, 2014 08:02PM |
Registered: 11 years ago Posts: 19 |
Re: Linux Kernel 3.12.0 Kirkwood package and rootfs (Non Flattened Device Tree) January 30, 2014 08:10PM |
Registered: 11 years ago Posts: 19 |
root@debian:/tmp# apt-get remove flash-kernel Reading package lists... Done Building dependency tree Reading state information... Done The following packages will be REMOVED: flash-kernel 0 upgraded, 0 newly installed, 1 to remove and 0 not upgraded. After this operation, 129 kB disk space will be freed. Do you want to continue [Y/n]? y (Reading database ... 21752 files and directories currently installed.) Removing flash-kernel ... root@debian:/tmp# dpkg -i linux-image-3.12.0-kirkwood-tld-5_5.0_armel.deb Selecting previously unselected package linux-image-3.12.0-kirkwood-tld-5. (Reading database ... 21737 files and directories currently installed.) Unpacking linux-image-3.12.0-kirkwood-tld-5 (from linux-image-3.12.0-kirkwood-tld-5_5.0_armel.deb) ... debconf: unable to initialize frontend: Dialog debconf: (No usable dialog-like program is installed, so the dialog based frontend cannot be used. at /usr/share/perl5/Debconf/FrontEnd/Dialog.pm line 76.) debconf: falling back to frontend: Readline Done. Setting up linux-image-3.12.0-kirkwood-tld-5 (5.0) ... debconf: unable to initialize frontend: Dialog debconf: (No usable dialog-like program is installed, so the dialog based frontend cannot be used. at /usr/share/perl5/Debconf/FrontEnd/Dialog.pm line 76.) debconf: falling back to frontend: Readline Hmm. There is a symbolic link /lib/modules/3.12.0-kirkwood-tld-5/build However, I can not read it: No such file or directory Therefore, I am deleting /lib/modules/3.12.0-kirkwood-tld-5/build Hmm. The package shipped with a symbolic link /lib/modules/3.12.0-kirkwood-tld-5/source However, I can not read the target: No such file or directory Therefore, I am deleting /lib/modules/3.12.0-kirkwood-tld-5/source Running depmod. Examining /etc/kernel/postinst.d. run-parts: executing /etc/kernel/postinst.d/initramfs-tools 3.12.0-kirkwood-tld-5 /boot/vmlinuz-3.12.0-kirkwood-tld-5 update-initramfs: Generating /boot/initrd.img-3.12.0-kirkwood-tld-5 run-parts: executing /etc/kernel/postinst.d/zz-flash-kernel 3.12.0-kirkwood-tld-5 /boot/vmlinuz-3.12.0-kirkwood-tld-5 root@debian:/tmp# mkimage -A arm -O linux -T kernel -C none -a 0x00008000 -e 0x00008000 -n Linux-3.12.0-kirkwood-tld-5 -d /boot/vmlinuz-3.12.0-kirkwood-tld-5 /boot/uImage Image Name: Linux-3.12.0-kirkwood-tld-5 Created: Fri Jan 31 02:05:31 2014 Image Type: ARM Linux Kernel Image (uncompressed) Data Size: 2342512 Bytes = 2287.61 kB = 2.23 MB Load Address: 00008000 Entry Point: 00008000 root@debian:/tmp# mkimage -A arm -O linux -T ramdisk -C gzip -a 0x00000000 -e 0x00000000 -n initramfs-3.12.0-kirkwood-tld-5 -d /boot/initrd.img-3.12.0-kirkwood-tld-5 /boot/uInitrd Image Name: initramfs-3.12.0-kirkwood-tld-5 Created: Fri Jan 31 02:05:42 2014 Image Type: ARM Linux RAMDisk Image (gzip compressed) Data Size: 5982187 Bytes = 5841.98 kB = 5.71 MB Load Address: 00000000 Entry Point: 00000000 root@debian:/tmp# sync root@debian:/tmp# shutdown -r now Broadcast message from root@debian (pts/0) (Fri Jan 31 02:05:54 2014): The system is going down for reboot NOW!
fw_setenv machid dd6
fw_setenv machid
Re: Linux Kernel 3.12.0 Kirkwood package and rootfs (Non Flattened Device Tree) January 31, 2014 01:57AM |
Admin Registered: 13 years ago Posts: 18,821 |
Re: Linux Kernel 3.12.0 Kirkwood package and rootfs (Non Flattened Device Tree) January 31, 2014 03:35AM |
Admin Registered: 13 years ago Posts: 18,821 |
apt-get install dialog
nekitip
Re: Linux Kernel 3.12.0 Kirkwood package and rootfs (Non Flattened Device Tree) January 31, 2014 03:35PM |
Re: Linux Kernel 3.12.0 Kirkwood package and rootfs (Non Flattened Device Tree) January 31, 2014 04:13PM |
Admin Registered: 13 years ago Posts: 18,821 |
nekitip
Re: Linux Kernel 3.12.0 Kirkwood package and rootfs (Non Flattened Device Tree) February 01, 2014 12:51PM |
config LEDS_TRIGGER_IDE_DISK bool "LED IDE Disk Trigger" - depends on IDE_GD_ATA depends on LEDS_TRIGGERS help This allows LEDs to be controlled by IDE disk activity.once you've done that, "cat nsa310:red:hdd/trigger" will show that now you do have ide-disk, and you are able to do
echo ide-disk > /sys/class/leds/nsa310:red:hdd/triggerhowever, it will not blink.
#include <scsi/scsi_cmnd.h> #include <scsi/scsi_device.h> #include <linux/libata.h> +#include <linux/leds.h> { int want_ncq = (protocol == ATA_PROT_NCQ); + ledtrig_ide_activity(); if (pp->pp_flags & MV_PP_FLAG_EDMA_EN) { int using_ncq = ((pp->pp_flags & MV_PP_FLAG_NCQ_EN) != 0); if (want_ncq != using_ncq)
Re: Linux Kernel 3.12.0 Kirkwood package and rootfs (Non Flattened Device Tree) February 01, 2014 06:03PM |
Admin Registered: 13 years ago Posts: 18,821 |
CONFIG_LEDS_TRIGGERS=y CONFIG_LEDS_TRIGGER_TIMER=y CONFIG_LEDS_TRIGGER_ONESHOT=y CONFIG_LEDS_TRIGGER_IDE_DISK=y CONFIG_LEDS_TRIGGER_HEARTBEAT=y CONFIG_LEDS_TRIGGER_BACKLIGHT=m # CONFIG_LEDS_TRIGGER_CPU is not set CONFIG_LEDS_TRIGGER_GPIO=y CONFIG_LEDS_TRIGGER_DEFAULT_ON=y CONFIG_LEDS_TRIGGER_TRANSIENT=m # CONFIG_LEDS_TRIGGER_CAMERA is not set
nekitip
Re: Linux Kernel 3.12.0 Kirkwood package and rootfs (Non Flattened Device Tree) February 02, 2014 04:42AM |
MPP38_GPIO, // VID B0 MPP45_GPIO, // VID B1 MPP44_GPIO, // Buzzer MPP43_GPIO, // HTP MPP47_GPIO, // Power Resume Data MPP49_GPIO, // Power Resume Clock
Atesz
Re: Linux Kernel 3.12.0 Kirkwood package and rootfs (Non Flattened Device Tree) February 02, 2014 05:20AM |
Re: Linux Kernel 3.12.0 Kirkwood package and rootfs (Non Flattened Device Tree) February 02, 2014 05:25AM |
Admin Registered: 13 years ago Posts: 18,821 |
Quote
I hope you are making patch already with this new data.