From patchwork Thu Dec 15 21:30:40 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Fabio Estevam X-Patchwork-Id: 706262 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from theia.denx.de (theia.denx.de [85.214.87.163]) by ozlabs.org (Postfix) with ESMTP id 3tfmpN0WYbz9t0q for ; Fri, 16 Dec 2016 08:31:08 +1100 (AEDT) Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b="PVIpV5dh"; dkim-atps=neutral Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 9D0CFA75AC; Thu, 15 Dec 2016 22:31:05 +0100 (CET) Received: from theia.denx.de ([127.0.0.1]) by localhost (theia.denx.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id XfGFTOisn9mn; Thu, 15 Dec 2016 22:31:05 +0100 (CET) Received: from theia.denx.de (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 0798F4BA35; Thu, 15 Dec 2016 22:31:05 +0100 (CET) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 7AE3A4BA35 for ; Thu, 15 Dec 2016 22:31:01 +0100 (CET) Received: from theia.denx.de ([127.0.0.1]) by localhost (theia.denx.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id nD5qDyl70OJX for ; Thu, 15 Dec 2016 22:31:01 +0100 (CET) X-policyd-weight: NOT_IN_SBL_XBL_SPAMHAUS=-1.5 NOT_IN_SPAMCOP=-1.5 NOT_IN_BL_NJABL=-1.5 (only DNSBL check requested) Received: from mail-qt0-f193.google.com (mail-qt0-f193.google.com [209.85.216.193]) by theia.denx.de (Postfix) with ESMTPS id 04CF04BA16 for ; Thu, 15 Dec 2016 22:30:56 +0100 (CET) Received: by mail-qt0-f193.google.com with SMTP id n6so8584720qtd.0 for ; Thu, 15 Dec 2016 13:30:56 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id; bh=8Zwww4uKp60p3d0kBLml+Ru2wt3OSXJCc+LX6ZBhPQM=; b=PVIpV5dhS10768zKwHinzNBZSjiOSqUqHl2xxgh0nhM4eNwXurmK33/+avUtZ505zi Tet2IN9fWtPjxH7avXN/RiR/fBG+fIdbkgu+7Tq96X9bSfA/5PlMyCNyIHZfpv+u2gzG jeJBbNtLFotuLmJFPGQ5Hff3RPuy6DOlUnErCkUu7OrMTKMF4tkISpnRKYn8vfUf7XlG dBZA0TxU4dyXovqYdXLs66+XE9vhKW5brF0D6wVKqaBpInaNxgQPTtUxgvuXLA7QYyn8 sH0bHYHoLs6qWH32Wz/8u84pZgxpj3aKQL3HALCJCvSk/M046/QfB4f3Ze2v/GLAqOP/ kZ3w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=8Zwww4uKp60p3d0kBLml+Ru2wt3OSXJCc+LX6ZBhPQM=; b=rtBZlFszQC9HAPv7Rgaf0nbkxwt9yjSnEU9/aNpDCshcWSFQNvRA0MZYXwg7NzFdCv lBiunzNLaUYwU3UqF/qnMmiFntW8Y8EfGEfqIR7xtggJDb0D2NMDSnhm6o1yEF8WGoh0 6mqh9+WHg+jyINHyxqHzHd+CvLHjDdK3Ha/BbEPEf63FzTv4xuzjIraKLB3HVaJ7v2o2 XdIYuFarHzHtgvuWroH418gDHc49SZTcXhi0Ep15RHJz9b/eboJVllrniqOheVU/tiLH 7/53QZQxVnm3HlHDoAtgpPvepunAsq7MCqhG9o9+clPdYBwQWnkEHT8FLApBPKPmUQXz OKFg== X-Gm-Message-State: AIkVDXJrO4qGNiNuYOY1jyFKeSlzBCoWpW4yLvcfMA0GwpRyK+HVhbse5Lm/rg07xAr+/w== X-Received: by 10.200.44.196 with SMTP id 4mr2100494qtx.262.1481837455040; Thu, 15 Dec 2016 13:30:55 -0800 (PST) Received: from localhost.localdomain ([179.159.167.69]) by smtp.gmail.com with ESMTPSA id b198sm2051198qkc.42.2016.12.15.13.30.52 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Thu, 15 Dec 2016 13:30:54 -0800 (PST) From: Fabio Estevam To: trini@konsulko.com Date: Thu, 15 Dec 2016 19:30:40 -0200 Message-Id: <1481837440-3770-1-git-send-email-festevam@gmail.com> X-Mailer: git-send-email 2.7.4 Cc: Fabio Estevam , u-boot@lists.denx.de Subject: [U-Boot] [PATCH v3] Kconfig: Move USE_ARCH_MEMCPY/MEMSET to Kconfig X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.15 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" From: Fabio Estevam Move USE_ARCH_MEMCPY/MEMSET options to Kconfig. Make it "default y" for the ARMv7 architecture and make it depend on !ARM64 && !SPL. Signed-off-by: Fabio Estevam --- Changes since v2: - Move it to arch/arm/Kconfig - Change default and depends logic arch/arm/Kconfig | 18 ++++++++++++++++++ include/configs/armadillo-800eva.h | 2 -- include/configs/blanche.h | 3 --- include/configs/colibri_imx7.h | 2 -- include/configs/colibri_vf.h | 2 -- include/configs/exynos-common.h | 3 --- include/configs/pcm052.h | 1 - include/configs/tegra-common.h | 6 ------ include/configs/uniphier.h | 5 ----- include/configs/vf610twr.h | 1 - 10 files changed, 18 insertions(+), 25 deletions(-) diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig index 714dd8b..b15f13f 100644 --- a/arch/arm/Kconfig +++ b/arch/arm/Kconfig @@ -126,6 +126,24 @@ config ENABLE_ARM_SOC_BOOT0_HOOK ARM_SOC_BOOT0_HOOK which contains the required assembler preprocessor code. +config USE_ARCH_MEMCPY + bool "Use an assembly optimized implementation of memcpy" + default y if CPU_V7 + depends on !ARM64 && !SPL + help + Enable the generation of an optimized version of memcpy. + Such implementation may be faster under some conditions + but may increase the binary size. + +config USE_ARCH_MEMSET + bool "Use an assembly optimized implementation of memset" + default y if CPU_V7 + depends on !ARM64 && !SPL + help + Enable the generation of an optimized version of memset. + Such implementation may be faster under some conditions + but may increase the binary size. + config ARCH_OMAP2 bool select CPU_V7 diff --git a/include/configs/armadillo-800eva.h b/include/configs/armadillo-800eva.h index 2d24253..3775a49 100644 --- a/include/configs/armadillo-800eva.h +++ b/include/configs/armadillo-800eva.h @@ -28,8 +28,6 @@ #define CONFIG_ARCH_CPU_INIT #define CONFIG_BOARD_EARLY_INIT_F -#define CONFIG_USE_ARCH_MEMSET -#define CONFIG_USE_ARCH_MEMCPY #define CONFIG_TMU_TIMER #define CONFIG_SYS_DCACHE_OFF diff --git a/include/configs/blanche.h b/include/configs/blanche.h index f094bbe..0deb350 100755 --- a/include/configs/blanche.h +++ b/include/configs/blanche.h @@ -16,9 +16,6 @@ #include "rcar-gen2-common.h" -#define CONFIG_USE_ARCH_MEMSET -#define CONFIG_USE_ARCH_MEMCPY - /* STACK */ #define CONFIG_SYS_INIT_SP_ADDR 0xE817FFFC #define STACK_AREA_SIZE 0xC000 diff --git a/include/configs/colibri_imx7.h b/include/configs/colibri_imx7.h index 5ce0a34..bc3b53b 100644 --- a/include/configs/colibri_imx7.h +++ b/include/configs/colibri_imx7.h @@ -15,8 +15,6 @@ #include "mx7_common.h" #define CONFIG_SYS_THUMB_BUILD -#define CONFIG_USE_ARCH_MEMCPY -#define CONFIG_USE_ARCH_MEMSET /*#define CONFIG_DBG_MONITOR*/ #define PHYS_SDRAM_SIZE SZ_512M diff --git a/include/configs/colibri_vf.h b/include/configs/colibri_vf.h index d58145e..47dea62 100644 --- a/include/configs/colibri_vf.h +++ b/include/configs/colibri_vf.h @@ -16,8 +16,6 @@ #define CONFIG_VF610 #define CONFIG_SYS_THUMB_BUILD -#define CONFIG_USE_ARCH_MEMCPY -#define CONFIG_USE_ARCH_MEMSET #define CONFIG_SYS_FSL_CLK #define CONFIG_ARCH_MISC_INIT diff --git a/include/configs/exynos-common.h b/include/configs/exynos-common.h index 3b61a41..566f246 100644 --- a/include/configs/exynos-common.h +++ b/include/configs/exynos-common.h @@ -20,9 +20,6 @@ #define CONFIG_SKIP_LOWLEVEL_INIT #define CONFIG_BOARD_EARLY_INIT_F -#define CONFIG_USE_ARCH_MEMCPY -#define CONFIG_USE_ARCH_MEMSET - /* Keep L2 Cache Disabled */ /* input clock of PLL: 24MHz input clock */ diff --git a/include/configs/pcm052.h b/include/configs/pcm052.h index eb1944a..e70c3f0 100644 --- a/include/configs/pcm052.h +++ b/include/configs/pcm052.h @@ -35,7 +35,6 @@ #define CONFIG_SYS_NAND_ONFI_DETECTION #ifdef CONFIG_CMD_NAND -#define CONFIG_USE_ARCH_MEMCPY #define CONFIG_SYS_MAX_NAND_DEVICE 1 #define CONFIG_SYS_NAND_BASE NFC_BASE_ADDR diff --git a/include/configs/tegra-common.h b/include/configs/tegra-common.h index 63b711b..23a0e78 100644 --- a/include/configs/tegra-common.h +++ b/include/configs/tegra-common.h @@ -76,12 +76,6 @@ #define CONFIG_SYS_MEMTEST_START (NV_PA_SDRC_CS0 + 0x600000) #define CONFIG_SYS_MEMTEST_END (CONFIG_SYS_MEMTEST_START + 0x100000) -#ifndef CONFIG_ARM64 -#ifndef CONFIG_SPL_BUILD -#define CONFIG_USE_ARCH_MEMCPY -#endif -#endif - /*----------------------------------------------------------------------- * Physical Memory Map */ diff --git a/include/configs/uniphier.h b/include/configs/uniphier.h index f9c9f82..74f1373 100644 --- a/include/configs/uniphier.h +++ b/include/configs/uniphier.h @@ -63,11 +63,6 @@ /* serial console configuration */ #define CONFIG_BAUDRATE 115200 -#if !defined(CONFIG_SPL_BUILD) && !defined(CONFIG_ARM64) -#define CONFIG_USE_ARCH_MEMSET -#define CONFIG_USE_ARCH_MEMCPY -#endif - #define CONFIG_SYS_LONGHELP /* undef to save memory */ #define CONFIG_CMDLINE_EDITING /* add command line history */ diff --git a/include/configs/vf610twr.h b/include/configs/vf610twr.h index af5ba61..6aeb078 100644 --- a/include/configs/vf610twr.h +++ b/include/configs/vf610twr.h @@ -42,7 +42,6 @@ #define CONFIG_SYS_NAND_ONFI_DETECTION #ifdef CONFIG_CMD_NAND -#define CONFIG_USE_ARCH_MEMCPY #define CONFIG_SYS_MAX_NAND_DEVICE 1 #define CONFIG_SYS_NAND_BASE NFC_BASE_ADDR