From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id E3488C433EF for ; Tue, 5 Oct 2021 18:29:42 +0000 (UTC) Received: from phobos.denx.de (phobos.denx.de [85.214.62.61]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 585D7613AC for ; Tue, 5 Oct 2021 18:29:42 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org 585D7613AC Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=gmail.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=lists.denx.de Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 588948291E; Tue, 5 Oct 2021 20:29:40 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=gmail.com 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=gmail.com header.i=@gmail.com header.b="Njvad6rZ"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 403E282D7C; Tue, 5 Oct 2021 20:29:38 +0200 (CEST) Received: from mail-ot1-x335.google.com (mail-ot1-x335.google.com [IPv6:2607:f8b0:4864:20::335]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits)) (No client certificate requested) by phobos.denx.de (Postfix) with ESMTPS id 39C67807CD for ; Tue, 5 Oct 2021 20:29:34 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=mr.nuke.me@gmail.com Received: by mail-ot1-x335.google.com with SMTP id c6-20020a9d2786000000b005471981d559so21707otb.5 for ; Tue, 05 Oct 2021 11:29:34 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=subject:to:cc:references:from:message-id:date:user-agent :mime-version:in-reply-to:content-language:content-transfer-encoding; bh=C3R/BhqfR7XAsayEraUSZtu+dQADOAEyCOMjJ1yHttk=; b=Njvad6rZ2gZ4hYDeII0y90eQnTosoqZ5x9iTqXVXJ77uvMEfTNALzBnYa8QlwYY5at zb2WbmdVgPZ4XHCevbW0HyXyJeE+j/aZITzDSpka79+442DbjnwGT3kXlGEr1aFCSK+c Oyg3lEqIf1DSV3TBe6sYZlwZKFf8pVG2mLo8LVmMKCKedxynm/2y3908SZUNPeWvvmLw tpcCApuy9t+T5zLOItRnZvM65hVSSoEARLGq63WZ2bO0c/wpI/oSfghlaERwQRetRbzz /Ruu5DNZD20d+Lwtezes0E8eq2ZE9xX2rCN0sbE5zPrGcR4bmTRhHBeGY1KpD3s1WyW2 UWCQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:subject:to:cc:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=C3R/BhqfR7XAsayEraUSZtu+dQADOAEyCOMjJ1yHttk=; b=n5vn3r+cF3q1Yn84mkNG14VySlBD80G8F1acIgVcvuVfwOIp0WC3NRMqy5wwvR2oim 4BQFvacQ0B/MMIXNAAOZTuQW8QKcSlypCGq4hcpOx+iE+5yG8ws2mXpekdIQ6Kgdjkwm hVhFYlouTeqrFH2KCYDLUD0eAFB3aNrBrGbCaE/XnNz9fYowAxTDyx67mTZcd+J/yrjK 3aPWbSJSROgld5+FxHqQHXtIp/kk1STFpoSY8LH3F3kkGbfo3d63tHcZG8KQvunGHTX3 4/tzINTJZ+PV9HO/r1BSn6YgaWYZG7FQTosuZasTVbJ4idnas4iictUWIqpMhBQvWbpQ Gerw== X-Gm-Message-State: AOAM531QcMcZrWsrMqHTyoC/DEv/wJ/U5UzQGdV/v+Cfazk4jbeWNSty jqPN9qyu6JOHm/lOEMXK3fo= X-Google-Smtp-Source: ABdhPJxzHtiC4cWi2ah8yvHkG3WpS5hG9OfYUoOQGyEFL85P5bwDniMa5Eb1kvIM1nLrJBO7l9ICRQ== X-Received: by 2002:a05:6830:1090:: with SMTP id y16mr15207905oto.317.1633458572803; Tue, 05 Oct 2021 11:29:32 -0700 (PDT) Received: from nuclearis3.gtech (c-98-195-139-126.hsd1.tx.comcast.net. [98.195.139.126]) by smtp.gmail.com with ESMTPSA id c21sm3408951oiy.18.2021.10.05.11.29.31 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Tue, 05 Oct 2021 11:29:32 -0700 (PDT) Subject: Re: [PATCH v5 09/29] image: Use Kconfig to enable CONFIG_FIT_VERBOSE on host To: Simon Glass , U-Boot Mailing List Cc: Andre Przywara , Rasmus Villemoes , Robert Marko , Masahiro Yamada , Tom Rini , Joe Hershberger , Marek Vasut References: <20210926014342.127913-1-sjg@chromium.org> <20210925194327.v5.9.I0481c8d9b6f4bd7e467d0324c81295dd0a9bbc96@changeid> From: "Alex G." Message-ID: Date: Tue, 5 Oct 2021 13:29:31 -0500 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.8.1 MIME-Version: 1.0 In-Reply-To: <20210925194327.v5.9.I0481c8d9b6f4bd7e467d0324c81295dd0a9bbc96@changeid> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.34 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.103.2 at phobos.denx.de X-Virus-Status: Clean On 9/25/21 8:43 PM, Simon Glass wrote: > Add a host Kconfig for FIT_VERBOSE. With this we can use > CONFIG_IS_ENABLED(FIT_VERBOSE) directly in the host build, so drop the s/host build/ tools build/ > forcing of this in the image.h header. > > Signed-off-by: Simon Glass Reviewed-by: Alexandru Gagniuc > --- > > Changes in v5: > - Use TOOLS_ instead of HOST_ > > include/image.h | 5 ++--- > tools/Kconfig | 5 +++++ > 2 files changed, 7 insertions(+), 3 deletions(-) > > diff --git a/include/image.h b/include/image.h > index f09eb9de516..6efbef06e64 100644 > --- a/include/image.h > +++ b/include/image.h > @@ -28,7 +28,6 @@ struct fdt_region; > #include > > /* new uImage format support enabled on host */ > -#define CONFIG_FIT_VERBOSE 1 /* enable fit_format_{error,warning}() */ > #define CONFIG_FIT_RSASSA_PSS 1 > > #define IMAGE_ENABLE_IGNORE 0 > @@ -1458,7 +1457,7 @@ int fit_image_cipher_get_algo(const void *fit, int noffset, char **algo); > > struct cipher_algo *image_get_cipher_algo(const char *full_name); > > -#ifdef CONFIG_FIT_VERBOSE > +#if CONFIG_IS_ENABLED(FIT_VERBOSE) > #define fit_unsupported(msg) printf("! %s:%d " \ > "FIT images not supported for '%s'\n", \ > __FILE__, __LINE__, (msg)) I think if we made this a higher level message, like debug, or spew. we wouldn't need to #ifdef it out with a CONFIG in the first place. > @@ -1470,7 +1469,7 @@ struct cipher_algo *image_get_cipher_algo(const char *full_name); > #else > #define fit_unsupported(msg) > #define fit_unsupported_reset(msg) > -#endif /* CONFIG_FIT_VERBOSE */ > +#endif /* FIT_VERBOSE */ > #endif /* CONFIG_FIT */ > > #if !defined(USE_HOSTCC) > diff --git a/tools/Kconfig b/tools/Kconfig > index 747d221803f..9d1c0efd40c 100644 > --- a/tools/Kconfig > +++ b/tools/Kconfig > @@ -45,6 +45,11 @@ config TOOLS_FIT_SIGNATURE_MAX_SIZE > depends on TOOLS_FIT_SIGNATURE > default 0x10000000 > > +config TOOLS_FIT_VERBOSE > + def_bool y > + help > + Support verbose FIT output in the tools builds > + > config TOOLS_MD5 > def_bool y > help >