Re: [LEDE-DEV] [PATCH] Add support for Comfast E380AC v1 and v2

2016-10-20 Thread Gareth Parker
Because there are two versions of this device there are two different $board 
values cf-e380ac-v1 and cf-e380ac-v2, however there is one struct for gpio's in 
the corresponding mach file referencing cf-e380ac.  What would be the procedure 
or protocol to follow here in regards to using $board in diag.sh and 02_leds?

Gareth

-Original Message-
From: John Crispin [mailto:j...@phrozen.org] 
Sent: Tuesday, 18 October 2016 7:13 p.m.
To: Rafał Miłecki; Gareth Parker
Cc: LEDE Development List; gar...@zappie.net.nz
Subject: Re: [LEDE-DEV] [PATCH] Add support for Comfast E380AC v1 and v2



On 18/10/2016 07:54, Rafał Miłecki wrote:
> On 17 October 2016 at 12:14, Gareth Parker <garet...@orcon.net.nz> wrote:
>> The Comfast E380AC is a single port PoE Dual Band AP.
>>
>> There are two versions which are only identifiable through the web 
>> administration interface, v1 has 128mb ram and a uboot size of 128k, v2 has 
>> 256mb ram and a uboot size of 256k, the remaining hardware and PCB markings 
>> are the same.
> 
> Minor note: mb means milli-bits. You probably meant MiB which means 
> mebi-bytes.
> https://en.wikipedia.org/wiki/Metric_prefix
> https://en.wikipedia.org/wiki/Binary_prefix
> 
> 
>> diff --git a/target/linux/ar71xx/base-files/etc/diag.sh 
>> b/target/linux/ar71xx/base-files/etc/diag.sh
>> index d6e257d..c8e6b48 100644
>> --- a/target/linux/ar71xx/base-files/etc/diag.sh
>> +++ b/target/linux/ar71xx/base-files/etc/diag.sh
>> @@ -82,6 +82,10 @@ get_status_led() {
>> cf-e316n-v2)
>> status_led="$board:blue:wan"
>> ;;
>> +   cf-e380ac-v1|\
>> +   cf-e380ac-v2)
>> +   status_led="cfe380ac:green"
>> +   ;;
>> cpe510)
>> status_led="tp-link:green:link4"
>> ;;
> 
> See comment below.
> 
> 
>> +static struct gpio_led cf_e380ac_leds_gpio[] __initdata = {
>> +   {
>> +   .name   = "cfe380ac:red",
>> +   .gpio   = CF_E380AC_GPIO_LED_RED,
>> +   .active_low = 0,
>> +   },
>> +   {
>> +   .name   = "cfe380ac:green",
>> +   .gpio   = CF_E380AC_GPIO_LED_GREEN,
>> +   .active_low = 0,
>> +   },
>> +   {
>> +   .name   = "cfe380ac:blue",
>> +   .gpio   = CF_E380AC_GPIO_LED_BLUE,
>> +   .active_low = 0,
>> +   },
>> +
>> +};
> 
> What about functions of these LEDs? Take a look at 
> Documentation/leds/leds-class.txt, you should be using 
> "devicename:colour:function".

please make sure to use $board instead of the board name when referencing the 
leds.

> 
> ___
> Lede-dev mailing list
> Lede-dev@lists.infradead.org
> http://lists.infradead.org/mailman/listinfo/lede-dev
> 


___
Lede-dev mailing list
Lede-dev@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/lede-dev


[LEDE-DEV] [PATCH] add support for the Comfast CF-E380AC

2016-08-28 Thread Gareth Parker
This is a Dual Band PoE AP with gigabit Ethernet, 5ghz is supported with the
ath10k driver.

Gareth


cf-e380ac.patch
Description: Binary data
___
Lede-dev mailing list
Lede-dev@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/lede-dev


[LEDE-DEV] uap-pro jffs2 error

2016-08-28 Thread Gareth Parker
Just built LEDE from latest source and get a jffs2 error on the Ubiquiti
UAP-PRO.  The errors continue on down the screen for several pages before
the device crashes and reboots again in a loop.  Openwrt doesn't have this
problem.

Gareth


[0.00] Linux version 4.4.19 (xxx@xxx) (gcc version 5.4.0
(LEDE GCC 5.4.0 xxx) ) #0 Sun Aug 28 02:04:23 2016
[0.00] bootconsole [early0] enabled
[0.00] CPU0 revision is: 0001974c (MIPS 74Kc)
[0.00] SoC: Atheros AR9344 rev 3
[0.00] Determined physical RAM map:
[0.00]  memory: 0800 @  (usable)
[0.00] Initrd not found or empty - disabling initrd
[0.00] No valid device tree found, continuing without
[0.00] Zone ranges:
[0.00]   Normal   [mem 0x-0x07ff]
[0.00] Movable zone start for each node
[0.00] Early memory node ranges
[0.00]   node   0: [mem 0x-0x07ff]
[0.00] Initmem setup node 0 [mem
0x-0x07ff]
[0.00] Primary instruction cache 64kB, VIPT, 4-way, linesize 32
bytes.
[0.00] Primary data cache 32kB, 4-way, VIPT, cache aliases, linesize
32 bytes
[0.00] Built 1 zonelists in Zone order, mobility grouping on.  Total
pages: 32512
[0.00] Kernel command line:  board=UAP-PRO
mtdparts=spi0.0:256k(u-boot)ro,64k(u-boot-env)ro,1536k(kernel),14208k(rootfs
),256k(cfg)ro,64k(EEPROM)ro,15744k@0x5(firmware) console=ttyS0,115200
rootfstype=squashfs,jffs2 noinitrd
[0.00] PID hash table entries: 512 (order: -1, 2048 bytes)
[0.00] Dentry cache hash table entries: 16384 (order: 4, 65536
bytes)
[0.00] Inode-cache hash table entries: 8192 (order: 3, 32768 bytes)
[0.00] Writing ErrCtl register=
[0.00] Readback ErrCtl register=
[0.00] Memory: 125140K/131072K available (2974K kernel code, 154K
rwdata, 748K rodata, 276K init, 200K bss, 5932K reserved, 0K cma-reserved)
[0.00] SLUB: HWalign=32, Order=0-3, MinObjects=0, CPUs=1, Nodes=1
[0.00] NR_IRQS:51
[0.00] Clocks: CPU:560.000MHz, DDR:450.000MHz, AHB:225.000MHz,
Ref:40.000MHz
[0.00] clocksource: MIPS: mask: 0x max_cycles: 0x,
max_idle_ns: 6825930166 ns
[0.09] sched_clock: 32 bits at 280MHz, resolution 3ns, wraps every
7669584382ns
[0.008292] Calibrating delay loop... 278.93 BogoMIPS (lpj=1394688)
[0.081138] pid_max: default: 32768 minimum: 301
[0.086170] Mount-cache hash table entries: 1024 (order: 0, 4096 bytes)
[0.093224] Mountpoint-cache hash table entries: 1024 (order: 0, 4096
bytes)
[0.103117] clocksource: jiffies: mask: 0x max_cycles:
0x, max_idle_ns: 1911260446275 ns
[0.114303] NET: Registered protocol family 16
[0.120407] MIPS: machine is Ubiquiti UniFi AP Pro
[0.128816] registering PCI controller with io_map_base unset
[0.354243] PCI host bridge to bus :00
[0.358656] pci_bus :00: root bus resource [mem
0x1000-0x13ff]
[0.365972] pci_bus :00: root bus resource [io  0x]
[0.371919] pci_bus :00: root bus resource [??? 0x flags 0x0]
[0.379144] pci_bus :00: No busn resource found for root bus, will
use [bus 00-ff]
[0.387662] pci :00:00.0: invalid calibration data
[0.393573] pci :00:00.0: BAR 0: assigned [mem 0x1000-0x1001
64bit]
[0.401410] pci :00:00.0: BAR 6: assigned [mem 0x1002-0x1002
pref]
[0.409107] pci :00:00.0: using irq 40 for pin 1
[0.415233] clocksource: Switched to clocksource MIPS
[0.421868] NET: Registered protocol family 2
[0.427353] TCP established hash table entries: 1024 (order: 0, 4096
bytes)
[0.434782] TCP bind hash table entries: 1024 (order: 0, 4096 bytes)
[0.441590] TCP: Hash tables configured (established 1024 bind 1024)
[0.448447] UDP hash table entries: 256 (order: 0, 4096 bytes)
[0.454667] UDP-Lite hash table entries: 256 (order: 0, 4096 bytes)
[0.461622] NET: Registered protocol family 1
[0.470520] futex hash table entries: 256 (order: -1, 3072 bytes)
[0.477161] Crashlog allocated RAM at address 0x3f0
[0.496159] squashfs: version 4.0 (2009/01/31) Phillip Lougher
[0.502374] jffs2: version 2.2 (NAND) (SUMMARY) (LZMA) (RTIME)
(CMODE_PRIORITY) (c) 2001-2006 Red Hat, Inc.
[0.515344] io scheduler noop registered
[0.519526] io scheduler deadline registered (default)
[0.525210] Serial: 8250/16550 driver, 1 ports, IRQ sharing disabled
[0.532430] console [ttyS0] disabled
[0.556327] serial8250.0: ttyS0 at MMIO 0x1802 (irq = 11, base_baud =
250) is a 16550A
[0.565519] console [ttyS0] enabled
[0.565519] console [ttyS0] enabled
[0.572933] bootconsole [early0] disabled
[0.572933] bootconsole [early0] disabled
[0.584480] m25p80 spi0.0: found mx25l12805d, expected m25p80
[0.590396] m25p80 spi0.0: mx25l12805d 

Re: [LEDE-DEV] Adding support for Comfast CF-WR650AC

2016-06-04 Thread Gareth Parker
I have found part of the cause of switch problem

It's related to this commit:
http://git.openwrt.org/?p=openwrt.git;a=commit;h=ef54bfd6c8c82e865dd2f6c80b3
78a0c0f772ffc

I tried to checkout parent commit and worked fine, any commits after this
one cause the router to hang then reboot on issuing "swconfig dev switch0
show".
I also tried reverting this commit in lede, editing file
"target/linux/generic/files/drivers/net/phy/ar8216.c" but still had the same
problem, so it looks there's something else also causing this problem in
lede.

If anyone wants to have a look at this, I can give you remote access to a
linux box with serial console to router.


Here is what I get:

root@OpenWrt:/# swconfig dev switch0 show
Global attributes:
enable_vlan: 1
enable_mirror_rx: 0
enable_mirror_tx: 0
mirror_monitor_port: 0
mirror_source_port: 0

and it locks up there for approximately 5 seconds before router reboots, I'm
assuming the watchdog timer is forcing the reboot.  There's no other console
output that shows up.


Gareth



-Original Message-
From: Lede-dev [mailto:lede-dev-boun...@lists.infradead.org] On Behalf Of
Jo-Philipp Wich
Sent: Monday, 30 May 2016 1:09 a.m.
To: lede-dev@lists.infradead.org
Subject: Re: [LEDE-DEV] Adding support for Comfast CF-WR650AC

Hi Gareth,

the CC patch you linked looks reasonably clean so I can't spot immediate
reasons that would prevent it from getting included into LEDE.

I suggest that you fork https://github.com/lede-project/source and integrate
the required changes into your clone, then open a PR based on it. You can of
course use git-send-email and patches too if you prefer that.

If you need help porting certain changes to master let me know, a few things
surrounding image building and default config changed compared to CC.

Regards,
Jo

___
Lede-dev mailing list
Lede-dev@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/lede-dev


___
Lede-dev mailing list
Lede-dev@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/lede-dev


[LEDE-DEV] Supported device list and documentation over at openwrt.org

2016-06-01 Thread Gareth Parker
There is a lot of very useful specific router documentation still over at
openwrt.org, technical details, de-bricking info, device mods, plus loads
more info and photos relating to lots of individual devices.  Would it not
be wise to also bring this over to the lede website?  I quite often refer
back to a lot of this documentation.  With the openwrt problems and changes
recently and people leaving openwrt for lede, I’m worried this documentation
is in jeopardy of being lost.  I’ve seen this happen with other websites. 
If this were to happen it would certainly make life very difficult for some
people, I often refer back to the openwrt website for quite a few things
from time to time.  This plus the forum history is not mirrored anywhere
else I’m aware of, correct me if I’m wrong though.

Gareth



___
Lede-dev mailing list
Lede-dev@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/lede-dev


Re: [LEDE-DEV] Adding support for Comfast CF-WR650AC

2016-05-31 Thread Gareth Parker
Thanks Jo

I'll do just that and create a fork.  I've been doing some testing with an
earlier version of openwrt trunk trying to find out what change and when
that has caused the switch problem on this router.

This revision seen to be fine:
http://git.openwrt.org/?p=openwrt.git;a=commit;h=5603e83223a4bd5b3c97e7168fa
69b3a3e215671

It's just anything Designated Driver related that causes this problem, but
what exactly I'm not sure.

Regards,

Gareth


-Original Message-
From: Lede-dev [mailto:lede-dev-boun...@lists.infradead.org] On Behalf Of
Jo-Philipp Wich
Sent: Monday, 30 May 2016 1:09 a.m.
To: lede-dev@lists.infradead.org
Subject: Re: [LEDE-DEV] Adding support for Comfast CF-WR650AC

Hi Gareth,

the CC patch you linked looks reasonably clean so I can't spot immediate
reasons that would prevent it from getting included into LEDE.

I suggest that you fork https://github.com/lede-project/source and integrate
the required changes into your clone, then open a PR based on it. You can of
course use git-send-email and patches too if you prefer that.

If you need help porting certain changes to master let me know, a few things
surrounding image building and default config changed compared to CC.

Regards,
Jo

___
Lede-dev mailing list
Lede-dev@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/lede-dev


___
Lede-dev mailing list
Lede-dev@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/lede-dev