Re: [OpenWrt-Devel] [BB-rc3] Disabling DHCPv6 also disables IPv6 SLAAC
disabled is the same as omitting the dhcpv6 option. none is not valid in this context and causes havoc it seems ;)___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] openwrt-devel Digest, Vol 104, Issue 68
I for one second this patch. I have just bricked my router trying to get the current trx image to work on my WNR3500L. I am not sure why it worked previously but it does not now, but it was doing just as described, hanging at Starting program at 0x80001000. I thought it was because the MTD command had failed, so I tried from CFE and inadvertently overwrote my CFE - doh! Stephen Parry On 18/08/14 22:31, openwrt-devel-requ...@lists.openwrt.org wrote: Message: 2 Date: Mon, 18 Aug 2014 21:44:46 +0200 From: Rafa? Mi?ecki zaj...@gmail.com To: Hauke Mehrtens ha...@hauke-m.de,openwrt-devel@lists.openwrt.org Subject: [OpenWrt-Devel] [PATCH] brcm47xx: image: build alternative TRX using less optimized LZMA Message-ID: 1408391086-7330-1-git-send-email-zaj...@gmail.com Content-Type: text/plain; charset=UTF-8 There is a group of devices that lzma-loader doesn't work with. They simply hang at Starting program at 0x80001000 which is really hard to debug and we didn't find any solution for this for years. Broadcom doesn't use lzma-loader on these devices anyway. They decided to drop lzma-loader and use less optimal LZMA compression that can be handled by CFE itself (it doesn't use dictionary). So support these devices we will need kernel compressed with different parameters and trx without a loader. Signed-off-by: Rafa? Mi?ecki zaj...@gmail.com --- target/linux/brcm47xx/image/Makefile | 8 1 file changed, 8 insertions(+) diff --git a/target/linux/brcm47xx/image/Makefile b/target/linux/brcm47xx/image/Makefile index 584bb6c..d19a13e 100644 --- a/target/linux/brcm47xx/image/Makefile +++ b/target/linux/brcm47xx/image/Makefile @@ -12,7 +12,12 @@ define Build/Clean endef define Image/Prepare + # Optimized LZMA compression (with dictionary), handled by lzma-loader. cat $(KDIR)/vmlinux | $(STAGING_DIR_HOST)/bin/lzma e -si -so -eos -lc1 -lp2 -pb2 $(KDIR)/vmlinux.lzma + + # Less optimal LZMA compression (no dictionary), handled by CFE. + $(STAGING_DIR_HOST)/bin/lzma e -so -d16 $(KDIR)/vmlinux $(KDIR)/vmlinux-nodictionary.lzma + gzip -nc9 $(KDIR)/vmlinux $(KDIR)/vmlinux.gz ifneq ($(CONFIG_TARGET_ROOTFS_INITRAMFS),) cat $(KDIR)/vmlinux-initramfs | $(STAGING_DIR_HOST)/bin/lzma e -si -so -eos -lc1 -lp2 -pb2 $(KDIR)/vmlinux-initramfs.lzma @@ -230,6 +235,9 @@ define Image/Build $(STAGING_DIR_HOST)/bin/trx -o $(BIN_DIR)/$(IMG_PREFIX)-$(1).trx \ -f $(KDIR)/loader.gz -f $(KDIR)/vmlinux.lzma \ $(call trxalign/$(1),$(1)) + $(STAGING_DIR_HOST)/bin/trx -o $(BIN_DIR)/$(IMG_PREFIX)-$(1)-noloader-nodictionary.trx \ + -f $(KDIR)/vmlinux-nodictionary.lzma \ + $(call trxalign/$(1),$(1)) $(STAGING_DIR_HOST)/bin/trx -o $(BIN_DIR)/$(IMG_PREFIX)-$(1)-gz.trx \ -f $(KDIR)/vmlinux.gz \ $(call trxalign/$(1),$(1)) -- 1.8.4.5 ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] openwrt-devel Digest, Vol 104, Issue 85
The thing that makes my blood boil is this - there are plenty of use cases where initramfs is a must: - ELF boot from external media - KEXEC to external media - TFTP boot None of these currently work in BB whereas they used to. And you cannot easily add the scripts to support them because all the 'hookability' is outside of process id 1. This means when you try switch_root it blows up in your face. If you try pivot_root it fails cause you can't pivot_root ramfs. I have raised a bug - but no response yet. I have also submitted a small patch which was bounced? On 22/08/14 08:21, openwrt-devel-requ...@lists.openwrt.org wrote: Message: 3 Date: Thu, 21 Aug 2014 21:33:15 +0200 From: Rafa? Mi?ecki zaj...@gmail.com To: Hauke Mehrtens ha...@hauke-m.de Cc: OpenWrt Development List openwrt-devel@lists.openwrt.org Subject: Re: [OpenWrt-Devel] Firmware without SquashFS (initramfs + overlay) Message-ID: cacna6rxub8qm3-u3p-kb4gdx-sn-hb6dnkha3wfkhjrg1ea...@mail.gmail.com Content-Type: text/plain; charset=UTF-8 On 20 August 2014 23:22, Hauke Mehrtens ha...@hauke-m.de wrote: You want to use initramfs because the SquashFS image is booting very unreliable or are there any other reasons? Because firmware with SquashFS boot in unreliable :| This boot problems seams to be in the boot loader. The boot loader should not see a difference between an initramfs and a SquashFS image, could it be that the boot loader does not like small images or not aligned images? Could be some timing issue in OpenWrt as well. No idea how to debug that. -- Rafa? ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
[OpenWrt-Devel] [PATCH] brcm47xx: image: build alternative TRX using less optimized LZMA
I for one second this patch. I have just bricked my router trying to get the current trx image to work on my WNR3500L. I am not sure why it worked previously but it does not now, but it was doing just as described, hanging at Starting program at 0x80001000. I thought it was because the MTD command had failed, so I tried from CFE and inadvertently overwrote my CFE - doh! Stephen Parry P.S. Sorry for first post without subject - noob error. On 18/08/14 22:31, openwrt-devel-requ...@lists.openwrt.org wrote: Message: 2 Date: Mon, 18 Aug 2014 21:44:46 +0200 From: Rafa? Mi?ecki zaj...@gmail.com To: Hauke Mehrtens ha...@hauke-m.de,openwrt-devel@lists.openwrt.org Subject: [OpenWrt-Devel] [PATCH] brcm47xx: image: build alternative TRX using less optimized LZMA Message-ID: 1408391086-7330-1-git-send-email-zaj...@gmail.com Content-Type: text/plain; charset=UTF-8 There is a group of devices that lzma-loader doesn't work with. They simply hang at Starting program at 0x80001000 which is really hard to debug and we didn't find any solution for this for years. Broadcom doesn't use lzma-loader on these devices anyway. They decided to drop lzma-loader and use less optimal LZMA compression that can be handled by CFE itself (it doesn't use dictionary). So support these devices we will need kernel compressed with different parameters and trx without a loader. Signed-off-by: Rafa? Mi?ecki zaj...@gmail.com --- target/linux/brcm47xx/image/Makefile | 8 1 file changed, 8 insertions(+) diff --git a/target/linux/brcm47xx/image/Makefile b/target/linux/brcm47xx/image/Makefile index 584bb6c..d19a13e 100644 --- a/target/linux/brcm47xx/image/Makefile +++ b/target/linux/brcm47xx/image/Makefile @@ -12,7 +12,12 @@ define Build/Clean endef define Image/Prepare + # Optimized LZMA compression (with dictionary), handled by lzma-loader. cat $(KDIR)/vmlinux | $(STAGING_DIR_HOST)/bin/lzma e -si -so -eos -lc1 -lp2 -pb2 $(KDIR)/vmlinux.lzma + + # Less optimal LZMA compression (no dictionary), handled by CFE. + $(STAGING_DIR_HOST)/bin/lzma e -so -d16 $(KDIR)/vmlinux $(KDIR)/vmlinux-nodictionary.lzma + gzip -nc9 $(KDIR)/vmlinux $(KDIR)/vmlinux.gz ifneq ($(CONFIG_TARGET_ROOTFS_INITRAMFS),) cat $(KDIR)/vmlinux-initramfs | $(STAGING_DIR_HOST)/bin/lzma e -si -so -eos -lc1 -lp2 -pb2 $(KDIR)/vmlinux-initramfs.lzma @@ -230,6 +235,9 @@ define Image/Build $(STAGING_DIR_HOST)/bin/trx -o $(BIN_DIR)/$(IMG_PREFIX)-$(1).trx \ -f $(KDIR)/loader.gz -f $(KDIR)/vmlinux.lzma \ $(call trxalign/$(1),$(1)) + $(STAGING_DIR_HOST)/bin/trx -o $(BIN_DIR)/$(IMG_PREFIX)-$(1)-noloader-nodictionary.trx \ + -f $(KDIR)/vmlinux-nodictionary.lzma \ + $(call trxalign/$(1),$(1)) $(STAGING_DIR_HOST)/bin/trx -o $(BIN_DIR)/$(IMG_PREFIX)-$(1)-gz.trx \ -f $(KDIR)/vmlinux.gz \ $(call trxalign/$(1),$(1)) -- 1.8.4.5 ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] Firmware without SquashFS (initramfs + overlay)
The thing that makes my blood boil is this - there are plenty of use cases where initramfs is a must: - ELF boot from external media - KEXEC to external media - TFTP boot None of these currently work in BB whereas they used to. And you cannot easily add the scripts to support them because all the 'hookability' is outside of process id 1. This means when you try switch_root it blows up in your face. If you try pivot_root it fails cause you can't pivot_root ramfs. I have raised a bug - but no response yet. I have also submitted a small patch which was bounced? P.S. Sorry for first post without subject - noob error. On 22/08/14 08:21, openwrt-devel-requ...@lists.openwrt.org wrote: Message: 3 Date: Thu, 21 Aug 2014 21:33:15 +0200 From: Rafa? Mi?ecki zaj...@gmail.com To: Hauke Mehrtens ha...@hauke-m.de Cc: OpenWrt Development List openwrt-devel@lists.openwrt.org Subject: Re: [OpenWrt-Devel] Firmware without SquashFS (initramfs + overlay) Message-ID: cacna6rxub8qm3-u3p-kb4gdx-sn-hb6dnkha3wfkhjrg1ea...@mail.gmail.com Content-Type: text/plain; charset=UTF-8 On 20 August 2014 23:22, Hauke Mehrtens ha...@hauke-m.de wrote: You want to use initramfs because the SquashFS image is booting very unreliable or are there any other reasons? Because firmware with SquashFS boot in unreliable :| This boot problems seams to be in the boot loader. The boot loader should not see a difference between an initramfs and a SquashFS image, could it be that the boot loader does not like small images or not aligned images? Could be some timing issue in OpenWrt as well. No idea how to debug that. -- Rafa? ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
[OpenWrt-Devel] [PATCH] [boot] /init: allow easier customisation of ramfs boot.
/init is the first pid 1 process in an initramfs environment. This fix adds lines to check for the existence of /bin/ramfsinit or /sbin/ramfsinit and exec if present. This allows packages to switch root early in the boot process. This will help support booting or kexecing from external storage and go some way toward fixing ticket #17465. Signed-off-by: Stephen Parry sgpa...@mainscreen.com --- target/linux/generic/base-files/init | 8 1 file changed, 8 insertions(+) diff --git a/target/linux/generic/base-files/init b/target/linux/generic/base-files/init index 514be57..cae515d 100755 --- a/target/linux/generic/base-files/init +++ b/target/linux/generic/base-files/init @@ -1,4 +1,12 @@ #!/bin/sh # Copyright (C) 2006 OpenWrt.org export INITRAMFS=1 + +if [ -e /bin/ramfsinit ]; then + exec /bin/ramfsinit +fi +if [ -e /sbin/ramfsinit ]; then + exec /sbin/ramfsinit +fi + exec /sbin/init -- 1.9.1 ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
[OpenWrt-Devel] AsiaRF MT7620a mounting sdhci drive readonly
Hello All, Been trying to get an AsiaRF based MT7620a board running using CC r42230 and having issue getting the MMC SD card reader to mount rw. I have been in communication with the manufacturer to discover the GPIO (if any) used for the WP line for the SDHCI card reader on the board. They have not gotten back to me. In the mean time I have attempted to use some of the mmc driver properties such as wp-inverted to no avail. In desperation I implemented a patch based on http://permalink.gmane.org/gmane.linux.kernel.mmc/25615 which tells the driver to ignore the write protect line and assume r/w always... yet the card still mounts read only. note that when mounting the same SD card using a USB based reader the file system mounts rw as expected. here is the mount table showing the ro mount root@OpenWRT:~# mount rootfs on / type rootfs (rw) snip... /dev/mmcblk0p2 on /wxa type ext4 (ro,relatime,data=ordered) here is the DTS definition for the board sdhci@1013 { status = okay; broken-wp; }; following is the patch (some of you might find it useful). Any thoughts would greatly be appreciated. $ cat target/linux/ramips/patches-3.10/0402-mmc-add-broken-wp.patch --- a/Documentation/devicetree/bindings/mmc/mmc.txt2014-08-23 12:39:54.816004290 -0700 +++ b/Documentation/devicetree/bindings/mmc/mmc.txt2014-08-23 12:40:56.574123135 -0700 @@ -21,6 +21,8 @@ below for the case, when a GPIO is used for the CD line - wp-inverted: when present, polarity on the WP line is inverted. See the note below for the case, when a GPIO is used for the WP line +- broken-wp: when present, no indication of write protection is available, + and write protection is assumed always off. - max-frequency: maximum operating clock frequency - no-1-8-v: when present, denotes that 1.8v card voltage is not supported on this system, even if the controller claims it is. --- a/drivers/mmc/host/sdhci-pltfm.c2014-08-23 12:44:02.648454500 -0700 +++ b/drivers/mmc/host/sdhci-pltfm.c2014-08-23 12:45:52.009124011 -0700 @@ -80,7 +80,9 @@ bus_width == 1)) host-quirks |= SDHCI_QUIRK_FORCE_1_BIT_DATA; -if (sdhci_of_wp_inverted(np)) +if (of_get_property(np, sdhci,broken-wp, NULL) || of_get_property(np, broken-wp, NULL)) +host-quirks2 |= SDHCI_QUIRK2_BROKEN_WRITE_PROTECT; +else if (sdhci_of_wp_inverted(np)) host-quirks |= SDHCI_QUIRK_INVERTED_WRITE_PROTECT; if (of_get_property(np, broken-cd, NULL)) --- a/drivers/mmc/host/sdhci.c2014-08-23 12:46:10.028575138 -0700 +++ b/drivers/mmc/host/sdhci.c2014-08-23 12:48:23.588506665 -0700 @@ -1621,6 +1621,8 @@ if (host-flags SDHCI_DEVICE_DEAD) is_readonly = 0; +else if (host-quirks2 SDHCI_QUIRK2_BROKEN_WRITE_PROTECT) +is_readonly = 0; else if (host-ops-get_ro) is_readonly = host-ops-get_ro(host); else --- a/include/linux/mmc/sdhci.h2014-08-23 12:56:38.005445877 -0700 +++ b/include/linux/mmc/sdhci.h2014-08-23 12:58:58.113178602 -0700 @@ -95,6 +95,8 @@ /* The system physically doesn't support 1.8v, even if the host does */ #define SDHCI_QUIRK2_NO_1_8_V(12) #define SDHCI_QUIRK2_PRESET_VALUE_BROKEN(13) +/* There is no indication for write protection at all, assume RW */ +#define SDHCI_QUIRK2_BROKEN_WRITE_PROTECT(14) int irq;/* Device IRQ */ void __iomem *ioaddr;/* Mapped address */ -- Luis Soltero, Ph.D., MCS Director of Software Development, CTO Global Marine Networks, LLC StarPilot, LLC Tel: +1.865.379.8723 Fax: +1.865.681.5017 E-Mail: lsolt...@globalmarinenet.net Web: http://www.globalmarinenet.net Web: http://www.redportglobal.com Web: http://www.starpilotllc.com ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
[OpenWrt-Devel] [PATCH] mac80211/rt2x00: allow disabling bands through dts
Add dts property ralink,2ghz and ralink,5ghz e.g. disable 2ghz band: wmac@1018 { status = okay; ralink,2ghz = 0; } Signed-off-by: Alexander Couzens lyn...@fe80.eu --- ...-rt2x00-allow_disabling_bands_through_dts.patch | 27 ++ 1 file changed, 27 insertions(+) create mode 100644 package/kernel/mac80211/patches/609-rt2x00-allow_disabling_bands_through_dts.patch diff --git a/package/kernel/mac80211/patches/609-rt2x00-allow_disabling_bands_through_dts.patch b/package/kernel/mac80211/patches/609-rt2x00-allow_disabling_bands_through_dts.patch new file mode 100644 index 000..63a8641 --- /dev/null +++ b/package/kernel/mac80211/patches/609-rt2x00-allow_disabling_bands_through_dts.patch @@ -0,0 +1,27 @@ +--- a/drivers/net/wireless/rt2x00/rt2x00dev.c b/drivers/net/wireless/rt2x00/rt2x00dev.c +@@ -26,6 +26,7 @@ + #include linux/module.h + #include linux/slab.h + #include linux/log2.h ++#include linux/of.h + + #include rt2x00.h + #include rt2x00lib.h +@@ -951,6 +952,16 @@ static int rt2x00lib_probe_hw_modes(stru + struct ieee80211_rate *rates; + unsigned int num_rates; + unsigned int i; ++#ifdef CONFIG_OF ++ struct device_node *np = rt2x00dev-dev-of_node; ++ unsigned int enabled; ++ if (!of_property_read_u32(np, ralink,2ghz, ++ enabled) !enabled) ++ spec-supported_bands = ~SUPPORT_BAND_2GHZ; ++ if (!of_property_read_u32(np, ralink,5ghz, ++ enabled) !enabled) ++ spec-supported_bands = ~SUPPORT_BAND_5GHZ; ++#endif /* CONFIG_OF */ + + if (rt2x00dev-dev-platform_data) { + struct rt2x00_platform_data *pdata; -- 2.1.0 ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel