From patchwork Wed Mar 25 13:47:00 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Niel Fourie X-Patchwork-Id: 1261397 X-Patchwork-Delegate: sjg@chromium.org 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=2a01:238:438b:c500:173d:9f52:ddab:ee01; helo=phobos.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 Authentication-Results: ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=denx.de header.i=@denx.de header.a=rsa-sha256 header.s=phobos-20191101 header.b=OJM+ic1t; dkim-atps=neutral Received: from phobos.denx.de (phobos.denx.de [IPv6:2a01:238:438b:c500:173d:9f52:ddab:ee01]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 48nTvR71nZz9sQx for ; Thu, 26 Mar 2020 00:47:31 +1100 (AEDT) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 2F4D281813; Wed, 25 Mar 2020 14:47:25 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=none (p=none dis=none) header.from=denx.de Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=denx.de; s=phobos-20191101; t=1585144045; bh=v/7PDKExUeUrX6g4JqgAW8kMP4pT9N3yJwFuuQRR2gg=; h=From:To:Cc:Subject:Date:List-Id:List-Unsubscribe:List-Archive: List-Post:List-Help:List-Subscribe:From; b=OJM+ic1tm1eodxkgiVyCURVtui9z2eX2hqBSWBH1AUf1ptDNGbAgmU52rxC6zLXs/ CcdG2HTtExDgqBaF3od19U6/xK/WfyV3oYC/dU+0WuKShXBbWV18ksscVAez8E+Btl PG/KnMKqhSkR65Acw7wBg8Yk2SrDDYJ84J2fGq7pICk2HxDxib7fmIJU1hKiBUhbgo dW+f0dpWGNI9aNM+VVzsLxXRQRt83CKuTAdCefrKBfoFJJSUEcaDhq7NwIjCNs9b27 wnqyrTroc3NHMTOC+/M6MP6KGLQEBEpwduwDjJ542veXoiCSsxF1eJ4I3WonTYSNbM Ao6ABflqb/Cyg== Received: by phobos.denx.de (Postfix, from userid 109) id C207981813; Wed, 25 Mar 2020 14:47:22 +0100 (CET) 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, RCVD_IN_MSPIKE_H3, RCVD_IN_MSPIKE_WL,SPF_HELO_NONE,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.2 Received: from mail-out.m-online.net (mail-out.m-online.net [212.18.0.10]) (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 200BD8183D for ; Wed, 25 Mar 2020 14:47:13 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=none (p=none dis=none) header.from=denx.de Authentication-Results: phobos.denx.de; spf=none smtp.mailfrom=lusus@denx.de Received: from frontend01.mail.m-online.net (unknown [192.168.8.182]) by mail-out.m-online.net (Postfix) with ESMTP id 48nTv45SNZz1rtyS; Wed, 25 Mar 2020 14:47:12 +0100 (CET) Received: from localhost (dynscan1.mnet-online.de [192.168.6.70]) by mail.m-online.net (Postfix) with ESMTP id 48nTv44xptz1qqkg; Wed, 25 Mar 2020 14:47:12 +0100 (CET) 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 F6xEuJhFwF1B; Wed, 25 Mar 2020 14:47:11 +0100 (CET) X-Auth-Info: tyGpYXQC0cE+mzKX1bxLBDadGhBDMV/JISfh3iDHWm0= Received: from aldebaran.denx.de (unknown [62.91.23.180]) (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; Wed, 25 Mar 2020 14:47:11 +0100 (CET) From: Niel Fourie To: u-boot@lists.denx.de Cc: sjg@chromium.org, Niel Fourie Subject: [RFC PATCH 1/1] Makefile: Expand legacy (non-DM) driver warnings Date: Wed, 25 Mar 2020 14:47:00 +0100 Message-Id: <20200325134700.2014210-1-lusus@denx.de> X-Mailer: git-send-email 2.25.1 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 Expand warnings printed by Makefile after compile when legacy drivers are in use. These include: - CONFIG_HAVE_BLOCK_DEVICE without CONFIG_BLK - CONFIG_BOOTCOUNT_LIMIT without CONFIG_DM_BOOTCOUNT - CONFIG_MTD without CONFIG_DM_MTD - CONFIG_PHYLIB without CONFIG_DM_MDIO - CONFIG_POWER, also without CONFIG_DM_PMIC - Absence of CONFIG_RAM and CONFIG_SPL_RAM Also replaced existing CONFIG_DM_SPI warning for consistency. Removed CONFIG_BLK requirement for CONFIG_DM_USB, as all USB devices not block devices. Signed-off-by: Niel Fourie Cc: Simon Glass --- Makefile | 73 +++++++++++++++++++++++++++++++++++++++++++++++++++----- 1 file changed, 67 insertions(+), 6 deletions(-) diff --git a/Makefile b/Makefile index fa687f13a5..0df58ca7c1 100644 --- a/Makefile +++ b/Makefile @@ -963,11 +963,6 @@ cmd_cfgcheck = $(srctree)/scripts/check-config.sh $2 \ all: $(ALL-y) ifeq ($(CONFIG_DEPRECATED),y) $(warning "You have deprecated configuration options enabled in your .config! Please check your configuration.") -ifeq ($(CONFIG_SPI),y) -ifneq ($(CONFIG_DM_SPI)$(CONFIG_OF_CONTROL),yy) - $(warning "The relevant config item with associated code will remove in v2019.07 release.") -endif -endif endif ifneq ($(CONFIG_DM),y) @echo >&2 "===================== WARNING ======================" @@ -988,7 +983,7 @@ ifneq ($(CONFIG_DM_MMC)$(CONFIG_OF_CONTROL)$(CONFIG_BLK),yyy) endif endif ifeq ($(CONFIG_USB),y) -ifneq ($(CONFIG_DM_USB)$(CONFIG_OF_CONTROL)$(CONFIG_BLK),yyy) +ifneq ($(CONFIG_DM_USB)$(CONFIG_OF_CONTROL),yy) @echo >&2 "===================== WARNING ======================" @echo >&2 "This board does not use CONFIG_DM_USB. Please update" @echo >&2 "the board to use CONFIG_DM_USB before the v2019.07 release." @@ -1046,6 +1041,16 @@ ifeq ($(CONFIG_OF_EMBED),y) @echo >&2 "See doc/README.fdt-control for more info." @echo >&2 "====================================================" endif +ifeq ($(CONFIG_SPI),y) +ifneq ($(CONFIG_DM_SPI)$(CONFIG_OF_CONTROL),yy) + @echo >&2 "===================== WARNING ======================" + @echo >&2 "This board uses CONFIG_SPI without having CONFIG_DM_SPI" + @echo >&2 "enabled. Please update the board before the v2019.07 release." + @echo >&2 "Failure to update by the deadline may result in board removal." + @echo >&2 "See doc/driver-model/migration.rst for more info." + @echo >&2 "====================================================" +endif +endif ifeq ($(CONFIG_SPI_FLASH),y) ifneq ($(CONFIG_DM_SPI_FLASH)$(CONFIG_OF_CONTROL),yy) @echo >&2 "===================== WARNING ======================" @@ -1078,6 +1083,62 @@ ifneq ($(CONFIG_DM_ETH),y) @echo >&2 "====================================================" endif endif +ifeq ($(CONFIG_HAVE_BLOCK_DEVICE),y) +ifneq ($(CONFIG_BLK),y) + @echo >&2 "===================== WARNING ======================" + @echo >&2 "This board uses CONFIG_HAVE_BLOCK_DEVICE but does not" + @echo >&2 "have CONFIG_BLK enabled. This implies legacy block" + @echo >&2 "device support is enabled without driver model (DM)." + @echo >&2 "====================================================" +endif +endif +ifeq ($(CONFIG_BOOTCOUNT_LIMIT),y) +ifneq ($(CONFIG_DM_BOOTCOUNT),y) + @echo >&2 "===================== WARNING ======================" + @echo >&2 "This board uses CONFIG_BOOTCOUNT_LIMIT without" + @echo >&2 "having CONFIG_DM_BOOTCOUNT enabled. This implies a" + @echo >&2 "legacy bootcounter without driver model (DM) support." + @echo >&2 "====================================================" +endif +endif +ifeq ($(CONFIG_MTD),y) +ifneq ($(CONFIG_DM_MTD),y) + @echo >&2 "===================== WARNING ======================" + @echo >&2 "This board uses CONFIG_MTD without having CONFIG_DM_MTD" + @echo >&2 "enabled. This implies legacy MTD support, without" + @echo >&2 "driver model (DM)." + @echo >&2 "====================================================" +endif +endif +ifeq ($(CONFIG_PHYLIB),y) +ifneq ($(CONFIG_DM_MDIO),y) + @echo >&2 "===================== WARNING ======================" + @echo >&2 "This board uses CONFIG_PHYLIB, without having" + @echo >&2 "CONFIG_DM_MDIO enabled. This implies legacy ethernet" + @echo >&2 "phy support, without driver model (DM)." + @echo >&2 "====================================================" +endif +endif +ifeq ($(CONFIG_POWER),y) + @echo >&2 "===================== WARNING ======================" + @echo >&2 "This board uses CONFIG_POWER which enables the legacy" + @echo >&2 "pre-DM PMIC support." +ifneq ($(CONFIG_DM_PMIC),y) + @echo >&2 "CONFIG_DM_PMIC is disabled, therefore no driver model" + @echo >&2 "(DM) PMIC support is enabled." +endif + @echo >&2 "====================================================" +endif +ifneq ($(CONFIG_RAM),y) +ifneq ($(CONFIG_SPL_RAM),y) + @echo >&2 "===================== WARNING ======================" + @echo >&2 "This board does not use CONFIG_RAM or CONFIG_SPL_RAM" + @echo >&2 "This implies legacy memory configuration code is in" + @echo >&2 "use, without driver model (DM) support." + @echo >&2 "====================================================" +endif +endif + @# Check that this build does not use CONFIG options that we do not @# know about unless they are in Kconfig. All the existing CONFIG @# options are whitelisted, so new ones should not be added.