All of lore.kernel.org
 help / color / mirror / Atom feed
From: John Crispin <blogic@openwrt.org>
To: Ralf Baechle <ralf@linux-mips.org>
Cc: linux-mips@linux-mips.org, John Crispin <blogic@openwrt.org>
Subject: [RFC 11/11] MIPS: ralink: adds Kbuild files
Date: Wed, 23 Jan 2013 13:05:55 +0100	[thread overview]
Message-ID: <1358942755-25371-12-git-send-email-blogic@openwrt.org> (raw)
In-Reply-To: <1358942755-25371-1-git-send-email-blogic@openwrt.org>

Add the Kbuild symbols and Makefiles needed to actually build the ralink code
from this series

Signed-off-by: John Crispin <blogic@openwrt.org>
---
 arch/mips/Kbuild.platforms    |    1 +
 arch/mips/Kconfig             |   19 ++++++++++++++++++-
 arch/mips/ralink/Kconfig      |   27 +++++++++++++++++++++++++++
 arch/mips/ralink/Makefile     |   15 +++++++++++++++
 arch/mips/ralink/Platform     |   11 +++++++++++
 arch/mips/ralink/dts/Makefile |    1 +
 6 files changed, 73 insertions(+), 1 deletion(-)
 create mode 100644 arch/mips/ralink/Kconfig
 create mode 100644 arch/mips/ralink/Makefile
 create mode 100644 arch/mips/ralink/Platform
 create mode 100644 arch/mips/ralink/dts/Makefile

diff --git a/arch/mips/Kbuild.platforms b/arch/mips/Kbuild.platforms
index 91b9d69..9a73ce6 100644
--- a/arch/mips/Kbuild.platforms
+++ b/arch/mips/Kbuild.platforms
@@ -22,6 +22,7 @@ platforms += pmc-sierra
 platforms += pnx833x
 platforms += pnx8550
 platforms += powertv
+platforms += ralink
 platforms += rb532
 platforms += sgi-ip22
 platforms += sgi-ip27
diff --git a/arch/mips/Kconfig b/arch/mips/Kconfig
index 2ac626a..89c92d3 100644
--- a/arch/mips/Kconfig
+++ b/arch/mips/Kconfig
@@ -434,6 +434,22 @@ config POWERTV
 	help
 	  This enables support for the Cisco PowerTV Platform.
 
+config RALINK
+	bool "Ralink based machines"
+	select CEVT_R4K
+	select CSRC_R4K
+	select BOOT_RAW
+	select DMA_NONCOHERENT
+	select IRQ_CPU
+	select USE_OF
+	select SYS_HAS_CPU_MIPS32_R1
+	select SYS_HAS_CPU_MIPS32_R2
+	select SYS_SUPPORTS_32BIT_KERNEL
+	select SYS_SUPPORTS_LITTLE_ENDIAN
+	select SYS_HAS_EARLY_PRINTK
+	select HAVE_MACH_CLKDEV
+	select CLKDEV_LOOKUP
+
 config SGI_IP22
 	bool "SGI IP22 (Indy/Indigo2)"
 	select FW_ARC
@@ -846,6 +862,7 @@ source "arch/mips/lantiq/Kconfig"
 source "arch/mips/lasat/Kconfig"
 source "arch/mips/pmc-sierra/Kconfig"
 source "arch/mips/powertv/Kconfig"
+source "arch/mips/ralink/Kconfig"
 source "arch/mips/sgi-ip27/Kconfig"
 source "arch/mips/sibyte/Kconfig"
 source "arch/mips/txx9/Kconfig"
@@ -1160,7 +1177,7 @@ config BOOT_ELF32
 
 config MIPS_L1_CACHE_SHIFT
 	int
-	default "4" if MACH_DECSTATION || MIKROTIK_RB532 || PMC_MSP4200_EVAL
+	default "4" if MACH_DECSTATION || MIKROTIK_RB532 || PMC_MSP4200_EVAL || RALINK_RT288X
 	default "6" if MIPS_CPU_SCACHE
 	default "7" if SGI_IP22 || SGI_IP27 || SGI_IP28 || SNI_RM || CPU_CAVIUM_OCTEON
 	default "5"
diff --git a/arch/mips/ralink/Kconfig b/arch/mips/ralink/Kconfig
new file mode 100644
index 0000000..1be044c
--- /dev/null
+++ b/arch/mips/ralink/Kconfig
@@ -0,0 +1,27 @@
+if RALINK
+
+choice
+	prompt "Ralink SoC selection"
+	default SOC_RT305X
+	help
+	  Select Ralink MIPS SoC type.
+
+	config SOC_RT305X
+		bool "RT305x"
+		select USB_ARCH_HAS_OHCI
+		select USB_ARCH_HAS_EHCI
+
+endchoice
+
+choice
+	prompt "Devicetree selection"
+	default DTB_RT305X_EVAL
+	help
+	  Select the devicetree.
+
+	config DTB_RT305X_EVAL
+		bool "RT305x eval kit"
+
+endchoice
+
+endif
diff --git a/arch/mips/ralink/Makefile b/arch/mips/ralink/Makefile
new file mode 100644
index 0000000..939757f
--- /dev/null
+++ b/arch/mips/ralink/Makefile
@@ -0,0 +1,15 @@
+# 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.#
+# Makefile for the Ralink common stuff
+#
+# Copyright (C) 2009-2011 Gabor Juhos <juhosg@openwrt.org>
+# Copyright (C) 2013 John Crispin <blogic@openwrt.org>
+
+obj-y := prom.o of.o reset.o clk.o irq.o
+
+obj-$(CONFIG_SOC_RT305X) += rt305x.o
+
+obj-$(CONFIG_EARLY_PRINTK) += early_printk.o
+
+obj-y += dts/
diff --git a/arch/mips/ralink/Platform b/arch/mips/ralink/Platform
new file mode 100644
index 0000000..1d7e8fb
--- /dev/null
+++ b/arch/mips/ralink/Platform
@@ -0,0 +1,11 @@
+#
+# Ralink SoC common stuff
+#
+core-$(CONFIG_RALINK)     += arch/mips/ralink/
+cflags-$(CONFIG_RALINK)   += -I$(srctree)/arch/mips/include/asm/mach-ralink
+
+#
+# Ralink RT305x
+#
+cflags-$(CONFIG_SOC_RT305X) += -I$(srctree)/arch/mips/include/asm/mach-ralink/rt305x
+load-$(CONFIG_SOC_RT305X)   += 0xffffffff80000000
diff --git a/arch/mips/ralink/dts/Makefile b/arch/mips/ralink/dts/Makefile
new file mode 100644
index 0000000..e2ce7b4
--- /dev/null
+++ b/arch/mips/ralink/dts/Makefile
@@ -0,0 +1 @@
+obj-$(CONFIG_DTB_RT305X_EVAL) := rt305x.dtb.o
-- 
1.7.10.4

  parent reply	other threads:[~2013-01-23 12:12 UTC|newest]

Thread overview: 31+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-01-23 12:05 [RFC 00/11] MIPS: ralink: adds support for ralink platform John Crispin
2013-01-23 12:05 ` [RFC 01/11] MIPS: allow platforms to override cp0_compare_irq John Crispin
     [not found]   ` <5101043A.6080009@openwrt.org>
2013-01-24 10:00     ` John Crispin
2013-01-23 12:05 ` [RFC 02/11] MIPS: ralink: adds include files John Crispin
2013-01-24 10:34   ` Gabor Juhos
2013-01-23 12:05 ` [RFC 03/11] MIPS: ralink: adds irq code John Crispin
2013-01-24 10:44   ` Gabor Juhos
2013-01-23 12:05 ` [RFC 04/11] MIPS: ralink: adds reset code John Crispin
2013-01-23 12:05 ` [RFC 05/11] MIPS: ralink: adds prom and cmdline code John Crispin
2013-01-24 11:52   ` Gabor Juhos
2013-01-23 12:05 ` [RFC 06/11] MIPS: ralink: adds clkdev code John Crispin
2013-01-23 12:05 ` [RFC 07/11] MIPS: ralink: adds OF code John Crispin
2013-01-24 13:20   ` Gabor Juhos
2013-01-23 12:05 ` [RFC 08/11] MIPS: ralink: adds early_printk support John Crispin
2013-01-23 19:23   ` Florian Fainelli
2013-01-23 21:54     ` Sergei Shtylyov
2013-01-23 22:15   ` Sergei Shtylyov
2013-01-24  6:57     ` John Crispin
2013-01-24  7:23       ` John Crispin
2013-01-24  7:25         ` John Crispin
2013-01-24  9:58           ` Florian Fainelli
2013-01-24 12:02       ` Sergei Shtylyov
2013-01-24 12:11   ` Gabor Juhos
2013-01-23 12:05 ` [RFC 09/11] MIPS: ralink: adds support for RT305x SoC family John Crispin
2013-01-24 12:27   ` Gabor Juhos
2013-01-23 12:05 ` [RFC 10/11] MIPS: ralink: adds rt305x devicetree John Crispin
2013-01-24 13:52   ` Gabor Juhos
2013-01-23 12:05 ` John Crispin [this message]
2013-01-24 13:59   ` [RFC 11/11] MIPS: ralink: adds Kbuild files Gabor Juhos
2013-01-24 15:06     ` John Crispin
2013-01-23 19:25 ` [RFC 00/11] MIPS: ralink: adds support for ralink platform Florian Fainelli

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1358942755-25371-12-git-send-email-blogic@openwrt.org \
    --to=blogic@openwrt.org \
    --cc=linux-mips@linux-mips.org \
    --cc=ralf@linux-mips.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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.