From patchwork Mon Aug 23 07:37:49 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Michal Simek X-Patchwork-Id: 1519564 X-Patchwork-Delegate: monstr@monstr.eu 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; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=monstr-eu.20150623.gappssmtp.com header.i=@monstr-eu.20150623.gappssmtp.com header.a=rsa-sha256 header.s=20150623 header.b=jMptjn3a; 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)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 4GtPHY1MsGz9sWS for ; Mon, 23 Aug 2021 17:38:33 +1000 (AEST) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 104C18314B; Mon, 23 Aug 2021 09:38:19 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=fail (p=none dis=none) header.from=xilinx.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=monstr-eu.20150623.gappssmtp.com header.i=@monstr-eu.20150623.gappssmtp.com header.b="jMptjn3a"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id D1ED68314B; Mon, 23 Aug 2021 09:38:08 +0200 (CEST) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on phobos.denx.de X-Spam-Level: X-Spam-Status: No, score=-1.6 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,SPF_HELO_NONE,SPF_NONE autolearn=no autolearn_force=no version=3.4.2 Received: from mail-ed1-x534.google.com (mail-ed1-x534.google.com [IPv6:2a00:1450:4864:20::534]) (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 E2CC583151 for ; Mon, 23 Aug 2021 09:38:02 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=fail (p=none dis=none) header.from=xilinx.com Authentication-Results: phobos.denx.de; spf=none smtp.mailfrom=monstr@monstr.eu Received: by mail-ed1-x534.google.com with SMTP id q17so2899557edv.2 for ; Mon, 23 Aug 2021 00:38:02 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=monstr-eu.20150623.gappssmtp.com; s=20150623; h=sender:from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=SMI8ovQA4zh4qZZJUDbrgkCZRkM7+q1y6Ohp3X70qZk=; b=jMptjn3aqhbTsM1jg4UhXmxS5lDIZnqoszEeEQ+jDO9YuvNQNlRSOg1z4nPl6u6KtV krxTOLi3EmEBSpuyGs3y+i7wSCTtIMNy9jlHoS/sQMGujX2vSi1HxhBuDC7BjubdEbFV t3yT2DJ5IQeHSzfrRYRY/NMu1xoTLEN1isMf9CSlVPTfS6ZEpH82KYDMqZ7c82iqH4h2 JUhxwxa6rRsh2+isVF1H6lPEly/gKOIkAccp5fK+BuRvYDgPYlKX0jNU/+yTNdLYkSe4 WoCa3N/hhxD/gdbnPkKnypzxM/sUyPq148ba2wfijg/+q/PyOy9EgFtuABHVT2jIjfDA 8rnQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=SMI8ovQA4zh4qZZJUDbrgkCZRkM7+q1y6Ohp3X70qZk=; b=pj6h9A4ros6ajfhnxJ8NVodqPhugqq/MG2E1X8yYgD1CKVXjNe9G4BaWpn34fC5cj8 TBxV500JiGmTo7mzXvvF7ZPNWtyr8l1WgPIxmTvpw/uZcLcLfw1IX34A1Ai/qygjPMuL 4kBbQ4MRliU4Dcp12me0KoJlKag2gOZ9NQzw91ARl5+JOBV2181SQZN/d/YYJU4c1Ozp sVXHU0AiPdP5k5TYedPnhfrtdxsCuYY42GE1bo89GgkvPkdeDfUCQR0cMrTZSC5MLeob eCogujLVpMzqnl9AlhMdij/PFkarx/MgsvKT1GxZfQgUq4K587CF9h0ZwJ05pwnWCTA1 kDYA== X-Gm-Message-State: AOAM5315eQMofeIm1ylfIwVkB3do2EQWW+bjEnBjFkoKQapzraH1jrRx NGLnOHNxCZ5PSo3Rh1i1mc4GzA== X-Google-Smtp-Source: ABdhPJyoEy4uHCqL3Nx76wzGPTryXuzTb9+2sOvo+kWCnkcS5SJJRAogwXbiX9joUWOiFZObG7hCRA== X-Received: by 2002:a05:6402:3589:: with SMTP id y9mr36126853edc.247.1629704282565; Mon, 23 Aug 2021 00:38:02 -0700 (PDT) Received: from localhost ([2a02:768:2307:40d6:f666:9af6:3fed:e53b]) by smtp.gmail.com with ESMTPSA id c17sm8710733edu.11.2021.08.23.00.38.02 (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Mon, 23 Aug 2021 00:38:02 -0700 (PDT) From: Michal Simek To: andre.przywara@arm.com, u-boot@lists.denx.de, git@xilinx.com Cc: Ashok Reddy Soma , Michal Simek , Simon Glass , T Karthik Reddy Subject: [PATCH 02/10] xilinx: Use variable for passing board_name Date: Mon, 23 Aug 2021 09:37:49 +0200 Message-Id: X-Mailer: git-send-email 2.33.0 In-Reply-To: References: MIME-Version: 1.0 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 Use variable which points to DEVICE_TREE by default. The reason for this change is to enable DTB_RESELECT and MULTI_DTB_FIT where board detection can be used for change DTB at run time. That's why there must be reference in board_fit_config_name_match() via variable instead of hardcoding it which is sufficient for that use case. Signed-off-by: Michal Simek --- Changes in v2: None board/xilinx/common/board.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/board/xilinx/common/board.c b/board/xilinx/common/board.c index 1458b31c21a9..db9705c1b7e4 100644 --- a/board/xilinx/common/board.c +++ b/board/xilinx/common/board.c @@ -436,11 +436,13 @@ int board_late_init_xilinx(void) } #endif +static char *board_name = DEVICE_TREE; + int __maybe_unused board_fit_config_name_match(const char *name) { - debug("%s: Check %s, default %s\n", __func__, name, DEVICE_TREE); + debug("%s: Check %s, default %s\n", __func__, name, board_name); - if (!strcmp(name, DEVICE_TREE)) + if (!strcmp(name, board_name)) return 0; return -1;