Commit Graph

87 Commits (5f41e561cab9169a39ce7a23030c4af92b3399cd)

Author SHA1 Message Date
Hauke Mehrtens 0a5145e851 brcm47xx: make reboot a more reliable
A reboot is issued by setting the watchdog timer to a low value, when
the value is decreased from 1 to 0 by the hardware the system will
reboot. Setting this value to 1 does not work every time, it is a
little bit more reliable when setting it to 3. This timer runs with
some MHz or KHz so nobody will notice the increased waiting.

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

SVN-Revision: 41548
10 years ago
Hauke Mehrtens f42c36ea60 brcm47xx: add buttons support for Netgear WNR3500L
Ticket: #14406

Signed-off-by: Rafał Miłecki <zajec5@gmail.com>

SVN-Revision: 41547
10 years ago
Hauke Mehrtens df8741f92b brcm47xx: fix bcm4705 rebooting when initializing the switch.
When the Ethernet controller is powered down and someone wants to
access the mdio bus like the witch driver (b53) the system crashed if
PCI_D3hot was set before. This patch deactivates this power sawing mode
when a switch driver is in use.

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

SVN-Revision: 41527
10 years ago
Hauke Mehrtens 356663cdc8 brcm47xx: add LEDs for Netgear WNR3500L
https://dev.openwrt.org/ticket/14406

Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>

SVN-Revision: 41520
10 years ago
Hauke Mehrtens 8e4efd42d9 brcm47xx: make it possible to unregister the adm switch
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>

SVN-Revision: 41517
10 years ago
Hauke Mehrtens 03e2310a38 brcm47xx: fix LEDs on WRTSL54GS
https://dev.openwrt.org/ticket/16991

Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>

SVN-Revision: 41516
10 years ago
Hauke Mehrtens 77dee19ab4 brcm47xx: increase fallback mac addresses by one
Now the mac address is increased by two for the first fallback mac
address. It could be that the address increased should be used for the
wan port.

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

SVN-Revision: 41515
10 years ago
Hauke Mehrtens 3fff38f93a brcm47xx: do not use mac addresses with 00:90:4C prefix, prevent mac address collisions.
The address prefix 00:90:4C is used by Broadcom in their initial
configuration. When a mac address with the prefix 00:90:4C is used
all devices from the same series are sharing the same mac address.
To prevent mac address collisions we replace them with a mac address
based on the base address.

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

SVN-Revision: 41513
10 years ago
Hauke Mehrtens 3f64bb8f8f brcm47xx: add LEDs for Asus RT-N15U and update RT-N66U
Signed-off-by: Rafał Miłecki <zajec5@gmail.com>

SVN-Revision: 41501
10 years ago
Hauke Mehrtens f95fc5b2d5 brcm47xx: refresh patches
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>

SVN-Revision: 41487
10 years ago
Hauke Mehrtens ba1b49dbab brcm47xx: backport BCM47XX Linksys WRT54G series patches
Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>

SVN-Revision: 41486
10 years ago
Hauke Mehrtens 717e8b6f3c brcm47xx: remove old gpio and nvram interfaces
These were only used by broadcom-diag any more.

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

SVN-Revision: 41048
10 years ago
Felix Fietkau 32d1e0ed2c kernel: add a ssb backport required for a new mac80211 update
Signed-off-by: Felix Fietkau <nbd@openwrt.org>

SVN-Revision: 40833
10 years ago
Hauke Mehrtens c286feac80 brcm47xx: backport 3.14 patch for nvram GPIO pin read
Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>

SVN-Revision: 40346
10 years ago
Hauke Mehrtens 499d1f1401 brcm47xx: Name LEDs colors for Linksys E1000 V2.1
Handle it by creating a new patch for simple database changes.

Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>

SVN-Revision: 40345
10 years ago
Hauke Mehrtens a1f4a43cef brcm47xx: update workarounds patch to V3
Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>

SVN-Revision: 40344
10 years ago
Gabor Juhos 627baa28d3 kernel: update 3.10 to 3.10.34
Signed-off-by: Gabor Juhos <juhosg@openwrt.org>

SVN-Revision: 40291
10 years ago
Hauke Mehrtens 5b388e5716 brcm47xx: b44: some fixes in combination with the switch
Let the switch start the carrier and set the duplex mode independently
if this nic is up of not.

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

SVN-Revision: 39733
11 years ago
Hauke Mehrtens f587bacc26 brcm47xx: b44: start the phy
We did not start the PHY when an external phy was in use. Without this
patch the driver uses half duplex mode and the switch uses full duplex
mode, which causes problems.
Thank you fback for spotting this problem.

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

SVN-Revision: 39719
11 years ago
Hauke Mehrtens 15a7efa119 brcm47xx: fix detection of some Linksys WRT54G* devices
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>

SVN-Revision: 39718
11 years ago
Hauke Mehrtens 2ad7e55a89 brcm47xx: new patch adding arch workarounds.c
It was recently sent to linux-mips for comments. It adds workaround for
WNR3500L to enable USB port.

Signed-off-by: Rafał Miłecki <zajec5@gmail.com>

SVN-Revision: 39469
11 years ago
Hauke Mehrtens 14113eb88f brcm47xx: use upstream patch removing WGT634U code
It does the same, it just reorders things

Signed-off-by: Rafał Miłecki <zajec5@gmail.com>

SVN-Revision: 39468
11 years ago
Hauke Mehrtens db73f1433b brcm47xx: move OpenWrt arch patches a bit further
This allows picking more upstreamed stuff

Signed-off-by: Rafał Miłecki <zajec5@gmail.com>

SVN-Revision: 39467
11 years ago
Hauke Mehrtens 7ae5ff92ae kernel: ssb: update ssb to a version from kernel 3.14-rc1
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>

SVN-Revision: 39464
11 years ago
Hauke Mehrtens e0d4a548fb kernel: bcma: update bcma to a version from kernel 3.14-rc1
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>

SVN-Revision: 39463
11 years ago
Gabor Juhos a2543d72d8 kernel: update 3.10 to 3.10.28
Signed-off-by: Gabor Juhos <juhosg@openwrt.org>

SVN-Revision: 39399
11 years ago
Hauke Mehrtens c2992ee273 brcm47xx: add new led and button support
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>

SVN-Revision: 39252
11 years ago
Hauke Mehrtens 30cf6f5815 brcm47xx: update some patches to versions in linux mainline
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>

SVN-Revision: 39251
11 years ago
Hauke Mehrtens 7d654de038 brcm74xx: fix patch for BCM4706 CPUs
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>

SVN-Revision: 39250
11 years ago
Hauke Mehrtens e585841044 brcm47xx: update mtd drivers
This backports some patches from linux upstream.

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

SVN-Revision: 39249
11 years ago
Hauke Mehrtens 8c085f647b brcm47xx: fix cpu wait for BCM4706
This was called to early.

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

SVN-Revision: 39167
11 years ago
Hauke Mehrtens 961d5b4453 brcm47xx: b44: This updates the phylib patches to the version send upstream
This uses a fixed phy instead of a dummy one.

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

SVN-Revision: 39166
11 years ago
Hauke Mehrtens 36197755dc brcm47xx: deactivate early printk support
This breaks some devices where the serial console is not at port 0 but
somewhere else.

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

SVN-Revision: 39060
11 years ago
Hauke Mehrtens 94f7ae90f8 brcm47xx: misc cleanups
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>

SVN-Revision: 38980
11 years ago
Hauke Mehrtens c48f285147 brcm47xx: deactivate mips wait instruction only for BCM4706
The wait instruction is only broken on the BCM4706 and not on the other
similar SoCs.

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

SVN-Revision: 38979
11 years ago
Hauke Mehrtens 3fb7e8b851 brcm47xx: add vectored interrupts
This adds support for vectored interrupts in this SoC.
This is supported by the 74K cpus.

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

SVN-Revision: 38975
11 years ago
Hauke Mehrtens 25ca004f24 brcm47xx: add cpu overwrites
bcm47xx misses cpu overwrites for the features of the CPUs used in
these SoCs.
Instead of manually checking, it is now known at compile time for some
options and the compiler is able to remove the checks and optimize the
code.

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

SVN-Revision: 38974
11 years ago
Hauke Mehrtens d7ebbd0ac7 brcm47xx: use "firmware" partition name
Some time ago, after switching to the mainline bcm47xxpart driver
following patch has been applied:

commit 03cef8725d2062335ffc3de50fc037b294fd458c
Author: hauke <hauke@3c298f89-4303-0410-b956-a3cf2f4a3e73>
Date:   Sat Apr 6 22:22:26 2013 +0000

    brcm47xx: use old partition names again for kernel 3.8

    This fixes sysupgrade. The partition names are used all over the Internet in various howtos.

    Thank you russell for spotting this problem.

I propose to revert this change and make sysupgrade use "firmware"
instead. This makes brcm47xx compatible with widely used ar71xx and
after all "firmware" sounds like a much better name for... the firmware.

This change doesn't affect "sysupgrade" usage, because it never takes a
partition name as a parameter. This change only affects users using mtd
tool directly. Hopefully there are not many howtos using "mtd" command.

Signed-off-by: Rafał Miłecki <zajec5@gmail.com>

SVN-Revision: 38973
11 years ago
Hauke Mehrtens 4abd860ab2 brcm47xx: swap also early boot console if necessary.
Some devices are using tty1 as the default console, also swap the early
boot console in such case. This is needed for the WGT634U.

Thank you Russell for reporting this.

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

SVN-Revision: 38794
11 years ago
Hauke Mehrtens e8d0b52496 linux/brcm47xx : Belkin F7Dx30x board detection
boardnum is unstable, so allow using NULL to make it unchecked.

A method for differentiating F7D3301 from F7D3302 using nvram is
unknown at this point. Reading the first 32bits of magic from the
"linux" mtd partition would do the trick, but these 2 are similar
enough that we don't need separate led/button definitions. Not knowing
which one you have is only a usability issue for upgrading the device:
they expect different magic numbers for their trx images.

Signed-off-by: Cody P Schafer <devel@codyps.com>

SVN-Revision: 38767
11 years ago
Hauke Mehrtens 091e3fde4c brcm47xx: b44: fix logic in BUG_ON()
It is a problem when phydev is not set at this position and not the other way around.

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

SVN-Revision: 38744
11 years ago
Hauke Mehrtens 874650d235 brcm47xx: add detection for Linksys WRT54GS V1
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>

SVN-Revision: 38700
11 years ago
Hauke Mehrtens 68081fc1c8 brcm47xx: register ADM6996L switch
This patch makes it possible to use adm6996.c on first generation
BCM47XX devices with ADM switches.

This was tested on a WRT54GS version 1.0, thank you Dirk Neukirchen for
the device.

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

SVN-Revision: 38699
11 years ago
Hauke Mehrtens 73ed236907 brcm47xx: fix detection of Asus RT-N12B1 and Netgear WNR3500L
This closes #14367 and #14328.

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

SVN-Revision: 38656
11 years ago
Hauke Mehrtens 40790e6b84 brcm47xx: b44: fix error handling for dummy phy creation
When the mdio bus is unregistered the newly created phy will also be
unregistered and freed.

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

SVN-Revision: 38539
11 years ago
Hauke Mehrtens c185d48b7c brcm47xx: b44: add dummy phy device if we do not find any
On some devices with e.g. a BCM2535F switch the second MAC is used, but
we can not find a phy under all addresses between 0 and 31, 0xffffffff
is returned as phy id. If we can not find a phy at the expected address
create a dummy one.

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

SVN-Revision: 38538
11 years ago
Hauke Mehrtens 6d2136c3f2 brcm47xx: b44: detect external phy by bit set in DevControl register
Without this patch we treated only phy addr 30 as an external phy, but
there is a register to check that. Now we do not have to try to reset
the switch to check for an external switch.

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

SVN-Revision: 38502
11 years ago
Hauke Mehrtens 551a250e58 brcm47xx: fix detection of some boards
This adds some more boards.

This fixes parts of #14316 and #14133.

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

SVN-Revision: 38383
11 years ago
Hauke Mehrtens 64c2bc256c brcm47xx: Cocci spatch "noderef"
sizeof when applied to a pointer typed expression gives the size of the
pointer.
Found by coccinelle spatch "misc/noderef.cocci"

Signed-off-by: Thomas Meyer <thomas@m3y3r.de>

SVN-Revision: 38312
11 years ago
Hauke Mehrtens 2402f8a9ee brcm47xx: move clock detection patches
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>

SVN-Revision: 38311
11 years ago