From patchwork Fri Sep 29 12:52:29 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Mario Six X-Patchwork-Id: 819979 X-Patchwork-Delegate: wd@denx.de Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=none (mailfrom) smtp.mailfrom=lists.denx.de (client-ip=81.169.180.215; helo=lists.denx.de; envelope-from=u-boot-bounces@lists.denx.de; receiver=) Received: from lists.denx.de (dione.denx.de [81.169.180.215]) by ozlabs.org (Postfix) with ESMTP id 3y3XvH19Gmz9t3f for ; Fri, 29 Sep 2017 23:48:11 +1000 (AEST) Received: by lists.denx.de (Postfix, from userid 105) id DDB9EC21EA5; Fri, 29 Sep 2017 13:13:56 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on lists.denx.de X-Spam-Level: X-Spam-Status: No, score=-0.0 required=5.0 tests=RCVD_IN_MSPIKE_H3, RCVD_IN_MSPIKE_WL, SPF_HELO_PASS autolearn=unavailable autolearn_force=no version=3.4.0 Received: from lists.denx.de (localhost [IPv6:::1]) by lists.denx.de (Postfix) with ESMTP id D68F9C21DAA; Fri, 29 Sep 2017 13:00:14 +0000 (UTC) Received: by lists.denx.de (Postfix, from userid 105) id E400FC21EA6; Fri, 29 Sep 2017 12:55:04 +0000 (UTC) Received: from smtprelay05.ispgateway.de (smtprelay05.ispgateway.de [80.67.18.28]) by lists.denx.de (Postfix) with ESMTPS id C20B9C21EF0 for ; Fri, 29 Sep 2017 12:54:58 +0000 (UTC) Received: from [87.191.40.34] (helo=bob3.testumgebung.local) by smtprelay05.ispgateway.de with esmtpa (Exim 4.89) (envelope-from ) id 1dxuok-00004w-3R; Fri, 29 Sep 2017 14:54:58 +0200 From: Mario Six To: U-Boot Mailing List , Ilya Yanok , Dirk Eibach , Simon Glass , Heiko Schocher , Stefan Roese , Jagan Teki , Joe Hershberger Date: Fri, 29 Sep 2017 14:52:29 +0200 Message-Id: <20170929125238.26226-71-mario.six@gdsys.cc> X-Mailer: git-send-email 2.11.0 In-Reply-To: <20170929125238.26226-1-mario.six@gdsys.cc> References: <20170929125238.26226-1-mario.six@gdsys.cc> X-Df-Sender: bWFyaW8uc2l4QGdkc3lzLmNj Subject: [U-Boot] [PATCH 071/080] common: board_r: Fix style violations X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.18 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" Fix some style violations in the board_r file. Signed-off-by: Mario Six Reviewed-by: Simon Glass --- common/board_r.c | 27 ++++++++++++++------------- 1 file changed, 14 insertions(+), 13 deletions(-) diff --git a/common/board_r.c b/common/board_r.c index 94697e7bc1..a81addc005 100644 --- a/common/board_r.c +++ b/common/board_r.c @@ -161,9 +161,9 @@ static int initr_reloc_global_data(void) #endif #ifdef CONFIG_OF_EMBED /* - * The fdt_blob needs to be moved to new relocation address - * incase of FDT blob is embedded with in image - */ + * The fdt_blob needs to be moved to new relocation address + * incase of FDT blob is embedded with in image + */ gd->fdt_blob += gd->reloc_off; #endif #ifdef CONFIG_EFI_LOADER @@ -368,14 +368,16 @@ static int initr_flash(void) print_size(flash_size, ""); #ifdef CONFIG_SYS_FLASH_CHECKSUM /* - * Compute and print flash CRC if flashchecksum is set to 'y' - * - * NOTE: Maybe we should add some WATCHDOG_RESET()? XXX - */ + * Compute and print flash CRC if flashchecksum is set to 'y' + * + * NOTE: Maybe we should add some WATCHDOG_RESET()? XXX + */ if (env_get_yesno("flashchecksum") == 1) { + const uchar *flash_base = (const uchar *)CONFIG_SYS_FLASH_BASE; + printf(" CRC: %08X", crc32(0, - (const unsigned char *) CONFIG_SYS_FLASH_BASE, - flash_size)); + flash_base, + flash_size)); } #endif /* CONFIG_SYS_FLASH_CHECKSUM */ putc('\n'); @@ -392,7 +394,6 @@ static int initr_flash(void) update_flash_size(flash_size); #endif - #if defined(CONFIG_OXC) || defined(CONFIG_RMU) /* flash mapped at end of memory map */ bd->bi_flashoffset = CONFIG_SYS_TEXT_BASE + flash_size; @@ -657,7 +658,7 @@ int initr_mem(void) /* Also take the logbuffer into account (pram is in kB) */ pram += (LOGBUFF_LEN + LOGBUFF_OVERHEAD) / 1024; # endif - sprintf(memsz, "%ldk", (long int) ((gd->ram_size / 1024) - pram)); + sprintf(memsz, "%ldk", (long int)((gd->ram_size / 1024) - pram)); env_set("mem", memsz); return 0; @@ -710,7 +711,7 @@ static init_fnc_t init_sequence_r[] = { initr_caches, /* Note: For Freescale LS2 SoCs, new MMU table is created in DDR. * A temporary mapping of IFC high region is since removed, - * so environmental variables in NOR flash is not availble + * so environmental variables in NOR flash is not available * until board_init() is called below to remap IFC to high * region. */ @@ -775,7 +776,7 @@ static init_fnc_t init_sequence_r[] = { #if defined(CONFIG_PCI) && defined(CONFIG_SYS_EARLY_PCI_INIT) /* * Do early PCI configuration _before_ the flash gets initialised, - * because PCU ressources are crucial for flash access on some boards. + * because PCU resources are crucial for flash access on some boards. */ initr_pci, #endif