From patchwork Fri Jun 26 06:13:34 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Masahiro Yamada X-Patchwork-Id: 1317389 X-Patchwork-Delegate: trini@ti.com Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=lists.denx.de (client-ip=85.214.62.61; helo=phobos.denx.de; envelope-from=u-boot-bounces@lists.denx.de; receiver=) Authentication-Results: ozlabs.org; dmarc=fail (p=none dis=none) header.from=kernel.org Authentication-Results: ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=nifty.com header.i=@nifty.com header.a=rsa-sha256 header.s=dec2015msa header.b=XesTSVM1; dkim-atps=neutral Received: from phobos.denx.de (phobos.denx.de [85.214.62.61]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 49tRRK5rSvz9sRR for ; Fri, 26 Jun 2020 16:14:05 +1000 (AEST) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 8512C8179F; Fri, 26 Jun 2020 08:14:02 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=fail (p=none dis=none) header.from=kernel.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (2048-bit key; unprotected) header.d=nifty.com header.i=@nifty.com header.b="XesTSVM1"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id B9BEA8179F; Fri, 26 Jun 2020 08:14:00 +0200 (CEST) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on phobos.denx.de X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,RCVD_IN_MSPIKE_H2,SPF_HELO_NONE,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.2 Received: from conuserg-10.nifty.com (conuserg-10.nifty.com [210.131.2.77]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by phobos.denx.de (Postfix) with ESMTPS id 3C256804BA for ; Fri, 26 Jun 2020 08:13:54 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=fail (p=none dis=none) header.from=kernel.org Authentication-Results: phobos.denx.de; spf=fail smtp.mailfrom=masahiroy@kernel.org Received: from oscar.flets-west.jp (softbank126090202047.bbtec.net [126.90.202.47]) (authenticated) by conuserg-10.nifty.com with ESMTP id 05Q6DbT9000659; Fri, 26 Jun 2020 15:13:39 +0900 DKIM-Filter: OpenDKIM Filter v2.10.3 conuserg-10.nifty.com 05Q6DbT9000659 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nifty.com; s=dec2015msa; t=1593152019; bh=0ECeogR6bHgcmhNXV19uqql3HBBe/+/6J+s8A2uEFYY=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=XesTSVM1XepNsLu2jX6Cop0JCURy6HOkWbSHmZOVBHddov2jB26qcwG0yBnD2elv5 VP35kmL5JrT+T1pGXvFtMRA0VOqzv3bTaYcMcHcuxy+C7xyVEY95khaiVg/graLslM 7obTIt6uqcFK2C+A7Mu6phpYD3+HzkK30lN8YPtMYWFaY68YdhS4Tg/Re0eT3Tmc+A mRxqm8FvjVvdPhJXL/Cbm40Rr1dgsnulFll7ykq4+9hq1eHSOHpxuH85TzoQCNxY6S DeP6xw1+mtXsA9QE/J12DU6F0oaQbXXB8zG7uzHB9UCVXEHkWOiQlLe+CndIJ5sXEm Z4udstHjmZXNw== X-Nifty-SrcIP: [126.90.202.47] From: Masahiro Yamada To: u-boot@lists.denx.de Cc: Masahiro Yamada Subject: [PATCH 2/3] treewide: convert bd_t to struct bd_info manually Date: Fri, 26 Jun 2020 15:13:34 +0900 Message-Id: <20200626061335.1611120-2-masahiroy@kernel.org> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20200626061335.1611120-1-masahiroy@kernel.org> References: <20200626061335.1611120-1-masahiroy@kernel.org> MIME-Version: 1.0 X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.30rc1 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" X-Virus-Scanned: clamav-milter 0.102.2 at phobos.denx.de X-Virus-Status: Clean Some code was not converted by coccinelle, somehow. I manually fixed up the remaining, and comments, README docs. Signed-off-by: Masahiro Yamada --- arch/m68k/cpu/mcf523x/cpu.c | 2 +- arch/m68k/cpu/mcf52x2/cpu.c | 2 +- arch/m68k/cpu/mcf532x/cpu.c | 2 +- arch/m68k/cpu/mcf5445x/cpu.c | 2 +- arch/m68k/cpu/mcf547x_8x/cpu.c | 2 +- cmd/bootm.c | 2 +- doc/README.POST | 6 +++--- doc/README.arm-relocation | 4 ++-- doc/README.atmel_mci | 2 +- doc/README.console | 2 +- doc/README.generic-board | 2 +- doc/driver-model/ethernet.rst | 2 +- drivers/net/fec_mxc.c | 4 ++-- drivers/net/ldpaa_eth/ldpaa_eth.c | 2 +- drivers/net/smc911x.c | 2 +- 15 files changed, 19 insertions(+), 19 deletions(-) diff --git a/arch/m68k/cpu/mcf523x/cpu.c b/arch/m68k/cpu/mcf523x/cpu.c index a3a79fb4d2..8664231b5a 100644 --- a/arch/m68k/cpu/mcf523x/cpu.c +++ b/arch/m68k/cpu/mcf523x/cpu.c @@ -105,7 +105,7 @@ int watchdog_init(void) #if defined(CONFIG_MCFFEC) /* Default initializations for MCFFEC controllers. To override, * create a board-specific function called: - * int board_eth_init(bd_t *bis) + * int board_eth_init(struct bd_info *bis) */ int cpu_eth_init(struct bd_info *bis) diff --git a/arch/m68k/cpu/mcf52x2/cpu.c b/arch/m68k/cpu/mcf52x2/cpu.c index 1ca28e46ce..8898a7562a 100644 --- a/arch/m68k/cpu/mcf52x2/cpu.c +++ b/arch/m68k/cpu/mcf52x2/cpu.c @@ -420,7 +420,7 @@ int do_reset(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]) #if defined(CONFIG_MCFFEC) /* Default initializations for MCFFEC controllers. To override, * create a board-specific function called: - * int board_eth_init(bd_t *bis) + * int board_eth_init(struct bd_info *bis) */ int cpu_eth_init(struct bd_info *bis) diff --git a/arch/m68k/cpu/mcf532x/cpu.c b/arch/m68k/cpu/mcf532x/cpu.c index 805108f7ac..f1e6f734eb 100644 --- a/arch/m68k/cpu/mcf532x/cpu.c +++ b/arch/m68k/cpu/mcf532x/cpu.c @@ -147,7 +147,7 @@ int watchdog_init(void) #if defined(CONFIG_MCFFEC) /* Default initializations for MCFFEC controllers. To override, * create a board-specific function called: - * int board_eth_init(bd_t *bis) + * int board_eth_init(struct bd_info *bis) */ int cpu_eth_init(struct bd_info *bis) { diff --git a/arch/m68k/cpu/mcf5445x/cpu.c b/arch/m68k/cpu/mcf5445x/cpu.c index f5c1947b22..ebe15ca518 100644 --- a/arch/m68k/cpu/mcf5445x/cpu.c +++ b/arch/m68k/cpu/mcf5445x/cpu.c @@ -109,7 +109,7 @@ int print_cpuinfo(void) #if defined(CONFIG_MCFFEC) /* Default initializations for MCFFEC controllers. To override, * create a board-specific function called: - * int board_eth_init(bd_t *bis) + * int board_eth_init(struct bd_info *bis) */ int cpu_eth_init(struct bd_info *bis) diff --git a/arch/m68k/cpu/mcf547x_8x/cpu.c b/arch/m68k/cpu/mcf547x_8x/cpu.c index 76d2e77fc0..e53adeb46b 100644 --- a/arch/m68k/cpu/mcf547x_8x/cpu.c +++ b/arch/m68k/cpu/mcf547x_8x/cpu.c @@ -136,7 +136,7 @@ int watchdog_init(void) #if defined(CONFIG_FSLDMAFEC) || defined(CONFIG_MCFFEC) /* Default initializations for MCFFEC controllers. To override, * create a board-specific function called: - * int board_eth_init(bd_t *bis) + * int board_eth_init(struct bd_info *bis) */ int cpu_eth_init(struct bd_info *bis) diff --git a/cmd/bootm.c b/cmd/bootm.c index d5f877cb54..e6b0e04413 100644 --- a/cmd/bootm.c +++ b/cmd/bootm.c @@ -185,7 +185,7 @@ static char bootm_help_text[] = "\tfdt - relocate flat device tree\n" #endif "\tcmdline - OS specific command line processing/setup\n" - "\tbdt - OS specific bd_t processing\n" + "\tbdt - OS specific bd_info processing\n" "\tprep - OS specific prep before relocation or go\n" #if defined(CONFIG_TRACE) "\tfake - OS specific fake start without go\n" diff --git a/doc/README.POST b/doc/README.POST index 43f424f60f..1d1c25bdf9 100644 --- a/doc/README.POST +++ b/doc/README.POST @@ -126,7 +126,7 @@ The following flags will be defined: The POST layer will export the following interface routines: - o) int post_run(bd_t *bd, char *name, int flags); + o) int post_run(struct bd_info *bd, char *name, int flags); This routine will run the test (or the group of tests) specified by the name and flag arguments. More specifically, if the name @@ -175,7 +175,7 @@ struct post_test { char *cmd; char *desc; int flags; - int (*test)(bd_t *bd, int flags); + int (*test)(struct bd_info *bd, int flags); }; o) name @@ -364,7 +364,7 @@ declaration/body: ... ... -int watchdog_post_test(bd_t *bd, int flags) +int watchdog_post_test(struct bd_info *bd, int flags) { unsigned long start_time; diff --git a/doc/README.arm-relocation b/doc/README.arm-relocation index d2a7e8122e..bc6644911b 100644 --- a/doc/README.arm-relocation +++ b/doc/README.arm-relocation @@ -27,7 +27,7 @@ At board level: TODO: move also dram initialization there on boards where it is possible. - Setup of the the bd_t dram bank info is done in the new function + Setup of the bd_info dram bank info is done in the new function dram_init_banksize() called after bd is accessible. At lib level: @@ -65,7 +65,7 @@ in f) could be saved. TODO -- fill in bd_t infos (check) +- fill in struct bd_info infos (check) - adapt all boards - maybe adapt CONFIG_SYS_TEXT_BASE (this must be checked from board maintainers) diff --git a/doc/README.atmel_mci b/doc/README.atmel_mci index 6c027b089f..00e64ba0c7 100644 --- a/doc/README.atmel_mci +++ b/doc/README.atmel_mci @@ -47,7 +47,7 @@ the board specific file need added: ... #ifdef CONFIG_GENERIC_ATMEL_MCI /* this is a weak define that we are overriding */ -int board_mmc_init(bd_t *bd) +int board_mmc_init(struct bd_info *bd) { /* Enable clock */ at91_sys_write(AT91_PMC_PCER, 1 << AT91SAM9260_ID_MCI); diff --git a/doc/README.console b/doc/README.console index 02428fb396..9f5812c89d 100644 --- a/doc/README.console +++ b/doc/README.console @@ -62,7 +62,7 @@ U-Boot relocation (done in 'board_init_r' in arch/*/lib/board.c). HOW CAN I USE STANDARD FILE INTO APPLICATIONS? ---------------------------------------------- -Use the 'bd_mon_fnc' field of the bd_t structure passed to the +Use the 'bd_mon_fnc' field of the bd_info structure passed to the application to do everything you want with the console. But REMEMBER that that will work only if you have not overwritten any diff --git a/doc/README.generic-board b/doc/README.generic-board index 32ddb1d19a..bc35179fbf 100644 --- a/doc/README.generic-board +++ b/doc/README.generic-board @@ -22,7 +22,7 @@ The main change is that the arch//lib/board.c file is removed in favour of common/board_f.c (for pre-relocation init) and common/board_r.c (for post-relocation init). -Related to this, the global_data and bd_t structures now have a core set of +Related to this, the global_data and bd_info structures now have a core set of fields which are common to all architectures. Architecture-specific fields have been moved to separate structures. diff --git a/doc/driver-model/ethernet.rst b/doc/driver-model/ethernet.rst index 359a0523cf..1f5310daaa 100644 --- a/doc/driver-model/ethernet.rst +++ b/doc/driver-model/ethernet.rst @@ -250,7 +250,7 @@ register function. The pseudo code would look something like: .. code-block:: c - int ape_register(bd_t *bis, int iobase) + int ape_register(struct bd_info *bis, int iobase) { struct ape_priv *priv; struct eth_device *dev; diff --git a/drivers/net/fec_mxc.c b/drivers/net/fec_mxc.c index 469c7b7cef..b3d4acb106 100644 --- a/drivers/net/fec_mxc.c +++ b/drivers/net/fec_mxc.c @@ -588,7 +588,7 @@ static int fec_open(struct eth_device *edev) #ifdef CONFIG_DM_ETH static int fecmxc_init(struct udevice *dev) #else -static int fec_init(struct eth_device *dev, bd_t *bd) +static int fec_init(struct eth_device *dev, struct bd_info *bd) #endif { #ifdef CONFIG_DM_ETH @@ -1105,7 +1105,7 @@ struct mii_dev *fec_get_miibus(ulong base_addr, int dev_id) int fec_probe(struct bd_info *bd, int dev_id, uint32_t base_addr, struct mii_dev *bus, struct phy_device *phydev) #else -static int fec_probe(bd_t *bd, int dev_id, uint32_t base_addr, +static int fec_probe(struct bd_info *bd, int dev_id, uint32_t base_addr, struct mii_dev *bus, int phy_id) #endif { diff --git a/drivers/net/ldpaa_eth/ldpaa_eth.c b/drivers/net/ldpaa_eth/ldpaa_eth.c index 116b307b67..67da549fdb 100644 --- a/drivers/net/ldpaa_eth/ldpaa_eth.c +++ b/drivers/net/ldpaa_eth/ldpaa_eth.c @@ -514,7 +514,7 @@ static int ldpaa_eth_open(struct udevice *dev) struct eth_pdata *plat = dev_get_platdata(dev); struct ldpaa_eth_priv *priv = dev_get_priv(dev); #else -static int ldpaa_eth_open(struct eth_device *net_dev, bd_t *bd) +static int ldpaa_eth_open(struct eth_device *net_dev, struct bd_info *bd) { struct ldpaa_eth_priv *priv = (struct ldpaa_eth_priv *)net_dev->priv; #endif diff --git a/drivers/net/smc911x.c b/drivers/net/smc911x.c index 9d2790e561..0f5bb51a68 100644 --- a/drivers/net/smc911x.c +++ b/drivers/net/smc911x.c @@ -435,7 +435,7 @@ static int smc911x_initialize_mii(struct smc911x_priv *priv) } #endif -static int smc911x_init(struct eth_device *dev, bd_t *bd) +static int smc911x_init(struct eth_device *dev, struct bd_info *bd) { struct smc911x_priv *priv = container_of(dev, struct smc911x_priv, dev);