All of lore.kernel.org
 help / color / mirror / Atom feed
From: thomas.petazzoni@free-electrons.com (Thomas Petazzoni)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 2/6] arm: mvebu: don't list all boards in dt compat field for Armada 370/XP
Date: Mon, 12 Nov 2012 18:20:35 +0100	[thread overview]
Message-ID: <1352740839-13586-3-git-send-email-thomas.petazzoni@free-electrons.com> (raw)
In-Reply-To: <1352740839-13586-1-git-send-email-thomas.petazzoni@free-electrons.com>

Instead of listing explicitly all boards in the .dt_compat field of
the DT_MACHINE_START structure for Armada 370/XP, use instead a
compatible string that is common to all boards using the Armada
370/XP.

This allows to add new boards by just using a different Device Tree,
without having to modify the source code of the kernel.

Note that the name of the array containing the compatible string is
also renamed, to reflect the fact that it no longer contains the list
of all boards.

Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Acked-by: Gregory CLEMENT <gregory.clement@free-electrons.com>
Tested-by: Gregory CLEMENT <gregory.clement@free-electrons.com>
---
This might be considered 3.7 material if not late. Otherwise, there's
no big deal if it goes into 3.8.
---
 arch/arm/mach-mvebu/armada-370-xp.c |    7 +++----
 1 file changed, 3 insertions(+), 4 deletions(-)

diff --git a/arch/arm/mach-mvebu/armada-370-xp.c b/arch/arm/mach-mvebu/armada-370-xp.c
index 49d7915..29c27cd 100644
--- a/arch/arm/mach-mvebu/armada-370-xp.c
+++ b/arch/arm/mach-mvebu/armada-370-xp.c
@@ -46,9 +46,8 @@ static void __init armada_370_xp_dt_init(void)
 	of_platform_populate(NULL, of_default_bus_match_table, NULL, NULL);
 }
 
-static const char * const armada_370_xp_dt_board_dt_compat[] = {
-	"marvell,a370-db",
-	"marvell,axp-db",
+static const char * const armada_370_xp_dt_compat[] = {
+	"marvell,armada-370-xp",
 	NULL,
 };
 
@@ -59,5 +58,5 @@ DT_MACHINE_START(ARMADA_XP_DT, "Marvell Aramada 370/XP (Device Tree)")
 	.handle_irq     = armada_370_xp_handle_irq,
 	.timer		= &armada_370_xp_timer,
 	.restart	= mvebu_restart,
-	.dt_compat	= armada_370_xp_dt_board_dt_compat,
+	.dt_compat	= armada_370_xp_dt_compat,
 MACHINE_END
-- 
1.7.9.5

  parent reply	other threads:[~2012-11-12 17:20 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-11-12 17:20 arm: mvebu: Pull request for 'marvell-boards' branch Thomas Petazzoni
2012-11-12 17:20 ` [PATCH 1/6] arm: mvebu: fix compatible string in armada-370-xp.dtsi Thomas Petazzoni
2012-11-12 17:20 ` Thomas Petazzoni [this message]
2012-11-12 17:20 ` [PATCH 3/6] arm: mvebu: fix typo in machine name for Armada 370/XP Thomas Petazzoni
2012-11-12 17:20 ` [PATCH 4/6] arm: mvebu: support for the PlatHome OpenBlocks AX3-4 board Thomas Petazzoni
2012-11-12 17:20 ` [PATCH 5/6] arm: mvebu: support for the Globalscale Mirabox board Thomas Petazzoni
2012-11-12 17:20 ` [PATCH 6/6] arm: mvebu: add LED support in defconfig Thomas Petazzoni
2012-11-13 18:46 ` arm: mvebu: Pull request for 'marvell-boards' branch Jason Cooper

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=1352740839-13586-3-git-send-email-thomas.petazzoni@free-electrons.com \
    --to=thomas.petazzoni@free-electrons.com \
    --cc=linux-arm-kernel@lists.infradead.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.