Commit graph

1374 commits

Author SHA1 Message Date
Jo-Philipp Wich
527ec2af59 all: remove dummy ucidef_set_interface_loopback() from board.d
Signed-off-by: Jo-Philipp Wich <jow@openwrt.org>

SVN-Revision: 47744
2015-12-03 23:13:00 +00:00
Jo-Philipp Wich
8f8b702f85 board.d: remove redundant ucidef_set_interfaces_lan_wan() calls
This removes calls to ucidef_set_interfaces_lan_wan() and
ucidef_set_interfaces_lan() on boards where all relevant info can be
inferred from the switch definition.

Signed-off-by: Jo-Philipp Wich <jow@openwrt.org>

SVN-Revision: 47722
2015-12-03 17:30:56 +00:00
Jo-Philipp Wich
9b02e73188 board.d: merge ucidef_add_switch() and ucidef_add_switch_ports()
This changes uci-defaults-new.sh, config_generate and all relevant board.d
files in order combine ucidef_add_switch() and ucidef_add_switch_ports() into
a single function.

Also removes now superfluous enable and reset arguments.

Signed-off-by: Jo-Philipp Wich <jow@openwrt.org>

SVN-Revision: 47721
2015-12-03 17:30:24 +00:00
Jo-Philipp Wich
d17a64c7c0 base-files: uci-defaults-new: remove reset/enable args of ucidef_add_switch()
Out of 69 switch definitions, only 3 pass something different than "1" as
values for reset and enable, with one of those three being invalid.

This change ...

 * removes the reset and enable arguments from ucidef_add_switch()
 * unconditionally writes reset:1 and enable:1 to JSON
 * converts the three users of nonstandard values to ucidef_add_switch_attr()

Signed-off-by: Jo-Philipp Wich <jow@openwrt.org>

SVN-Revision: 47720
2015-12-03 17:30:08 +00:00
Jo-Philipp Wich
de51026515 ramips: switch ucidef_add_switch_vlan() to ucidef_add_switch_ports()
This migrates the final board.d user of ucidef_add_switch_vlan() to the new
ucidef_add_switch_ports() approach, fixing some logic errors for a few boards
along the way.

Signed-off-by: Jo-Philipp Wich <jow@openwrt.org>

SVN-Revision: 47717
2015-12-03 15:46:29 +00:00
John Crispin
06af966094 ramips: remove duplicate patch
Signed-off-by: John Crispin <blogic@openwrt.org>

SVN-Revision: 47670
2015-11-28 23:26:03 +00:00
John Crispin
82557aee85 ramips: adapt VoCore to new second spi device code
Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>

SVN-Revision: 47667
2015-11-28 23:24:52 +00:00
John Crispin
af14fa011c ramips: add second SPI clocks
These clocks were missing in the changes introduced in r47573-47580

Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>

SVN-Revision: 47666
2015-11-28 23:24:40 +00:00
Jo-Philipp Wich
ecf5b4fab7 ramips: hg255d: replace ucidef_set_led_interface() with ucidef_set_led_netdev()
Signed-off-by: Jo-Philipp Wich <jow@openwrt.org>

SVN-Revision: 47657
2015-11-26 12:46:04 +00:00
John Crispin
7b4acdeff6 ralink: renable nand support
CONFIG_MTK_MTD_NAND was incorrectly disabled by r47619.

Signed-off-by: John Crispin <blogic@openwrt.org>

SVN-Revision: 47640
2015-11-24 22:00:55 +00:00
Felix Fietkau
d8a62fdbc2 ramips: fix typo in image makefile (#18712)
Signed-off-by: Felix Fietkau <nbd@openwrt.org>

SVN-Revision: 47627
2015-11-24 19:29:56 +00:00
John Crispin
8c1f5141ce ralink: add support for netis WF-2881
netis WF-2881 is an MT7621AT based router with MT7602EN, MT7612EN.
It has 128MB DDR3, 128MB SLC NAND FLASH, 5-port Gbps switch and 1x USB 3.0.
The following patch adds support for this device.

this device only works on top of UBI.

Tested and working:
* ethernet
* both WiFi radios
* USB 3.0
* buttons (reset button)
* ethernet switch and USB diag LEDs
* UART
* GPIOs
* sysupgrade

Tested and not working
* failsafe

Signed-off-by: YounJae Rho <luxflow@live.com>

SVN-Revision: 47619
2015-11-24 18:29:26 +00:00
John Crispin
e9baf8265b ramips: add support for Youku YK1
Changes since V1:
I resend this patch for current trunk.The former V1 patch is for CC branch.

Signed-off-by: Shonn Lu <countrysideboy@qq.com>

SVN-Revision: 47617
2015-11-24 18:29:02 +00:00
John Crispin
12b6f4cf71 ramips: add second spi master sysclk
for mt7620, rt3883 and rt5350

Signed-off-by: Michael Lee <igvtee@gmail.com>

SVN-Revision: 47616
2015-11-24 18:28:54 +00:00
John Crispin
c550ad3d3a ramips: update dtsi files to support second spi device
Signed-off-by: Michael Lee <igvtee@gmail.com>

SVN-Revision: 47580
2015-11-22 11:49:13 +00:00
John Crispin
a941b34008 ramips: use transfer_one instead of transfer_one_message on rt2880 spi
* use kernel buildin transfer_one_message. we only need to implement
transfer_one and set_cs function
* should support use gpio as cs pin
* deselected the spi device when setup and add debug info
* only reset device when first driver probe

Signed-off-by: Michael Lee <igvtee@gmail.com>

SVN-Revision: 47579
2015-11-22 11:49:04 +00:00
John Crispin
95aa28da81 ramips: move rt2880 spi clock and reset init code to spi_prepare_message
before spi transfer. use spi_prepare_message to setup spi hardware. it
will setup MSB, spi mode and speed
remove sys_freq member and speed check code

Signed-off-by: Michael Lee <igvtee@gmail.com>

SVN-Revision: 47578
2015-11-22 11:48:57 +00:00
John Crispin
a58dec6275 ramips: improve rt2880 spi setup
* check clock rate, SPI mode, and word sizes
* setup spi polarity
* enable spi1 hw if need

Signed-off-by: Michael Lee <igvtee@gmail.com>

SVN-Revision: 47577
2015-11-22 11:48:51 +00:00
John Crispin
2ce886f149 ramips: clean up rt2880 spi probe/remove
* fill struct according to the member order
* add error clean up
* set min/max spi speed. so we don't need to check again

Signed-off-by: Michael Lee <igvtee@gmail.com>

SVN-Revision: 47576
2015-11-22 11:48:45 +00:00
John Crispin
bf89d139e1 ramips: improve rt2880 spi wait ready function
use loops_per_jiffy, spi clock speed and write bytes to get the
spi loop count. if loop to 0 than spi operation timeout.
remove usleep. we only write 1 byte to spi device. use busy loop
would be better.

Signed-off-by: Michael Lee <igvtee@gmail.com>

SVN-Revision: 47575
2015-11-22 11:48:34 +00:00
John Crispin
702c480dfe ramips: remove rt2880 spi lock and clean bit operation
Signed-off-by: Michael Lee <igvtee@gmail.com>

SVN-Revision: 47574
2015-11-22 11:48:21 +00:00
John Crispin
13fbd6fea7 ramips: add rt2880/mt7620 spi register defines
Signed-off-by: Michael Lee <igvtee@gmail.com>

SVN-Revision: 47573
2015-11-22 11:48:10 +00:00
John Crispin
55ee2e0ef7 ralink: add missing nand layer hack
It turned out that mtk_nand driver uses some sophisticated accounting and a
general nand code must be patched.

This patch adds required read and erase calls to a general nand code. I
used a  code  for re6500 released by Linksys as a reference.

All required operations (erase, write and read) are usable. However I found
that jffs2 filesystem can be created only on top of a ubi volume. I tried
to create jffs2 directly on mtd device but pages with clean markers are
became uncorrectable.

Signed-off-by: Kirill Berezin <fyiwdt@gmail.com>

SVN-Revision: 47565
2015-11-21 21:25:33 +00:00
John Crispin
40ddc71cc9 ramips: init usb power for Lenovo Y1S
Signed-off-by: Shonn Lu <countrysideboy@qq.com>

SVN-Revision: 47557
2015-11-21 21:24:38 +00:00
Felix Fietkau
b95aed986a ramips: minor fixes for mt7621 profiles
* remove references to non-existing kmod-usb3-mt7621
 * ZTB WG2626 doesn't have an RTC (thanks to Piotr Dymacz!)

Signed-off-by: Daniel Golle <daniel@makrotopia.org>

SVN-Revision: 47407
2015-11-07 12:51:48 +00:00
John Crispin
aebf73f045 ramips: fix previous commit
r47388 accidentially changed 2 files too many

Signed-off-by: John Crispin <blogic@openwrt.org>

SVN-Revision: 47389
2015-11-05 10:03:58 +00:00
John Crispin
dc699dd547 ramips: minor tweak to the lks7688 baord name
Signed-off-by: John Crispin <blogic@openwrt.org>

SVN-Revision: 47388
2015-11-05 10:01:23 +00:00
John Crispin
2350c149b5 ramips: add feature to blink led on sysupgrade
Signed-off-by: John Crispin <blogic@openwrt.org>

SVN-Revision: 47373
2015-11-03 13:32:02 +00:00
John Crispin
165244a222 ramips: add support for ZBT WG2626
Signed-off-by: Daniel Golle <daniel@makrotopia.org>

SVN-Revision: 47351
2015-11-02 10:18:19 +00:00
John Crispin
0f4b153e3d ramips: add eeprom mtd partition to the Asus RP-N53 dts
This patch adds the eeprom property to the dts for the Asus RP-N53. It is necessary to get the wifi in the soc working.

Signed-off-by:  Alberto Mattea <alberto@mattea.info>

SVN-Revision: 47350
2015-11-02 10:18:09 +00:00
John Crispin
907c67fa87 ramips: preinit: use iproute2 instead of vconfig
Replace use of vconfig with the corresponding iproute2 syntax in
/lib/preinit/07_set_preinit_iface_ramips

The switch reset work-around needed on some ramips targets used the
deprecated vconfig tool to bring up the pre-init/failsafe interface.
This doesn't work on recent builds where vconfig is no longer being
deployed, resulting in the device being unreachable when triggered
into failsafe mode.

Signed-off-by: Daniel Golle <daniel@makrotopia.org>

SVN-Revision: 47349
2015-11-02 10:18:02 +00:00
John Crispin
3760b95702 ramips: add support for Dovado tiny AC
Add support for Dovado tiny AC wifi router.

Soc: mt7620a
ram: 64MB
flash: 8MB
1x usb 2.0
two gigabit lan ports

5ghz wlan is not supported on this board since there is no gpl driverfor mt7610e wifi chip.

Signed-off-by: Andrej Vlasic <andrej.vlasic0@gmail.com>

SVN-Revision: 47348
2015-11-02 10:17:51 +00:00
John Crispin
83693c911a ramips: add function to change rt2x00 wifi eeprom mac
Some boards like dovado tiny ac have generic ralink mac in onflash wifi eeprom.
Add eeprom_set_macaddr function to rt2x00 eeprom extract script which changes mac addr insde eeprom dump.

Signed-off-by: Andrej Vlasic <andrej.vlasic0@gmail.com>

SVN-Revision: 47347
2015-11-02 10:17:41 +00:00
John Crispin
a76de8e7b3 ramips: mt7620 add icplus phy driver kernel config symbol
Add missing icplus phy driver kernel config symbol to mt7620 subtarget.
This is needed since some mt7620 devices have icplus ip1001 ethernet transceiver

Signed-off-by: Andrej Vlasic <andrej.vlasic0@gmail.com>

SVN-Revision: 47346
2015-11-02 10:17:35 +00:00
John Crispin
8fa6927415 ramips: add support for the Asus RP-N53 in the "02_network" boot script
This patch adds a case for the Asus RP-N53 in the "02_network" boot script. Without this, the lan interface does not get configured on startup, effectively bricking the device.

Signed-off-by:  Alberto Mattea <alberto@mattea.info>

SVN-Revision: 47345
2015-11-02 10:17:26 +00:00
John Crispin
ed30ca8e39 ramips: rt305x: enable seama mtdsplit parser
D-Link DIR-610 A1 needs seama mtdsplit parser.
This patch should fix #18046.

Signed-off-by: Piotr Dymacz <pepe2k@gmail.com>

SVN-Revision: 47341
2015-11-02 10:16:56 +00:00
John Crispin
6dcbf74a94 ramips: rt305x: update kernel config symbols
Signed-off-by: Piotr Dymacz <pepe2k@gmail.com>

SVN-Revision: 47340
2015-11-02 10:16:48 +00:00
Hauke Mehrtens
55a912f43e kernel: update kernel 3.18 to version 3.18.23
Changelog:
 * https://cdn.kernel.org/pub/linux/kernel/v3.x/ChangeLog-3.18.22
 * https://cdn.kernel.org/pub/linux/kernel/v3.x/ChangeLog-3.18.23

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>

SVN-Revision: 47334
2015-11-01 13:45:57 +00:00
Felix Fietkau
b100027a83 ramips: fix for kernel 4.0 napi repoll need return budgets number
Signed-off-by: Michael Lee <igvtee@gmail.com>

SVN-Revision: 47306
2015-10-30 22:32:49 +00:00
John Crispin
228eeb647e ramips: make the alsa driver register the codec
this allows using the codec even if it is not listed in the DTS

Signed-off-by: John Crispin <blogic@openwrt.org>

SVN-Revision: 47256
2015-10-26 09:00:42 +00:00
John Crispin
e043ada1d5 ramips: gpio-mt7621 was not handling irqs above 31 properly
Signed-off-by: John Crispin <blogic@openwrt.org>

SVN-Revision: 47238
2015-10-20 07:09:20 +00:00
John Crispin
7295e9fb8b ramips: add alsa support
add the SDK alsa driver. this has only been tested on mt7628/88 and wm8960.
mt7620 is only compile tested.

Signed-off-by: John Crispin <blogic@openwrt.org>

SVN-Revision: 47205
2015-10-19 10:07:54 +00:00
John Crispin
f5d5cb0114 ramips: add a baurate hack
When talking to an atmel controller we need 9600 or 250000 baud.
as 250000 does not exist we use 2500000.

Signed-off-by: John Crispin <blogic@openwrt.org>

SVN-Revision: 47204
2015-10-19 10:07:43 +00:00
John Crispin
51dd991d39 ramips: add LinkIt Smart7688 support
Signed-off-by: John Crispin <blogic@openwrt.org>

SVN-Revision: 47203
2015-10-19 10:07:38 +00:00
John Crispin
b0f7e6bc83 ramips: fix /target/linux/ramips/dts/HC5XXX.dtsi
dtb complained about those lines

Signed-off-by: John Crispin <blogic@openwrt.org>

SVN-Revision: 47151
2015-10-07 08:00:40 +00:00
Felix Fietkau
2686dc6dd8 ramips: enable mt76 by default for the mt7620 subtarget (for devices with mt7620 + mt7612)
Signed-off-by: Felix Fietkau <nbd@openwrt.org>

SVN-Revision: 47146
2015-10-06 12:32:31 +00:00
Felix Fietkau
38389c79c2 ramips: improve read performance of the m25p80 chunked io patch
Signed-off-by: Felix Fietkau <nbd@openwrt.org>

SVN-Revision: 47137
2015-10-05 11:34:16 +00:00
John Crispin
b4db6d29d3 ramips: improve systick timer
when sleep mode is disable use MIPS as clocksource and clockevent instead of systick.
because MIPS timer has higher resolution 5ns less than systick 20us and
larger counter bits 32 > 16.
clean interrupt by write compare register at isr.
fix typo cause sleep mode not enable.

Signed-off-by: Michael Lee <igvtee@gmail.com>

SVN-Revision: 47122
2015-10-05 10:27:09 +00:00
John Crispin
10f75a2b7f ramips: fix use remove_irq to release irqaction resource
Signed-off-by: Michael Lee <igvtee@gmail.com>

SVN-Revision: 47121
2015-10-05 10:27:04 +00:00
John Crispin
ccf89e71f2 ramips: add support for 16MB VoCore
Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>

SVN-Revision: 47120
2015-10-05 10:27:00 +00:00