Re: [OpenWrt-Devel] [patch 0/8] powerpc64 and kexec-tools updates
On 08/14/2009 03:09 PM, Geoff Levand wrote: Hi, This set of patches introduces a new target feature powerpc64 to help simplify the build files, updates the kexec-tools package to version 2.0.1, and does some kexec-tools package cleanups. [patch 1/8] powerpc: Create a powerpc64 config feature [patch 2/8] pxcab: Replace TARGET_pxcab with feature powerpc64 [patch 3/8] kexec-tools: Update package to version 2.0.1 [patch 4/8] kexec-tools: Add libtool PKG_FIXUP [patch 5/8] kexec-tools: Minor makefile line end fixes [patch 6/8] kexec-tools: Make build of kdump optional [patch 7/8] kexec-tools: Make link /sbin/kexec for compatability with other distros [patch 8/8] kexec-tools: Remove the unused file kexec.sh Are there any comments regarding these updates? If not, I would like to commit them sometime soon. Mita-san and Florian, and comments on patch [2]? I think it should be OK for pxcab. -Geoff ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] [patch 0/8] powerpc64 and kexec-tools updates
Hi Geoff, Le Wednesday 19 August 2009 00:10:52 Geoff Levand, vous avez écrit : On 08/14/2009 03:09 PM, Geoff Levand wrote: Hi, This set of patches introduces a new target feature powerpc64 to help simplify the build files, updates the kexec-tools package to version 2.0.1, and does some kexec-tools package cleanups. [patch 1/8] powerpc: Create a powerpc64 config feature [patch 2/8] pxcab: Replace TARGET_pxcab with feature powerpc64 [patch 3/8] kexec-tools: Update package to version 2.0.1 [patch 4/8] kexec-tools: Add libtool PKG_FIXUP [patch 5/8] kexec-tools: Minor makefile line end fixes [patch 6/8] kexec-tools: Make build of kdump optional [patch 7/8] kexec-tools: Make link /sbin/kexec for compatability with other distros [patch 8/8] kexec-tools: Remove the unused file kexec.sh Are there any comments regarding these updates? If not, I would like to commit them sometime soon. Mita-san and Florian, and comments on patch [2]? I think it should be OK for pxcab. Yes it is, that should have been done when merging the pxcab target. Go ahead for patches 1 and 2. Thanks. -Geoff -- Best regards, Florian Fainelli Email: flor...@openwrt.org Web: http://openwrt.org IRC: [florian] on irc.freenode.net --- signature.asc Description: This is a digitally signed message part. ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] [patch 0/8] powerpc64 and kexec-tools updates
On 08/18/2009 03:36 PM, Florian Fainelli wrote: Hi Geoff, Le Wednesday 19 August 2009 00:10:52 Geoff Levand, vous avez écrit : On 08/14/2009 03:09 PM, Geoff Levand wrote: Hi, This set of patches introduces a new target feature powerpc64 to help simplify the build files, updates the kexec-tools package to version 2.0.1, and does some kexec-tools package cleanups. [patch 1/8] powerpc: Create a powerpc64 config feature [patch 2/8] pxcab: Replace TARGET_pxcab with feature powerpc64 [patch 3/8] kexec-tools: Update package to version 2.0.1 [patch 4/8] kexec-tools: Add libtool PKG_FIXUP [patch 5/8] kexec-tools: Minor makefile line end fixes [patch 6/8] kexec-tools: Make build of kdump optional [patch 7/8] kexec-tools: Make link /sbin/kexec for compatability with other distros [patch 8/8] kexec-tools: Remove the unused file kexec.sh Are there any comments regarding these updates? If not, I would like to commit them sometime soon. Mita-san and Florian, and comments on patch [2]? I think it should be OK for pxcab. Yes it is, that should have been done when merging the pxcab target. Go ahead for patches 1 and 2. Thanks. OK, I committed [1] and [2] as revisions 17306 and 17307. -Geoff ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] replace /jffs with usb stick
I am having a hard time to find the place where mounting root / really happens .. It's in /sbin/mount_root. And yes, it is not exactly trivial to find (although in retrospect I had to admit that the name should have made it pretty obvious). See below the patch I use on my WL-700gE to mount the IDE drive's partition. Stefan Index: mount_root === --- mount_root (révision 14605) +++ mount_root (copie de travail) @@ -2,15 +2,75 @@ # Copyright (C) 2006 OpenWrt.org . /etc/functions.sh +echo mount_root /tmp/stef + jffs2_ready () { mtdpart=$(find_mtd_part rootfs_data) magic=$(hexdump $mtdpart -n 4 -e '4/1 %02x') [ $magic != deadc0de ] } +### Try to mount some drive. +mount_drive () { +# for m in jbd ext3; do +# echo mount_drive $m /tmp/stef +# insmod $m /tmp/stef 21 +# done + +rootdev=$1 + +COUNTER=0 +while [ ! -b $rootdev ] [ $COUNTER -lt 10 ]; do +echo mount sleep for $rootdev /tmp/stef +sleep 1 +let COUNTER=COUNTER+1 +done + +mount $rootdev /mnt [ -x /mnt/sbin/init ] { +echo mounted $rootdev /tmp/stef +. /bin/firstboot +pivot /mnt /rom +exit +} +} + +# mount_ide () { +# echo mount_ide /tmp/stef +# for m in ide-core aec62xx ide-generic ide-disk; do +# insmod $m /tmp/stef 21 +# done +# mount_drive /dev/hde1 +# } + +# mount_usb () { +# echo mount_usb /tmp/stef +# # ehci-hcd is for USB2, ohci-hcd and uhci-hcd are both for USB1 but only +# # one of them works. For WRTSL54GS, it's ohci, for WL700gE it's uhci. +# for m in usbcore ohci-hcd uhci-hcd ehci-hcd scsi_mod sd_mod usb-storage; do +# echo mount_usb $m /tmp/stef +# insmod $m /tmp/stef 21 +# done +# mount_drive /dev/sda1 +# } + +#mount_usb +#mount_ide +(cd /etc/modules.d load_modules *) +# GPIO 6 on WL-700gE is the `copy' button; if the button is released, +# gpioctl returns 0, and it return 64 if it is pressed. +# GPIO 4 on WL-700gE is the `ezsetup' button; if the button is released, +# gpioctl returns 0, and it return 16 if it is pressed. +if gpioctl get 6 /dev/null gpioctl get 4 /dev/null; then + # FIXME: This device name should come from a CONFIG_setting. + mount_drive /dev/hde1 +fi + +### If no drive, mount the JFFS2 partition or a ramdisk. grep rootfs_data /proc/mtd /dev/null 2/dev/null { +echo mount_root-11 /tmp/stef . /bin/firstboot mtd unlock rootfs_data +echo mount_root-12 /tmp/stef jffs2_ready { echo switching to jffs2 mount $(find_mtd_part rootfs_data) /jffs -t jffs2 \ ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/mailman/listinfo/openwrt-devel
[OpenWrt-Devel] [PATCH] pxcab: build fix for 2.6.30.5
0001-powerpc-mpic-Fix-mapping-of-DCR-based-MPIC-variants.patch was merged in 2.6.30.4 Signed-off-by: Akinobu Mita akinobu.m...@gmail.com --- ...ic-Fix-mapping-of-DCR-based-MPIC-variants.patch | 107 1 files changed, 0 insertions(+), 107 deletions(-) delete mode 100644 target/linux/pxcab/patches-2.6.30/0001-powerpc-mpic-Fix-mapping-of-DCR-based-MPIC-variants.patch diff --git a/target/linux/pxcab/patches-2.6.30/0001-powerpc-mpic-Fix-mapping-of-DCR-based-MPIC-variants.patch b/target/linux/pxcab/patches-2.6.30/0001-powerpc-mpic-Fix-mapping-of-DCR-based-MPIC-variants.patch deleted file mode 100644 index c546919..000 --- a/target/linux/pxcab/patches-2.6.30/0001-powerpc-mpic-Fix-mapping-of-DCR-based-MPIC-variants.patch +++ /dev/null @@ -1,107 +0,0 @@ -commit 5a2642f620eb6e40792822fa0eafe23046fbb55e -Author: Benjamin Herrenschmidt b...@kernel.crashing.org -Date: Mon Jun 22 16:47:59 2009 + - -powerpc/mpic: Fix mapping of DCR based MPIC variants - -Commit 31207dab7d2e63795eb15823947bd2f7025b08e2 -Fix incorrect allocation of interrupt rev-map -introduced a regression crashing on boot on machines using -a DCR based MPIC, such as the Cell blades. - -The reason is that the irq host data structure is initialized -much later as a result of that patch, causing our calls to -mpic_map() do be done before we have a host setup. - -Unfortunately, this breaks _mpic_map_dcr() which uses the -mpic-irqhost to get to the device node. - -This fixes it by, instead, passing the device node explicitely -to mpic_map(). - -Signed-off-by: Benjamin Herrenschmidt b...@kernel.crashing.org -Acked-by: Akira Tsukamoto aki...@rd.scei.sony.co.jp - -diff --git a/arch/powerpc/sysdev/mpic.c b/arch/powerpc/sysdev/mpic.c -index 9c3af50..32a2e95 100644 a/arch/powerpc/sysdev/mpic.c -+++ b/arch/powerpc/sysdev/mpic.c -@@ -279,28 +279,29 @@ static void _mpic_map_mmio(struct mpic *mpic, phys_addr_t phys_addr, - } - - #ifdef CONFIG_PPC_DCR --static void _mpic_map_dcr(struct mpic *mpic, struct mpic_reg_bank *rb, -+static void _mpic_map_dcr(struct mpic *mpic, struct device_node *node, -+struct mpic_reg_bank *rb, - unsigned int offset, unsigned int size) - { - const u32 *dbasep; - -- dbasep = of_get_property(mpic-irqhost-of_node, dcr-reg, NULL); -+ dbasep = of_get_property(node, dcr-reg, NULL); - -- rb-dhost = dcr_map(mpic-irqhost-of_node, *dbasep + offset, size); -+ rb-dhost = dcr_map(node, *dbasep + offset, size); - BUG_ON(!DCR_MAP_OK(rb-dhost)); - } - --static inline void mpic_map(struct mpic *mpic, phys_addr_t phys_addr, -- struct mpic_reg_bank *rb, unsigned int offset, -- unsigned int size) -+static inline void mpic_map(struct mpic *mpic, struct device_node *node, -+ phys_addr_t phys_addr, struct mpic_reg_bank *rb, -+ unsigned int offset, unsigned int size) - { - if (mpic-flags MPIC_USES_DCR) -- _mpic_map_dcr(mpic, rb, offset, size); -+ _mpic_map_dcr(mpic, node, rb, offset, size); - else - _mpic_map_mmio(mpic, phys_addr, rb, offset, size); - } - #else /* CONFIG_PPC_DCR */ --#define mpic_map(m,p,b,o,s) _mpic_map_mmio(m,p,b,o,s) -+#define mpic_map(m,n,p,b,o,s) _mpic_map_mmio(m,p,b,o,s) - #endif /* !CONFIG_PPC_DCR */ - - -@@ -1152,8 +1153,8 @@ struct mpic * __init mpic_alloc(struct device_node *node, - } - - /* Map the global registers */ -- mpic_map(mpic, paddr, mpic-gregs, MPIC_INFO(GREG_BASE), 0x1000); -- mpic_map(mpic, paddr, mpic-tmregs, MPIC_INFO(TIMER_BASE), 0x1000); -+ mpic_map(mpic, node, paddr, mpic-gregs, MPIC_INFO(GREG_BASE), 0x1000); -+ mpic_map(mpic, node, paddr, mpic-tmregs, MPIC_INFO(TIMER_BASE), 0x1000); - - /* Reset */ - if (flags MPIC_WANTS_RESET) { -@@ -1194,7 +1195,7 @@ struct mpic * __init mpic_alloc(struct device_node *node, - - /* Map the per-CPU registers */ - for (i = 0; i mpic-num_cpus; i++) { -- mpic_map(mpic, paddr, mpic-cpuregs[i], -+ mpic_map(mpic, node, paddr, mpic-cpuregs[i], -MPIC_INFO(CPU_BASE) + i * MPIC_INFO(CPU_STRIDE), -0x1000); - } -@@ -1202,7 +1203,7 @@ struct mpic * __init mpic_alloc(struct device_node *node, - /* Initialize main ISU if none provided */ - if (mpic-isu_size == 0) { - mpic-isu_size = mpic-num_sources; -- mpic_map(mpic, paddr, mpic-isus[0], -+ mpic_map(mpic, node, paddr, mpic-isus[0], -MPIC_INFO(IRQ_BASE), MPIC_INFO(IRQ_STRIDE) * mpic-isu_size); - } - mpic-isu_shift = 1 + __ilog2(mpic-isu_size - 1); -@@ -1256,8 +1257,10 @@ void __init mpic_assign_isu(struct mpic *mpic, unsigned int isu_num, - - BUG_ON(isu_num =