Re: [OpenWrt-Devel] [RFC] commit message in YAML format for new devices
On Sun, 12 Jan 2020 11:47:29 -1000, Paul Spooren wrote: > All commits adding new devices already include most relevant information > for creating the overview. However it would be convenient if developers > would format their commit messages in a generic format, therefore I'd > propose the following: > > Every commit message for newly added devices must contain a number of > hardware information and steps for an initial installation. > The hardware information should contain at least the following > information, maybe more: > > SoC, flash, ram, wifi, LEDs, buttons, USB, serial, vendor, model, device > tree ID, Ethernet ports Having just pitched this idea to you a few minutes ago, of course I'll be the first to ACK. ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] [PATCH] lantiq: spi-max-frequency
On Sat, 2015-11-21 at 19:15 +0100, John Crispin wrote: > Hi, > > common, you know how to send a patch and put a SoB under it. i've seen > you do it lots of times ;) > > John Yes, but it just doesn't feel right for me to do when the patch is essentially from Joerg and not from me. ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] [PATCH] lantiq: spi-max-frequency
On Sat, 2015-11-21 at 10:27 -0800, Daniel Gimpelevich wrote: > On Sat, 2015-11-21 at 19:15 +0100, John Crispin wrote: > > Hi, > > > > common, you know how to send a patch and put a SoB under it. i've seen > > you do it lots of times ;) > > > > John > > Yes, but it just doesn't feel right for me to do when the patch is > essentially from Joerg and not from me. > Are there any other DTS files to which this would apply? ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] [PATCH] lantiq: spi-max-frequency
On Sat, 2015-11-21 at 20:19 +0100, John Crispin wrote: > > On 21/11/2015 20:17, Daniel Gimpelevich wrote: > > On Sat, 2015-11-21 at 20:15 +0100, John Crispin wrote: > >> On 21/11/2015 20:05, Daniel Gimpelevich wrote: > >>> On Sat, 2015-11-21 at 10:27 -0800, Daniel Gimpelevich wrote: > >>>> On Sat, 2015-11-21 at 19:15 +0100, John Crispin wrote: > >>>>> Hi, > >>>>> > >>>>> common, you know how to send a patch and put a SoB under it. i've seen > >>>>> you do it lots of times ;) > >>>>> > >>>>> John > >>>> > >>>> Yes, but it just doesn't feel right for me to do when the patch is > >>>> essentially from Joerg and not from me. > >>>> > >>> > >>> Are there any other DTS files to which this would apply? > >>> > >> > >> grep for spi-gpio in the dts folder > > > > Do all three of those use the same chip? > > probably not > > > > I ask because Joerg mentioned some sort of datasheet. I only know that he tried the patch with BB on the TP-Link and it worked, and I tried it with DD on the Netgear and it worked. I never got CC to work properly with or without it. Any chance you can test on the FritzBox before a resubmit? ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] [PATCH] lantiq: spi-max-frequency
On Sat, 2015-11-21 at 20:15 +0100, John Crispin wrote: > On 21/11/2015 20:05, Daniel Gimpelevich wrote: > > On Sat, 2015-11-21 at 10:27 -0800, Daniel Gimpelevich wrote: > >> On Sat, 2015-11-21 at 19:15 +0100, John Crispin wrote: > >>> Hi, > >>> > >>> common, you know how to send a patch and put a SoB under it. i've seen > >>> you do it lots of times ;) > >>> > >>> John > >> > >> Yes, but it just doesn't feel right for me to do when the patch is > >> essentially from Joerg and not from me. > >> > > > > Are there any other DTS files to which this would apply? > > > > grep for spi-gpio in the dts folder Do all three of those use the same chip? ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
[OpenWrt-Devel] [PATCH] lantiq: spi-max-frequency
On Thu, 2015-02-26 at 16:02 +0100, Joerg Jungermann wrote: > Hi, > > I have here multiple TD-W8970 with Annex A and Annex B. > > > m25p80@0 { > > #address-cells = <1>; > > #size-cells = <1>; > > compatible = "s25fl129p0"; > > reg = <0 0>; > > linux,modalias = "m25p80", "mx25l3205d"; > > spi-max-frequency = <100>; > > I increased spi-max-frequency = <5000>. > According to the datasheets I found that is maximum frequency. > > With my 3 models (2x A, 1x B) these settings work with BB (kernel > 3.10) well. > I have not yet tested 3.18. > I benchmarked boot up times from spi-flash with my build. > I could lower bootup times (from uboot to init-completed) from 2m01s > to 1m18s. > > I suggest backporting this increase of the spi freq to BB. > > best regards Index: target/linux/lantiq/dts/DGN3500.dtsi === --- a/target/linux/lantiq/dts/DGN3500.dtsi (revision 47278) +++ b/target/linux/lantiq/dts/DGN3500.dtsi (working copy) @@ -85,7 +85,7 @@ compatible = "s25fl129p0"; reg = <0 0>; linux,modalias = "m25p80", "mx25l3205d"; - spi-max-frequency = <100>; + spi-max-frequency = <5000>; partition@0 { reg = <0x0 0x1>; Index: target/linux/lantiq/dts/TDW89X0.dtsi === --- a/target/linux/lantiq/dts/TDW89X0.dtsi (revision 47278) +++ b/target/linux/lantiq/dts/TDW89X0.dtsi (working copy) @@ -160,7 +160,7 @@ compatible = "en25q64", "m25p80"; reg = <0 0>; linux,modalias = "en25q64"; - spi-max-frequency = <100>; + spi-max-frequency = <5000>; partition@0 { reg = <0x0 0x2>; ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] [packages] broken package: procd is broken in 15.05 (#1879)
On Thu, 2015-10-22 at 22:30 +0100, Carlos Ferreira wrote: > Daniel > Your patch did not work without some simple modifications. > This puzzled me until I realized you meant the other Daniel. PS: HAPPY INTERNATIONAL CAPS LOCK DAY! ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] [packages] broken package: procd is broken in 15.05 (#1879)
On Thu, 2015-10-22 at 22:50 +0100, Carlos Ferreira wrote: > Yes :S Sorry! > Btw, Caps lock day? Did my Gmail applied some weird format again ? :S HTML. ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] [packages] broken package: procd is broken in 15.05 (#1879)
On Thu, 2015-10-22 at 17:54 +0200, Felix Fietkau wrote: > On 2015-10-21 01:34, Daniel Golle wrote: > > Hi! > > > > This has been an argument going on between the gcc and the glibc people > > for about 10 years now. > > See > > https://gcc.gnu.org/bugzilla/show_bug.cgi?id=25509 > > > > It seems like commit b6618ffa which added the symlinks silently broke > > things when building with glibc. > > Don't ask me why glibc enabled warn_unused_result for symlink(3) but > > doesn't for found mount(2) or mkdir(3)... > > > > A way around it would be to take things as they are and simply make > > sure to surpress the warning as shown in > > http://www.redhat.com/archives/rhl-devel-list/2007-March/msg00692.html [snip] > inline functions should be static. the always_inline part is irrelevant > here. > > - Felix Maybe it can just be typecast to void? This kind of issue was one of the last things I expected. I first learned C before ANSI or ISO had even draft standards, and I guess it still shows. ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] [PATCH procd] move /dev/shm to /tmp/shm
I see procd got an update. Any reason this patch was left out? On Fri, 2015-09-11 at 13:05 -0700, Daniel Gimpelevich wrote: > Is there an ETA for merging this? > > On Sun, 2015-07-19 at 19:14 -0700, Daniel Gimpelevich wrote: > > I'm intending for this fix to be backported to CC as well. > > > > On Tue, 2015-07-14 at 09:59 -0700, Daniel Gimpelevich wrote: > > > OpenSSL session caches create shared memory segments that appear as > > > files under /dev/shm. If there is not enough room there, execution > > > terminates with SIGBUS upon access. Even a single instance would > > > exceed > > > 512K. > > > > > > On Tue, 2015-07-14 at 11:50 +0200, John Crispin wrote: > > > > what kind of usage do you expect ? > > > > > > > > On 11/07/2015 03:58, Daniel Gimpelevich wrote: > > > > > Since the /dev filesystem is tiny, /dev/shm needs to live > > > somewhere > > > > > else. ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] [PATCH procd] move /dev/shm to /tmp/shm
Is there an ETA for merging this? On Sun, 2015-07-19 at 19:14 -0700, Daniel Gimpelevich wrote: > I'm intending for this fix to be backported to CC as well. > > On Tue, 2015-07-14 at 09:59 -0700, Daniel Gimpelevich wrote: > > OpenSSL session caches create shared memory segments that appear as > > files under /dev/shm. If there is not enough room there, execution > > terminates with SIGBUS upon access. Even a single instance would > > exceed > > 512K. > > > > On Tue, 2015-07-14 at 11:50 +0200, John Crispin wrote: > > > what kind of usage do you expect ? > > > > > > On 11/07/2015 03:58, Daniel Gimpelevich wrote: > > > > Since the /dev filesystem is tiny, /dev/shm needs to live > > somewhere > > > > else. ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] [PATCH procd] move /dev/shm to /tmp/shm
I'm intending for this fix to be backported to CC as well. On Tue, 2015-07-14 at 09:59 -0700, Daniel Gimpelevich wrote: OpenSSL session caches create shared memory segments that appear as files under /dev/shm. If there is not enough room there, execution terminates with SIGBUS upon access. Even a single instance would exceed 512K. On Tue, 2015-07-14 at 11:50 +0200, John Crispin wrote: what kind of usage do you expect ? On 11/07/2015 03:58, Daniel Gimpelevich wrote: Since the /dev filesystem is tiny, /dev/shm needs to live somewhere else. ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] [PATCH procd] move /dev/shm to /tmp/shm
OpenSSL session caches create shared memory segments that appear as files under /dev/shm. If there is not enough room there, execution terminates with SIGBUS upon access. Even a single instance would exceed 512K. On Tue, 2015-07-14 at 11:50 +0200, John Crispin wrote: what kind of usage do you expect ? On 11/07/2015 03:58, Daniel Gimpelevich wrote: Since the /dev filesystem is tiny, /dev/shm needs to live somewhere else. Signed-off-by: Daniel Gimpelevich dan...@gimpelevich.san-francisco.ca.us --- a/initd/early.c 2015-06-19 14:01:25.0 -0700 +++ b/initd/early.c 2015-07-10 15:04:23.270143065 -0700 @@ -66,16 +66,20 @@ mount(sysfs, /sys, sysfs, MS_NOATIME, 0); mount(none, /sys/fs/cgroup, cgroup, 0, 0); mount(tmpfs, /dev, tmpfs, MS_NOATIME, mode=0755,size=512K); - mkdir(/dev/shm, 01777); + symlink(/tmp/shm, /dev/shm); mkdir(/dev/pts, 0755); mount(devpts, /dev/pts, devpts, MS_NOATIME, mode=600); early_dev(); early_console(/dev/console); - if (mount_zram_on_tmp()) + if (mount_zram_on_tmp()) { mount(tmpfs, /tmp, tmpfs, MS_NOSUID | MS_NODEV | MS_NOATIME, NULL); - else - mkdev(*, 0600); + mkdir(/tmp/shm, 01777); + } else { + mkdir(/tmp/shm, 01777); + mount(tmpfs, /tmp/shm, tmpfs, MS_NOSUID | MS_NODEV | MS_NOATIME, + mode=01777); + } mkdir(/tmp/run, 0777); mkdir(/tmp/lock, 0777); mkdir(/tmp/state, 0777); --- a/plug/coldplug.c 2015-06-19 14:01:25.0 -0700 +++ b/plug/coldplug.c 2015-07-10 15:04:19.270123233 -0700 @@ -45,7 +45,7 @@ umount2(/dev/pts, MNT_DETACH); umount2(/dev/, MNT_DETACH); mount(tmpfs, /dev, tmpfs, 0, mode=0755,size=512K); - mkdir(/dev/shm, 01777); + symlink(/tmp/shm, /dev/shm); mkdir(/dev/pts, 0755); umask(oldumask); mount(devpts, /dev/pts, devpts, 0, 0); ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] [PATCH] Make virtualization guests built for pentium4 with SMP
On Sun, 2015-07-12 at 14:00 +0200, Hauke Mehrtens wrote: Will this work on most CPUs also the Atoms and so on? I would rather prefer -march=i686 and -mtune=generic for the x86 virtual machine images, but I am not an x86 expert. Do I need hardware support for visualization in my host CPU for all these images? Are all the AMD CPUs with hardware visualization support when IO build with -march=pentium4 ? It's already used for the Xen guest kernel, just not GCC. The gcc manpage says that all -march=pentium4 means is enable MMX, SSE, and SSE2, which I believe the old Atoms support, but even if they don't, running any VM on such low-spec processors isn't likely to work anyway. Using -march=i686 is an alias for Pentium Pro, that is, before the Pentium II. ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
[OpenWrt-Devel] [PATCH] Make virtualization guests built for pentium4 with SMP
Signed-off-by: Daniel Gimpelevich dan...@gimpelevich.san-francisco.ca.us --- include/target.mk | 1 + target/linux/x86/kvm_guest/config-default | 15 ++- target/linux/x86/kvm_guest/target.mk | 1 + target/linux/x86/xen_domu/target.mk | 1 + 4 files changed, 17 insertions(+), 1 deletion(-) diff --git a/include/target.mk b/include/target.mk index bfead52..3e7f17d 100644 --- a/include/target.mk +++ b/include/target.mk @@ -222,6 +222,7 @@ ifeq ($(DUMP),1) ifeq ($(ARCH),i386) CPU_TYPE ?= i486 CPU_CFLAGS_i486 = -march=i486 +CPU_CFLAGS_pentium4 = -march=pentium4 CPU_CFLAGS_geode = -march=geode -mmmx -m3dnow endif ifneq ($(findstring arm,$(ARCH)),) diff --git a/target/linux/x86/kvm_guest/config-default b/target/linux/x86/kvm_guest/config-default index f26e268..b54b1df 100644 --- a/target/linux/x86/kvm_guest/config-default +++ b/target/linux/x86/kvm_guest/config-default @@ -19,12 +19,14 @@ CONFIG_ACPI_PROCESSOR=y # CONFIG_ACPI_THERMAL is not set # CONFIG_ACPI_WMI is not set CONFIG_ARCH_MIGHT_HAVE_ACPI_PDC=y +CONFIG_ARCH_PHYS_ADDR_T_64BIT=y # CONFIG_ASUS_LAPTOP is not set CONFIG_CPU_IDLE_GOV_MENU=y # CONFIG_EEEPC_LAPTOP is not set # CONFIG_EFI is not set CONFIG_HAVE_ACPI_APEI=y CONFIG_HAVE_ACPI_APEI_NMI=y +# CONFIG_HIGHMEM64G is not set CONFIG_HOTPLUG_PCI=y CONFIG_HOTPLUG_PCI_ACPI=y # CONFIG_HOTPLUG_PCI_ACPI_IBM is not set @@ -45,17 +47,21 @@ CONFIG_HYPERVISOR_GUEST=y CONFIG_KVM_GUEST=y # CONFIG_LGUEST is not set # CONFIG_LGUEST_GUEST is not set -CONFIG_NLS=y CONFIG_NO_HZ=y +# CONFIG_M486 is not set +CONFIG_MPENTIUM4=y +CONFIG_NR_CPUS=4 CONFIG_PARAVIRT=y CONFIG_PARAVIRT_CLOCK=y # CONFIG_PARAVIRT_DEBUG is not set +CONFIG_PARAVIRT_SPINLOCKS=y CONFIG_PARAVIRT_TIME_ACCOUNTING=y CONFIG_PCIEAER=y CONFIG_PCIEPORTBUS=y CONFIG_PCI_IOAPIC=y CONFIG_PCI_LABEL=y CONFIG_PCI_MMCONFIG=y +CONFIG_PHYS_ADDR_T_64BIT=y CONFIG_PNP=y CONFIG_PNPACPI=y CONFIG_PNP_DEBUG_MESSAGES=y @@ -64,6 +70,8 @@ CONFIG_RAS=y # CONFIG_SAMSUNG_Q10 is not set # CONFIG_SCSI_VIRTIO is not set CONFIG_SERIAL_8250_PNP=y +CONFIG_SLUB_CPU_PARTIAL=y +CONFIG_SMP=y # CONFIG_THINKPAD_ACPI is not set # CONFIG_TOPSTAR_LAPTOP is not set # CONFIG_TOSHIBA_BT_RFKILL is not set @@ -76,14 +84,19 @@ CONFIG_VIRTIO_PCI=y CONFIG_VIRTUALIZATION=y # CONFIG_VMWARE_BALLOON is not set # CONFIG_VT_HW_CONSOLE_BINDING is not set +CONFIG_X86_32_SMP=y # CONFIG_X86_ACPI_CPUFREQ is not set +# CONFIG_X86_BIGSMP is not set # CONFIG_X86_E_POWERSAVER is not set # CONFIG_X86_GENERIC is not set +CONFIG_X86_HT=y # CONFIG_X86_INTEL_LPSS is not set CONFIG_X86_INTERNODE_CACHE_SHIFT=4 CONFIG_X86_L1_CACHE_SHIFT=4 # CONFIG_X86_LONGHAUL is not set +CONFIG_X86_PAE=y # CONFIG_X86_PAT is not set # CONFIG_X86_PCC_CPUFREQ is not set CONFIG_X86_PM_TIMER=y # CONFIG_X86_PPRO_FENCE is not set +# CONFIG_XEN is not set diff --git a/target/linux/x86/kvm_guest/target.mk b/target/linux/x86/kvm_guest/target.mk index d3f950f..4bdfbc6 100644 --- a/target/linux/x86/kvm_guest/target.mk +++ b/target/linux/x86/kvm_guest/target.mk @@ -1,3 +1,4 @@ BOARDNAME:=KVM Guest FEATURES:=ext4 pci usb DEFAULT_PACKAGES += kmod-virtio-balloon kmod-virtio-net kmod-virtio-random +CPU_TYPE := pentium4 diff --git a/target/linux/x86/xen_domu/target.mk b/target/linux/x86/xen_domu/target.mk index f7a69bf..31d110c 100644 --- a/target/linux/x86/xen_domu/target.mk +++ b/target/linux/x86/xen_domu/target.mk @@ -1,3 +1,4 @@ BOARDNAME:=Xen Paravirt Guest DEFAULT_PACKAGES += kmod-xen-fs kmod-xen-evtchn kmod-xen-netdev kmod-xen-kbddev FEATURES:=display ext4 targz +CPU_TYPE := pentium4 -- 1.9.1 ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
[OpenWrt-Devel] [PATCH procd] move /dev/shm to /tmp/shm
Since the /dev filesystem is tiny, /dev/shm needs to live somewhere else. Signed-off-by: Daniel Gimpelevich dan...@gimpelevich.san-francisco.ca.us --- a/initd/early.c 2015-06-19 14:01:25.0 -0700 +++ b/initd/early.c 2015-07-10 15:04:23.270143065 -0700 @@ -66,16 +66,20 @@ mount(sysfs, /sys, sysfs, MS_NOATIME, 0); mount(none, /sys/fs/cgroup, cgroup, 0, 0); mount(tmpfs, /dev, tmpfs, MS_NOATIME, mode=0755,size=512K); - mkdir(/dev/shm, 01777); + symlink(/tmp/shm, /dev/shm); mkdir(/dev/pts, 0755); mount(devpts, /dev/pts, devpts, MS_NOATIME, mode=600); early_dev(); early_console(/dev/console); - if (mount_zram_on_tmp()) + if (mount_zram_on_tmp()) { mount(tmpfs, /tmp, tmpfs, MS_NOSUID | MS_NODEV | MS_NOATIME, NULL); - else - mkdev(*, 0600); + mkdir(/tmp/shm, 01777); + } else { + mkdir(/tmp/shm, 01777); + mount(tmpfs, /tmp/shm, tmpfs, MS_NOSUID | MS_NODEV | MS_NOATIME, + mode=01777); + } mkdir(/tmp/run, 0777); mkdir(/tmp/lock, 0777); mkdir(/tmp/state, 0777); --- a/plug/coldplug.c 2015-06-19 14:01:25.0 -0700 +++ b/plug/coldplug.c 2015-07-10 15:04:19.270123233 -0700 @@ -45,7 +45,7 @@ umount2(/dev/pts, MNT_DETACH); umount2(/dev/, MNT_DETACH); mount(tmpfs, /dev, tmpfs, 0, mode=0755,size=512K); - mkdir(/dev/shm, 01777); + symlink(/tmp/shm, /dev/shm); mkdir(/dev/pts, 0755); umask(oldumask); mount(devpts, /dev/pts, devpts, 0, 0); ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
[OpenWrt-Devel] [PATCH procd] fix /dev/shm permissions
On my Ubuntu system, the permissions are 1777. They are incorrect in procd, leading to this: https://forum.openwrt.org/viewtopic.php?id=57073 This in intended for both CC and DD. Signed-off-by: Daniel Gimpelevich dan...@gimpelevich.san-francisco.ca.us --- a/initd/early.c 2015-06-14 19:31:47.0 -0700 +++ b/initd/early.c 2015-06-17 02:15:23.858379753 -0700 @@ -64,7 +64,7 @@ mount(sysfs, /sys, sysfs, MS_NOATIME, 0); mount(none, /sys/fs/cgroup, cgroup, 0, 0); mount(tmpfs, /dev, tmpfs, MS_NOATIME, mode=0755,size=512K); - mkdir(/dev/shm, 0755); + mkdir(/dev/shm, 01777); mkdir(/dev/pts, 0755); mount(devpts, /dev/pts, devpts, MS_NOATIME, mode=600); early_dev(); --- a/plug/coldplug.c 2015-06-14 19:31:47.0 -0700 +++ b/plug/coldplug.c 2015-06-17 02:17:43.259071000 -0700 @@ -44,7 +44,7 @@ umount2(/dev/pts, MNT_DETACH); umount2(/dev/, MNT_DETACH); mount(tmpfs, /dev, tmpfs, 0, mode=0755,size=512K); - mkdir(/dev/shm, 0755); + mkdir(/dev/shm, 01777); mkdir(/dev/pts, 0755); mount(devpts, /dev/pts, devpts, 0, 0); udevtrigger.cb = udevtrigger_complete; ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] [PATCH] cyassl: version bump
On Wed, 2015-05-20 at 15:34 -0700, Daniel Gimpelevich wrote: On Thu, 2015-05-21 at 00:19 +0200, Hauke Mehrtens wrote: On 05/20/2015 11:42 PM, Daniel Gimpelevich wrote: This patch introduces a new build error into coova-chilli, but coova-chilli already fails to build even without it anyway. CyaSSL is now called wolfSSL, and all the API's have been renamed, and backward-compatibility headers added. Does this fix any security Issues? Otherwise I would wait till the branch to update this library. Hauke It's mostly new features and many bug fixes, though there are a few minor security-related changes relating to obsolete algorithms and protocols. The changelog contains the following note: - No high level security fixes that requires an update though we always recommend updating to the latest (except note 6 use case of ecc/normal math) It should be noted that since version 3.3.0, there have been versions 3.3.2, 3.4.0, and 3.4.6 now. It might be worth fixing the coova-chilli package to build before the branch so that it isn't stuck with a broken package, but if anyone does that without this patch, applying this patch will re-break it, so it might pay to do this a priori. If you disagree, I believe the branch is scheduled for this week, so the wait wouldn't be long. Chaos Calmer has been branched. Time to apply the patch? ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
[OpenWrt-Devel] [PATCH] cyassl: version bump
This patch introduces a new build error into coova-chilli, but coova-chilli already fails to build even without it anyway. CyaSSL is now called wolfSSL, and all the API's have been renamed, and backward-compatibility headers added. Signed-off-by: Daniel Gimpelevich dan...@gimpelevich.san-francisco.ca.us --- a/package/libs/cyassl/Makefile (revision 45705) +++ b/package/libs/cyassl/Makefile (working copy) @@ -7,13 +7,13 @@ include $(TOPDIR)/rules.mk -PKG_NAME:=cyassl -PKG_VERSION:=3.3.0 -PKG_RELEASE:=2 +PKG_NAME:=wolfssl +PKG_VERSION:=3.4.6 +PKG_RELEASE:=1 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).zip PKG_SOURCE_URL:=http://www.yassl.com/ -PKG_MD5SUM:=0303eb0f2f9065a1207d9104ab0eba7c +PKG_MD5SUM:=0410b3841588d635e9ecacb2d42c38f5 PKG_FIXUP:=libtool PKG_INSTALL:=1 @@ -45,17 +45,27 @@ --enable-ecc \ --disable-examples +ifneq ($(CONFIG_TARGET_x86),) + CONFIGURE_ARGS += --enable-intelasm +endif +ifneq ($(CONFIG_TARGET_x86_64),) + CONFIGURE_ARGS += --enable-intelasm +endif + define Build/InstallDev $(INSTALL_DIR) $(1)/usr/include $(CP) $(PKG_INSTALL_DIR)/usr/include/* $(1)/usr/include/ $(INSTALL_DIR) $(1)/usr/lib - $(CP) $(PKG_INSTALL_DIR)/usr/lib/libcyassl.{so*,la} $(1)/usr/lib/ + $(CP) $(PKG_INSTALL_DIR)/usr/lib/libwolfssl.{so*,la} $(1)/usr/lib/ + ln -s libwolfssl.so $(1)/usr/lib/libcyassl.so + ln -s libwolfssl.la $(1)/usr/lib/libcyassl.la endef define Package/libcyassl/install $(INSTALL_DIR) $(1)/usr/lib - $(CP) $(PKG_INSTALL_DIR)/usr/lib/libcyassl.so* $(1)/usr/lib/ + $(CP) $(PKG_INSTALL_DIR)/usr/lib/libwolfssl.so* $(1)/usr/lib/ + ln -s libwolfssl.so $(1)/usr/lib/libcyassl.so endef $(eval $(call BuildPackage,libcyassl)) --- a/package/libs/cyassl/patches/200-SSL_accept-handle-hello-garbage.patch (revision 45705) +++ b/package/libs/cyassl/patches/200-SSL_accept-handle-hello-garbage.patch (working copy) @@ -1,6 +1,6 @@ --- a/src/internal.c +++ b/src/internal.c -@@ -6037,6 +6037,10 @@ int ProcessReply(CYASSL* ssl) +@@ -6353,6 +6353,10 @@ int ProcessReply(CYASSL* ssl) b1 = ssl-buffers.inputBuffer.buffer[ssl-buffers.inputBuffer.idx++]; ssl-curSize = (word16)(((b0 0x7f) 8) | b1); --- a/package/libs/cyassl/patches/300-SSL_set_tlsext_host_name.patch (revision 45705) +++ b/package/libs/cyassl/patches/300-SSL_set_tlsext_host_name.patch (working copy) @@ -1,10 +1,10 @@ a/cyassl/openssl/ssl.h -+++ b/cyassl/openssl/ssl.h -@@ -372,6 +373,7 @@ - #define SSL_CTX_get_ex_new_index CyaSSL_CTX_get_ex_new_index +--- a/wolfssl/openssl/ssl.h b/wolfssl/openssl/ssl.h +@@ -398,6 +398,7 @@ + #define SSL_get_default_timeout(ctx) 500 -+#define SSL_set_tlsext_host_name(x, y) CyaSSL_UseSNI(x, CYASSL_SNI_HOST_NAME, y, strlen(y)) ++#define SSL_set_tlsext_host_name(x, y) wolfSSL_UseSNI(x, WOLFSSL_SNI_HOST_NAME, y, strlen(y)) #ifdef __cplusplus } /* extern C */ --- /dev/null (revision 0) +++ b/package/libs/cyassl/patches/400-additional_compatibility.patch (working copy) @@ -0,0 +1,15 @@ +--- a/cyassl/openssl/ssl.h 2015-02-25 13:04:52.0 -0800 b/cyassl/openssl/ssl.h 2015-05-20 11:13:44.476628943 -0700 +@@ -25,3 +25,12 @@ + */ + ++#ifndef CYASSL_OPENSSL_H_ ++#define CYASSL_OPENSSL_H_ ++ ++#include cyassl/ssl.h ++#ifndef HAVE_SNI ++#undef CYASSL_SNI_HOST_NAME ++#endif + #include wolfssl/openssl/ssl.h ++ ++#endif ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] [PATCH] cyassl: version bump
On Thu, 2015-05-21 at 00:19 +0200, Hauke Mehrtens wrote: On 05/20/2015 11:42 PM, Daniel Gimpelevich wrote: This patch introduces a new build error into coova-chilli, but coova-chilli already fails to build even without it anyway. CyaSSL is now called wolfSSL, and all the API's have been renamed, and backward-compatibility headers added. Does this fix any security Issues? Otherwise I would wait till the branch to update this library. Hauke It's mostly new features and many bug fixes, though there are a few minor security-related changes relating to obsolete algorithms and protocols. The changelog contains the following note: - No high level security fixes that requires an update though we always recommend updating to the latest (except note 6 use case of ecc/normal math) It should be noted that since version 3.3.0, there have been versions 3.3.2, 3.4.0, and 3.4.6 now. It might be worth fixing the coova-chilli package to build before the branch so that it isn't stuck with a broken package, but if anyone does that without this patch, applying this patch will re-break it, so it might pay to do this a priori. If you disagree, I believe the branch is scheduled for this week, so the wait wouldn't be long. ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] Lantiq 3.10 (BB) was lantiq v3.18
On Thu, 26 Feb 2015 16:02:23 +0100, Joerg Jungermann wrote: Hi, I have here multiple TD-W8970 with Annex A and Annex B. m25p80@0 { #address-cells = 1; #size-cells = 1; compatible = s25fl129p0; reg = 0 0; linux,modalias = m25p80, mx25l3205d; spi-max-frequency = 100; I increased spi-max-frequency = 5000. According to the datasheets I found that is maximum frequency. With my 3 models (2x A, 1x B) these settings work with BB (kernel 3.10) well. I have not yet tested 3.18. I benchmarked boot up times from spi-flash with my build. I could lower bootup times (from uboot to init-completed) from 2m01s to 1m18s. I suggest backporting this increase of the spi freq to BB. best regards I will be very interested to see you try 3.18 and report back, because 3.14 worked fine for me where 3.18 does not. ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] lantiq v3.18
On Thu, 2015-02-26 at 09:06 +0100, John Crispin wrote: you might want to consider the td8970. it works well for many people but also has the slow spi flash problem and takes ages the boot. Considering that the whole target is heading for unsupported status, I don't understand how switching to a td8970 would improve things. I'm not sure what work has been done to support MediaTek DSL interfaces after they released driver source, but AFAIK they don't involve VoIP hardware, and the wifi driver is not nearly as mature as Atheros. ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] lantiq v3.18
On Sun, 15 Feb 2015 05:21:34 +, Daniel Gimpelevich wrote: On Sat, 14 Feb 2015 19:55:03 +0100, John Crispin wrote: ok, i think the spi clock is just really slow m25p80@0 { #address-cells = 1; #size-cells = 1; compatible = s25fl129p0; reg = 0 0; linux,modalias = m25p80, mx25l3205d; spi-max-frequency = 100; try increasing it to 10 or 20 mhz. running the flash at 1 Mhz explains why it takes a week to boot and do anything useful. even with the bus being bitbanged it should be possible to go beyond 1mhz 1) I'm not sure what tests to run to see what frequency is safe. 2) That's the flash, though. I don't think it explains why the DSL interface in particular takes forever and a day to acknowledge anything. Does it? OK, adding an extra zero to spi-max-frequency leaves me with no Internet after boot. The nas0 interface is created but not brought up. Also, /etc/init.d/dsl_control STILL takes about twenty minutes to execute. Here is the output of logread: Wed Feb 25 16:33:51 2015 kern.info kernel: [ 28.50] IFXUSB: ifxusb_hcd: version 3.2 B110801 Wed Feb 25 16:33:51 2015 kern.info kernel: [ 29.004000] IFXUSB: USB core #0 soft-reset Wed Feb 25 16:33:51 2015 kern.info kernel: [ 29.208000] IFXUSB: USB core #0 soft-reset Wed Feb 25 16:33:51 2015 kern.info kernel: [ 29.208000] ifxusb_hcd ifxusb_hcd: IFX USB Controller Wed Feb 25 16:33:51 2015 kern.info kernel: [ 29.212000] ifxusb_hcd ifxusb_hcd: new USB bus registered, assigned bus number 1 Wed Feb 25 16:33:51 2015 kern.info kernel: [ 29.22] ifxusb_hcd ifxusb_hcd: irq 62, io mem 0xbe101000 Wed Feb 25 16:33:51 2015 kern.info kernel: [ 29.228000] IFXUSB: Init: Power Port (0) Wed Feb 25 16:33:51 2015 kern.info kernel: [ 29.236000] hub 1-0:1.0: USB hub found Wed Feb 25 16:33:51 2015 kern.info kernel: [ 29.236000] hub 1-0:1.0: 1 port detected Wed Feb 25 16:33:51 2015 kern.notice kernel: [ 30.916000] random: mktemp urandom read with 121 bits of entropy available Wed Feb 25 16:33:51 2015 kern.notice kernel: [ 32.852000] random: nonblocking pool is initialized Wed Feb 25 16:33:51 2015 kern.notice kernel: [ 40.812000] jffs2: notice: (286) jffs2_build_xattr_subsystem: complete building xattr subsystem, 0 of xdatum (0 unchecked, 0 orphan) and 0 of xref (0 dead, 0 orphan) found. Wed Feb 25 16:33:51 2015 user.info kernel: [ 40.832000] block: attempting to load /tmp/jffs_cfg/upper/etc/config/fstab Wed Feb 25 16:33:51 2015 user.info kernel: [ 40.912000] block: extroot: not configured Wed Feb 25 16:33:51 2015 kern.notice kernel: [ 42.54] jffs2: notice: (283) jffs2_build_xattr_subsystem: complete building xattr subsystem, 0 of xdatum (0 unchecked, 0 orphan) and 0 of xref (0 dead, 0 orphan) found. Wed Feb 25 16:33:51 2015 user.info kernel: [ 47.672000] block: attempting to load /tmp/jffs_cfg/upper/etc/config/fstab Wed Feb 25 16:33:51 2015 user.info kernel: [ 47.72] block: extroot: not configured Wed Feb 25 16:33:51 2015 kern.info kernel: [ 53.648000] NET: Registered protocol family 10 Wed Feb 25 16:33:51 2015 kern.info kernel: [ 53.672000] zram: Created 1 device(s) ... Wed Feb 25 16:33:51 2015 kern.info kernel: [ 53.68] NET: Registered protocol family 8 Wed Feb 25 16:33:51 2015 kern.info kernel: [ 53.684000] NET: Registered protocol family 20 Wed Feb 25 16:33:51 2015 kern.info kernel: [ 53.70] tun: Universal TUN/TAP device driver, 1.6 Wed Feb 25 16:33:51 2015 kern.info kernel: [ 53.704000] tun: (C) 1999-2004 Max Krasnyansky m...@qualcomm.com Wed Feb 25 16:33:51 2015 kern.info kernel: [ 53.724000] sit: IPv6 over IPv4 tunneling driver Wed Feb 25 16:33:51 2015 kern.info kernel: [ 53.744000] PPP generic driver version 2.4.2 Wed Feb 25 16:33:51 2015 kern.info kernel: [ 53.764000] ip6_tables: (C) 2000-2006 Netfilter Core Team Wed Feb 25 16:33:51 2015 kern.info kernel: [ 53.796000] nf_conntrack version 0.5.0 (945 buckets, 3780 max) Wed Feb 25 16:33:51 2015 kern.info kernel: [ 53.896000] IFX MEI Version 5.00.00 Wed Feb 25 16:33:51 2015 kern.warn kernel: [ 53.924000] Infineon CPE API Driver version: DSL CPE API V3.24.4.4 Wed Feb 25 16:33:51 2015 kern.info kernel: [ 54.084000] u32 classifier Wed Feb 25 16:33:51 2015 kern.info kernel: [ 54.088000] input device check on Wed Feb 25 16:33:51 2015 kern.info kernel: [ 54.088000] Actions configured Wed Feb 25 16:33:51 2015 kern.info kernel: [ 54.124000] Mirror/redirect action on Wed Feb 25 16:33:51 2015 kern.info kernel: [ 54.196000] Loading modules backported from Linux version master-2014-11-04-0-gf3660a2 Wed Feb 25 16:33:51 2015 kern.info kernel: [ 54.204000] Backport generated by backports.git backports-20141023-2-g4ff890b Wed Feb 25 16:33:51 2015 kern.info kernel: [ 54.216000] ip_tables: (C) 2000-2006 Netfilter Core Team Wed
Re: [OpenWrt-Devel] lantiq v3.18
On Thu, 26 Feb 2015 07:23:20 +0100, John Crispin wrote: no idea what the poblem is. you'll have to wait till someone comes a long that has time to debug your problem. Considering that nobody else is working on lantiq, :( ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] lantiq v3.18
On Sat, 14 Feb 2015 19:55:03 +0100, John Crispin wrote: ok, i think the spi clock is just really slow m25p80@0 { #address-cells = 1; #size-cells = 1; compatible = s25fl129p0; reg = 0 0; linux,modalias = m25p80, mx25l3205d; spi-max-frequency = 100; try increasing it to 10 or 20 mhz. running the flash at 1 Mhz explains why it takes a week to boot and do anything useful. even with the bus being bitbanged it should be possible to go beyond 1mhz 1) I'm not sure what tests to run to see what frequency is safe. 2) That's the flash, though. I don't think it explains why the DSL interface in particular takes forever and a day to acknowledge anything. Does it? ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
[OpenWrt-Devel] [PATCH] Retry 6rd if wan is down
Currently, if you have dual WAN and the link needed for 6rd is down, it just silently fails. This patch makes it retry in case the link comes up. Signed-off-by: Daniel Gimpelevich dan...@gimpelevich.san-francisco.ca.us --- a/package/network/ipv6/6rd/files/6rd.sh (revision 44437) +++ b/package/network/ipv6/6rd/files/6rd.sh (working copy) @@ -33,7 +33,8 @@ fi if ! network_get_ipaddr ipaddr $wanif; then - proto_notify_error $cfg NO_WAN_LINK + sleep 60 + proto_setup_failed $cfg return fi } ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
[OpenWrt-Devel] [PATCH] ppp: Allow PPTP over a specified interface
In a dual-WAN setup, it's useful to specify an interface over which to have PPTP. Signed-off-by: Daniel Gimpelevich dan...@gimpelevich.san-francisco.ca.us --- a/package/network/services/ppp/files/ppp.sh (revision 44437) +++ b/package/network/services/ppp/files/ppp.sh (working copy) @@ -181,6 +181,7 @@ proto_pptp_init_config() { ppp_generic_init_config proto_config_add_string server + proto_config_add_string interface available=1 no_device=1 } @@ -190,9 +191,10 @@ local iface=$2 local ip serv_addr server - json_get_var server server { + json_get_vars interface server + [ -n $server ] { for ip in $(resolveip -t 5 $server); do - ( proto_add_host_dependency $config $ip ) + ( proto_add_host_dependency $config $ip $interface ) serv_addr=1 done } ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
[OpenWrt-Devel] [PATCH v2] ppp: Allow PPTP over a specified interface
On Fri, 13 Feb 2015 10:18:47 +, Daniel Gimpelevich wrote: In a dual-WAN setup, it's useful to specify an interface over which to have PPTP. Whoops, sent an out-of-date patch by mistake. Here's the real one. Signed-off-by: Daniel Gimpelevich dan...@gimpelevich.san-francisco.ca.us --- a/package/network/services/ppp/files/ppp.sh (revision 44437) +++ b/package/network/services/ppp/files/ppp.sh (working copy) @@ -181,6 +181,7 @@ proto_pptp_init_config() { ppp_generic_init_config proto_config_add_string server + proto_config_add_string interface available=1 no_device=1 } @@ -189,10 +190,11 @@ local config=$1 local iface=$2 - local ip serv_addr server - json_get_var server server { + local ip serv_addr server interface + json_get_vars interface server + [ -n $server ] { for ip in $(resolveip -t 5 $server); do - ( proto_add_host_dependency $config $ip ) + ( proto_add_host_dependency $config $ip $interface ) serv_addr=1 done } ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] [PATCH] Retry 6rd if wan is down
On Fri, 13 Feb 2015 20:09:40 +0800, Yousong Zhou wrote: A wild guess is that `return 1` or `exit 1` should do the trick. yousong No, the return value is ignored. ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] lantiq v3.18
On Fri, 13 Feb 2015 09:23:16 +0100, Sylwester Petela wrote: PCI works, I have one more issue (present from 3.14 kernel) , unit will hang (without any errors in console output) when trying to reboot from cli/luci, but only when dsl_control is started at boot, without attached line or with dsl_control excluded from running on boot, everything works ok, even trying to stop dsl_control before reboot doesn't help. I'm thinking that dts for P-2812HNU has something to do with it, but I cannot trace it. I'm not sure whether this is the same issue, but when I boot with the DSL connected, it takes another five minutes after the console shows the line procd: - init complete - before the DSL actually connects, and if I type time /etc/init.d/dsl_control status after it connects and walk away, it tells me it took twenty minutes to complete. This makes LuCI unusable, because it tries to query the status every few seconds, exhausting the RAM, which causes a reboot. This problem did not exist on 3.14, so I suspect it may be related to the kernel config. I might not be able to test anything new till the middle of next week. ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] lantiq v3.18
On Fri, 13 Feb 2015 19:43:32 +0100, John Crispin wrote: look at /proc/cpuinfo please and tell us how many bogomips are reported system type : AR9 rev 1.2 machine : DGN3500 - Netgear DGN3500 processor : 0 cpu model : MIPS 34Kc V4.12 BogoMIPS: 221.18 wait instruction: yes microsecond timers : yes tlb_entries : 16 extra interrupt vector : yes hardware watchpoint : yes, count: 4, address/irw mask: [0x0ffc, 0x0ffc, 0x0ffb, 0x0ffb] isa : mips1 mips2 mips32r1 mips32r2 ASEs implemented: mips16 dsp mt shadow register sets: 1 kscratch registers : 0 package : 0 core: 0 VCED exceptions : not available VCEI exceptions : not available ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] lantiq v3.18
On Thu, 12 Feb 2015 18:38:09 +0100, John Crispin wrote: ah i see, not even sure why we attach that info. the mtdsplid should automatically set the root= try removing the root= parameter please and see if it boots properly That was there to override the root= from the bootloader, otherwise it would try to use /dev/mtdblock0. This corrects it better and boots: Signed-off-by: Daniel Gimpelevich dan...@gimpelevich.san-francisco.ca.us --- a/target/linux/lantiq/dts/DGN3500.dtsi (revision 44424) +++ b/target/linux/lantiq/dts/DGN3500.dtsi (working copy) @@ -2,7 +2,7 @@ / { chosen { - bootargs-append = root=/dev/mtdblock5 console=ttyLTQ0,115200; + bootargs-append = root= console=ttyLTQ0,115200; }; memory@0 { ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] lantiq v3.18
On Thu, Feb 12, 2015 at 3:19 AM, John Crispin blo...@openwrt.org wrote: On 10/02/2015 10:40, Daniel Gimpelevich wrote: Is there a patchset I could try? try r44421 or newer Tried initramfs, bootlog attached. [0.00] Linux version 3.18.6 (danielg4@chimera) (gcc version 4.8.3 (OpenWrt/Linaro GCC 4.8-2014.04 r43982) ) #2 Thu Feb 12 08:19:32 PST 2015 [0.00] SoC: AR9 rev 1.2 [0.00] bootconsole [early0] enabled [0.00] CPU0 revision is: 0001954c (MIPS 34Kc) [0.00] MIPS: machine is DGN3500 - Netgear DGN3500 [0.00] Determined physical RAM map: [0.00] memory: 0400 @ (usable) [0.00] User-defined physical RAM map: [0.00] memory: 0400 @ (usable) [0.00] Initrd not found or empty - disabling initrd [0.00] Zone ranges: [0.00] Normal [mem 0x-0x03ff] [0.00] Movable zone start for each node [0.00] Early memory node ranges [0.00] node 0: [mem 0x-0x03ff] [0.00] Initmem setup node 0 [mem 0x-0x03ff] [0.00] Primary instruction cache 32kB, VIPT, 4-way, linesize 32 bytes. [0.00] Primary data cache 16kB, 4-way, VIPT, no aliases, linesize 32 bytes [0.00] Built 1 zonelists in Zone order, mobility grouping on. Total pages: 16256 [0.00] Kernel command line: root=/dev/ram rw ip=192.168.1.1:192.168.1.15eth0:on console=ttyS1,115200 ethaddr=30:46:9a:31:0c:99 phym=64M mem=64M panic=1 root=/dev/mtdblock5 console=ttyLTQ0,115200 [0.00] PID hash table entries: 256 (order: -2, 1024 bytes) [0.00] Dentry cache hash table entries: 8192 (order: 3, 32768 bytes) [0.00] Inode-cache hash table entries: 4096 (order: 2, 16384 bytes) [0.00] Writing ErrCtl register=1bc2 [0.00] Readback ErrCtl register=1bc2 [0.00] Memory: 56244K/65536K available (3319K kernel code, 150K rwdata, 672K rodata, 4288K init, 194K bss, 9292K reserved) [0.00] NR_IRQS:256 [0.00] CPU Clock: 333MHz [0.00] Calibrating delay loop... 221.18 BogoMIPS (lpj=442368) [0.04] pid_max: default: 32768 minimum: 301 [0.044000] Mount-cache hash table entries: 1024 (order: 0, 4096 bytes) [0.048000] Mountpoint-cache hash table entries: 1024 (order: 0, 4096 bytes) [0.056000] pinctrl core: initialized pinctrl subsystem [0.064000] NET: Registered protocol family 16 [0.072000] pinctrl-xway 1e100b10.pinmux: Init done [0.076000] dma-xway 1e104100.dma: Init done - hw rev: 6, ports: 5, channels: 20 [0.084000] PCI host bridge /fpi@1000/pci@E105400 ranges: [0.088000] MEM 0x1800..0x19ff [0.092000] IO 0x1ae0..0x1aff [0.096000] ath9k,eeprom ath9k_eep: failed to load eeprom address [0.108000] usbcore: registered new interface driver usbfs [0.112000] usbcore: registered new interface driver hub [0.116000] usbcore: registered new device driver usb [0.12] PCI host bridge to bus :00 [0.124000] pci_bus :00: root bus resource [mem 0x1800-0x19ff] [0.128000] pci_bus :00: root bus resource [io 0x] [0.132000] pci_bus :00: No busn resource found for root bus, will use [bus 00-ff] [0.136000] pci :00:0e.0: BAR 0: assigned [mem 0x1800-0x1800] [0.14] Switched to clocksource MIPS [0.144000] NET: Registered protocol family 2 [0.152000] TCP established hash table entries: 1024 (order: 0, 4096 bytes) [0.156000] TCP bind hash table entries: 1024 (order: 0, 4096 bytes) [0.164000] TCP: Hash tables configured (established 1024 bind 1024) [0.172000] TCP: reno registered [0.172000] UDP hash table entries: 256 (order: 0, 4096 bytes) [0.18] UDP-Lite hash table entries: 256 (order: 0, 4096 bytes) [0.188000] NET: Registered protocol family 1 [ 10.284000] gptu: totally 6 16-bit timers/counters [ 10.288000] gptu: misc_register on minor 63 [ 10.292000] gptu: succeeded to request irq 126 [ 10.30] gptu: succeeded to request irq 127 [ 10.304000] gptu: succeeded to request irq 128 [ 10.308000] gptu: succeeded to request irq 129 [ 10.312000] gptu: succeeded to request irq 130 [ 10.316000] gptu: succeeded to request irq 131 [ 10.324000] futex hash table entries: 256 (order: -1, 3072 bytes) [ 10.332000] squashfs: version 4.0 (2009/01/31) Phillip Lougher [ 10.336000] jffs2: version 2.2 (NAND) (SUMMARY) (LZMA) (RTIME) (CMODE_PRIORITY) (c) 2001-2006 Red Hat, Inc. [ 10.348000] msgmni has been set to 109 [ 10.352000] io scheduler noop registered [ 10.356000] io scheduler deadline registered (default) [ 10.36] 1e100c00.serial: ttyLTQ0 at MMIO 0x1e100c00 (irq = 112, base_baud = 0) is a lantiq,asc [ 10.372000] console [ttyLTQ0] enabled [ 10.372000] console [ttyLTQ0] enabled [ 10.38] bootconsole [early0] disabled [ 10.38] bootconsole [early0] disabled [ 10.40
Re: [OpenWrt-Devel] lantiq v3.18
On Thu, Feb 12, 2015 at 8:54 AM, Daniel Gimpelevich dan...@gimpelevich.san-francisco.ca.us wrote: On Thu, Feb 12, 2015 at 3:19 AM, John Crispin blo...@openwrt.org wrote: On 10/02/2015 10:40, Daniel Gimpelevich wrote: Is there a patchset I could try? try r44421 or newer Tried initramfs, bootlog attached. With this image, booting from SPI flash still fails, because there is no longer a kernel partition, so the rootfs is now /dev/mtdblock4, while the DTS file still specifies /dev/mtdblock5. ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] lantiq v3.18
On Thu, Feb 12, 2015 at 9:33 AM, John Crispin blo...@openwrt.org wrote: On 12/02/2015 18:30, Daniel Gimpelevich wrote: On Thu, Feb 12, 2015 at 8:54 AM, Daniel Gimpelevich dan...@gimpelevich.san-francisco.ca.us mailto:dan...@gimpelevich.san-francisco.ca.us wrote: On Thu, Feb 12, 2015 at 3:19 AM, John Crispin blo...@openwrt.org mailto:blo...@openwrt.org wrote: On 10/02/2015 10:40, Daniel Gimpelevich wrote: Is there a patchset I could try? try r44421 or newer Tried initramfs, bootlog attached. With this image, booting from SPI flash still fails, because there is no longer a kernel partition, so the rootfs is now /dev/mtdblock4, while the DTS file still specifies /dev/mtdblock5. and why does that cause booting to fail ? If the kernel cannot find the rootfs, it cannot boot. ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] lantiq v3.18
John Crispin j...@phrozen.org writes: On 10/02/2015 19:35, Joerg Hollmann wrote: Hello Daniel, could it be, that the definition of the kernel partition in the dts file of your device ist too small? i think the problem is that spi-gpio is either not loaded or loaded too late. i wont have time to look at it till friday though. I have seen similar error messages on the builds for the VG3503J. there is a kernel part defined in the dts ? the mtdsplit should handle it for your. i'll look at that aswell, only tested a initramfs on the VG3503J Booting an initramfs of 3.18 succeeds but still does not detect the SPI flash. It also uses a wrong macaddr, no doubt due to the following wrong logic in 0035-owrt-lantiq-wifi-and-ethernet-eeprom-handling.patch --- a/drivers/net/ethernet/lantiq_etop.c +++ b/drivers/net/ethernet/lantiq_etop.c @@ -161,7 +161,7 @@ struct ltq_etop_priv { int tx_irq; int rx_irq; - const void *mac; + void *mac; int mii_mode; spinlock_t lock; @@ -840,7 +840,11 @@ ltq_etop_init(struct net_device *dev) if (err) goto err_hw; - memcpy(mac, priv-pldata-mac, sizeof(struct sockaddr)); + if (priv-mac) + memcpy(mac, priv-mac, sizeof(struct sockaddr)); + else + memcpy(mac, ltq_get_eth_mac(), sizeof(struct sockaddr)) + if (!is_valid_ether_addr(mac.sa_data)) { pr_warn(etop: invalid MAC, using random\n); eth_random_addr(mac.sa_data); This stuffs the macaddr into the wrong field of the sockaddr and reads beyond the end of the macaddr. The corresponding patch to 3.14 was right ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] lantiq v3.18
Is there a patchset I could try? On Mon, 2015-02-09 at 12:44 -0800, Daniel Gimpelevich wrote: On Mon, 2015-02-09 at 21:27 +0100, John Crispin wrote: bootlog please On 09/02/2015 21:25, Daniel Gimpelevich wrote: On Mon, 2015-02-09 at 19:18 +0100, John Crispin wrote: try r44366 or newer please SPI flash is not detected, bricking the device. [0.00] Linux version 3.18.6 (danielg4@chimera) (gcc version 4.8.3 (OpenWrt/Linaro GCC 4.8-2014.04 r43982) ) #3 Mon Feb 9 115 [0.00] SoC: AR9 rev 1.2 [0.00] bootconsole [early0] enabled [0.00] CPU0 revision is: 0001954c (MIPS 34Kc) [0.00] MIPS: machine is DGN3500 - Netgear DGN3500 [0.00] Determined physical RAM map: [0.00] memory: 0400 @ (usable) [0.00] User-defined physical RAM map: [0.00] memory: 0400 @ (usable) [0.00] Initrd not found or empty - disabling initrd [0.00] Zone ranges: [0.00] Normal [mem 0x-0x03ff] [0.00] Movable zone start for each node [0.00] Early memory node ranges [0.00] node 0: [mem 0x-0x03ff] [0.00] Initmem setup node 0 [mem 0x-0x03ff] [0.00] Primary instruction cache 32kB, VIPT, 4-way, linesize 32 bytes. [0.00] Primary data cache 16kB, 4-way, VIPT, no aliases, linesize 32 bytes [0.00] Built 1 zonelists in Zone order, mobility grouping on. Total pages: 16256 [0.00] Kernel command line: root=/dev/mtdblock0 ip=192.168.1.1:192.168.1.15eth0:on console=ttyS1,115200 ethaddr=30:46:90 [0.00] PID hash table entries: 256 (order: -2, 1024 bytes) [0.00] Dentry cache hash table entries: 8192 (order: 3, 32768 bytes) [0.00] Inode-cache hash table entries: 4096 (order: 2, 16384 bytes) [0.00] Writing ErrCtl register=5880 [0.00] Readback ErrCtl register=5880 [0.00] Memory: 60404K/65536K available (3312K kernel code, 147K rwdata, 664K rodata, 144K init, 194K bss, 5132K reserved) [0.00] NR_IRQS:256 [0.00] CPU Clock: 333MHz [0.00] Calibrating delay loop... 221.18 BogoMIPS (lpj=442368) [0.036000] pid_max: default: 32768 minimum: 301 [0.04] Mount-cache hash table entries: 1024 (order: 0, 4096 bytes) [0.044000] Mountpoint-cache hash table entries: 1024 (order: 0, 4096 bytes) [0.052000] pinctrl core: initialized pinctrl subsystem [0.056000] NET: Registered protocol family 16 [0.064000] pinctrl-xway 1e100b10.pinmux: Init done [0.068000] dma-xway 1e104100.dma: Init done - hw rev: 6, ports: 5, channels: 20 [0.076000] PCI host bridge /fpi@1000/pci@E105400 ranges: [0.08] MEM 0x1800..0x19ff [0.084000] IO 0x1ae0..0x1aff [0.088000] ath9k,eeprom ath9k_eep: failed to load eeprom address [0.10] usbcore: registered new interface driver usbfs [0.104000] usbcore: registered new interface driver hub [0.108000] usbcore: registered new device driver usb [0.112000] PCI host bridge to bus :00 [0.116000] pci_bus :00: root bus resource [mem 0x1800-0x19ff] [0.12] pci_bus :00: root bus resource [io 0x] [0.124000] pci_bus :00: No busn resource found for root bus, will use [bus 00-ff] [0.128000] pci :00:0e.0: BAR 0: assigned [mem 0x1800-0x1800] [0.132000] Switched to clocksource MIPS [0.136000] NET: Registered protocol family 2 [0.144000] TCP established hash table entries: 1024 (order: 0, 4096 bytes) [0.148000] TCP bind hash table entries: 1024 (order: 0, 4096 bytes) [0.156000] TCP: Hash tables configured (established 1024 bind 1024) [0.164000] TCP: reno registered [0.164000] UDP hash table entries: 256 (order: 0, 4096 bytes) [0.172000] UDP-Lite hash table entries: 256 (order: 0, 4096 bytes) [0.18] NET: Registered protocol family 1 [0.184000] gptu: totally 6 16-bit timers/counters [0.188000] gptu: misc_register on minor 63 [0.192000] gptu: succeeded to request irq 126 [0.196000] gptu: succeeded to request irq 127 [0.20] gptu: succeeded to request irq 128 [0.204000] gptu: succeeded to request irq 129 [0.212000] gptu: succeeded to request irq 130 [0.216000] gptu: succeeded to request irq 131 [0.22] futex hash table entries: 256 (order: -1, 3072 bytes) [0.228000] squashfs: version 4.0 (2009/01/31) Phillip Lougher [0.236000] jffs2: version 2.2 (NAND) (SUMMARY) (LZMA) (RTIME) (CMODE_PRIORITY) (c) 2001-2006 Red Hat, Inc. [0.248000] msgmni has been set to 117 [0.252000] io scheduler noop registered [0.256000] io scheduler deadline registered (default) [0.26] 1e100c00.serial: ttyLTQ0 at MMIO 0x1e100c00 (irq = 112, base_baud = 0) is a lantiq,asc [0.268000] console [ttyLTQ0
Re: [OpenWrt-Devel] lantiq v3.18
On Mon, 2015-02-09 at 13:30 +0100, John Crispin wrote: Hi, i bumped the lantiq support to v3.18 and tested it on 6 different boards. I have not tested vdsl support due to lack of a vdsl line. could someone please do so. @antii: can you rebase/resnd the dwc2 series ? it does not apply to the v3.18 patches John Build now fails for AR9. Relevant log: scripts/kconfig/conf --silentoldconfig Kconfig net/sched/Kconfig:43: warning: menuconfig statement without prompt * * Restart config... * * * Staging drivers * Staging drivers (STAGING) [Y/n/?] y Data acquisition support (comedi) (COMEDI) [N/m/?] n RealTek RTL8192U Wireless LAN NIC driver (RTL8192U) [N/m/?] n Support for rtllib wireless devices (RTLLIB) [N/m/?] n RealTek RTL8712U (RTL8192SU) Wireless LAN NIC driver (R8712U) [N/m/y/?] n Realtek RTL8188EU Wireless LAN NIC driver (R8188EU) [N/m/y/?] n Realtek RTL8723AU Wireless LAN NIC driver (R8723AU) [N/m/?] (NEW) aborted! ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] lantiq v3.18
On Mon, 2015-02-09 at 19:18 +0100, John Crispin wrote: try r44366 or newer please SPI flash is not detected, bricking the device. ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] lantiq v3.18
On Mon, 2015-02-09 at 21:27 +0100, John Crispin wrote: bootlog please On 09/02/2015 21:25, Daniel Gimpelevich wrote: On Mon, 2015-02-09 at 19:18 +0100, John Crispin wrote: try r44366 or newer please SPI flash is not detected, bricking the device. [0.00] Linux version 3.18.6 (danielg4@chimera) (gcc version 4.8.3 (OpenWrt/Linaro GCC 4.8-2014.04 r43982) ) #3 Mon Feb 9 115 [0.00] SoC: AR9 rev 1.2 [0.00] bootconsole [early0] enabled [0.00] CPU0 revision is: 0001954c (MIPS 34Kc) [0.00] MIPS: machine is DGN3500 - Netgear DGN3500 [0.00] Determined physical RAM map: [0.00] memory: 0400 @ (usable) [0.00] User-defined physical RAM map: [0.00] memory: 0400 @ (usable) [0.00] Initrd not found or empty - disabling initrd [0.00] Zone ranges: [0.00] Normal [mem 0x-0x03ff] [0.00] Movable zone start for each node [0.00] Early memory node ranges [0.00] node 0: [mem 0x-0x03ff] [0.00] Initmem setup node 0 [mem 0x-0x03ff] [0.00] Primary instruction cache 32kB, VIPT, 4-way, linesize 32 bytes. [0.00] Primary data cache 16kB, 4-way, VIPT, no aliases, linesize 32 bytes [0.00] Built 1 zonelists in Zone order, mobility grouping on. Total pages: 16256 [0.00] Kernel command line: root=/dev/mtdblock0 ip=192.168.1.1:192.168.1.15eth0:on console=ttyS1,115200 ethaddr=30:46:90 [0.00] PID hash table entries: 256 (order: -2, 1024 bytes) [0.00] Dentry cache hash table entries: 8192 (order: 3, 32768 bytes) [0.00] Inode-cache hash table entries: 4096 (order: 2, 16384 bytes) [0.00] Writing ErrCtl register=5880 [0.00] Readback ErrCtl register=5880 [0.00] Memory: 60404K/65536K available (3312K kernel code, 147K rwdata, 664K rodata, 144K init, 194K bss, 5132K reserved) [0.00] NR_IRQS:256 [0.00] CPU Clock: 333MHz [0.00] Calibrating delay loop... 221.18 BogoMIPS (lpj=442368) [0.036000] pid_max: default: 32768 minimum: 301 [0.04] Mount-cache hash table entries: 1024 (order: 0, 4096 bytes) [0.044000] Mountpoint-cache hash table entries: 1024 (order: 0, 4096 bytes) [0.052000] pinctrl core: initialized pinctrl subsystem [0.056000] NET: Registered protocol family 16 [0.064000] pinctrl-xway 1e100b10.pinmux: Init done [0.068000] dma-xway 1e104100.dma: Init done - hw rev: 6, ports: 5, channels: 20 [0.076000] PCI host bridge /fpi@1000/pci@E105400 ranges: [0.08] MEM 0x1800..0x19ff [0.084000] IO 0x1ae0..0x1aff [0.088000] ath9k,eeprom ath9k_eep: failed to load eeprom address [0.10] usbcore: registered new interface driver usbfs [0.104000] usbcore: registered new interface driver hub [0.108000] usbcore: registered new device driver usb [0.112000] PCI host bridge to bus :00 [0.116000] pci_bus :00: root bus resource [mem 0x1800-0x19ff] [0.12] pci_bus :00: root bus resource [io 0x] [0.124000] pci_bus :00: No busn resource found for root bus, will use [bus 00-ff] [0.128000] pci :00:0e.0: BAR 0: assigned [mem 0x1800-0x1800] [0.132000] Switched to clocksource MIPS [0.136000] NET: Registered protocol family 2 [0.144000] TCP established hash table entries: 1024 (order: 0, 4096 bytes) [0.148000] TCP bind hash table entries: 1024 (order: 0, 4096 bytes) [0.156000] TCP: Hash tables configured (established 1024 bind 1024) [0.164000] TCP: reno registered [0.164000] UDP hash table entries: 256 (order: 0, 4096 bytes) [0.172000] UDP-Lite hash table entries: 256 (order: 0, 4096 bytes) [0.18] NET: Registered protocol family 1 [0.184000] gptu: totally 6 16-bit timers/counters [0.188000] gptu: misc_register on minor 63 [0.192000] gptu: succeeded to request irq 126 [0.196000] gptu: succeeded to request irq 127 [0.20] gptu: succeeded to request irq 128 [0.204000] gptu: succeeded to request irq 129 [0.212000] gptu: succeeded to request irq 130 [0.216000] gptu: succeeded to request irq 131 [0.22] futex hash table entries: 256 (order: -1, 3072 bytes) [0.228000] squashfs: version 4.0 (2009/01/31) Phillip Lougher [0.236000] jffs2: version 2.2 (NAND) (SUMMARY) (LZMA) (RTIME) (CMODE_PRIORITY) (c) 2001-2006 Red Hat, Inc. [0.248000] msgmni has been set to 117 [0.252000] io scheduler noop registered [0.256000] io scheduler deadline registered (default) [0.26] 1e100c00.serial: ttyLTQ0 at MMIO 0x1e100c00 (irq = 112, base_baud = 0) is a lantiq,asc [0.268000] console [ttyLTQ0] enabled [0.268000] console [ttyLTQ0] enabled [0.276000] bootconsole [early0] disabled [0.276000] bootconsole [early0] disabled [0.332000] Realtek RTL8366RB ethernet switch
[OpenWrt-Devel] [PATCH 4/4] lantiq: DGN3500 cleanups
This patch builds on the previous three to streamline support for the Netgear DGN3500. Signed-off-by: Daniel Gimpelevich dan...@gimpelevich.san-francisco.ca.us --- a/target/linux/lantiq/base-files/etc/uci-defaults/02_network (revision 44023) +++ b/target/linux/lantiq/base-files/etc/uci-defaults/02_network (working copy) @@ -120,8 +120,6 @@ ;; DGN3500*) - lan_mac=$(mtd_get_mac_ascii uboot-env ethaddr) - wan_mac=$(macaddr_add $lan_mac 1) ucidef_set_interface_lan eth0.1 ucidef_add_switch switch0 1 1 ucidef_add_switch_vlan switch0 1 3 2 1 0 5t --- a/target/linux/lantiq/dts/DGN3500.dtsi (revision 44023) +++ b/target/linux/lantiq/dts/DGN3500.dtsi (working copy) @@ -2,7 +2,7 @@ / { chosen { - bootargs = console=ttyLTQ0,115200 init=/etc/preinit; + bootargs-append = root=/dev/mtdblock5 console=ttyLTQ0,115200; }; memory@0 { ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
[OpenWrt-Devel] [PATCH 1/4] lantiq: Fix initscript issue
Currently this initscript fails if the macaddr has any leading zeroes. This patch corrects the problem. Signed-off-by: Daniel Gimpelevich dan...@gimpelevich.san-francisco.ca.us --- a/target/linux/lantiq/base-files/etc/init.d/esi (revision 44023) +++ b/target/linux/lantiq/base-files/etc/init.d/esi (working copy) @@ -3,5 +3,5 @@ START=19 start() { - esi $(printf '%X' $((1+0x$(tr -d : /sys/class/net/eth0/address 2/dev/null || : + esi $(printf '%012X' $((1+0x$(tr -d : /sys/class/net/eth0/address 2/dev/console || : } ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
[OpenWrt-Devel] [PATCH 3/4] lantiq: Restore call to orphaned etop function
It seems the call to ltq_get_eth_mac() disappeared at some point. This patch puts it where it currently most makes sense. Signed-off-by: Daniel Gimpelevich dan...@gimpelevich.san-francisco.ca.us --- a/target/linux/lantiq/patches-3.14/0035-owrt-lantiq-wifi-and-ethernet-eeprom-handling.patch (revision 44023) +++ b/target/linux/lantiq/patches-3.14/0035-owrt-lantiq-wifi-and-ethernet-eeprom-handling.patch (working copy) @@ -19,8 +19,10 @@ create mode 100644 arch/mips/lantiq/xway/pci-ath-fixup.c create mode 100644 arch/mips/lantiq/xway/rt_eep.c /dev/null -+++ b/arch/mips/include/asm/mach-lantiq/pci-ath-fixup.h +Index: linux-3.14.28/arch/mips/include/asm/mach-lantiq/pci-ath-fixup.h +=== +--- /dev/null 1970-01-01 00:00:00.0 + linux-3.14.28/arch/mips/include/asm/mach-lantiq/pci-ath-fixup.h 2015-01-17 10:55:03.329443942 -0800 @@ -0,0 +1,6 @@ +#ifndef _PCI_ATH_FIXUP +#define _PCI_ATH_FIXUP @@ -28,9 +30,11 @@ +void ltq_pci_ath_fixup(unsigned slot, u16 *cal_data) __init; + +#endif /* _PCI_ATH_FIXUP */ a/arch/mips/include/asm/mach-lantiq/xway/lantiq_soc.h -+++ b/arch/mips/include/asm/mach-lantiq/xway/lantiq_soc.h -@@ -90,5 +90,8 @@ int xrx200_gphy_boot(struct device *dev, +Index: linux-3.14.28/arch/mips/include/asm/mach-lantiq/xway/lantiq_soc.h +=== +--- linux-3.14.28.orig/arch/mips/include/asm/mach-lantiq/xway/lantiq_soc.h 2015-01-17 10:55:03.337443971 -0800 linux-3.14.28/arch/mips/include/asm/mach-lantiq/xway/lantiq_soc.h 2015-01-17 10:55:03.329443942 -0800 +@@ -90,5 +90,8 @@ extern void ltq_pmu_enable(unsigned int module); extern void ltq_pmu_disable(unsigned int module); @@ -39,9 +43,11 @@ + #endif /* CONFIG_SOC_TYPE_XWAY */ #endif /* _LTQ_XWAY_H__ */ a/arch/mips/lantiq/xway/Makefile -+++ b/arch/mips/lantiq/xway/Makefile -@@ -2,4 +2,7 @@ obj-y := prom.o sysctrl.o clk.o reset.o +Index: linux-3.14.28/arch/mips/lantiq/xway/Makefile +=== +--- linux-3.14.28.orig/arch/mips/lantiq/xway/Makefile 2015-01-17 10:55:03.337443971 -0800 linux-3.14.28/arch/mips/lantiq/xway/Makefile 2015-01-17 11:58:16.0 -0800 +@@ -2,4 +2,7 @@ obj-y += vmmc.o tffs.o @@ -49,8 +55,10 @@ +obj-$(CONFIG_PCI) += ath_eep.o rt_eep.o pci-ath-fixup.o + obj-$(CONFIG_XRX200_PHY_FW) += xrx200_phy_fw.o /dev/null -+++ b/arch/mips/lantiq/xway/ath_eep.c +Index: linux-3.14.28/arch/mips/lantiq/xway/ath_eep.c +=== +--- /dev/null 1970-01-01 00:00:00.0 + linux-3.14.28/arch/mips/lantiq/xway/ath_eep.c 2015-01-17 10:55:03.329443942 -0800 @@ -0,0 +1,282 @@ +/* + * Copyright (C) 2011 Luca Olivetti l...@ventoso.org @@ -334,8 +342,10 @@ + return platform_driver_probe(ath5k_eeprom_driver, of_ath5k_eeprom_probe); +} +device_initcall(of_ath5k_eeprom_init); /dev/null -+++ b/arch/mips/lantiq/xway/eth_mac.c +Index: linux-3.14.28/arch/mips/lantiq/xway/eth_mac.c +=== +--- /dev/null 1970-01-01 00:00:00.0 + linux-3.14.28/arch/mips/lantiq/xway/eth_mac.c 2015-01-17 11:14:42.823292726 -0800 @@ -0,0 +1,76 @@ +/* + * Copyright (C) 2012 John Crispin blo...@openwrt.org @@ -413,8 +423,10 @@ + return platform_driver_probe(eth_mac_driver, of_eth_mac_probe); +} +device_initcall(of_eth_mac_init); /dev/null -+++ b/arch/mips/lantiq/xway/pci-ath-fixup.c +Index: linux-3.14.28/arch/mips/lantiq/xway/pci-ath-fixup.c +=== +--- /dev/null 1970-01-01 00:00:00.0 + linux-3.14.28/arch/mips/lantiq/xway/pci-ath-fixup.c2015-01-17 10:55:03.329443942 -0800 @@ -0,0 +1,109 @@ +/* + * Atheros AP94 reference board PCI initialization @@ -525,8 +537,10 @@ + ath_fixups[ath_num_fixups].cal_data = cal_data; + ath_num_fixups++; +} /dev/null -+++ b/arch/mips/lantiq/xway/rt_eep.c +Index: linux-3.14.28/arch/mips/lantiq/xway/rt_eep.c +=== +--- /dev/null 1970-01-01 00:00:00.0 + linux-3.14.28/arch/mips/lantiq/xway/rt_eep.c 2015-01-17 10:55:03.329443942 -0800 @@ -0,0 +1,60 @@ +/* + * Copyright (C) 2011 John Crispin blo...@openwrt.org @@ -588,3 +602,17 @@ + return platform_driver_probe(ralink_eeprom_driver, of_ralink_eeprom_probe); +} +device_initcall(of_ralink_eeprom_init); +Index: linux-3.14.28/drivers/net/ethernet/lantiq_etop.c +=== +--- linux-3.14.28.orig/drivers/net/ethernet/lantiq_etop.c 2015-01-17 11:52:03.818405214 -0800 linux-3.14.28/drivers/net/ethernet/lantiq_etop.c 2015-01-17 12:02:20.905465188 -0800 +@@ -843,6 +843,9
Re: [OpenWrt-Devel] [PATCH 00/17] atheros: checkpatch fixes
On Tue, 2014-06-24 at 13:51 -0700, Florian Fainelli wrote: 2014-06-24 13:30 GMT-07:00 Daniel Gimpelevich dan...@gimpelevich.san-francisco.ca.us: On Tue, 2014-06-24 at 12:38 -0700, Florian Fainelli wrote: I think AR231x has none of those, it's an End of Life platform, the code base has been mostly static and well know for a while, so I would argue that Device Tree should not be made a requirement here as it will just delay Sergey's upstreaming effort even more. Very valuable input. Still, there is no way for software to determine which AR231x board it's running on, and they all have different uses of GPIO, plus the AR2317 watchdog operates completely differently from the AR2315 one. What solution do you propose? Some earlier discussion: http://patchwork.openwrt.org/patch/4351/ For GPIOs, since the way they are used most likely varies on a per-board basis, we could probably come up with the same mechanism as used on ath79 where we end-up patching the kernel command-line to insert a MIPS machine id for instance. For the watchdog driver, if we have access to a revision register we can read at runtime, then we could use a separate platform driver name (e.g: ar2315-wdt vs ar2317-wdt) that would lead to either two separate drivers to get registered, or have different code-paths being used in the same ar231x driver. In case we do not have that revision register, we can leverage solution 1) for GPIOs. Wait, what is this ath79 target? ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] [PATCH 00/17] atheros: checkpatch fixes
This is much appreciated, but what is really needed for upstream merge is converting the target to device tree usage. On Tue, 2014-06-10 at 04:29 +0400, Sergey Ryazanov wrote: This series is an attempt to cleanup checkpatch generated warnings and errors to make AR231x patches suitable for upstream merge. Sergey Ryazanov (17): atheros: avoid CamelCase atheros: various comments fixes atheros: parenthesis around complex macroses value atheros: remove parentheses around return values atheros: do not assignment in if condition atheros: remove trailing whitespace atheros: do not initialize statics to 0 or false atheros: various braces fixes atheros: various printk(...) fixes atheros: fix includes atheros: indent fixes atheros: spaces fixes atheros: trailing statements fixes atheros: avoid __FUNCTION__ usage atheros: constify some static structures atheros: shorten lines atheros: fix too short msleep target/linux/atheros/patches-3.10/100-board.patch | 864 +++-- .../patches-3.10/101-early-printk-support.patch| 8 +- .../atheros/patches-3.10/105-ar2315_pci.patch | 64 +- .../atheros/patches-3.10/110-ar2313_ethernet.patch | 369 - .../linux/atheros/patches-3.10/120-spiflash.patch | 68 +- .../linux/atheros/patches-3.10/130-watchdog.patch | 85 +- .../patches-3.10/140-redboot_boardconfig.patch | 14 +- .../patches-3.10/141-redboot_partition_scan.patch | 4 +- .../142-redboot_various_erase_size_fix.patch | 12 +- .../atheros/patches-3.10/210-reset_button.patch| 4 +- .../patches-3.10/220-enet_micrel_workaround.patch | 28 +- .../atheros/patches-3.10/230-3_10-updates.patch| 10 +- 12 files changed, 781 insertions(+), 749 deletions(-) ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] [PATCH 00/17] atheros: checkpatch fixes
On Tue, 2014-06-24 at 12:38 -0700, Florian Fainelli wrote: I think AR231x has none of those, it's an End of Life platform, the code base has been mostly static and well know for a while, so I would argue that Device Tree should not be made a requirement here as it will just delay Sergey's upstreaming effort even more. Very valuable input. Still, there is no way for software to determine which AR231x board it's running on, and they all have different uses of GPIO, plus the AR2317 watchdog operates completely differently from the AR2315 one. What solution do you propose? Some earlier discussion: http://patchwork.openwrt.org/patch/4351/ ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] [PATCH 00/17] atheros: checkpatch fixes
On Tue, 2014-06-24 at 13:51 -0700, Florian Fainelli wrote: For the watchdog driver, if we have access to a revision register we can read at runtime, then we could use a separate platform driver name (e.g: ar2315-wdt vs ar2317-wdt) that would lead to either two separate drivers to get registered, or have different code-paths being used in the same ar231x driver. In case we do not have that revision register, we can leverage solution 1) for GPIOs. AFAIK, at least as far as RedBoot goes, that's determined at compile time. ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] [PATCH 00/17] atheros: checkpatch fixes
On Tue, 2014-06-24 at 15:33 -0700, Florian Fainelli wrote: I think, if the differences we have to abstract for are (hopefully) limited to GPIOs and the watchdog driver differences, we can have a small data-base in the kernel, nobdoy should hopefully yell at you for doing that. If we are talking about a few dozen regulators, SPI, i2c peripherals, that's another story, and DT could be one way to get that done in a generic way. If we could catalogue all known AR231x devices, we could have a reference to see whether any might use regulators, SPI, or I2C. If we find none, we'll just need to build a separate image for each device that will each have its own board ID to refer to, which can sort out the GPIO differences and tell the watchdog driver which protocol to use. ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] [PATCH] lantiq: fix ath9k eeprom loading once and for all
On Sun, 2013-11-17 at 18:52 +0100, John Crispin wrote: Hi, rather than fix up the patches, could you send a patch that sits on top of the existing ones that i can fold myself please ? John OK, here is a theoretical file that would sit in target/linux/lantiq/patches-3.10, minus the whitespace fix, which really should be made in the existing patch, otherwise quilt complains. --- a/arch/mips/lantiq/xway/ath_eep.c +++ b/arch/mips/lantiq/xway/ath_eep.c @@ -36,6 +36,7 @@ return 0; } +static int ath9k_eep_load; int __init of_ath9k_eeprom_probe(struct platform_device *pdev) { struct device_node *np = pdev-dev.of_node, *mtd_np; @@ -112,6 +113,12 @@ if (!of_property_read_u32(np, ath,pci-slot, pci_slot)) { ltq_pci_ath_fixup(pci_slot, ath9k_pdata.eeprom_data); dev_info(pdev-dev, pci slot: %u\n, pci_slot); + if (ath9k_eep_load) { + struct pci_dev *d = NULL; + while ((d = pci_get_device(PCI_VENDOR_ID_ATHEROS, + PCI_ANY_ID, d)) != NULL) + pci_fixup_device(pci_fixup_early, d); + } } dev_info(pdev-dev, loaded ath9k eeprom\n); @@ -132,20 +139,19 @@ }, }; -static int ath9k_eep_loaded; static int __init of_ath9k_eeprom_init(void) { int ret = platform_driver_probe(ath9k_eeprom_driver, of_ath9k_eeprom_probe); - if (!ret) - ath9k_eep_loaded = 1; + if (ret) + ath9k_eep_load = 1; return ret; } static int __init of_ath9k_eeprom_init_late(void) { - if (ath9k_eep_loaded) + if (!ath9k_eep_load) return 0; return platform_driver_probe(ath9k_eeprom_driver, of_ath9k_eeprom_probe); } @@ -247,4 +253,4 @@ { return platform_driver_probe(ath5k_eeprom_driver, of_ath5k_eeprom_probe); } -device_initcall(of_ath5k_eeprom_init); +subsys_initcall(of_ath5k_eeprom_init); ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
[OpenWrt-Devel] [PATCH] atheros: /etc/diag.sh for FON2201
In Backfire, the power LED worked normally on the Fonera+, but in Barrier Breaker, it's unused. I can't seem to find a way to differentiate among hardware in the atheros target, so I'm submitting a FIXME patch to be further patched with info from other devices. Signed-off-by: Daniel Gimpelevich dan...@gimpelevich.san-francisco.ca.us --- /dev/null 2013-11-09 12:36:28.330833697 -0800 +++ b/target/linux/atheros/base-files/etc/diag.sh 2013-11-10 07:34:45.372612754 -0800 @@ -0,0 +1,27 @@ +#!/bin/sh +# Copyright (C) 2013 OpenWrt.org + +. /lib/functions/leds.sh + +set_state() { + status_led=gpio4 + + [ -d /sys/class/leds/gpio4/ ] + [ -d /sys/class/leds/gpio7/ ] { + + case $1 in + preinit) + led_timer gpio7 200 200 + status_led_off + ;; + failsafe) + status_led_blink_failsafe + led_off gpio7 + ;; + done) + status_led_on + led_off gpio7 + ;; + esac + } +} ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] [PATCH 1/2] mtd_get_mac_ascii bugfix
On Fri, 2013-11-08 at 13:24 +0100, Gabor Juhos wrote: 2013.11.08. 13:20 keltezéssel, Gabor Juhos írta: 2013.11.07. 17:23 keltezéssel, Daniel Gimpelevich írta: The mtd_get_mac_ascii utility function was broken. This fixes it. Signed-off-by: Daniel Gimpelevich dan...@gimpelevich.san-francisco.ca.us Applied. Thanks, Gabor You changed it from using printf to using tr, which might not be good if colons are missing. ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
[OpenWrt-Devel] [PATCH 1/2] mtd_get_mac_ascii bugfix
The mtd_get_mac_ascii utility function was broken. This fixes it. Signed-off-by: Daniel Gimpelevich dan...@gimpelevich.san-francisco.ca.us Index: package/base-files/files/lib/functions.sh === --- a/package/base-files/files/lib/functions.sh (revision 38679) +++ b/package/base-files/files/lib/functions.sh (working copy) @@ -248,15 +248,13 @@ local part local mac_dirty - . /lib/functions.sh - part=$(find_mtd_part $mtdname) if [ -z $part ]; then echo mtd_get_mac_ascii: partition $mtdname not found! 2 return fi - mac_dirty=$(strings $part | sed -n 's/'$key'=//p') + mac_dirty=$(strings $part | sed -n 's/^'$key'=//p') # canonicalize mac printf %02x:%02x:%02x:%02x:%02x:%02x 0x${mac_dirty//:/ 0x} } ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
[OpenWrt-Devel] [PATCH 2/2] lantiq: DGN3500 fixups
Just fixing up a few things for the Netgear DGN3500. Signed-off-by: Daniel Gimpelevich dan...@gimpelevich.san-francisco.ca.us Index: target/linux/lantiq/dts/DGN3500.dtsi === --- a/target/linux/lantiq/dts/DGN3500.dtsi (revision 38679) +++ b/target/linux/lantiq/dts/DGN3500.dtsi (working copy) @@ -2,7 +2,7 @@ / { chosen { - bootargs-append = console=ttyLTQ0,115200 init=/etc/preinit; + bootargs = console=ttyLTQ0,115200 init=/etc/preinit; }; memory@0 { Index: target/linux/lantiq/base-files/etc/uci-defaults/02_network === --- a/target/linux/lantiq/base-files/etc/uci-defaults/02_network (revision 38679) +++ b/target/linux/lantiq/base-files/etc/uci-defaults/02_network (working copy) @@ -78,6 +78,8 @@ ;; DGN3500*) + lan_mac=$(mtd_get_mac_ascii uboot-env ethaddr) + wan_mac=$(macaddr_add $lan_mac 1) ucidef_set_interface_lan eth0.1 ucidef_add_switch switch0 1 1 ucidef_add_switch_vlan switch0 1 3 2 1 0 5t ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
[OpenWrt-Devel] [PATCH] Fix arch-dependent bug in hso module
I've also submitted this upstream. Without it, the module causes an oops on rt5350. Signed-off-by: Daniel Gimpelevich dan...@gimpelevich.san-francisco.ca.us --- .../patches-3.10/005-hso-stack-clobber-fix.patch | 56 .../patches-3.3/005-hso-stack-clobber-fix.patch| 56 .../patches-3.6/005-hso-stack-clobber-fix.patch| 56 .../patches-3.8/005-hso-stack-clobber-fix.patch| 56 .../patches-3.9/005-hso-stack-clobber-fix.patch| 56 5 files changed, 280 insertions(+) create mode 100644 target/linux/generic/patches-3.10/005-hso-stack-clobber-fix.patch create mode 100644 target/linux/generic/patches-3.3/005-hso-stack-clobber-fix.patch create mode 100644 target/linux/generic/patches-3.6/005-hso-stack-clobber-fix.patch create mode 100644 target/linux/generic/patches-3.8/005-hso-stack-clobber-fix.patch create mode 100644 target/linux/generic/patches-3.9/005-hso-stack-clobber-fix.patch diff --git a/target/linux/generic/patches-3.10/005-hso-stack-clobber-fix.patch b/target/linux/generic/patches-3.10/005-hso-stack-clobber-fix.patch new file mode 100644 index 000..3e0e7c1 --- /dev/null +++ b/target/linux/generic/patches-3.10/005-hso-stack-clobber-fix.patch @@ -0,0 +1,56 @@ +diff --git a/drivers/net/usb/hso.c b/drivers/net/usb/hso.c +index cba1d46..86292e6 100644 +--- a/drivers/net/usb/hso.c b/drivers/net/usb/hso.c +@@ -2816,13 +2816,16 @@ exit: + static int hso_get_config_data(struct usb_interface *interface) + { + struct usb_device *usbdev = interface_to_usbdev(interface); +- u8 config_data[17]; ++ u8 *config_data = kmalloc(17, GFP_KERNEL); + u32 if_num = interface-altsetting-desc.bInterfaceNumber; + s32 result; + ++ if (!config_data) ++ return -ENOMEM; + if (usb_control_msg(usbdev, usb_rcvctrlpipe(usbdev, 0), + 0x86, 0xC0, 0, 0, config_data, 17, + USB_CTRL_SET_TIMEOUT) != 0x11) { ++ kfree(config_data); + return -EIO; + } + +@@ -2873,6 +2876,7 @@ static int hso_get_config_data(struct usb_interface *interface) + if (config_data[16] 0x1) + result |= HSO_INFO_CRC_BUG; + ++ kfree(config_data); + return result; + } + +@@ -2886,6 +2890,11 @@ static int hso_probe(struct usb_interface *interface, + struct hso_shared_int *shared_int; + struct hso_device *tmp_dev = NULL; + ++ if (interface-cur_altsetting-desc.bInterfaceClass != 0xFF) { ++ dev_err(interface-dev, Not our interface\n); ++ return -ENODEV; ++ } ++ + if_num = interface-altsetting-desc.bInterfaceNumber; + + /* Get the interface/port specification from either driver_info or from +@@ -2895,10 +2904,6 @@ static int hso_probe(struct usb_interface *interface, + else + port_spec = hso_get_config_data(interface); + +- if (interface-cur_altsetting-desc.bInterfaceClass != 0xFF) { +- dev_err(interface-dev, Not our interface\n); +- return -ENODEV; +- } + /* Check if we need to switch to alt interfaces prior to port +* configuration */ + if (interface-num_altsetting 1) +-- +1.7.9.5 + diff --git a/target/linux/generic/patches-3.3/005-hso-stack-clobber-fix.patch b/target/linux/generic/patches-3.3/005-hso-stack-clobber-fix.patch new file mode 100644 index 000..3e0e7c1 --- /dev/null +++ b/target/linux/generic/patches-3.3/005-hso-stack-clobber-fix.patch @@ -0,0 +1,56 @@ +diff --git a/drivers/net/usb/hso.c b/drivers/net/usb/hso.c +index cba1d46..86292e6 100644 +--- a/drivers/net/usb/hso.c b/drivers/net/usb/hso.c +@@ -2816,13 +2816,16 @@ exit: + static int hso_get_config_data(struct usb_interface *interface) + { + struct usb_device *usbdev = interface_to_usbdev(interface); +- u8 config_data[17]; ++ u8 *config_data = kmalloc(17, GFP_KERNEL); + u32 if_num = interface-altsetting-desc.bInterfaceNumber; + s32 result; + ++ if (!config_data) ++ return -ENOMEM; + if (usb_control_msg(usbdev, usb_rcvctrlpipe(usbdev, 0), + 0x86, 0xC0, 0, 0, config_data, 17, + USB_CTRL_SET_TIMEOUT) != 0x11) { ++ kfree(config_data); + return -EIO; + } + +@@ -2873,6 +2876,7 @@ static int hso_get_config_data(struct usb_interface *interface) + if (config_data[16] 0x1) + result |= HSO_INFO_CRC_BUG; + ++ kfree(config_data); + return result; + } + +@@ -2886,6 +2890,11 @@ static int hso_probe(struct usb_interface *interface, + struct hso_shared_int *shared_int; + struct hso_device *tmp_dev = NULL; + ++ if (interface-cur_altsetting-desc.bInterfaceClass != 0xFF) { ++ dev_err(interface-dev, Not our interface\n); ++ return -ENODEV
Re: [OpenWrt-Devel] [PATCH] Fix arch-dependent bug in hso module
On Tue, 2013-08-20 at 01:30 +0200, Luka Perkov wrote: Hi Daniel, Please update your patches with better commit message. It should also contain links to the mailing list and/or patchwork where the patch was sent (if possible of course). Also, patches inside generic should have very detailed description. This is not the case for many patches at the moment but I plan to work on this in the (near) future. Take a look at the links bellow for an example: https://dev.openwrt.org/changeset/37808 https://dev.openwrt.org/browser/trunk/target/linux/generic/patches-3.10/470-mtd_m25p80_add_pm25_flash_support.patch Luka This could actually be taken straight from my upstream submission: https://patchwork.kernel.org/patch/2846700/ ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] [PATCH] Fix arch-dependent bug in hso module
On Tue, 2013-08-20 at 02:30 +0200, Luka Perkov wrote: Or you could resend the patch. Luka I think I'll see what upstream does before I do that. ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] [PATCH] Initial support for AirLive AIR3GII
On Thu, 2012-11-22 at 15:08 +0100, Cezary Jackiewicz wrote: AirLive AIR3GII is Ralink RT5350F based device with 100Mbps switch, USB port, 4MB flash and 32MB ram. Works: ethernet (LAN WAN), wps button, led, USB, sysupgrade Does not work: wifi (chip RT5350), reset button [ 13.39] phy0 - rt2800_init_eeprom: Error - Invalid RT chipset 0x5350 detected. [ 13.40] phy0 - rt2x00lib_probe_dev: Error - Failed to allocate device. Other problem: LAN leds is reverse (lights when not cable connected and vice versa) I saw TL-MR3020 on this page, so I ordered it: http://www.rakuten.com/pr/product.aspx?sku=245965249 That turned out to be a misnomer. It's actually this device: http://www.newegg.com/Product/Product.aspx?Item=9SIA0U00H07470 Functionally, the hardware seems similar to the Air3GII, but I would like confirmation from someone who has one of those. This device has a red LED, a green LED, and a blue LED. When running an OpenWrt build for Air3GII, airlive:green:mobile (GPIO 9) is the blue LED and rt2800pci-phy0::radio is the red LED. The green one comes on when Ethernet is unplugged, and off when plugged back in. I can find no programmatic way to control it. The reset button is GPIO 10. GPIO's 7 and 8 do not appear to have any function. There is a toggle switch labeled 3G and DHCP on the outside, but I have so far not found a way to detect its position programmatically. It has no other buttons, LED's, or switches. Can you please build current trunk for your device and tell me how it differs? Thanks. ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] [PATCHv2 5/8][lantiq] set ATM ESI
I hate being a pest, but this should be added into the record: [Wed 2013-05-29 01:32:07 AM PDT] blogic dape: will need to look into the esi thing [Wed 2013-05-29 01:32:16 AM PDT] blogic the rest looks ok now ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] [PATCH v2][lantiq] Add support for loading athxk eeproms through mtd
On Sat, 2013-06-15 at 18:07 +0200, Álvaro Fernández Rojas wrote: This patch enables retrieving the wifi calibration data from an MTD partition. Try to copy mac address from ethernet before generating a random one. This fixes DGN3500 ath9k support. It should be ath,eep-endian; and not ath,endian; there. ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] [PATCH][lantiq] Add support for loading athxk eeproms through mtd
On Thu, 2013-06-13 at 19:18 +0200, Álvaro Fernández Rojas wrote: This patch enables retrieving the wifi calibration data from an MTD partition. Try to copy mac address from ethernet before generating a random one. This fixes DGN3500 ath9k support. You forgot the correction to target/linux/lantiq/dts/DGN3500.dtsi ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] free Linksys E3200
On Tue, 2013-06-11 at 11:00 -0700, Warren Turkal wrote: Hey openwrt devs, I clearly have no time to mess with the the E3200 I have. I have modded the thing to have a rs232 db9 port. I'd like to offer it for free to anyone that wants to work on OpenWRT on this device. Any takers? wt I'm not familiar with that model. How much RAM and flash, and which target? Any special features, e.g. USB? ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] free Linksys E3200
On Tue, 2013-06-11 at 20:52 +0200, Rafał Miłecki wrote: 2013/6/11 Daniel Gimpelevich dan...@gimpelevich.san-francisco.ca.us: On Tue, 2013-06-11 at 11:00 -0700, Warren Turkal wrote: Hey openwrt devs, I clearly have no time to mess with the the E3200 I have. I have modded the thing to have a rs232 db9 port. I'd like to offer it for free to anyone that wants to work on OpenWRT on this device. Any takers? wt I'm not familiar with that model. How much RAM and flash, and which target? Any special features, e.g. USB? Have you tried something called Google? http://wiki.openwrt.org/toh/linksys/e3200 http://wikidevi.com/wiki/Linksys_E3200 Looks like a nice update of the WRT350Nv1 I've been meaning to get back to. Pity about the wifi. Wifi was the big issue with the WRT350Nv1 last I tried. I figure I should try it again first to see how trunk or at least AA will function with its 32MB RAM. If it's too tight now, I might be interested, but I no longer have a car, so you'd have to drop it off in that case. I'd strongly prefer one of the TP-Link models Felix has been working on instead, though. I might just order one of those if it comes to that; we'll see within the next few weeks. ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] [PATCH][lantiq] Fixes to athxk EEPROM loading
On Tue, 2013-06-04 at 13:39 +0200, Álvaro Fernández Rojas wrote: Hello John, the patch doesn't fix the DGN3500 eeprom loading, but it's an outstanding fix we need to make. I think it's better if we fix what we currently have first and then add Daniel's patches. Regards, Álvaro I already have an updated patch on top of your set waiting, but I am out of town at the moment and cannot test it until after my return on Sunday. If your device works properly with your patchset, I think it's safe to commit for now, and when I can test what I have, I can submit that. ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] [PATCH][lantiq] Fixes to athxk EEPROM loading
On Mon, 2013-06-03 at 19:54 +0200, Álvaro Fernández Rojas wrote: Use platform data array for storing ath5k EEPROM instead of creating another one. EEPROM size is 2048 words (2 bytes), so we must read 4096 bytes from flash. No need to keep the checksum fix now that the EEPROM is loaded completely. Add a manual eeprom swap for ath9k and keep the endian way. Use mac-offset property retrieved from the DTS. The lantiq target is now on the 3.8 kernel, so I see no need to patch the patches-3.7 directory. Also, another reminder of the backlog: http://patchwork.openwrt.org/project/openwrt/list/?submitter=235 ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/mailman/listinfo/openwrt-devel
[OpenWrt-Devel] Pending lantiq patches
Seems these got forgotten: http://patchwork.openwrt.org/project/openwrt/list/?submitter=235 ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/mailman/listinfo/openwrt-devel
[OpenWrt-Devel] [PATCHv2 1/8][lantiq] make kernel_oldconfig
Seems the existing kernel config for 3.8 was cp'ed from 3.7; this patch is the result of make kernel_oldconfig with defaults for new options. Signed-off-by: Daniel Gimpelevich dan...@gimpelevich.san-francisco.ca.us Index: target/linux/lantiq/config-default === --- a/target/linux/lantiq/config-default(revision 36739) +++ b/target/linux/lantiq/config-default(working copy) @@ -8,7 +8,6 @@ CONFIG_ARCH_SUSPEND_POSSIBLE=y CONFIG_ARCH_WANT_IPC_PARSE_VERSION=y CONFIG_CEVT_R4K=y -CONFIG_CEVT_R4K_LIB=y CONFIG_CLKDEV_LOOKUP=y CONFIG_CPU_BIG_ENDIAN=y CONFIG_CPU_GENERIC_DUMP_TLB=y @@ -23,7 +22,6 @@ CONFIG_CPU_SUPPORTS_32BIT_KERNEL=y CONFIG_CPU_SUPPORTS_HIGHMEM=y CONFIG_CSRC_R4K=y -CONFIG_CSRC_R4K_LIB=y # CONFIG_DEBUG_PINCTRL is not set CONFIG_DECOMPRESS_LZMA=y CONFIG_DMA_NONCOHERENT=y @@ -50,6 +48,7 @@ CONFIG_HAS_IOPORT=y CONFIG_HAVE_ARCH_JUMP_LABEL=y CONFIG_HAVE_ARCH_KGDB=y +CONFIG_HAVE_ARCH_TRANSPARENT_HUGEPAGE=y CONFIG_HAVE_CLK=y CONFIG_HAVE_C_RECORDMCOUNT=y CONFIG_HAVE_DEBUG_KMEMLEAK=y @@ -68,6 +67,7 @@ CONFIG_HAVE_MEMBLOCK=y CONFIG_HAVE_MEMBLOCK_NODE_MAP=y CONFIG_HAVE_MOD_ARCH_SPECIFIC=y +CONFIG_HAVE_NET_DSA=y CONFIG_HAVE_OPROFILE=y CONFIG_HAVE_PERF_EVENTS=y CONFIG_HW_HAS_PCI=y @@ -75,7 +75,6 @@ CONFIG_HZ=250 # CONFIG_HZ_100 is not set CONFIG_HZ_250=y -# CONFIG_I2C_MUX_PINCTRL is not set CONFIG_INITRAMFS_SOURCE= CONFIG_IRQ_CPU=y CONFIG_IRQ_DOMAIN=y @@ -86,8 +85,11 @@ CONFIG_LANTIQ_WDT=y CONFIG_LANTIQ_XRX200=y CONFIG_LEDS_GPIO=y +# CONFIG_LZO_COMPRESS is not set +# CONFIG_LZO_DECOMPRESS is not set CONFIG_MDIO_BOARDINFO=y CONFIG_MIPS=y +# CONFIG_MIPS_HUGE_TLB_SUPPORT is not set CONFIG_MIPS_L1_CACHE_SHIFT=5 # CONFIG_MIPS_MACHINE is not set CONFIG_MIPS_MT_DISABLED=y @@ -122,13 +124,12 @@ # CONFIG_PCIE_LANTIQ is not set CONFIG_PCI_DOMAINS=y CONFIG_PCI_LANTIQ=y +CONFIG_PERCPU_RWSEM=y CONFIG_PERF_USE_VMALLOC=y CONFIG_PHYLIB=y CONFIG_PINCONF=y CONFIG_PINCTRL=y -# CONFIG_PINCTRL_EXYNOS4 is not set CONFIG_PINCTRL_LANTIQ=y -# CONFIG_PINCTRL_SAMSUNG is not set # CONFIG_PINCTRL_SINGLE is not set CONFIG_PINCTRL_XWAY=y CONFIG_PINMUX=y @@ -142,7 +143,6 @@ CONFIG_SERIAL_LANTIQ=y # CONFIG_SOC_AMAZON_SE is not set # CONFIG_SOC_FALCON is not set -# CONFIG_SOC_SVIP is not set CONFIG_SOC_TYPE_XWAY=y CONFIG_SOC_XWAY=y CONFIG_SWAP_IO_SPACE=y ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/mailman/listinfo/openwrt-devel
[OpenWrt-Devel] [PATCHv2 2/8][lantiq] fix 3.8 kernel config for DEU support
Trying to load the DEU modules results in unresolved symbols. This provides them. This requires the previous patch to be applied first. Signed-off-by: Daniel Gimpelevich dan...@gimpelevich.san-francisco.ca.us --- a/target/linux/lantiq/config-default2013-05-28 02:46:04.156620670 -0700 +++ b/target/linux/lantiq/config-default2013-05-28 02:40:48.595055885 -0700 @@ -21,6 +21,8 @@ CONFIG_CPU_R4K_FPU=y CONFIG_CPU_SUPPORTS_32BIT_KERNEL=y CONFIG_CPU_SUPPORTS_HIGHMEM=y +CONFIG_CRYPTO_HASH=y +CONFIG_CRYPTO_HASH2=y CONFIG_CSRC_R4K=y # CONFIG_DEBUG_PINCTRL is not set CONFIG_DECOMPRESS_LZMA=y ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/mailman/listinfo/openwrt-devel
[OpenWrt-Devel] [PATCHv2 3/8][lantiq] fix LED-handling oversights
An attempt is made to use ucidef_set_led_usbdev without the required kernel config option, provided here, and the PPPoE status is reassigned to the LED that was intended to indicate it, rather than the DSL sync light. Signed-off-by: Daniel Gimpelevich dan...@gimpelevich.san-francisco.ca.us Index: target/linux/lantiq/xway/config-default === --- a/target/linux/lantiq/xway/config-default (revision 36739) +++ b/target/linux/lantiq/xway/config-default (working copy) @@ -6,6 +6,7 @@ CONFIG_INPUT_POLLDEV=y # CONFIG_ISDN is not set CONFIG_LEDS_TRIGGER_HEARTBEAT=y +CONFIG_LEDS_TRIGGER_USBDEV=y CONFIG_M25PXX_USE_FAST_READ=y CONFIG_MTD_M25P80=y CONFIG_MTD_NAND=y Index: target/linux/lantiq/base-files/etc/uci-defaults/01_leds === --- a/target/linux/lantiq/base-files/etc/uci-defaults/01_leds (revision 36739) +++ b/target/linux/lantiq/base-files/etc/uci-defaults/01_leds (working copy) @@ -9,7 +9,7 @@ [ -e /sys/class/leds/wifi ] ucidef_set_led_wlan wifi wifi wifi phy0tpt [ -e /sys/class/leds/usb ] ucidef_set_led_usbdev usb usb usb 1-1 -[ -e /sys/class/leds/dsl ] ucidef_set_led_netdev dsl dsl dsl pppoe-wan +[ -e /sys/class/leds/internet ]ucidef_set_led_netdev internet internet internet pppoe-wan for a in `ls /sys/class/leds/`; do grep -q \[none\] /sys/class/leds/$a/trigger ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/mailman/listinfo/openwrt-devel
[OpenWrt-Devel] [PATCHv2 5/8][lantiq] set ATM ESI
This patch sets the ESI properly for the Lantiq ATM driver so that things like DHCP over RFC1483 will work correctly. Signed-off-by: Daniel Gimpelevich dan...@gimpelevich.san-francisco.ca.us Index: target/linux/lantiq/ase/target.mk === --- a/target/linux/lantiq/ase/target.mk (revision 36739) +++ b/target/linux/lantiq/ase/target.mk (working copy) @@ -3,7 +3,7 @@ BOARDNAME:=Amazon-SE FEATURES:=squashfs jffs2 atm -DEFAULT_PACKAGES+=kmod-pppoa ppp-mod-pppoa linux-atm atm-tools br2684ctl kmod-ltq-dsl-ase ltq-dsl-app +DEFAULT_PACKAGES+=kmod-pppoa ppp-mod-pppoa linux-atm atm-esi atm-tools br2684ctl kmod-ltq-dsl-ase ltq-dsl-app define Target/Description Lantiq ASE Index: target/linux/lantiq/xway/target.mk === --- a/target/linux/lantiq/xway/target.mk(revision 36739) +++ b/target/linux/lantiq/xway/target.mk(working copy) @@ -3,7 +3,7 @@ BOARDNAME:=XWAY FEATURES:=squashfs jffs2 atm -DEFAULT_PACKAGES+=kmod-leds-gpio kmod-gpio-button-hotplug +DEFAULT_PACKAGES+=kmod-leds-gpio kmod-gpio-button-hotplug linux-atm atm-esi define Target/Description Lantiq XWAY Index: target/linux/lantiq/base-files/etc/init.d/esi === --- a/target/linux/lantiq/base-files/etc/init.d/esi (revision 0) +++ b/target/linux/lantiq/base-files/etc/init.d/esi (revision 0) @@ -0,0 +1,7 @@ +#!/bin/sh /etc/rc.common +# Copyright (C) 2013 OpenWrt.org + +START=19 +start() { + esi $(printf '%X' $((1+0x$(tr -d : /sys/class/net/eth0/address 2/dev/null || : +} Property changes on: target/linux/lantiq/base-files/etc/init.d/esi ___ Added: svn:executable + * ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/mailman/listinfo/openwrt-devel
[OpenWrt-Devel] [PATCHv2 4/8][lantiq] diag.sh with both red and green power LEDs
This provides a boot LED sequence suitable for devices with both red and green LEDs for power. This assumes no default-on settings in the device tree. Signed-off-by: Daniel Gimpelevich dan...@gimpelevich.san-francisco.ca.us Index: target/linux/lantiq/base-files/etc/diag.sh === --- a/target/linux/lantiq/base-files/etc/diag.sh(revision 36739) +++ b/target/linux/lantiq/base-files/etc/diag.sh(working copy) @@ -6,6 +6,26 @@ status_led=power set_state() { + [ -d /sys/class/leds/power2/ ] { + + case $1 in + preinit) + led_set_attr power2 trigger heartbeat + ;; + init) + status_led_on + ;; + failsafe) + led_off power2 + status_led_set_timer 100 100 + ;; + done) + led_off power2 + ;; + esac + return + } + case $1 in preinit) status_led_set_heartbeat ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/mailman/listinfo/openwrt-devel
[OpenWrt-Devel] [PATCHv2 6/8][lantiq] wifi calibration from flash
This patch enables retrieving the wifi calibration data from a flash partition. Signed-off-by: Daniel Gimpelevich dan...@gimpelevich.san-francisco.ca.us Index: target/linux/lantiq/patches-3.8/0037-owrt-lantiq-wifi-and-ethernet-eeprom-handling.patch === --- a/target/linux/lantiq/patches-3.8/0037-owrt-lantiq-wifi-and-ethernet-eeprom-handling.patch (revision 36739) +++ b/target/linux/lantiq/patches-3.8/0037-owrt-lantiq-wifi-and-ethernet-eeprom-handling.patch (working copy) @@ -50,7 +50,7 @@ obj-$(CONFIG_XRX200_PHY_FW) += xrx200_phy_fw.o --- /dev/null +++ b/arch/mips/lantiq/xway/ath_eep.c -@@ -0,0 +1,206 @@ +@@ -0,0 +1,246 @@ +/* + * Copyright (C) 2011 Luca Olivetti l...@ventoso.org + * Copyright (C) 2011 John Crispin blo...@openwrt.org @@ -69,7 +69,10 @@ +#include linux/ath5k_platform.h +#include linux/ath9k_platform.h +#include linux/pci.h ++#include linux/err.h ++#include linux/mtd/mtd.h +#include pci-ath-fixup.h ++#include lantiq_soc.h + +extern int (*ltq_pci_plat_dev_init)(struct pci_dev *dev); +struct ath5k_platform_data ath5k_pdata; @@ -88,32 +91,50 @@ +int __init of_ath9k_eeprom_probe(struct platform_device *pdev) +{ + struct device_node *np = pdev-dev.of_node; -+ struct resource *eep_res, *mac_res; ++ struct resource *eep_res, *mac_res = NULL; + void __iomem *eep, *mac; + int mac_offset; -+ u32 mac_inc = 0, pci_slot = 0; ++ u32 mac_inc = 0, pci_slot = 0, mtd_addr[2]; + int i; + u16 *eepdata, sum, el; ++ struct mtd_info *the_mtd; ++ size_t flash_readlen; + -+ eep_res = platform_get_resource(pdev, IORESOURCE_MEM, 0); -+ mac_res = platform_get_resource(pdev, IORESOURCE_MEM, 1); ++ if (of_property_read_u32_array(np, ath,eep-flash, mtd_addr, 2) == 0 ++ (the_mtd = get_mtd_device(NULL, mtd_addr[0])) ++ != ERR_PTR(-ENODEV)) { ++ i = mtd_read(the_mtd, mtd_addr[1], ++ sizeof(ath9k_pdata.eeprom_data), flash_readlen, ++ (void *) ath9k_pdata.eeprom_data); ++ put_mtd_device(the_mtd); ++ if ((sizeof(ath9k_pdata.eeprom_data) != flash_readlen) || i) { ++ dev_err(pdev-dev, failed to load eeprom from mtd\n); ++ return -ENODEV; ++ } ++ } else { ++ eep_res = platform_get_resource(pdev, IORESOURCE_MEM, 0); ++ mac_res = platform_get_resource(pdev, IORESOURCE_MEM, 1); + -+ if (!eep_res) { -+ dev_err(pdev-dev, failed to load eeprom address\n); -+ return -ENODEV; ++ if (!eep_res) { ++ dev_err(pdev-dev, failed to load eeprom address\n); ++ return -ENODEV; ++ } ++ if (resource_size(eep_res) != ATH9K_PLAT_EEP_MAX_WORDS) { ++ dev_err(pdev-dev, eeprom has an invalid size\n); ++ return -EINVAL; ++ } ++ ++ eep = ioremap(eep_res-start, resource_size(eep_res)); ++ memcpy_fromio(ath9k_pdata.eeprom_data, eep, ++ ATH9K_PLAT_EEP_MAX_WORDS); + } -+ if (resource_size(eep_res) != ATH9K_PLAT_EEP_MAX_WORDS) { -+ dev_err(pdev-dev, eeprom has an invalid size\n); -+ return -EINVAL; -+ } + -+ eep = ioremap(eep_res-start, resource_size(eep_res)); -+ memcpy_fromio(ath9k_pdata.eeprom_data, eep, ATH9K_PLAT_EEP_MAX_WORDS); -+ + if (of_find_property(np, ath,eep-swap, NULL)) { + ath9k_pdata.endian_check = true; -+ + dev_info(pdev-dev, endian check enabled.\n); ++ for (i = 0; i ATH9K_PLAT_EEP_MAX_WORDS; i++) ++ ath9k_pdata.eeprom_data[i] = ++ swab16(ath9k_pdata.eeprom_data[i]); + } + + if (of_find_property(np, ath,eep-csum, NULL)) { @@ -137,7 +158,9 @@ + } + mac = ioremap(mac_res-start, resource_size(mac_res)); + memcpy_fromio(athxk_eeprom_mac, mac, 6); -+ } else { ++ } else if (ltq_get_eth_mac()) ++ memcpy(athxk_eeprom_mac, ltq_get_eth_mac(), 6); ++ else { + dev_warn(pdev-dev, using random mac\n); + random_ether_addr(athxk_eeprom_mac); + } @@ -176,7 +199,7 @@ +{ + return platform_driver_probe(ath9k_eeprom_driver, of_ath9k_eeprom_probe); +} -+arch_initcall(of_ath9k_eeprom_init); ++late_initcall(of_ath9k_eeprom_init); + + +static int ath5k_pci_plat_dev_init(struct pci_dev *dev) @@ -188,30 +211,45 @@ +int __init of_ath5k_eeprom_probe(struct platform_device *pdev) +{ + struct device_node *np = pdev-dev.of_node; -+ struct resource *eep_res, *mac_res; ++ struct resource *eep_res, *mac_res = NULL; + void __iomem *eep, *mac; + int
[OpenWrt-Devel] [PATCHv2 7/8][lantiq] enable retrieving kernel args from bootloader
This patch is a device tree enhancement that IMHO is worthy of mainline. It could even go into target/linux/generic here, but for the moment, I am putting it under the lantiq target. Signed-off-by: Daniel Gimpelevich dan...@gimpelevich.san-francisco.ca.us Index: target/linux/lantiq/patches-3.8/0304-MIPS-cmdline.patch === --- a/target/linux/lantiq/patches-3.8/0304-MIPS-cmdline.patch (revision 0) +++ b/target/linux/lantiq/patches-3.8/0304-MIPS-cmdline.patch (revision 0) @@ -0,0 +1,12 @@ +--- a/drivers/of/fdt.c b/drivers/of/fdt.c +@@ -677,6 +677,9 @@ int __init early_init_dt_scan_chosen(uns + p = of_get_flat_dt_prop(node, bootargs, l); + if (p != NULL l 0) + strlcpy(data, p, min((int)l, COMMAND_LINE_SIZE)); ++ p = of_get_flat_dt_prop(node, bootargs-append, l); ++ if (p != NULL l 0) ++ strlcat(data, p, min(strlen(data) + (int)l, COMMAND_LINE_SIZE)); + + /* +* CONFIG_CMDLINE is meant to be a default in case nothing else ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/mailman/listinfo/openwrt-devel
[OpenWrt-Devel] [PATCHv2 8/8][lantiq] DGN3500 support
This requires all the preceding patches and finishes support for the DGN3500, also removing an obsolete file. Signed-off-by: Daniel Gimpelevich dan...@gimpelevich.san-francisco.ca.us Index: target/linux/lantiq/base-files/lib/preinit/42_athfix === --- a/target/linux/lantiq/base-files/lib/preinit/42_athfix (revision 36739) +++ b/target/linux/lantiq/base-files/lib/preinit/42_athfix (working copy) @@ -1,19 +0,0 @@ -#!/bin/sh - -. /lib/functions/lantiq.sh - -init_atheeprom() { - local board=$(lantiq_board_name) - case $board in - Netgear DGN3500B) - echo - loading eeprom - - dd if=/dev/mtd2 of=/sys/firmware/ath_eeprom bs=1k skip=60 count=4 - echo 0 /sys/bus/pci/slots/\:00\:0e.0/power - sleep 1 - echo 1 /sys/bus/pci/rescan - ;; - esac -} - -boot_hook_add preinit_essential init_atheeprom - Index: target/linux/lantiq/base-files/etc/uci-defaults/02_network === --- a/target/linux/lantiq/base-files/etc/uci-defaults/02_network (revision 36739) +++ b/target/linux/lantiq/base-files/etc/uci-defaults/02_network (working copy) @@ -72,6 +72,11 @@ VG3503J) ucidef_set_interface_lan 'eth0 eth1' ;; +DGN3500*) + ucidef_set_interface_lan eth0.1 + ucidef_add_switch switch0 1 1 + ucidef_add_switch_vlan switch0 1 3 2 1 0 5t + ;; esac [ -z $(ls /lib/modules/`uname -r`/ltq_atm*) ] || set_atm_wan $vpi $vci $encaps $payload Index: target/linux/lantiq/dts/DGN3500.dtsi === --- a/target/linux/lantiq/dts/DGN3500.dtsi (revision 36739) +++ b/target/linux/lantiq/dts/DGN3500.dtsi (working copy) @@ -2,7 +2,7 @@ / { chosen { - bootargs = console=ttyLTQ0,115200 init=/etc/preinit; + bootargs-append = console=ttyLTQ0,115200 init=/etc/preinit; }; memory@0 { @@ -112,6 +112,13 @@ }; }; + ath9k_eep { + compatible = ath9k,eeprom; + ath,eep-flash = 2 0xf000; + ath,pci-slot = 14; + ath,eep-swap; + }; + rtl8366rb { compatible = rtl8366rb; gpio-sda = gpio 35 0; @@ -144,7 +151,7 @@ gpio-leds { compatible = gpio-leds; internet { - label = inernet; + label = internet; gpios = gpio 2 1; }; dsl { @@ -158,7 +165,6 @@ power { label = power; gpios = gpio 34 1; - default-state = on; }; power2 { label = power2; ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] [PATCHv2 5/8][lantiq] set ATM ESI
On Tue, 2013-05-28 at 14:21 +0200, John Crispin wrote: esi is not a default package really. you are the first user in 6 years that needs it. make it a board specific option. i dont mind it being default for dgn3500 but other arv baords with 4mb flash dont need to ship this. It should be board specific to any board capable of RFC1483, which is why I put it in the subtargets capable of that; Florian separated the package out of a metapackage precisely for the purpose of making it trivial enough in size to include anywhere. this should be in the esi package and not the target folder This script is not a part of the esi utility; it's part of the ATM initialization. I will resubmit the rest of the patches, but so far I remain unconvinced that this one is incorrect, yet I am open to suggestions. ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/mailman/listinfo/openwrt-devel
[OpenWrt-Devel] [PATCHv3 1/5][lantiq] fix LED-handling oversights
This reassigns the PPPoE status to the LED that was intended to indicate it, rather than the DSL sync light. Signed-off-by: Daniel Gimpelevich dan...@gimpelevich.san-francisco.ca.us Index: target/linux/lantiq/base-files/etc/uci-defaults/01_leds === --- a/target/linux/lantiq/base-files/etc/uci-defaults/01_leds (revision 36749) +++ b/target/linux/lantiq/base-files/etc/uci-defaults/01_leds (working copy) @@ -9,7 +9,7 @@ [ -e /sys/class/leds/wifi ] ucidef_set_led_wlan wifi wifi wifi phy0tpt [ -e /sys/class/leds/usb ] ucidef_set_led_usbdev usb usb usb 1-1 -[ -e /sys/class/leds/dsl ] ucidef_set_led_netdev dsl dsl dsl pppoe-wan +[ -e /sys/class/leds/internet ]ucidef_set_led_netdev internet internet internet pppoe-wan for a in `ls /sys/class/leds/`; do grep -q \[none\] /sys/class/leds/$a/trigger ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/mailman/listinfo/openwrt-devel
[OpenWrt-Devel] [PATCHv3 4/5][lantiq] enable retrieving kernel args from bootloader
This patch is a device tree enhancement that IMHO is worthy of mainline. It allows the bootloader's commandline to be preserved even when the device tree specifies one. Signed-off-by: Daniel Gimpelevich dan...@gimpelevich.san-francisco.ca.us Index: target/linux/generic/patches-3.10/997-device_tree_cmdline.patch === --- a/target/linux/generic/patches-3.10/997-device_tree_cmdline.patch (revision 0) +++ b/target/linux/generic/patches-3.10/997-device_tree_cmdline.patch (revision 0) @@ -0,0 +1,12 @@ +--- a/drivers/of/fdt.c b/drivers/of/fdt.c +@@ -677,6 +677,9 @@ int __init early_init_dt_scan_chosen(uns + p = of_get_flat_dt_prop(node, bootargs, l); + if (p != NULL l 0) + strlcpy(data, p, min((int)l, COMMAND_LINE_SIZE)); ++ p = of_get_flat_dt_prop(node, bootargs-append, l); ++ if (p != NULL l 0) ++ strlcat(data, p, min(strlen(data) + (int)l, COMMAND_LINE_SIZE)); + + /* +* CONFIG_CMDLINE is meant to be a default in case nothing else Index: target/linux/generic/patches-3.8/997-device_tree_cmdline.patch === --- a/target/linux/generic/patches-3.8/997-device_tree_cmdline.patch (revision 0) +++ b/target/linux/generic/patches-3.8/997-device_tree_cmdline.patch (revision 0) @@ -0,0 +1,12 @@ +--- a/drivers/of/fdt.c b/drivers/of/fdt.c +@@ -677,6 +677,9 @@ int __init early_init_dt_scan_chosen(uns + p = of_get_flat_dt_prop(node, bootargs, l); + if (p != NULL l 0) + strlcpy(data, p, min((int)l, COMMAND_LINE_SIZE)); ++ p = of_get_flat_dt_prop(node, bootargs-append, l); ++ if (p != NULL l 0) ++ strlcat(data, p, min(strlen(data) + (int)l, COMMAND_LINE_SIZE)); + + /* +* CONFIG_CMDLINE is meant to be a default in case nothing else Index: target/linux/generic/patches-3.9/997-device_tree_cmdline.patch === --- a/target/linux/generic/patches-3.9/997-device_tree_cmdline.patch (revision 0) +++ b/target/linux/generic/patches-3.9/997-device_tree_cmdline.patch (revision 0) @@ -0,0 +1,12 @@ +--- a/drivers/of/fdt.c b/drivers/of/fdt.c +@@ -677,6 +677,9 @@ int __init early_init_dt_scan_chosen(uns + p = of_get_flat_dt_prop(node, bootargs, l); + if (p != NULL l 0) + strlcpy(data, p, min((int)l, COMMAND_LINE_SIZE)); ++ p = of_get_flat_dt_prop(node, bootargs-append, l); ++ if (p != NULL l 0) ++ strlcat(data, p, min(strlen(data) + (int)l, COMMAND_LINE_SIZE)); + + /* +* CONFIG_CMDLINE is meant to be a default in case nothing else ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/mailman/listinfo/openwrt-devel
[OpenWrt-Devel] [PATCHv3 3/5][lantiq] wifi calibration from MTD
This patch enables retrieving the wifi calibration data from an MTD partition. It requires the previous patch. Signed-off-by: Daniel Gimpelevich dan...@gimpelevich.san-francisco.ca.us --- a/target/linux/lantiq/patches-3.8/0037-owrt-lantiq-wifi-and-ethernet-eeprom-handling.patch 2013-05-28 13:41:59.558775919 -0700 +++ b/target/linux/lantiq/patches-3.8/0037-owrt-lantiq-wifi-and-ethernet-eeprom-handling.patch 2013-05-28 13:35:39.484891230 -0700 @@ -50,7 +50,7 @@ obj-$(CONFIG_XRX200_PHY_FW) += xrx200_phy_fw.o --- /dev/null +++ b/arch/mips/lantiq/xway/ath_eep.c -@@ -0,0 +1,206 @@ +@@ -0,0 +1,258 @@ +/* + * Copyright (C) 2011 Luca Olivetti l...@ventoso.org + * Copyright (C) 2011 John Crispin blo...@openwrt.org @@ -69,7 +69,10 @@ +#include linux/ath5k_platform.h +#include linux/ath9k_platform.h +#include linux/pci.h ++#include linux/err.h ++#include linux/mtd/mtd.h +#include pci-ath-fixup.h ++#include lantiq_soc.h + +extern int (*ltq_pci_plat_dev_init)(struct pci_dev *dev); +struct ath5k_platform_data ath5k_pdata; @@ -87,33 +90,57 @@ + +int __init of_ath9k_eeprom_probe(struct platform_device *pdev) +{ -+ struct device_node *np = pdev-dev.of_node; -+ struct resource *eep_res, *mac_res; ++ struct device_node *np = pdev-dev.of_node, *mtd_np; ++ struct resource *eep_res, *mac_res = NULL; + void __iomem *eep, *mac; + int mac_offset; + u32 mac_inc = 0, pci_slot = 0; + int i; + u16 *eepdata, sum, el; ++ struct mtd_info *the_mtd; ++ size_t flash_readlen; ++ const __be32 *list; ++ const char *part; ++ phandle phandle; ++ ++ if ((list = of_get_property(np, ath,eep-flash, i)) i == 2 * ++ sizeof(*list) (phandle = be32_to_cpup(list++)) ++ (mtd_np = of_find_node_by_phandle(phandle)) ((part = ++ of_get_property(mtd_np, label, NULL)) || (part = ++ mtd_np-name)) (the_mtd = get_mtd_device_nm(part)) ++ != ERR_PTR(-ENODEV)) { ++ i = mtd_read(the_mtd, be32_to_cpup(list), ++ sizeof(ath9k_pdata.eeprom_data), flash_readlen, ++ (void *) ath9k_pdata.eeprom_data); ++ put_mtd_device(the_mtd); ++ if ((sizeof(ath9k_pdata.eeprom_data) != flash_readlen) || i) { ++ dev_err(pdev-dev, failed to load eeprom from mtd\n); ++ return -ENODEV; ++ } ++ } else { ++ eep_res = platform_get_resource(pdev, IORESOURCE_MEM, 0); ++ mac_res = platform_get_resource(pdev, IORESOURCE_MEM, 1); + -+ eep_res = platform_get_resource(pdev, IORESOURCE_MEM, 0); -+ mac_res = platform_get_resource(pdev, IORESOURCE_MEM, 1); ++ if (!eep_res) { ++ dev_err(pdev-dev, failed to load eeprom address\n); ++ return -ENODEV; ++ } ++ if (resource_size(eep_res) != ATH9K_PLAT_EEP_MAX_WORDS) { ++ dev_err(pdev-dev, eeprom has an invalid size\n); ++ return -EINVAL; ++ } + -+ if (!eep_res) { -+ dev_err(pdev-dev, failed to load eeprom address\n); -+ return -ENODEV; -+ } -+ if (resource_size(eep_res) != ATH9K_PLAT_EEP_MAX_WORDS) { -+ dev_err(pdev-dev, eeprom has an invalid size\n); -+ return -EINVAL; ++ eep = ioremap(eep_res-start, resource_size(eep_res)); ++ memcpy_fromio(ath9k_pdata.eeprom_data, eep, ++ ATH9K_PLAT_EEP_MAX_WORDS); + } + -+ eep = ioremap(eep_res-start, resource_size(eep_res)); -+ memcpy_fromio(ath9k_pdata.eeprom_data, eep, ATH9K_PLAT_EEP_MAX_WORDS); -+ + if (of_find_property(np, ath,eep-swap, NULL)) { + ath9k_pdata.endian_check = true; -+ + dev_info(pdev-dev, endian check enabled.\n); ++ for (i = 0; i ATH9K_PLAT_EEP_MAX_WORDS; i++) ++ ath9k_pdata.eeprom_data[i] = ++ swab16(ath9k_pdata.eeprom_data[i]); + } + + if (of_find_property(np, ath,eep-csum, NULL)) { @@ -137,7 +164,9 @@ + } + mac = ioremap(mac_res-start, resource_size(mac_res)); + memcpy_fromio(athxk_eeprom_mac, mac, 6); -+ } else { ++ } else if (ltq_get_eth_mac()) ++ memcpy(athxk_eeprom_mac, ltq_get_eth_mac(), 6); ++ else { + dev_warn(pdev-dev, using random mac\n); + random_ether_addr(athxk_eeprom_mac); + } @@ -187,31 +216,52 @@ + +int __init of_ath5k_eeprom_probe(struct platform_device *pdev) +{ -+ struct device_node *np = pdev-dev.of_node; -+ struct resource *eep_res, *mac_res; ++ struct device_node *np = pdev-dev.of_node, *mtd_np; ++ struct resource *eep_res, *mac_res = NULL; + void __iomem *eep
[OpenWrt-Devel] [PATCH 1/5][lantiq] Please make sure this doesn't break other hardware
This first patch fixes unresolved kernel symbols when including the DEU modules. Signed-off-by: Daniel Gimpelevich dan...@gimpelevich.san-francisco.ca.us Index: target/linux/lantiq/config-default === --- target/linux/lantiq/config-default (revision 36698) +++ target/linux/lantiq/config-default (working copy) @@ -8,7 +8,6 @@ CONFIG_ARCH_SUSPEND_POSSIBLE=y CONFIG_ARCH_WANT_IPC_PARSE_VERSION=y CONFIG_CEVT_R4K=y -CONFIG_CEVT_R4K_LIB=y CONFIG_CLKDEV_LOOKUP=y CONFIG_CPU_BIG_ENDIAN=y CONFIG_CPU_GENERIC_DUMP_TLB=y @@ -22,8 +21,9 @@ CONFIG_CPU_R4K_FPU=y CONFIG_CPU_SUPPORTS_32BIT_KERNEL=y CONFIG_CPU_SUPPORTS_HIGHMEM=y +CONFIG_CRYPTO_HASH=y +CONFIG_CRYPTO_HASH2=y CONFIG_CSRC_R4K=y -CONFIG_CSRC_R4K_LIB=y # CONFIG_DEBUG_PINCTRL is not set CONFIG_DECOMPRESS_LZMA=y CONFIG_DMA_NONCOHERENT=y @@ -50,6 +50,7 @@ CONFIG_HAS_IOPORT=y CONFIG_HAVE_ARCH_JUMP_LABEL=y CONFIG_HAVE_ARCH_KGDB=y +CONFIG_HAVE_ARCH_TRANSPARENT_HUGEPAGE=y CONFIG_HAVE_CLK=y CONFIG_HAVE_C_RECORDMCOUNT=y CONFIG_HAVE_DEBUG_KMEMLEAK=y @@ -68,6 +69,7 @@ CONFIG_HAVE_MEMBLOCK=y CONFIG_HAVE_MEMBLOCK_NODE_MAP=y CONFIG_HAVE_MOD_ARCH_SPECIFIC=y +CONFIG_HAVE_NET_DSA=y CONFIG_HAVE_OPROFILE=y CONFIG_HAVE_PERF_EVENTS=y CONFIG_HW_HAS_PCI=y @@ -75,7 +77,6 @@ CONFIG_HZ=250 # CONFIG_HZ_100 is not set CONFIG_HZ_250=y -# CONFIG_I2C_MUX_PINCTRL is not set CONFIG_INITRAMFS_SOURCE= CONFIG_IRQ_CPU=y CONFIG_IRQ_DOMAIN=y @@ -86,8 +87,11 @@ CONFIG_LANTIQ_WDT=y CONFIG_LANTIQ_XRX200=y CONFIG_LEDS_GPIO=y +# CONFIG_LZO_COMPRESS is not set +# CONFIG_LZO_DECOMPRESS is not set CONFIG_MDIO_BOARDINFO=y CONFIG_MIPS=y +# CONFIG_MIPS_HUGE_TLB_SUPPORT is not set CONFIG_MIPS_L1_CACHE_SHIFT=5 # CONFIG_MIPS_MACHINE is not set CONFIG_MIPS_MT_DISABLED=y @@ -122,13 +126,12 @@ # CONFIG_PCIE_LANTIQ is not set CONFIG_PCI_DOMAINS=y CONFIG_PCI_LANTIQ=y +CONFIG_PERCPU_RWSEM=y CONFIG_PERF_USE_VMALLOC=y CONFIG_PHYLIB=y CONFIG_PINCONF=y CONFIG_PINCTRL=y -# CONFIG_PINCTRL_EXYNOS4 is not set CONFIG_PINCTRL_LANTIQ=y -# CONFIG_PINCTRL_SAMSUNG is not set # CONFIG_PINCTRL_SINGLE is not set CONFIG_PINCTRL_XWAY=y CONFIG_PINMUX=y @@ -142,7 +145,6 @@ CONFIG_SERIAL_LANTIQ=y # CONFIG_SOC_AMAZON_SE is not set # CONFIG_SOC_FALCON is not set -# CONFIG_SOC_SVIP is not set CONFIG_SOC_TYPE_XWAY=y CONFIG_SOC_XWAY=y CONFIG_SWAP_IO_SPACE=y ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] [PATCH 0/5][lantiq] Please make sure this doesn't break other hardware
On Fri, 2013-05-24 at 15:17 +0200, John Crispin wrote: Hi, few comments * the patches are against the wrong base directory The patches are against trunk. Should they not be? * the descriptions are undescriptives Yes, I already know documentation is not a forte of mine. I tried my best. * please make sure that each patch only holds one change. a quick look told me, that they hold more John Patch #1 has only one change, from make kernel_menuconfig updated from the file simply copied from the 3.7 config. Patch #2 has one change in two files, and a closely related change in a third file. Patch #3 has a single change, applicable across three files. Patch #4 is the big one. It patches the 0037 patchfile in the patches-3.8 directory, containing many changes, but it's largely atomic because the 0037 patchfile itself contains many changes which, as I said in the description, would be more manageable if it were itself separated into multiple patchfiles. Patch #5 is relatively trivial altogether. ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] [PATCH 0/5][lantiq] Please make sure this doesn't break other hardware
On Fri, 2013-05-24 at 16:14 +0200, John Crispin wrote: * the patches are against the wrong base directory The patches are against trunk. Should they not be? its explained in the how to submit patches howto. The howto says these patches are against the correct base directory, so I don't know what you mean. ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/mailman/listinfo/openwrt-devel
[OpenWrt-Devel] [PATCH 0/5][lantiq] Please make sure this doesn't break other hardware
I have made the Netgear DGN3500 work as it should, but it required some changes that would affect other hardware. If anyone out there has Lantiq hardware supported in trunk, please try this patchset, in whole or in part, and report back what works and what breaks. I'm attaching the whole thing as a blob to this message, and splitting it into 5 patches in the following ones. Signed-off-by: Daniel Gimpelevich dan...@gimpelevich.san-francisco.ca.us Index: target/linux/lantiq/config-default === --- target/linux/lantiq/config-default (revision 36698) +++ target/linux/lantiq/config-default (working copy) @@ -8,7 +8,6 @@ CONFIG_ARCH_SUSPEND_POSSIBLE=y CONFIG_ARCH_WANT_IPC_PARSE_VERSION=y CONFIG_CEVT_R4K=y -CONFIG_CEVT_R4K_LIB=y CONFIG_CLKDEV_LOOKUP=y CONFIG_CPU_BIG_ENDIAN=y CONFIG_CPU_GENERIC_DUMP_TLB=y @@ -22,8 +21,9 @@ CONFIG_CPU_R4K_FPU=y CONFIG_CPU_SUPPORTS_32BIT_KERNEL=y CONFIG_CPU_SUPPORTS_HIGHMEM=y +CONFIG_CRYPTO_HASH=y +CONFIG_CRYPTO_HASH2=y CONFIG_CSRC_R4K=y -CONFIG_CSRC_R4K_LIB=y # CONFIG_DEBUG_PINCTRL is not set CONFIG_DECOMPRESS_LZMA=y CONFIG_DMA_NONCOHERENT=y @@ -50,6 +50,7 @@ CONFIG_HAS_IOPORT=y CONFIG_HAVE_ARCH_JUMP_LABEL=y CONFIG_HAVE_ARCH_KGDB=y +CONFIG_HAVE_ARCH_TRANSPARENT_HUGEPAGE=y CONFIG_HAVE_CLK=y CONFIG_HAVE_C_RECORDMCOUNT=y CONFIG_HAVE_DEBUG_KMEMLEAK=y @@ -68,6 +69,7 @@ CONFIG_HAVE_MEMBLOCK=y CONFIG_HAVE_MEMBLOCK_NODE_MAP=y CONFIG_HAVE_MOD_ARCH_SPECIFIC=y +CONFIG_HAVE_NET_DSA=y CONFIG_HAVE_OPROFILE=y CONFIG_HAVE_PERF_EVENTS=y CONFIG_HW_HAS_PCI=y @@ -75,7 +77,6 @@ CONFIG_HZ=250 # CONFIG_HZ_100 is not set CONFIG_HZ_250=y -# CONFIG_I2C_MUX_PINCTRL is not set CONFIG_INITRAMFS_SOURCE= CONFIG_IRQ_CPU=y CONFIG_IRQ_DOMAIN=y @@ -86,8 +87,11 @@ CONFIG_LANTIQ_WDT=y CONFIG_LANTIQ_XRX200=y CONFIG_LEDS_GPIO=y +# CONFIG_LZO_COMPRESS is not set +# CONFIG_LZO_DECOMPRESS is not set CONFIG_MDIO_BOARDINFO=y CONFIG_MIPS=y +# CONFIG_MIPS_HUGE_TLB_SUPPORT is not set CONFIG_MIPS_L1_CACHE_SHIFT=5 # CONFIG_MIPS_MACHINE is not set CONFIG_MIPS_MT_DISABLED=y @@ -122,13 +126,12 @@ # CONFIG_PCIE_LANTIQ is not set CONFIG_PCI_DOMAINS=y CONFIG_PCI_LANTIQ=y +CONFIG_PERCPU_RWSEM=y CONFIG_PERF_USE_VMALLOC=y CONFIG_PHYLIB=y CONFIG_PINCONF=y CONFIG_PINCTRL=y -# CONFIG_PINCTRL_EXYNOS4 is not set CONFIG_PINCTRL_LANTIQ=y -# CONFIG_PINCTRL_SAMSUNG is not set # CONFIG_PINCTRL_SINGLE is not set CONFIG_PINCTRL_XWAY=y CONFIG_PINMUX=y @@ -142,7 +145,6 @@ CONFIG_SERIAL_LANTIQ=y # CONFIG_SOC_AMAZON_SE is not set # CONFIG_SOC_FALCON is not set -# CONFIG_SOC_SVIP is not set CONFIG_SOC_TYPE_XWAY=y CONFIG_SOC_XWAY=y CONFIG_SWAP_IO_SPACE=y Index: target/linux/lantiq/xway/config-default === --- target/linux/lantiq/xway/config-default (revision 36698) +++ target/linux/lantiq/xway/config-default (working copy) @@ -6,6 +6,7 @@ CONFIG_INPUT_POLLDEV=y # CONFIG_ISDN is not set CONFIG_LEDS_TRIGGER_HEARTBEAT=y +CONFIG_LEDS_TRIGGER_USBDEV=y CONFIG_M25PXX_USE_FAST_READ=y CONFIG_MTD_M25P80=y CONFIG_MTD_NAND=y Index: target/linux/lantiq/xway/target.mk === --- target/linux/lantiq/xway/target.mk (revision 36698) +++ target/linux/lantiq/xway/target.mk (working copy) @@ -3,7 +3,7 @@ BOARDNAME:=XWAY FEATURES:=squashfs jffs2 atm -DEFAULT_PACKAGES+=kmod-leds-gpio kmod-gpio-button-hotplug +DEFAULT_PACKAGES+=kmod-leds-gpio kmod-gpio-button-hotplug linux-atm atm-esi define Target/Description Lantiq XWAY Index: target/linux/lantiq/dts/DGN3500.dtsi === --- target/linux/lantiq/dts/DGN3500.dtsi(revision 36698) +++ target/linux/lantiq/dts/DGN3500.dtsi(working copy) @@ -2,7 +2,7 @@ / { chosen { - bootargs = console=ttyLTQ0,115200 init=/etc/preinit; + bootargs-append = console=ttyLTQ0,115200 init=/etc/preinit; }; memory@0 { @@ -112,6 +112,13 @@ }; }; + ath9k_eep { + compatible = ath9k,eeprom; + ath,eep-flash = 2 0xf000; + ath,pci-slot = 14; + ath,eep-swap; + }; + rtl8366rb { compatible = rtl8366rb; gpio-sda = gpio 35 0; @@ -144,7 +151,7 @@ gpio-leds { compatible = gpio-leds; internet { - label = inernet; + label = internet; gpios = gpio 2 1; }; dsl { @@ -158,7 +165,6 @@ power { label = power; gpios = gpio 34 1; - default-state = on; }; power2 { label = power2; Index: target/linux/lantiq/patches-3.8/0304-MIPS-cmdline.patch
[OpenWrt-Devel] [PATCH 3/5][lantiq] Please make sure this doesn't break other hardware
This patch sets the ESI properly for the Lantiq ATM driver so that things like DHCP over RFC1483 will work correctly. Signed-off-by: Daniel Gimpelevich dan...@gimpelevich.san-francisco.ca.us Index: target/linux/lantiq/ase/target.mk === --- target/linux/lantiq/ase/target.mk (revision 36698) +++ target/linux/lantiq/ase/target.mk (working copy) @@ -3,7 +3,7 @@ BOARDNAME:=Amazon-SE FEATURES:=squashfs jffs2 atm -DEFAULT_PACKAGES+=kmod-pppoa ppp-mod-pppoa linux-atm atm-tools br2684ctl kmod-ltq-dsl-ase ltq-dsl-app +DEFAULT_PACKAGES+=kmod-pppoa ppp-mod-pppoa linux-atm atm-esi atm-tools br2684ctl kmod-ltq-dsl-ase ltq-dsl-app define Target/Description Lantiq ASE Index: target/linux/lantiq/xway/target.mk === --- target/linux/lantiq/xway/target.mk (revision 36698) +++ target/linux/lantiq/xway/target.mk (working copy) @@ -3,7 +3,7 @@ BOARDNAME:=XWAY FEATURES:=squashfs jffs2 atm -DEFAULT_PACKAGES+=kmod-leds-gpio kmod-gpio-button-hotplug +DEFAULT_PACKAGES+=kmod-leds-gpio kmod-gpio-button-hotplug linux-atm atm-esi define Target/Description Lantiq XWAY Index: target/linux/lantiq/base-files/etc/init.d/esi === --- target/linux/lantiq/base-files/etc/init.d/esi (revision 0) +++ target/linux/lantiq/base-files/etc/init.d/esi (revision 0) @@ -0,0 +1,7 @@ +#!/bin/sh /etc/rc.common +# Copyright (C) 2013 OpenWrt.org + +START=19 +start() { + esi $(printf '%X' $((1+0x$(tr -d : /sys/class/net/eth0/address 2/dev/null || : +} Property changes on: target/linux/lantiq/base-files/etc/init.d/esi ___ Added: svn:executable + * ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/mailman/listinfo/openwrt-devel
[OpenWrt-Devel] [PATCH 4/5][lantiq] Please make sure this doesn't break other hardware
This patch changes the kernel to make support of the DGN3500 possible and may enhance and/or break support for other devices. It's mostly changes to an existing platform patch, which itself really should be separated out. The remainder (in a separate file) is a device tree enhancement that IMHO is worthy of mainline. It could even go into target/linux/generic here, but for the moment, I am putting it under the lantiq target. Signed-off-by: Daniel Gimpelevich dan...@gimpelevich.san-francisco.ca.us Index: target/linux/lantiq/patches-3.8/0037-owrt-lantiq-wifi-and-ethernet-eeprom-handling.patch === --- target/linux/lantiq/patches-3.8/0037-owrt-lantiq-wifi-and-ethernet-eeprom-handling.patch (revision 36698) +++ target/linux/lantiq/patches-3.8/0037-owrt-lantiq-wifi-and-ethernet-eeprom-handling.patch (working copy) @@ -19,8 +19,10 @@ create mode 100644 arch/mips/lantiq/xway/pci-ath-fixup.c create mode 100644 arch/mips/lantiq/xway/rt_eep.c /dev/null -+++ b/arch/mips/include/asm/mach-lantiq/pci-ath-fixup.h +Index: linux-3.8.12/arch/mips/include/asm/mach-lantiq/pci-ath-fixup.h +=== +--- /dev/null 1970-01-01 00:00:00.0 + linux-3.8.12/arch/mips/include/asm/mach-lantiq/pci-ath-fixup.h 2013-05-23 19:40:28.323008317 -0700 @@ -0,0 +1,6 @@ +#ifndef _PCI_ATH_FIXUP +#define _PCI_ATH_FIXUP @@ -28,9 +30,11 @@ +void ltq_pci_ath_fixup(unsigned slot, u16 *cal_data) __init; + +#endif /* _PCI_ATH_FIXUP */ a/arch/mips/include/asm/mach-lantiq/xway/lantiq_soc.h -+++ b/arch/mips/include/asm/mach-lantiq/xway/lantiq_soc.h -@@ -90,5 +90,8 @@ int xrx200_gphy_boot(struct device *dev, +Index: linux-3.8.12/arch/mips/include/asm/mach-lantiq/xway/lantiq_soc.h +=== +--- linux-3.8.12.orig/arch/mips/include/asm/mach-lantiq/xway/lantiq_soc.h 2013-05-23 19:39:58.682861338 -0700 linux-3.8.12/arch/mips/include/asm/mach-lantiq/xway/lantiq_soc.h 2013-05-23 19:40:28.323008317 -0700 +@@ -90,5 +90,8 @@ extern void ltq_pmu_enable(unsigned int module); extern void ltq_pmu_disable(unsigned int module); @@ -39,8 +43,10 @@ + #endif /* CONFIG_SOC_TYPE_XWAY */ #endif /* _LTQ_XWAY_H__ */ a/arch/mips/lantiq/xway/Makefile -+++ b/arch/mips/lantiq/xway/Makefile +Index: linux-3.8.12/arch/mips/lantiq/xway/Makefile +=== +--- linux-3.8.12.orig/arch/mips/lantiq/xway/Makefile 2013-05-23 19:40:28.247007941 -0700 linux-3.8.12/arch/mips/lantiq/xway/Makefile2013-05-23 21:48:16.965035065 -0700 @@ -1,3 +1,6 @@ obj-y := prom.o sysctrl.o clk.o reset.o dma.o gptu.o dcdc.o @@ -48,9 +54,11 @@ +obj-$(CONFIG_PCI) += ath_eep.o rt_eep.o pci-ath-fixup.o + obj-$(CONFIG_XRX200_PHY_FW) += xrx200_phy_fw.o /dev/null -+++ b/arch/mips/lantiq/xway/ath_eep.c -@@ -0,0 +1,206 @@ +Index: linux-3.8.12/arch/mips/lantiq/xway/ath_eep.c +=== +--- /dev/null 1970-01-01 00:00:00.0 + linux-3.8.12/arch/mips/lantiq/xway/ath_eep.c 2013-05-23 21:38:32.758138144 -0700 +@@ -0,0 +1,246 @@ +/* + * Copyright (C) 2011 Luca Olivetti l...@ventoso.org + * Copyright (C) 2011 John Crispin blo...@openwrt.org @@ -69,7 +77,10 @@ +#include linux/ath5k_platform.h +#include linux/ath9k_platform.h +#include linux/pci.h ++#include linux/err.h ++#include linux/mtd/mtd.h +#include pci-ath-fixup.h ++#include lantiq_soc.h + +extern int (*ltq_pci_plat_dev_init)(struct pci_dev *dev); +struct ath5k_platform_data ath5k_pdata; @@ -88,32 +99,50 @@ +int __init of_ath9k_eeprom_probe(struct platform_device *pdev) +{ + struct device_node *np = pdev-dev.of_node; -+ struct resource *eep_res, *mac_res; ++ struct resource *eep_res, *mac_res = NULL; + void __iomem *eep, *mac; + int mac_offset; -+ u32 mac_inc = 0, pci_slot = 0; ++ u32 mac_inc = 0, pci_slot = 0, mtd_addr[2]; + int i; + u16 *eepdata, sum, el; ++ struct mtd_info *the_mtd; ++ size_t flash_readlen; + -+ eep_res = platform_get_resource(pdev, IORESOURCE_MEM, 0); -+ mac_res = platform_get_resource(pdev, IORESOURCE_MEM, 1); ++ if (of_property_read_u32_array(np, ath,eep-flash, mtd_addr, 2) == 0 ++ (the_mtd = get_mtd_device(NULL, mtd_addr[0])) ++ != ERR_PTR(-ENODEV)) { ++ i = mtd_read(the_mtd, mtd_addr[1], ++ sizeof(ath9k_pdata.eeprom_data), flash_readlen, ++ (void *) ath9k_pdata.eeprom_data); ++ put_mtd_device(the_mtd); ++ if ((sizeof(ath9k_pdata.eeprom_data) != flash_readlen) || i) { ++ dev_err(pdev-dev, failed to load eeprom from mtd\n); ++ return
[OpenWrt-Devel] [PATCH 2/5][lantiq] Please make sure this doesn't break other hardware
This second patch fixes the DSL sync light so that it's not tied to PPPoE, which is intended to be the Internet light. It also adds the kernel config option already used by the LED control in uci-defaults. Lastly, it provides a boot LED sequence suitable for devices with both red and green LEDs for power. Signed-off-by: Daniel Gimpelevich dan...@gimpelevich.san-francisco.ca.us Index: target/linux/lantiq/xway/config-default === --- target/linux/lantiq/xway/config-default (revision 36698) +++ target/linux/lantiq/xway/config-default (working copy) @@ -6,6 +6,7 @@ CONFIG_INPUT_POLLDEV=y # CONFIG_ISDN is not set CONFIG_LEDS_TRIGGER_HEARTBEAT=y +CONFIG_LEDS_TRIGGER_USBDEV=y CONFIG_M25PXX_USE_FAST_READ=y CONFIG_MTD_M25P80=y CONFIG_MTD_NAND=y Index: target/linux/lantiq/base-files/etc/uci-defaults/01_leds === --- target/linux/lantiq/base-files/etc/uci-defaults/01_leds (revision 36698) +++ target/linux/lantiq/base-files/etc/uci-defaults/01_leds (working copy) @@ -9,7 +9,7 @@ [ -e /sys/class/leds/wifi ] ucidef_set_led_wlan wifi wifi wifi phy0tpt [ -e /sys/class/leds/usb ] ucidef_set_led_usbdev usb usb usb 1-1 -[ -e /sys/class/leds/dsl ] ucidef_set_led_netdev dsl dsl dsl pppoe-wan +[ -e /sys/class/leds/internet ]ucidef_set_led_netdev internet internet internet pppoe-wan for a in `ls /sys/class/leds/`; do grep -q \[none\] /sys/class/leds/$a/trigger Index: target/linux/lantiq/base-files/etc/diag.sh === --- target/linux/lantiq/base-files/etc/diag.sh (revision 36698) +++ target/linux/lantiq/base-files/etc/diag.sh (working copy) @@ -6,6 +6,27 @@ status_led=power set_state() { + [ -d /sys/class/leds/power2/ ] { + + case $1 in + preinit) + led_set_attr power2 trigger heartbeat + ;; + init) + status_led_on + ;; + failsafe) + led_off power2 + status_led_set_timer 100 100 + ;; + done) + status_led_on + led_off power2 + ;; + esac + return + } + case $1 in preinit) status_led_set_heartbeat ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/mailman/listinfo/openwrt-devel
[OpenWrt-Devel] [PATCH 5/5][lantiq] Please make sure this doesn't break other hardware
Lastly, the patch that requires the previous ones to support the DGN3500. Signed-off-by: Daniel Gimpelevich dan...@gimpelevich.san-francisco.ca.us Index: target/linux/lantiq/dts/DGN3500.dtsi === --- target/linux/lantiq/dts/DGN3500.dtsi(revision 36698) +++ target/linux/lantiq/dts/DGN3500.dtsi(working copy) @@ -2,7 +2,7 @@ / { chosen { - bootargs = console=ttyLTQ0,115200 init=/etc/preinit; + bootargs-append = console=ttyLTQ0,115200 init=/etc/preinit; }; memory@0 { @@ -112,6 +112,13 @@ }; }; + ath9k_eep { + compatible = ath9k,eeprom; + ath,eep-flash = 2 0xf000; + ath,pci-slot = 14; + ath,eep-swap; + }; + rtl8366rb { compatible = rtl8366rb; gpio-sda = gpio 35 0; @@ -144,7 +151,7 @@ gpio-leds { compatible = gpio-leds; internet { - label = inernet; + label = internet; gpios = gpio 2 1; }; dsl { @@ -158,7 +165,6 @@ power { label = power; gpios = gpio 34 1; - default-state = on; }; power2 { label = power2; Index: target/linux/lantiq/base-files/etc/uci-defaults/02_network === --- target/linux/lantiq/base-files/etc/uci-defaults/02_network (revision 36698) +++ target/linux/lantiq/base-files/etc/uci-defaults/02_network (working copy) @@ -72,6 +72,11 @@ VG3503J) ucidef_set_interface_lan 'eth0 eth1' ;; +DGN3500*) + ucidef_set_interface_lan eth0.1 + ucidef_add_switch switch0 1 1 + ucidef_add_switch_vlan switch0 1 3 2 1 0 5t + ;; esac [ -z $(ls /lib/modules/`uname -r`/ltq_atm*) ] || set_atm_wan $vpi $vci $encaps $payload ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] [brcm63xx] Re: source code / disassembler / decompiler
On Thu, 2013-01-31 at 08:55 +0100, Bastian Bittorf wrote: * Daniel Gimpelevich dan...@gimpelevich.san-francisco.ca.us [31.01.2013 08:48]: I don't know whether this will be of much use. Florian, any hope of reusing the binary ADSL modules in 3.x? They're there as unversioned .o, back in the old days we just used disassemblers, now we even have tools which make c-code out of an .o - has anyone tried such tools to open the source? bye, bastian You mean the days before this? http://en.wikipedia.org/wiki/Bowers_v._Baystate_Technologies Any such effort to do this would need to be using the clean-room method, which is exactly what OpenWrt jumpstarted for the brcm43xx chips, leading to the modern b43 driver, which OpenWrt then made use of. IIRC, the whole process took about six years. There are other issues involved with Broadcom's ADSL drivers in particular, too. I'll leave it to Florian to either explain the situation for the Nth time, or link to earlier explanations. ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/mailman/listinfo/openwrt-devel
[OpenWrt-Devel] acx-mac80211 (was Re: [brcm63xx] Re: source code / disassembler / decompiler)
On Thu, 2013-01-31 at 17:13 +0100, Christoph Thielecke wrote: Hiho, hmmm, correct me but the drivers are GPL licenced (automatically) because they are shipped with a GPL-kernel. only problem is you havent the source. so simply make it and release anonymously? 8-) if you care i will do. i'am sure no one will complain... I would be become happy if acx100 (http://acx100.sourceforge.net/, driver for TNETW1130 (ACX111) / TNETW1100 (ACX100) / TNETW1450) would be a clean gpl source and ready to integrate into mainline. This driver has same problem :( Or is there are still a solution yet? Still using very old avm driver (on very old kernel) for avm fritz wlan usb on testmachine :( With best regards Christoph ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/mailman/listinfo/openwrt-devel It is my understanding that Lantiq determined that they now own the rights to the proprietary code that leaked into the acx-mac80211 driver and gave OpenWrt the official go-ahead to use it under the GPL. I could be wrong, but AFAIK, the status of this driver is no longer an issue. What IS still an issue is the lack of a usable driver for the TNETW1350A, because no one has the inclination to write it. The current upstream maintainer of acx-mac80211, Oliver Winker, said that such a driver would much more closely resemble the wl1251 driver than the acx driver, but the wl1251 maintainers know nothing about the TNETW1350A. ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] [brcm63xx] Re: source code for the device dsl-2730u
On Thu, 2013-01-31 at 17:03 +0100, Florian Fainelli wrote: We can't do anything serious out of this, the broadcom xDSL drivers make use of a heavily modified struct sk_buff which is subject to changes from one kernel version to another. -- Florian This was always the problem, and short of the type of monumental effort it would take to rewrite them to use linux-atm that b43 took, the only thing that _could_ be done for the time being would be creating some sort of abstraction layer around Broadcom's object code. I do not know in what different forms the xDSL drivers appeared in other tarballs, but I'm guessing some of them might be less or more suitable for this than others. Since Broadcom reimplements huge sections of the kernel themselves, I would expect they make rather minimal use of kernel ABI's, and maintaining a backward-compatibility layer to accommodate a single binary blob (as was done for one for the 2.6.11 kernel for a while) is not feasible, but as you can see, we keep seeing newer tarballs with blobs for newer kernel versions, so complete breakdowns in ABI compatibility are never permanent. I understand the decision not to put forth the effort to do this, and I understand that all efforts to negotiate a compromise with Broadcom like the one reached for wifi have failed, but what would it take to create more leverage? I know that at some point, the French ISP Neuf wanted to broker some sort of agreement which also failed, proving that ISP's do not have such standing with Broadcom, so which device manufacturer could best be approached to assist? ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] [PATCH] AA: unlocked bootloader for SX76x cannot read LAN for rescue, band-aid fix
On Wed, 2013-01-30 at 12:29 +0100, Luka Perkov wrote: On Tue, Jan 29, 2013 at 06:48:22PM -0800, Daniel Gimpelevich wrote: No sooner did I post this than it stopped working, even with this patch, no changes to the source. I'm guessing this uBoot isn't initializing the Ethernet switch properly. It definitely doesn't work in any way, shape, or form without this patch, though. Why don't you use u-boot from trunk? Luka That would require two separate build trees for the same device, trunk and AA, which I can do, but since it is known that trunk cannot currently build a firmware for the device, do you know for sure the the Lantiq uBoot in trunk works properly and has a recovery mode patched in like the AA one? ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/mailman/listinfo/openwrt-devel
[OpenWrt-Devel] [brcm63xx] Re: source code for the device dsl-2730u
On Thu, 2013-01-31 at 04:12 +, NUCLEAR WAR wrote: This is the source code for the device dsl-2730u http://pmdap.dlink.com.tw/PMD/GetAgileFile?itemNumber=GPL132fileName=DSL-2730U_C1_GPL_20130111.7zfileSize=2.14715066E8; kernel Ver for the source is : 2.6.30 Model : DSL-2730U H/W : C1 F/W: ME_1.00 CPU: 963281TAVNG Flash size: 8 mb Ram size : 32 mb I don't know whether this will be of much use. Florian, any hope of reusing the binary ADSL modules in 3.x? They're there as unversioned .o, to be linked into .ko out-of-tree. In any case, maybe more DT data can be gleaned from this tarball. ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/mailman/listinfo/openwrt-devel
[OpenWrt-Devel] [PATCH] AA: unlocked bootloader for SX76x cannot read LAN for rescue, band-aid fix
AA is supposed to be the current stable branch, and the wiki provides instructions on how to flash it on SX76x devices, requiring a replacement of the stock locked bootloader. It says to build it along with your image from menuconfig for the replacement. Currently, this builds a broken bootloader that can boot only an already flashed OpenWrt image, and you cannot reflash again without booting an older bootloader over serial in the UART boot mode. At this moment, this device is temporarily not supported in trunk, and this bootloader package was dropped after the AA branch, with a new one added later. This patch corrects the unmaintained AA bootloader to work as close to as designed as I could manage. I made this patch mostly through trial and error, and I don't really understand why it simply refuses to work properly without it. Again, this patch is ONLY for AA. Signed-off-by: Daniel Gimpelevich dan...@gimpelevich.san-francisco.ca.us Index: package/uboot-lantiq/patches/500-gigasx.patch === --- package/uboot-lantiq/patches/500-gigasx.patch (revision 35398) +++ package/uboot-lantiq/patches/500-gigasx.patch (working copy) @@ -1,6 +1,6 @@ --- a/Makefile +++ b/Makefile -@@ -3613,6 +3613,32 @@ +@@ -3615,6 +3615,33 @@ $(eval $(call arcadyan, arv752DPW%config)) $(eval $(call arcadyan, arv752DPW22%config)) @@ -23,6 +23,7 @@ + *) $(XECHO) ... DDR RAM config \\\$${DDR}\\\ unknown, use default; \ + esac; \ + fi ++ echo #define CONFIG_GIGASX76X_ENV $(obj)include/config.h + echo #define CONFIG_SWITCH_PORT1 1 $(obj)include/config.h + echo #define CONFIG_SWITCH_PIN 3 $(obj)include/config.h + echo #define CONFIG_BUTTON_PORT0 1 $(obj)include/config.h @@ -33,3 +34,63 @@ easy50712%config : unconfig @mkdir -p $(obj)include @mkdir -p $(obj)board/infineon/easy50712 +--- a/include/configs/easy50712.h b/include/configs/easy50712.h +@@ -114,7 +114,9 @@ + + #define CONFIG_CMD_HTTPD /* enable upgrade via HTTPD */ + ++#ifndef CONFIG_GIGASX76X_ENV + #define CONFIG_IPADDR 192.168.0.119 + #define CONFIG_ETHADDR00:01:02:03:04:05 ++#endif + + #endif/* __CONFIG_H */ +--- a/include/configs/ifx-common.h b/include/configs/ifx-common.h +@@ -35,6 +35,7 @@ + #undef CONFIG_PREBOOT + + #undefCONFIG_BOOTARGS ++#ifndef CONFIG_GIGASX76X_ENV + #define CONFIG_EXTRA_ENV_SETTINGS \ + ram_addr=0x8050\0 \ + kernel_addr=0xb002\0 \ +@@ -65,6 +66,7 @@ + cp.b ${ram_addr} ${kernel_addr} ${filesize}\0 + + #define CONFIG_BOOTCOMMANDrun flash_flash ++#endif + + /* + * TFTP is using fragmented packets +@@ -159,7 +161,12 @@ + + /* Address and size of Primary Environment Sector */ + #define CONFIG_ENV_ADDR 0xB001 ++#ifdef CONFIG_GIGASX76X_ENV ++#define CONFIG_ENV_SIZE 0xC00 ++#define CONFIG_ENV_SECT_SIZE 0x1 ++#else + #define CONFIG_ENV_SIZE 0x1 ++#endif + + #ifdef CONFIG_FLASH_CFI_DRIVER + #define CONFIG_SYS_FLASH_CFI +--- a/board/infineon/easy50712/danube.c b/board/infineon/easy50712/danube.c +@@ -331,6 +331,14 @@ + + int board_gpio_init(void) + { ++#ifdef CONFIG_GIGASX76X_ENV ++ setenv(ipaddr, 192.168.1.1); ++ setenv(serverip, 192.168.1.16); ++ setenv(gatewayip, 192.168.1.1); ++ setenv(ram_addr, 0x8010); ++ setenv(bootcmd, setenv bootargs board=$(boardid) ethaddr=$(ethaddr);bootm 0xb002); ++ setenv(bootdelay, 2); ++#endif + #ifdef CONFIG_BUTTON_PORT0 + *DANUBE_GPIO_P0_ALTSEL0 = ~(1CONFIG_BUTTON_PIN); + *DANUBE_GPIO_P0_ALTSEL1 = ~(1CONFIG_BUTTON_PIN); ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] [PATCH] AA: unlocked bootloader for SX76x cannot read LAN for rescue, band-aid fix
No sooner did I post this than it stopped working, even with this patch, no changes to the source. I'm guessing this uBoot isn't initializing the Ethernet switch properly. It definitely doesn't work in any way, shape, or form without this patch, though. On Tue, 2013-01-29 at 14:12 -0800, Daniel Gimpelevich wrote: AA is supposed to be the current stable branch, and the wiki provides instructions on how to flash it on SX76x devices, requiring a replacement of the stock locked bootloader. It says to build it along with your image from menuconfig for the replacement. Currently, this builds a broken bootloader that can boot only an already flashed OpenWrt image, and you cannot reflash again without booting an older bootloader over serial in the UART boot mode. At this moment, this device is temporarily not supported in trunk, and this bootloader package was dropped after the AA branch, with a new one added later. This patch corrects the unmaintained AA bootloader to work as close to as designed as I could manage. I made this patch mostly through trial and error, and I don't really understand why it simply refuses to work properly without it. Again, this patch is ONLY for AA. Signed-off-by: Daniel Gimpelevich dan...@gimpelevich.san-francisco.ca.us Index: package/uboot-lantiq/patches/500-gigasx.patch === --- package/uboot-lantiq/patches/500-gigasx.patch (revision 35398) +++ package/uboot-lantiq/patches/500-gigasx.patch (working copy) @@ -1,6 +1,6 @@ --- a/Makefile +++ b/Makefile -@@ -3613,6 +3613,32 @@ +@@ -3615,6 +3615,33 @@ $(eval $(call arcadyan, arv752DPW%config)) $(eval $(call arcadyan, arv752DPW22%config)) @@ -23,6 +23,7 @@ +*) $(XECHO) ... DDR RAM config \\\$${DDR}\\\ unknown, use default; \ +esac; \ +fi ++echo #define CONFIG_GIGASX76X_ENV $(obj)include/config.h +echo #define CONFIG_SWITCH_PORT1 1 $(obj)include/config.h +echo #define CONFIG_SWITCH_PIN 3 $(obj)include/config.h +echo #define CONFIG_BUTTON_PORT0 1 $(obj)include/config.h @@ -33,3 +34,63 @@ easy50712%config: unconfig @mkdir -p $(obj)include @mkdir -p $(obj)board/infineon/easy50712 +--- a/include/configs/easy50712.h b/include/configs/easy50712.h +@@ -114,7 +114,9 @@ + + #define CONFIG_CMD_HTTPD/* enable upgrade via HTTPD */ + ++#ifndef CONFIG_GIGASX76X_ENV + #define CONFIG_IPADDR 192.168.0.119 + #define CONFIG_ETHADDR 00:01:02:03:04:05 ++#endif + + #endif /* __CONFIG_H */ +--- a/include/configs/ifx-common.h b/include/configs/ifx-common.h +@@ -35,6 +35,7 @@ + #undef CONFIG_PREBOOT + + #undef CONFIG_BOOTARGS ++#ifndef CONFIG_GIGASX76X_ENV + #define CONFIG_EXTRA_ENV_SETTINGS \ + ram_addr=0x8050\0 \ + kernel_addr=0xb002\0 \ +@@ -65,6 +66,7 @@ + cp.b ${ram_addr} ${kernel_addr} ${filesize}\0 + + #define CONFIG_BOOTCOMMAND run flash_flash ++#endif + + /* + * TFTP is using fragmented packets +@@ -159,7 +161,12 @@ + + /* Address and size of Primary Environment Sector */ + #define CONFIG_ENV_ADDR 0xB001 ++#ifdef CONFIG_GIGASX76X_ENV ++#define CONFIG_ENV_SIZE 0xC00 ++#define CONFIG_ENV_SECT_SIZE0x1 ++#else + #define CONFIG_ENV_SIZE 0x1 ++#endif + + #ifdef CONFIG_FLASH_CFI_DRIVER + #define CONFIG_SYS_FLASH_CFI +--- a/board/infineon/easy50712/danube.c b/board/infineon/easy50712/danube.c +@@ -331,6 +331,14 @@ + + int board_gpio_init(void) + { ++#ifdef CONFIG_GIGASX76X_ENV ++setenv(ipaddr, 192.168.1.1); ++setenv(serverip, 192.168.1.16); ++setenv(gatewayip, 192.168.1.1); ++setenv(ram_addr, 0x8010); ++setenv(bootcmd, setenv bootargs board=$(boardid) ethaddr=$(ethaddr);bootm 0xb002); ++setenv(bootdelay, 2); ++#endif + #ifdef CONFIG_BUTTON_PORT0 + *DANUBE_GPIO_P0_ALTSEL0 = ~(1CONFIG_BUTTON_PIN); + *DANUBE_GPIO_P0_ALTSEL1 = ~(1CONFIG_BUTTON_PIN); ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] [PATCH] Re: [lantiq] kernel 3.7 update
On Sun, 2012-12-16 at 09:26 +0100, John Crispin wrote: as always please just state what yoiu want so we can implement it properly instead of random hacks Here is a list of things the random hacks do: 1) Fix a typo in the internet LED name 2) Provide some useful function for the power2 LED 3) Fix the fact that trunk fails to generate any image for the DGN3500A profile 4) Add the usbdev trigger to the Kconfig since the devtree file already uses it 5) Make the 42_athfix, when it's applicable again, apply to both flavors of DGN3500, not just the B 6) Assign the _correct_ LED to netdev 7) As previously stated, the bootargs code as is leaves the original bootargs unconditionally inaccessible, so restore the previous behavior This time, I have refrained from stepping on anything you might conceivably already be working on differently. You might still consider all of the above random hacks not to be done properly and you say to wait, but you know, one of the purposes of bringing a deck of cards on a mountain hike is that if you're alone and start playing Solitaire, it guarantees someone will come along and tell you which card to move where. When that happens, you can either get annoyed and shoo them away, or accept the input and bring the game to a sooner conclusion. Either way, the input is still there. ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/mailman/listinfo/openwrt-devel
[OpenWrt-Devel] [PATCH] Re: [lantiq] kernel 3.7 update
On Sat, 2012-12-15 at 12:10 +0100, John Crispin wrote: On 15/12/12 12:08, Stefan Hellermann wrote: wow thanks! Nice update! I will try it next week on a few Fritzbox 7320, looks like it's almost fully supported (only DECT missing). 7320 has limit support * the TAPI on the 7320 is not lantiq but avm ... never looked into it and i doubt it will work soon * wifi eeprom is located inside the TFFS2 and we dont have a driver working for it yet * the eth2 is not working yet ;) usb and dsl work like a charm however. the wifi and ethernet stuff are on my todo list however John In addition to SPI not coming up on the Netgear, neither does PCI in sysfs, but I guess that's a WIP. Here's a few interim enhancements to look at. I already know you won't like it, but you will you hate ALL of it? Note: I'm restoring the previous behavior of the leading - in bootargs, so that they can be replaced or appended per-target. Signed-off-by: Daniel Gimpelevich dan...@gimpelevich.san-francisco.ca.us Index: target/linux/lantiq/image/DGN3500.dtsi === --- target/linux/lantiq/image/DGN3500.dtsi (revision 34710) +++ target/linux/lantiq/image/DGN3500.dtsi (working copy) @@ -147,7 +147,7 @@ gpio-leds { compatible = gpio-leds; internet { - label = inernet; + label = internet; gpios = gpio 2 1; }; dsl { @@ -161,7 +161,6 @@ power { label = power; gpios = gpio 34 1; - default-state = on; }; power2 { label = power2; Index: target/linux/lantiq/image/DGN3500A.dts === --- target/linux/lantiq/image/DGN3500A.dts (revision 0) +++ target/linux/lantiq/image/DGN3500A.dts (revision 0) @@ -0,0 +1,7 @@ +/dts-v1/; + +/include/ DGN3500.dtsi + +/ { + model = DGN3500 - Netgear DGN3500; +}; Index: target/linux/lantiq/image/Makefile === --- target/linux/lantiq/image/Makefile (revision 34710) +++ target/linux/lantiq/image/Makefile (working copy) @@ -160,6 +160,9 @@ # AR9 +Image/BuildKernel/Profile/DGN3500A=$(call Image/BuildKernel/Template,DGN3500A) +Image/Build/Profile/DGN3500A=$(call Image/Build/$(1),$(1),DGN3500A) + Image/BuildKernel/Profile/DGN3500B=$(call Image/BuildKernel/Template,DGN3500B) Image/Build/Profile/DGN3500B=$(call Image/Build/$(1),$(1),DGN3500B) Index: target/linux/lantiq/xway/config-default === --- target/linux/lantiq/xway/config-default (revision 34710) +++ target/linux/lantiq/xway/config-default (working copy) @@ -6,6 +6,7 @@ CONFIG_INPUT_POLLDEV=y # CONFIG_ISDN is not set CONFIG_LEDS_TRIGGER_HEARTBEAT=y +CONFIG_LEDS_TRIGGER_USBDEV=y CONFIG_M25PXX_USE_FAST_READ=y CONFIG_MTD_M25P80=y CONFIG_MTD_NAND=y Index: target/linux/lantiq/base-files/lib/preinit/42_athfix === --- target/linux/lantiq/base-files/lib/preinit/42_athfix(revision 34710) +++ target/linux/lantiq/base-files/lib/preinit/42_athfix(working copy) @@ -3,9 +3,9 @@ . /lib/functions/lantiq.sh init_atheeprom() { - local board=$(lantiq_board_name) + local board=$(lantiq_board_id) case $board in - Netgear DGN3500B) + DGN3500*) echo - loading eeprom - dd if=/dev/mtd2 of=/sys/firmware/ath_eeprom bs=1k skip=60 count=4 echo 0 /sys/bus/pci/slots/\:00\:0e.0/power Index: target/linux/lantiq/base-files/etc/uci-defaults/leds === --- target/linux/lantiq/base-files/etc/uci-defaults/leds(revision 34710) +++ target/linux/lantiq/base-files/etc/uci-defaults/leds(working copy) @@ -9,7 +9,7 @@ [ -e /sys/class/leds/wifi ] ucidef_set_led_wlan wifi wifi wifi phy0tx [ -e /sys/class/leds/usb ] ucidef_set_led_usbdev usb usb usb 1-1 -[ -e /sys/class/leds/dsl ] ucidef_set_led_netdev dsl dsl dsl pppoe-wan +[ -e /sys/class/leds/internet ]ucidef_set_led_netdev internet internet internet pppoe-wan for a in `ls /sys/class/leds/`; do grep -q \[none\] /sys/class/leds/$a/trigger Index: target/linux/lantiq/base-files/etc/diag.sh === --- target/linux/lantiq/base-files/etc/diag.sh (revision 34710) +++ target/linux/lantiq/base-files/etc/diag.sh (working copy) @@ -25,6 +25,30 @@ return } + [ -d /sys/class/leds/power2/ ] { + + case $1 in + preinit) + echo heartbeat /sys/class/leds/power2
Re: [OpenWrt-Devel] [lantiq] kernel 3.7 update
On Sat, 2012-12-15 at 11:56 +0100, John Crispin wrote: The following boards don't have a devicetree file yet due to lack of time / test hardware (help and hardware welcome!) ARV3527P GIGASX76X ARV4519PW BTHOMEHUBV2B BTHOMEHUBV3A WBMR P2601HNFX H201L The GIGASX76X I could help with if I can ever get a serial console on it... ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] [PATCH] lantiq and Netgear fixes/enhancements
On Sat, 2012-12-08 at 10:49 +, David Woodhouse wrote: On Fri, 2012-12-07 at 18:58 -0800, Daniel Gimpelevich wrote: OK, but hotplug never generates any atm events, so Felix suggested this instead. Hm, it should do. We have other scripts in /etc/hotplug.d/atm, and hotplug2.rules definitely *looks* like it should be invoking them. There is only one such script, and you should make sure it still works, because I put one in to test, and it was never executed. That needs fixing then. Don't just do things wrongly to work around a bug elsewhere — *fix* the bug. I may be able to take a look at this in a few days' time, once my Geos is up and running again. Bad Felix, if he really advised you to use an initscript and he meant it as a long-term thing rather than a temporary hack for testing the concept. Does solos-pci add the sysfs entri(es) when the module is inserted, or later? Modules are inserted before hotplug is running, so if solos-pci does not add at that time, that could account for the discrepancy. I would have assumed Felix knew hotplug wasn't running yet when he suggested this. ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] [PATCH] lantiq and Netgear fixes/enhancements
On Sat, 2012-12-08 at 14:44 +0100, Felix Fietkau wrote: As for the time when hotplug is running wrt. loaded modules - normally udevtrigger should take care of generating the right events. Modules are loaded before any of this is possible, in /etc/init.d/boot as currently written. I was suggesting this as a hack rather than a proper fix. I don't see any of the script based MAC address override approaches as a long term solution. Miscommunication, my bad. The proper long term solution is to make sure that the kernel does the right thing and doesn't require userspace fixup for these devices. - Felix As per previous discussion, this just isn't going to happen on lantiq. ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] [PATCH] lantiq and Netgear fixes/enhancements
On Thu, 2012-11-29 at 07:40 -0800, Daniel Gimpelevich wrote: On Thu, 2012-11-29 at 10:35 +, Conor O'Gorman wrote: I don't want to drag this out longer than necessary. You used the phrase 'hack'. What do you think is the preferred solution? If I had a better one, I would have used it. RFC, again. Well, here's a better one; take 2: Signed-off-by: Daniel Gimpelevich dan...@gimpelevich.san-francisco.ca.us Index: target/linux/lantiq/vr9/target.mk === --- target/linux/lantiq/vr9/target.mk (revision 34577) +++ target/linux/lantiq/vr9/target.mk (working copy) @@ -3,7 +3,7 @@ BOARDNAME:=VR9 FEATURES:=squashfs jffs2 atm -DEFAULT_PACKAGES+=kmod-pppoa ppp-mod-pppoa linux-atm atm-tools br2684ctl kmod-ltq-dsl-vr9 ltq-dsl-app swconfig +DEFAULT_PACKAGES+=kmod-pppoa ppp-mod-pppoa linux-atm atm-esi atm-tools br2684ctl kmod-ltq-dsl-vr9 ltq-dsl-app swconfig define Target/Description Lantiq VR9 Index: target/linux/lantiq/image/Makefile === --- target/linux/lantiq/image/Makefile (revision 34577) +++ target/linux/lantiq/image/Makefile (working copy) @@ -154,7 +154,7 @@ ifeq ($(CONFIG_TARGET_lantiq_ar9),y) Image/BuildKernel/Profile/WBMR=$(call Image/BuildKernel/Template,WBMR,$(xway_cmdline)) -Image/BuildKernel/Profile/DGN3500B=$(call Image/BuildKernel/Template,DGN3500B,$(xway_cmdline)) +Image/BuildKernel/Profile/DGN3500B=$(call Image/BuildKernel/Template,DGN3500B,$(sx76x_cmdline)) Image/BuildKernel/Profile/P2601HNFX=$(call Image/BuildKernel/Template,P2601HNFX,$(xway_cmdline)) Image/BuildKernel/Profile/H201L=$(call Image/BuildKernel/Template,H201L,$(xway_cmdline)) Image/BuildKernel/Profile/FRITZ7320=$(call Image/BuildKernelEVA/Template,FRITZ7320,$(xway_cmdline)) Index: target/linux/lantiq/ar9/target.mk === --- target/linux/lantiq/ar9/target.mk (revision 34577) +++ target/linux/lantiq/ar9/target.mk (working copy) @@ -3,7 +3,7 @@ BOARDNAME:=AR9 FEATURES:=squashfs jffs2 atm -DEFAULT_PACKAGES+=kmod-pppoa ppp-mod-pppoa linux-atm atm-tools br2684ctl kmod-ltq-dsl-ar9 ltq-dsl-app \ +DEFAULT_PACKAGES+=kmod-pppoa ppp-mod-pppoa linux-atm atm-esi atm-tools br2684ctl kmod-ltq-dsl-ar9 ltq-dsl-app \ kmod-input-gpio-keys-polled kmod-ledtrig-netdev kmod-leds-gpio kmod-button-hotplug \ swconfig Index: target/linux/lantiq/danube/target.mk === --- target/linux/lantiq/danube/target.mk(revision 34577) +++ target/linux/lantiq/danube/target.mk(working copy) @@ -3,7 +3,7 @@ BOARDNAME:=Danube FEATURES:=squashfs jffs2 atm -DEFAULT_PACKAGES+=kmod-pppoa ppp-mod-pppoa linux-atm atm-tools br2684ctl kmod-ltq-dsl-danube ltq-dsl-app \ +DEFAULT_PACKAGES+=kmod-pppoa ppp-mod-pppoa linux-atm atm-esi atm-tools br2684ctl kmod-ltq-dsl-danube ltq-dsl-app \ kmod-input-gpio-keys-polled kmod-ledtrig-netdev kmod-leds-gpio kmod-button-hotplug \ swconfig Index: target/linux/lantiq/files-3.3/arch/mips/lantiq/xway/mach-netgear.c === --- target/linux/lantiq/files-3.3/arch/mips/lantiq/xway/mach-netgear.c (revision 34577) +++ target/linux/lantiq/files-3.3/arch/mips/lantiq/xway/mach-netgear.c (working copy) @@ -77,8 +77,8 @@ static struct gpio_led dgn3500_gpio_leds[] __initdata = { - { .name = soc:green:power, .gpio = 34, .active_low = 1, }, - { .name = soc:red:power, .gpio = 39, .active_low = 1, }, + { .name = soc:green:power, .gpio = 34, .active_low = 1, .default_trigger = default-on }, + { .name = soc:red:power, .gpio = 39, .active_low = 1, .default_trigger = default-on }, { .name = soc:orange:wlan, .gpio = 51, .active_low = 1, }, { .name = soc:green:wps, .gpio = 52, .active_low = 1, }, { .name = soc:green:usb, .gpio = 22, .active_low = 1, }, @@ -91,7 +91,7 @@ { .desc = wps, .type = EV_KEY, - .code = BTN_0, + .code = KEY_WPS_BUTTON, .debounce_interval = LTQ_KEYS_DEBOUNCE_INTERVAL, .gpio = 54, .active_low = 1, @@ -99,8 +99,16 @@ { .desc = reset, .type = EV_KEY, - .code = BTN_1, + .code = BTN_0, .debounce_interval = LTQ_KEYS_DEBOUNCE_INTERVAL, + .gpio = 53, + .active_low = 1, + }, + { + .desc = rfkill, + .type = EV_KEY, + .code = KEY_RFKILL, + .debounce_interval = LTQ_KEYS_DEBOUNCE_INTERVAL, .gpio = 36, .active_low = 1, }, @@ -253,5 +261,5 @@ MIPS_MACHINE(LANTIQ_MACH_DGN3500B, DGN3500B, -Netgear DGN3500B, +DGN3500B
Re: [OpenWrt-Devel] [PATCH] lantiq and Netgear fixes/enhancements
On Fri, 2012-12-07 at 12:15 -0800, Daniel Gimpelevich wrote: On Thu, 2012-11-29 at 07:40 -0800, Daniel Gimpelevich wrote: On Thu, 2012-11-29 at 10:35 +, Conor O'Gorman wrote: I don't want to drag this out longer than necessary. You used the phrase 'hack'. What do you think is the preferred solution? If I had a better one, I would have used it. RFC, again. Well, here's a better one; take 2: Whoops; minor oversight. This is the patch as it should be: Signed-off-by: Daniel Gimpelevich dan...@gimpelevich.san-francisco.ca.us Index: target/linux/lantiq/vr9/target.mk === --- target/linux/lantiq/vr9/target.mk (revision 34577) +++ target/linux/lantiq/vr9/target.mk (working copy) @@ -3,7 +3,7 @@ BOARDNAME:=VR9 FEATURES:=squashfs jffs2 atm -DEFAULT_PACKAGES+=kmod-pppoa ppp-mod-pppoa linux-atm atm-tools br2684ctl kmod-ltq-dsl-vr9 ltq-dsl-app swconfig +DEFAULT_PACKAGES+=kmod-pppoa ppp-mod-pppoa linux-atm atm-esi atm-tools br2684ctl kmod-ltq-dsl-vr9 ltq-dsl-app swconfig define Target/Description Lantiq VR9 Index: target/linux/lantiq/image/Makefile === --- target/linux/lantiq/image/Makefile (revision 34577) +++ target/linux/lantiq/image/Makefile (working copy) @@ -154,7 +154,7 @@ ifeq ($(CONFIG_TARGET_lantiq_ar9),y) Image/BuildKernel/Profile/WBMR=$(call Image/BuildKernel/Template,WBMR,$(xway_cmdline)) -Image/BuildKernel/Profile/DGN3500B=$(call Image/BuildKernel/Template,DGN3500B,$(xway_cmdline)) +Image/BuildKernel/Profile/DGN3500B=$(call Image/BuildKernel/Template,DGN3500B,$(sx76x_cmdline)) Image/BuildKernel/Profile/P2601HNFX=$(call Image/BuildKernel/Template,P2601HNFX,$(xway_cmdline)) Image/BuildKernel/Profile/H201L=$(call Image/BuildKernel/Template,H201L,$(xway_cmdline)) Image/BuildKernel/Profile/FRITZ7320=$(call Image/BuildKernelEVA/Template,FRITZ7320,$(xway_cmdline)) Index: target/linux/lantiq/ar9/target.mk === --- target/linux/lantiq/ar9/target.mk (revision 34577) +++ target/linux/lantiq/ar9/target.mk (working copy) @@ -3,7 +3,7 @@ BOARDNAME:=AR9 FEATURES:=squashfs jffs2 atm -DEFAULT_PACKAGES+=kmod-pppoa ppp-mod-pppoa linux-atm atm-tools br2684ctl kmod-ltq-dsl-ar9 ltq-dsl-app \ +DEFAULT_PACKAGES+=kmod-pppoa ppp-mod-pppoa linux-atm atm-esi atm-tools br2684ctl kmod-ltq-dsl-ar9 ltq-dsl-app \ kmod-input-gpio-keys-polled kmod-ledtrig-netdev kmod-leds-gpio kmod-button-hotplug \ swconfig Index: target/linux/lantiq/danube/target.mk === --- target/linux/lantiq/danube/target.mk(revision 34577) +++ target/linux/lantiq/danube/target.mk(working copy) @@ -3,7 +3,7 @@ BOARDNAME:=Danube FEATURES:=squashfs jffs2 atm -DEFAULT_PACKAGES+=kmod-pppoa ppp-mod-pppoa linux-atm atm-tools br2684ctl kmod-ltq-dsl-danube ltq-dsl-app \ +DEFAULT_PACKAGES+=kmod-pppoa ppp-mod-pppoa linux-atm atm-esi atm-tools br2684ctl kmod-ltq-dsl-danube ltq-dsl-app \ kmod-input-gpio-keys-polled kmod-ledtrig-netdev kmod-leds-gpio kmod-button-hotplug \ swconfig Index: target/linux/lantiq/files-3.3/arch/mips/lantiq/xway/mach-netgear.c === --- target/linux/lantiq/files-3.3/arch/mips/lantiq/xway/mach-netgear.c (revision 34577) +++ target/linux/lantiq/files-3.3/arch/mips/lantiq/xway/mach-netgear.c (working copy) @@ -77,8 +77,8 @@ static struct gpio_led dgn3500_gpio_leds[] __initdata = { - { .name = soc:green:power, .gpio = 34, .active_low = 1, }, - { .name = soc:red:power, .gpio = 39, .active_low = 1, }, + { .name = soc:green:power, .gpio = 34, .active_low = 1, .default_trigger = default-on }, + { .name = soc:red:power, .gpio = 39, .active_low = 1, .default_trigger = default-on }, { .name = soc:orange:wlan, .gpio = 51, .active_low = 1, }, { .name = soc:green:wps, .gpio = 52, .active_low = 1, }, { .name = soc:green:usb, .gpio = 22, .active_low = 1, }, @@ -91,7 +91,7 @@ { .desc = wps, .type = EV_KEY, - .code = BTN_0, + .code = KEY_WPS_BUTTON, .debounce_interval = LTQ_KEYS_DEBOUNCE_INTERVAL, .gpio = 54, .active_low = 1, @@ -99,8 +99,16 @@ { .desc = reset, .type = EV_KEY, - .code = BTN_1, + .code = BTN_0, .debounce_interval = LTQ_KEYS_DEBOUNCE_INTERVAL, + .gpio = 53, + .active_low = 1, + }, + { + .desc = rfkill, + .type = EV_KEY, + .code = KEY_RFKILL, + .debounce_interval = LTQ_KEYS_DEBOUNCE_INTERVAL, .gpio = 36, .active_low = 1, }, @@ -253,5
Re: [OpenWrt-Devel] [PATCH] lantiq and Netgear fixes/enhancements
On Fri, 2012-12-07 at 12:24 -0800, Daniel Gimpelevich wrote: On Fri, 2012-12-07 at 12:15 -0800, Daniel Gimpelevich wrote: On Thu, 2012-11-29 at 07:40 -0800, Daniel Gimpelevich wrote: On Thu, 2012-11-29 at 10:35 +, Conor O'Gorman wrote: I don't want to drag this out longer than necessary. You used the phrase 'hack'. What do you think is the preferred solution? If I had a better one, I would have used it. RFC, again. Well, here's a better one; take 2: Whoops; minor oversight. This is the patch as it should be: Third time's a charm: Signed-off-by: Daniel Gimpelevich dan...@gimpelevich.san-francisco.ca.us Index: target/linux/lantiq/vr9/target.mk === --- target/linux/lantiq/vr9/target.mk (revision 34577) +++ target/linux/lantiq/vr9/target.mk (working copy) @@ -3,7 +3,7 @@ BOARDNAME:=VR9 FEATURES:=squashfs jffs2 atm -DEFAULT_PACKAGES+=kmod-pppoa ppp-mod-pppoa linux-atm atm-tools br2684ctl kmod-ltq-dsl-vr9 ltq-dsl-app swconfig +DEFAULT_PACKAGES+=kmod-pppoa ppp-mod-pppoa linux-atm atm-esi atm-tools br2684ctl kmod-ltq-dsl-vr9 ltq-dsl-app swconfig define Target/Description Lantiq VR9 Index: target/linux/lantiq/image/Makefile === --- target/linux/lantiq/image/Makefile (revision 34577) +++ target/linux/lantiq/image/Makefile (working copy) @@ -154,7 +154,7 @@ ifeq ($(CONFIG_TARGET_lantiq_ar9),y) Image/BuildKernel/Profile/WBMR=$(call Image/BuildKernel/Template,WBMR,$(xway_cmdline)) -Image/BuildKernel/Profile/DGN3500B=$(call Image/BuildKernel/Template,DGN3500B,$(xway_cmdline)) +Image/BuildKernel/Profile/DGN3500B=$(call Image/BuildKernel/Template,DGN3500B,$(sx76x_cmdline)) Image/BuildKernel/Profile/P2601HNFX=$(call Image/BuildKernel/Template,P2601HNFX,$(xway_cmdline)) Image/BuildKernel/Profile/H201L=$(call Image/BuildKernel/Template,H201L,$(xway_cmdline)) Image/BuildKernel/Profile/FRITZ7320=$(call Image/BuildKernelEVA/Template,FRITZ7320,$(xway_cmdline)) Index: target/linux/lantiq/ar9/target.mk === --- target/linux/lantiq/ar9/target.mk (revision 34577) +++ target/linux/lantiq/ar9/target.mk (working copy) @@ -3,7 +3,7 @@ BOARDNAME:=AR9 FEATURES:=squashfs jffs2 atm -DEFAULT_PACKAGES+=kmod-pppoa ppp-mod-pppoa linux-atm atm-tools br2684ctl kmod-ltq-dsl-ar9 ltq-dsl-app \ +DEFAULT_PACKAGES+=kmod-pppoa ppp-mod-pppoa linux-atm atm-esi atm-tools br2684ctl kmod-ltq-dsl-ar9 ltq-dsl-app \ kmod-input-gpio-keys-polled kmod-ledtrig-netdev kmod-leds-gpio kmod-button-hotplug \ swconfig Index: target/linux/lantiq/danube/target.mk === --- target/linux/lantiq/danube/target.mk(revision 34577) +++ target/linux/lantiq/danube/target.mk(working copy) @@ -3,7 +3,7 @@ BOARDNAME:=Danube FEATURES:=squashfs jffs2 atm -DEFAULT_PACKAGES+=kmod-pppoa ppp-mod-pppoa linux-atm atm-tools br2684ctl kmod-ltq-dsl-danube ltq-dsl-app \ +DEFAULT_PACKAGES+=kmod-pppoa ppp-mod-pppoa linux-atm atm-esi atm-tools br2684ctl kmod-ltq-dsl-danube ltq-dsl-app \ kmod-input-gpio-keys-polled kmod-ledtrig-netdev kmod-leds-gpio kmod-button-hotplug \ swconfig Index: target/linux/lantiq/files-3.3/arch/mips/lantiq/xway/mach-netgear.c === --- target/linux/lantiq/files-3.3/arch/mips/lantiq/xway/mach-netgear.c (revision 34577) +++ target/linux/lantiq/files-3.3/arch/mips/lantiq/xway/mach-netgear.c (working copy) @@ -77,8 +77,8 @@ static struct gpio_led dgn3500_gpio_leds[] __initdata = { - { .name = soc:green:power, .gpio = 34, .active_low = 1, }, - { .name = soc:red:power, .gpio = 39, .active_low = 1, }, + { .name = soc:green:power, .gpio = 34, .active_low = 1, .default_trigger = default-on }, + { .name = soc:red:power, .gpio = 39, .active_low = 1, .default_trigger = default-on }, { .name = soc:orange:wlan, .gpio = 51, .active_low = 1, }, { .name = soc:green:wps, .gpio = 52, .active_low = 1, }, { .name = soc:green:usb, .gpio = 22, .active_low = 1, }, @@ -91,7 +91,7 @@ { .desc = wps, .type = EV_KEY, - .code = BTN_0, + .code = KEY_WPS_BUTTON, .debounce_interval = LTQ_KEYS_DEBOUNCE_INTERVAL, .gpio = 54, .active_low = 1, @@ -99,8 +99,16 @@ { .desc = reset, .type = EV_KEY, - .code = BTN_1, + .code = BTN_0, .debounce_interval = LTQ_KEYS_DEBOUNCE_INTERVAL, + .gpio = 53, + .active_low = 1, + }, + { + .desc = rfkill, + .type = EV_KEY, + .code = KEY_RFKILL, + .debounce_interval