From patchwork Wed Sep 4 22:16:37 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Lukasz Majewski X-Patchwork-Id: 1158139 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=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=) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=denx.de Received: from lists.denx.de (dione.denx.de [81.169.180.215]) by ozlabs.org (Postfix) with ESMTP id 46NyqG18h4z9sDB for ; Thu, 5 Sep 2019 08:17:12 +1000 (AEST) Received: by lists.denx.de (Postfix, from userid 105) id 155BBC21DED; Wed, 4 Sep 2019 22:17:02 +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=none 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 F1CBBC21C2F; Wed, 4 Sep 2019 22:17:00 +0000 (UTC) Received: by lists.denx.de (Postfix, from userid 105) id 23581C21C2F; Wed, 4 Sep 2019 22:16:59 +0000 (UTC) Received: from mail-out.m-online.net (mail-out.m-online.net [212.18.0.9]) by lists.denx.de (Postfix) with ESMTPS id BCBD8C21C29 for ; Wed, 4 Sep 2019 22:16:58 +0000 (UTC) Received: from frontend01.mail.m-online.net (unknown [192.168.8.182]) by mail-out.m-online.net (Postfix) with ESMTP id 46Nypx5Kmlz1rJsn; Thu, 5 Sep 2019 00:16:57 +0200 (CEST) Received: from localhost (dynscan1.mnet-online.de [192.168.6.70]) by mail.m-online.net (Postfix) with ESMTP id 46Nypx4cGJz1qqkb; Thu, 5 Sep 2019 00:16:57 +0200 (CEST) X-Virus-Scanned: amavisd-new at mnet-online.de Received: from mail.mnet-online.de ([192.168.8.182]) by localhost (dynscan1.mail.m-online.net [192.168.6.70]) (amavisd-new, port 10024) with ESMTP id Z_2z1p_KIy5X; Thu, 5 Sep 2019 00:16:55 +0200 (CEST) X-Auth-Info: ecpOviw6c4fEtSdWqdEjpaCsM5FllDZrjb8uR+vYFP4= Received: from localhost.localdomain (85-222-111-42.dynamic.chello.pl [85.222.111.42]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.mnet-online.de (Postfix) with ESMTPSA; Thu, 5 Sep 2019 00:16:55 +0200 (CEST) From: Lukasz Majewski To: Simon Glass , Tom Rini , Stefano Babic , Fabio Estevam Date: Thu, 5 Sep 2019 00:16:37 +0200 Message-Id: <20190904221639.26469-2-lukma@denx.de> X-Mailer: git-send-email 2.11.0 In-Reply-To: <20190904221639.26469-1-lukma@denx.de> References: <20190904221639.26469-1-lukma@denx.de> Cc: Pankit Garg , Vinitha V Pillai , u-boot@lists.denx.de, York Sun Subject: [U-Boot] [PATCH v3 1/3] spi: Move DM_SPI_FLASH to Kconfig (for NXP's ls1043a) 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" This patch fixes issue with defining the DM_SPI_FLASH in the configs/include/ instead of enabling this option in Kconfig. The problem is that CONFIG_IS_ENABLED(DM_SPI_FLASH) shows false as there is no DM_SPI_FLASH=y in .config (but the define is set in u-boot.cfg). As a result conversion of DM_SPI_FLASH to using CONFIG_IS_ENABLED() is not working properly. Signed-off-by: Lukasz Majewski --- Changes in v3: - Provide better Kconfig flags conditionals to avoid not compiling relavant code (there is negative diff observed after applying those patches) Changes in v2: None Buildman test code: ./tools/buildman/buildman.py -b HEAD --count=4 ls1043 --output-dir=../BUILD/ --force-build -CveE ./tools/buildman/buildman.py -b HEAD --count=4 ls1043 --output-dir=../BUILD/ -Ssdel --- arch/arm/Kconfig | 4 ++++ include/configs/ls1043a_common.h | 2 -- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig index 3b0e315061..b13173d7a0 100644 --- a/arch/arm/Kconfig +++ b/arch/arm/Kconfig @@ -1407,6 +1407,8 @@ config TARGET_LS1043AQDS select BOARD_LATE_INIT select SUPPORT_SPL select FSL_DDR_INTERACTIVE if !SPL + select FSL_DSPI if !SPL_NO_DSPI + select DM_SPI_FLASH if FSL_DSPI && !SPL_NO_DSPI imply SCSI imply SCSI_AHCI help @@ -1421,6 +1423,8 @@ config TARGET_LS1043ARDB select BOARD_EARLY_INIT_F select BOARD_LATE_INIT select SUPPORT_SPL + select FSL_DSPI if !SPL_NO_DSPI + select DM_SPI_FLASH if FSL_DSPI && !SPL_NO_DSPI help Support for Freescale LS1043ARDB platform. diff --git a/include/configs/ls1043a_common.h b/include/configs/ls1043a_common.h index 70447a2183..fd8bf705cd 100644 --- a/include/configs/ls1043a_common.h +++ b/include/configs/ls1043a_common.h @@ -165,9 +165,7 @@ /* DSPI */ #ifndef SPL_NO_DSPI -#define CONFIG_FSL_DSPI #ifdef CONFIG_FSL_DSPI -#define CONFIG_DM_SPI_FLASH #define CONFIG_SPI_FLASH_STMICRO /* cs0 */ #define CONFIG_SPI_FLASH_SST /* cs1 */ #define CONFIG_SPI_FLASH_EON /* cs2 */