kirkwood: get rid of config.mk files
RFC PATCH v2 1/1 kirkwood: get rid of config.mk files
After moving the definition of CONFIG_SYS_TEXT_BASE to the respective board config files, all Marvell kirkwood board have just a single and common entry in their config.mk files:
KWD_CONFIG = $(SRCTREE)/board/$(BOARDDIR)/kwbimage.cfg
Replace the only reference to KWD_CONFIG in the top level Makefile by an equivalent setting, and remove all kirkwood config.mk files.
---
Hi,
this is a (basicly untested) proposal how to clean up support for the kirkwood boards. Unfortunately I have no hardware available to test any of this, so I need your help here.
Thanks.
Wolfgang Denk
Change for v2:
1. board config modifications moved in common config files instead of individual
2. CONFIG_SYS_KWD_CONFIG macro used with provision of refination if needed
2. CONFIG_SYS_TEXT_BASE macro used with provision of refination if needed
--- Makefile | 2 +- board/Marvell/guruplug/config.mk | 27 ------------------------- board/Marvell/mv88f6281gtw_ge/config.mk | 28 -------------------------- board/Marvell/openrd_base/config.mk | 33 ------------------------------- board/Marvell/rd6281a/config.mk | 28 -------------------------- board/Marvell/sheevaplug/config.mk | 28 -------------------------- board/keymile/km_arm/config.mk | 28 -------------------------- include/configs/keymile-common.h | 16 +++++++++++++++ include/configs/mv-common.h | 16 +++++++++++++++ 9 files changed, 33 insertions(+), 173 deletions(-) delete mode 100644 board/Marvell/guruplug/config.mk delete mode 100644 board/Marvell/mv88f6281gtw_ge/config.mk delete mode 100644 board/Marvell/openrd_base/config.mk delete mode 100644 board/Marvell/rd6281a/config.mk delete mode 100644 board/Marvell/sheevaplug/config.mk delete mode 100644 board/keymile/km_arm/config.mk
Makefile +1 -1
@@ -357,7 +357,7 @@ $(obj)u-boot.imx: $(obj)u-boot.bin -e $(CONFIG_SYS_TEXT_BASE) -d $< $@ $(obj)u-boot.kwb: $(obj)u-boot.bin - $(obj)tools/mkimage -n $(KWD_CONFIG) -T kwbimage \ + $(obj)tools/mkimage -n $(CONFIG_SYS_KWD_CONFIG) -T kwbimage \ -a $(CONFIG_SYS_TEXT_BASE) -e $(CONFIG_SYS_TEXT_BASE) -d $< $@ $(obj)u-boot.sha1: $(obj)u-boot.bin
board/Marvell/guruplug/config.mk deleted +0 -27
@@ -1,27 +0,0 @@ -# -# (C) Copyright 2009 -# Marvell Semiconductor <www.marvell.com> -# Written-by: Siddarth Gore <[email protected]> -# -# See file CREDITS for list of people who contributed to this -# project. -# -# 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; either version 2 of -# the License, or (at your option) any later version. -# -# 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., 51 Franklin Street, Fifth Floor, Boston, -# MA 02110-1301 USA -# - -CONFIG_SYS_TEXT_BASE = 0x00600000 - -KWD_CONFIG = $(SRCTREE)/board/$(BOARDDIR)/kwbimage.cfg
board/Marvell/mv88f6281gtw_ge/config.mk deleted +0 -28
@@ -1,28 +0,0 @@ -# -# (C) Copyright 2009 -# Marvell Semiconductor <www.marvell.com> -# Written-by: Prafulla Wadaskar <[email protected]> -# -# See file CREDITS for list of people who contributed to this -# project. -# -# 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; either version 2 of -# the License, or (at your option) any later version. -# -# 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., 51 Franklin Street, Fifth Floor, Boston, -# MA 02110-1301 USA -# - -CONFIG_SYS_TEXT_BASE = 0x00600000 - -# Kirkwood Boot Image configuration file -KWD_CONFIG = $(SRCTREE)/board/$(BOARDDIR)/kwbimage.cfg
board/Marvell/openrd_base/config.mk deleted +0 -33
@@ -1,33 +0,0 @@ -# -# (C) Copyright 2009 -# Net Insight <www.netinsight.net> -# Written-by: Simon Kagstrom <[email protected]> -# -# Based on sheevaplug: -# (C) Copyright 2009 -# Marvell Semiconductor <www.marvell.com> -# Written-by: Prafulla Wadaskar <[email protected]> -# -# See file CREDITS for list of people who contributed to this -# project. -# -# 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; either version 2 of -# the License, or (at your option) any later version. -# -# 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., 51 Franklin Street, Fifth Floor, Boston, -# MA 02110-1301 USA -# - -CONFIG_SYS_TEXT_BASE = 0x00600000 - -# Kirkwood Boot Image configuration file -KWD_CONFIG = $(SRCTREE)/board/$(BOARDDIR)/kwbimage.cfg
board/Marvell/rd6281a/config.mk deleted +0 -28
@@ -1,28 +0,0 @@ -# -# (C) Copyright 2009 -# Marvell Semiconductor <www.marvell.com> -# Written-by: Prafulla Wadaskar <[email protected]> -# -# See file CREDITS for list of people who contributed to this -# project. -# -# 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; either version 2 of -# the License, or (at your option) any later version. -# -# 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., 51 Franklin Street, Fifth Floor, Boston, -# MA 02110-1301 USA -# - -CONFIG_SYS_TEXT_BASE = 0x00600000 - -# Kirkwood Boot Image configuration file -KWD_CONFIG = $(SRCTREE)/board/$(BOARDDIR)/kwbimage.cfg
board/Marvell/sheevaplug/config.mk deleted +0 -28
@@ -1,28 +0,0 @@ -# -# (C) Copyright 2009 -# Marvell Semiconductor <www.marvell.com> -# Written-by: Prafulla Wadaskar <[email protected]> -# -# See file CREDITS for list of people who contributed to this -# project. -# -# 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; either version 2 of -# the License, or (at your option) any later version. -# -# 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., 51 Franklin Street, Fifth Floor, Boston, -# MA 02110-1301 USA -# - -CONFIG_SYS_TEXT_BASE = 0x00600000 - -# Kirkwood Boot Image configuration file -KWD_CONFIG = $(SRCTREE)/board/$(BOARDDIR)/kwbimage.cfg
board/keymile/km_arm/config.mk deleted +0 -28
@@ -1,28 +0,0 @@ -# -# (C) Copyright 2009 -# Marvell Semiconductor <www.marvell.com> -# Prafulla Wadaskar <[email protected]> -# -# See file CREDITS for list of people who contributed to this -# project. -# -# 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; either version 2 of -# the License, or (at your option) any later version. -# -# 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., 51 Franklin Street, Fifth Floor, Boston, -# MA 02110-1301 USA -# - -CONFIG_SYS_TEXT_BASE = 0x004000000 - -# Kirkwood Boot Image configuration file -KWD_CONFIG = $(SRCTREE)/board/$(BOARDDIR)/kwbimage.cfg
include/configs/keymile-common.h +16 -0
@@ -30,6 +30,22 @@#define CONFIG_BOOTCOUNT_LIMIT /* +* By default kwbimage.cfg from board specific folder is used +* If for some board, different configuration file need to be used, +* CONFIG_SYS_KWD_CONFIG should be defined in board specific header file +*/ +#ifndef CONFIG_SYS_KWD_CONFIG +#define CONFIG_SYS_KWD_CONFIG $(SRCTREE)/$(CONFIG_BOARDDIR)/kwbimage.cfg +#endif /* CONFIG_SYS_KWD_CONFIG */ + +/* +* CONFIG_SYS_TEXT_BASE can be defined in board specific header file, if needed +*/ +#ifndef CONFIG_SYS_TEXT_BASE +#define CONFIG_SYS_TEXT_BASE 0x00400000 +#endif /* CONFIG_SYS_TEXT_BASE */ + +/* * Command line configuration. */ #include <config_cmd_default.h>
include/configs/mv-common.h +16 -0
@@ -45,6 +45,22 @@#define CONFIG_KIRKWOOD_RGMII_PAD_1V8 /* Set RGMII Pad voltage to 1.8V */ #define CONFIG_KIRKWOOD_PCIE_INIT /* Enable PCIE Port0 for kernel */ +/* +* By default kwbimage.cfg from board specific folder is used +* If for some board, different configuration file need to be used, +* CONFIG_SYS_KWD_CONFIG should be defined in board specific header file +*/ +#ifndef CONFIG_SYS_KWD_CONFIG +#define CONFIG_SYS_KWD_CONFIG $(SRCTREE)/$(CONFIG_BOARDDIR)/kwbimage.cfg +#endif /* CONFIG_SYS_KWD_CONFIG */ + +/* +* CONFIG_SYS_TEXT_BASE can be defined in board specific header file, if needed +*/ +#ifndef CONFIG_SYS_TEXT_BASE +#define CONFIG_SYS_TEXT_BASE 0x00600000 +#endif /* CONFIG_SYS_TEXT_BASE */ +#define CONFIG_I2C_MVTWSI_BASE KW_TWSI_BASE#define MV_UART0_BASE KW_UART0_BASE#define MV_SATA_BASE KW_SATA_BASE
Signature · 1 line
1.7.2.1
RFC PATCH v2 1/1 kirkwood: get rid of config.mk files
Dear Prafulla Wadaskar,
Quoted 9 lines · In message <[email protected]> you wrote:
After moving the definition of
CONFIG_SYS_TEXT_BASEto the respective board config files, all Marvell kirkwood board have just a single and common entry in their config.mk files:KWD_CONFIG = $(SRCTREE)/board/$(BOARDDIR)/kwbimage.cfgReplace the only reference to
KWD_CONFIGin the top levelMakefileby an equivalent setting, and remove all kirkwood config.mk files.
Quoted 7 lines
Signed-off-by Wolfgang Denk <[email protected] <http://lists.denx.de/mailman/listinfo/u-boot>>Cc Prafulla Wadaskar <[email protected] <http://lists.denx.de/mailman/listinfo/u-boot>>Cc Siddarth Gore <[email protected] <http://lists.denx.de/mailman/listinfo/u-boot>>Cc Simon Kagstrom <[email protected] <http://lists.denx.de/mailman/listinfo/u-boot>>Cc Heiko Schocher <[email protected] <http://lists.denx.de/mailman/listinfo/u-boot>>Cc Eric Cooper <[email protected] <http://lists.denx.de/mailman/listinfo/u-boot>>Signed-off-by Prafulla Wadaskar <[email protected]>
All the Cc: mail addresses are broken here.
Except for that:
Best regards,
Wolfgang Denk
Signature · 5 lines
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de It is easier to change the specification to fit the program than vice versa.
RFC PATCH v2 1/1 kirkwood: get rid of config.mk files
In reply to Prafulla WadaskarQuoted 30 lines
-----Original Message-----
From: Prafulla Wadaskar [mailto:prafulla at marvell.com]
Sent: Wednesday, October 27, 2010 7:18 PM
To: u-boot at lists.denx.de
Cc: Prabhanjan Sarnaik; Ashish Karkare; Prafulla Wadaskar
Subject: [PATCH v2] [U-Boot] [RFC] kirkwood: get rid of config.mk filesAfter moving the definition of
CONFIG_SYS_TEXT_BASEto the respective board config files, all Marvell kirkwood board have just a single and common entry in their config.mk files:KWD_CONFIG = $(SRCTREE)/board/$(BOARDDIR)/kwbimage.cfgReplace the only reference to
KWD_CONFIGin the top levelMakefileby an equivalent setting, and remove all kirkwood config.mk files.Signed-off-by Wolfgang Denk <[email protected]<http://lists.denx.de/mailman/listinfo/u-boot>>
Cc: Prafulla Wadaskar <[email protected]
<http://lists.denx.de/mailman/listinfo/u-boot>>
Cc: Siddarth Gore <[email protected]
<http://lists.denx.de/mailman/listinfo/u-boot>>
Cc: Simon Kagstrom <[email protected]
<http://lists.denx.de/mailman/listinfo/u-boot>>
Cc: Heiko Schocher <[email protected]
<http://lists.denx.de/mailman/listinfo/u-boot>>
Cc: Eric Cooper <[email protected] <http://lists.denx.de/mailman/listinfo/u-
boot>>
Quoted 1 line
Signed-off-by Prafulla Wadaskar <[email protected]>
Applied to u-boot-marvell.git master branch with modifications to cc info
Regards..
Prafulla . .