Skip to contentSkip to conversation

ARM: brcmstb: add infrastructure for ARM-based Broadcom STB SoCs

PATCH RESEND Superseded Marc C 1 participant 1 message Nov 23, 2013

Subsystems (3)

v1 of 7 Superseded Latest is v7 →

lore
Share & tools
lore

Marc C

author
#0 lore raw

PATCH RESEND 1/5 ARM: brcmstb: add infrastructure for ARM-based Broadcom STB SoCs

The BCM7xxx series of Broadcom SoCs are used primarily in set-top boxes.

This patch adds machine support for the ARM-based Broadcom SoCs.

---
 arch/arm/Kconfig                   |    2 +
 arch/arm/Kconfig.debug             |   16 +++-
 arch/arm/Makefile                  |    1 +
 arch/arm/configs/brcmstb_defconfig |  126 ++++++++++++++++++++++
 arch/arm/mach-brcmstb/Kconfig      |   24 ++++
 arch/arm/mach-brcmstb/Makefile     |   13 +++
 arch/arm/mach-brcmstb/common.c     |  153 ++++++++++++++++++++++++++
 arch/arm/mach-brcmstb/common.h     |   74 +++++++++++++
 arch/arm/mach-brcmstb/headsmp.S    |   33 ++++++
 arch/arm/mach-brcmstb/hotplug.c    |  208 ++++++++++++++++++++++++++++++++++++
 arch/arm/mach-brcmstb/platsmp.c    |   79 ++++++++++++++
 11 files changed, 728 insertions(+), 1 deletions(-)
 create mode 100644 arch/arm/configs/brcmstb_defconfig
 create mode 100644 arch/arm/mach-brcmstb/Kconfig
 create mode 100644 arch/arm/mach-brcmstb/Makefile
 create mode 100644 arch/arm/mach-brcmstb/common.c
 create mode 100644 arch/arm/mach-brcmstb/common.h
 create mode 100644 arch/arm/mach-brcmstb/headsmp.S
 create mode 100644 arch/arm/mach-brcmstb/hotplug.c
 create mode 100644 arch/arm/mach-brcmstb/platsmp.c
arch/arm/Kconfig +1 -0
index 1ad6fb6..62338a5 100644
@@ -930,6 +930,8 @@ source "arch/arm/mach-at91/Kconfig"
  source "arch/arm/mach-bcm/Kconfig"
 +source "arch/arm/mach-brcmstb/Kconfig"
+
 source "arch/arm/mach-bcm2835/Kconfig"
  source "arch/arm/mach-clps711x/Kconfig"
arch/arm/Kconfig.debug +14 -1
index 9762c84..e381b7a 100644
@@ -94,6 +94,17 @@ choice
 		depends on ARCH_BCM2835
 		select DEBUG_UART_PL01X
 +	config DEBUG_BRCMSTB_UART
+		bool "Use BRCMSTB UART for low-level debug"
+		depends on ARCH_BRCMSTB
+		select DEBUG_UART_8250
+		help
+		  Say Y here if you want the debug print routines to direct
+		  their output to the first serial port on these devices.
+
+		  If you have a Broadcom STB chip and would like early print
+		  messages to appear over the UART, select this option.
+
 	config DEBUG_CLPS711X_UART1
 		bool "Kernel low-level debugging messages via UART1"
 		depends on ARCH_CLPS711X
@@ -951,6 +962,7 @@ config DEBUG_UART_PHYS
 	default 0x20064000 if DEBUG_RK29_UART1 || DEBUG_RK3X_UART2
 	default 0x20068000 if DEBUG_RK29_UART2 || DEBUG_RK3X_UART3
 	default 0x20201000 if DEBUG_BCM2835
+	default 0xf0406b00 if DEBUG_BRCMSTB_UART
 	default 0x40090000 if ARCH_LPC32XX
 	default 0x40100000 if DEBUG_PXA_UART1
 	default 0x42000000 if ARCH_GEMINI
@@ -990,6 +1002,7 @@ config DEBUG_UART_VIRT
 	default 0xf0009000 if DEBUG_CNS3XXX
 	default 0xf01fb000 if DEBUG_NOMADIK_UART
 	default 0xf0201000 if DEBUG_BCM2835
+	default 0xfc406b00 if DEBUG_BRCMSTB_UART
 	default 0xf11f1000 if ARCH_VERSATILE
 	default 0xf1600000 if ARCH_INTEGRATOR
 	default 0xf1c28000 if DEBUG_SUNXI_UART0
@@ -1052,7 +1065,8 @@ config DEBUG_UART_8250_WORD
 	default y if DEBUG_PICOXCELL_UART || DEBUG_SOCFPGA_UART || \
 		ARCH_KEYSTONE || \
 		DEBUG_DAVINCI_DMx_UART0 || DEBUG_DAVINCI_DA8XX_UART1 || \
-		DEBUG_DAVINCI_DA8XX_UART2 || DEBUG_DAVINCI_TNETV107X_UART1
+		DEBUG_DAVINCI_DA8XX_UART2 || DEBUG_DAVINCI_TNETV107X_UART1 || \
+		DEBUG_BRCMSTB_UART
  config DEBUG_UART_8250_FLOW_CONTROL
 	bool "Enable flow control for 8250 UART"
arch/arm/Makefile +1 -0
index db50b62..4691de2 100644
@@ -147,6 +147,7 @@ textofs-$(CONFIG_ARCH_MSM8960) := 0x00208000
 machine-$(CONFIG_ARCH_AT91)		+= at91
 machine-$(CONFIG_ARCH_BCM)		+= bcm
 machine-$(CONFIG_ARCH_BCM2835)		+= bcm2835
+machine-$(CONFIG_ARCH_BRCMSTB)		+= brcmstb
 machine-$(CONFIG_ARCH_CLPS711X)		+= clps711x
 machine-$(CONFIG_ARCH_CNS3XXX)		+= cns3xxx
 machine-$(CONFIG_ARCH_DAVINCI)		+= davinci
arch/arm/configs/brcmstb_defconfig new file +126 -0

126 lines not on this page · raw message

arch/arm/mach-brcmstb/Kconfig new file +24 -0
new file mode 100644
index 0000000..3ed63ef
@@ -0,0 +1,24 @@
+config ARCH_BRCMSTB
+	bool "Broadcom BCM7XXX based boards" if ARCH_MULTI_V7
+	depends on MMU
+	select ARM_ARCH_TIMER
+	select ARM_GIC
+	select BRCMSTB
+	select MIGHT_HAVE_PCI
+	select HAVE_SMP
+	select USE_OF
+	select CPU_V7
+	select GENERIC_CLOCKEVENTS
+	help
+	  Say Y if you intend to run the kernel on a Broadcom ARM-based STB
+	  chipset.
+
+	  This enables support for Broadcom ARM-based set-top box chipsets,
+	  including the 7445 family of chips.
+
+####################################################################
+# Hidden options
+#####################################################################
+
+config BCM7445
+	bool
arch/arm/mach-brcmstb/Makefile new file +13 -0
new file mode 100644
index 0000000..9297c22
@@ -0,0 +1,13 @@
+#
+# Copyright (C) 2013 Broadcom Corporation
+#
+# This program is free software; you can redistribute it and/or
+# modify it under the terms of the GNU General Public License as
+# published by the Free Software Foundation version 2.
+#
+# This program is distributed "as is" WITHOUT ANY WARRANTY of any
+# kind, whether express or implied; without even the implied warranty
+# of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+# GNU General Public License for more details.
+
+obj-$(CONFIG_ARCH_BRCMSTB) := common.o headsmp.o platsmp.o hotplug.o
arch/arm/mach-brcmstb/common.c new file +153 -0

153 lines not on this page · raw message

arch/arm/mach-brcmstb/common.h new file +74 -0

74 lines not on this page · raw message

arch/arm/mach-brcmstb/headsmp.S new file +33 -0
new file mode 100644
index 0000000..1d01358
@@ -0,0 +1,33 @@
+/*
+ * SMP boot code for secondary CPUs
+ * Based on arch/arm/mach-tegra/headsmp.S
+ *
+ * Copyright (C) 2010 NVIDIA, Inc.
+ * Copyright (C) 2013 Broadcom Corporation
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+ */
+
+#include <linux/linkage.h>
+#include <linux/init.h>
+
+        .section ".text.head", "ax"
+	__CPUINIT
+
+ENTRY(brcmstb_secondary_startup)
+        mov     r0, #0xd3
+        msr     cpsr_fsxc, r0
+        bl      v7_invalidate_l1
+        b       secondary_startup
+ENDPROC(brcmstb_secondary_startup)
arch/arm/mach-brcmstb/hotplug.c new file +208 -0

208 lines not on this page · raw message

arch/arm/mach-brcmstb/platsmp.c new file +79 -0

79 lines not on this page · raw message

Signature · 1 line
1.7.1