All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/4] MIPS: BCM47xx: Platfrom updates from OpenWRT
@ 2010-07-27 20:12 Hauke Mehrtens
  2010-07-27 20:12 ` [PATCH 1/4] MIPS: BCM47xx: Really fix 128MB RAM problem Hauke Mehrtens
                   ` (3 more replies)
  0 siblings, 4 replies; 14+ messages in thread
From: Hauke Mehrtens @ 2010-07-27 20:12 UTC (permalink / raw)
  To: ralf, linux-mips; +Cc: Hauke Mehrtens

This series contains some patches for the Broadcom bcm47xx platform.
Most of these patches have been in OpenWRT for some time and they
should be stable. This work is intended for 2.6.36.

Hauke Mehrtens (4):
  MIPS: BCM47xx: Really fix 128MB RAM problem
  MIPS: BCM47xx: Fill values for b43 into ssb sprom
  MIPS: BCM47xx: Activate SSB_B43_PCI_BRIDGE by default
  MIPS: BCM47xx: Setup and register serial early

 arch/mips/Kconfig         |    1 +
 arch/mips/bcm47xx/prom.c  |   22 ++++--
 arch/mips/bcm47xx/setup.c |  168 ++++++++++++++++++++++++++++++++++++---------
 3 files changed, 149 insertions(+), 42 deletions(-)

^ permalink raw reply	[flat|nested] 14+ messages in thread
* [PATCH 1/4] MIPS: BCM47xx: Do not read config from CFE
@ 2010-11-27 16:45 Hauke Mehrtens
  2010-11-27 16:45 ` [PATCH 2/4] MIPS: BCM47xx: Fill values for b43 into ssb sprom Hauke Mehrtens
  0 siblings, 1 reply; 14+ messages in thread
From: Hauke Mehrtens @ 2010-11-27 16:45 UTC (permalink / raw)
  To: ralf, linux-mips; +Cc: Hauke Mehrtens

The config options read out here are not stored in CFE, but only in
NVRAM on the devices. Remove reading from CFE and only access the NVRAM.
Reading out CFE does not harm, but is useless here.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
---
 arch/mips/bcm47xx/setup.c |   28 +++++++++-------------------
 1 files changed, 9 insertions(+), 19 deletions(-)

diff --git a/arch/mips/bcm47xx/setup.c b/arch/mips/bcm47xx/setup.c
index b1aee33..2c6bdad 100644
--- a/arch/mips/bcm47xx/setup.c
+++ b/arch/mips/bcm47xx/setup.c
@@ -32,7 +32,6 @@
 #include <asm/reboot.h>
 #include <asm/time.h>
 #include <bcm47xx.h>
-#include <asm/fw/cfe/cfe_api.h>
 #include <asm/mach-bcm47xx/nvram.h>
 
 struct ssb_bus ssb_bcm47xx;
@@ -82,42 +81,33 @@ static int bcm47xx_get_invariants(struct ssb_bus *bus,
 	/* Fill boardinfo structure */
 	memset(&(iv->boardinfo), 0 , sizeof(struct ssb_boardinfo));
 
-	if (cfe_getenv("boardvendor", buf, sizeof(buf)) >= 0 ||
-	    nvram_getenv("boardvendor", buf, sizeof(buf)) >= 0)
+	if (nvram_getenv("boardvendor", buf, sizeof(buf)) >= 0)
 		iv->boardinfo.type = (u16)simple_strtoul(buf, NULL, 0);
-	if (cfe_getenv("boardtype", buf, sizeof(buf)) >= 0 ||
-	    nvram_getenv("boardtype", buf, sizeof(buf)) >= 0)
+	if (nvram_getenv("boardtype", buf, sizeof(buf)) >= 0)
 		iv->boardinfo.type = (u16)simple_strtoul(buf, NULL, 0);
-	if (cfe_getenv("boardrev", buf, sizeof(buf)) >= 0 ||
-	    nvram_getenv("boardrev", buf, sizeof(buf)) >= 0)
+	if (nvram_getenv("boardrev", buf, sizeof(buf)) >= 0)
 		iv->boardinfo.rev = (u16)simple_strtoul(buf, NULL, 0);
 
 	/* Fill sprom structure */
 	memset(&(iv->sprom), 0, sizeof(struct ssb_sprom));
 	iv->sprom.revision = 3;
 
-	if (cfe_getenv("et0macaddr", buf, sizeof(buf)) >= 0 ||
-	    nvram_getenv("et0macaddr", buf, sizeof(buf)) >= 0)
+	if (nvram_getenv("et0macaddr", buf, sizeof(buf)) >= 0)
 		str2eaddr(buf, iv->sprom.et0mac);
 
-	if (cfe_getenv("et1macaddr", buf, sizeof(buf)) >= 0 ||
-	    nvram_getenv("et1macaddr", buf, sizeof(buf)) >= 0)
+	if (nvram_getenv("et1macaddr", buf, sizeof(buf)) >= 0)
 		str2eaddr(buf, iv->sprom.et1mac);
 
-	if (cfe_getenv("et0phyaddr", buf, sizeof(buf)) >= 0 ||
-	    nvram_getenv("et0phyaddr", buf, sizeof(buf)) >= 0)
+	if (nvram_getenv("et0phyaddr", buf, sizeof(buf)) >= 0)
 		iv->sprom.et0phyaddr = simple_strtoul(buf, NULL, 0);
 
-	if (cfe_getenv("et1phyaddr", buf, sizeof(buf)) >= 0 ||
-	    nvram_getenv("et1phyaddr", buf, sizeof(buf)) >= 0)
+	if (nvram_getenv("et1phyaddr", buf, sizeof(buf)) >= 0)
 		iv->sprom.et1phyaddr = simple_strtoul(buf, NULL, 0);
 
-	if (cfe_getenv("et0mdcport", buf, sizeof(buf)) >= 0 ||
-	    nvram_getenv("et0mdcport", buf, sizeof(buf)) >= 0)
+	if (nvram_getenv("et0mdcport", buf, sizeof(buf)) >= 0)
 		iv->sprom.et0mdcport = simple_strtoul(buf, NULL, 10);
 
-	if (cfe_getenv("et1mdcport", buf, sizeof(buf)) >= 0 ||
-	    nvram_getenv("et1mdcport", buf, sizeof(buf)) >= 0)
+	if (nvram_getenv("et1mdcport", buf, sizeof(buf)) >= 0)
 		iv->sprom.et1mdcport = simple_strtoul(buf, NULL, 10);
 
 	return 0;
-- 
1.7.1

^ permalink raw reply related	[flat|nested] 14+ messages in thread

end of thread, other threads:[~2010-11-29 13:51 UTC | newest]

Thread overview: 14+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-07-27 20:12 [PATCH 0/4] MIPS: BCM47xx: Platfrom updates from OpenWRT Hauke Mehrtens
2010-07-27 20:12 ` [PATCH 1/4] MIPS: BCM47xx: Really fix 128MB RAM problem Hauke Mehrtens
2010-08-02 15:20   ` Ralf Baechle
2010-07-27 20:12 ` [PATCH 2/4] MIPS: BCM47xx: Fill values for b43 into ssb sprom Hauke Mehrtens
2010-08-02 15:31   ` Ralf Baechle
2010-08-02 19:25     ` Ralf Baechle
2010-08-02 21:46       ` Hauke Mehrtens
2010-07-27 20:12 ` [PATCH 3/4] MIPS: BCM47xx: Activate SSB_B43_PCI_BRIDGE by default Hauke Mehrtens
2010-08-02 15:35   ` Ralf Baechle
2010-07-27 20:12 ` [PATCH 4/4] MIPS: BCM47xx: Setup and register serial early Hauke Mehrtens
2010-07-28 13:23   ` Sergei Shtylyov
2010-08-02 15:37     ` Ralf Baechle
  -- strict thread matches above, loose matches on Subject: below --
2010-11-27 16:45 [PATCH 1/4] MIPS: BCM47xx: Do not read config from CFE Hauke Mehrtens
2010-11-27 16:45 ` [PATCH 2/4] MIPS: BCM47xx: Fill values for b43 into ssb sprom Hauke Mehrtens
2010-11-29 13:51   ` Ralf Baechle

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.