Received: by 2002:a05:7412:e794:b0:fa:551:50a7 with SMTP id o20csp1204352rdd; Wed, 10 Jan 2024 11:51:36 -0800 (PST) X-Google-Smtp-Source: AGHT+IGewxiWRv282JDYO/bG0nu6WN8M8Xb18o8xce81+mpv/UcndGBkFAmWRpJXI+WQyJizMDXx X-Received: by 2002:a17:90b:1917:b0:28d:bca7:d9d4 with SMTP id mp23-20020a17090b191700b0028dbca7d9d4mr41159pjb.12.1704916296685; Wed, 10 Jan 2024 11:51:36 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1704916296; cv=none; d=google.com; s=arc-20160816; b=vWuFCnlQUjyiojRCwF0ZQeXzJ6cB9H2/dclh2vSBge6oRbGqmy/VaUjNEzZfoZy4WB LWN8OXu3veVHb8gSQWoIk289/QWZNQmRdP+KW9CRCn6meV4vyJTEbmCutTKD8cTdBK9Z 5RcBIJkFp2VlI7kLvUF7V7owU8jcKCCzOS4k5eS5WEv0EkMVvrDGltvWd/iM8IP6C1MK YgHHirE3U7n65r8i+Rpc828y+U4TRGnLX6KoZLmWo7A4Lt9dNtyF3j8DQ5TKvJDiPemQ MKTEVp/AvGqfGALLX26VyDuicgEZo6BoY0xUPPNZtH7Q359gqXxsmL8U/w7HjvovrA2A VrPQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:in-reply-to:message-id :date:subject:cc:to:from:dkim-signature; bh=8tQFXGB0UBE3yQVmYcImKXXjk/ehD/gF98AYs7jrXzE=; fh=cIqT9NcZdjUqupo3CRF2zie7E78k65IMo1it3Fi0alA=; b=Ob9iJfhBsoc7O8fCtztVP6j5y7sc7UYQXk2LbqUXa6rORkXwGwZmjrsSB/JDAAEwbX Nk8Yuz+HBDthDZoRz+qP0Fn3SQJZnLa02hRKqkorGU4ZKjW7ePYxSai+jENoDIhNSNqv RktgYq+bp5fDtStb4ECpy04pAjftHXWlMhRueLXwb2B1klGTp+ACqaa+PqtrA9yG8GBQ 3M6eoCr6RLScfgXK3PRkYzyuijU5GshkuQSs19gviA3qtwI3TMdNboZlAbeOvSu9GI0o EumV8ly/PgABnJklL19Q0Ds0hBjbj5lGgvJ2cjtBs7+2DExWXrJySKHxIKPNy/xNQXUT gL0g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@baylibre-com.20230601.gappssmtp.com header.s=20230601 header.b="yKV/+Qfr"; spf=pass (google.com: domain of linux-kernel+bounces-22672-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-22672-linux.lists.archive=gmail.com@vger.kernel.org" Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [2604:1380:45e3:2400::1]) by mx.google.com with ESMTPS id q24-20020a17090aa01800b0028d946d7935si2113491pjp.140.2024.01.10.11.51.36 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 10 Jan 2024 11:51:36 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-22672-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) client-ip=2604:1380:45e3:2400::1; Authentication-Results: mx.google.com; dkim=pass header.i=@baylibre-com.20230601.gappssmtp.com header.s=20230601 header.b="yKV/+Qfr"; spf=pass (google.com: domain of linux-kernel+bounces-22672-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-22672-linux.lists.archive=gmail.com@vger.kernel.org" Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sv.mirrors.kernel.org (Postfix) with ESMTPS id 78A5F284DE5 for ; Wed, 10 Jan 2024 19:51:35 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 0F94D4E1DC; Wed, 10 Jan 2024 19:51:15 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=baylibre-com.20230601.gappssmtp.com header.i=@baylibre-com.20230601.gappssmtp.com header.b="yKV/+Qfr" Received: from mail-oo1-f44.google.com (mail-oo1-f44.google.com [209.85.161.44]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id D09D84EB26 for ; Wed, 10 Jan 2024 19:51:11 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=baylibre.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=baylibre.com Received: by mail-oo1-f44.google.com with SMTP id 006d021491bc7-5955a4a9b23so2450117eaf.1 for ; Wed, 10 Jan 2024 11:51:11 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20230601.gappssmtp.com; s=20230601; t=1704916271; x=1705521071; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=8tQFXGB0UBE3yQVmYcImKXXjk/ehD/gF98AYs7jrXzE=; b=yKV/+Qfriqeu0qBj16IXEt1rSLw90lnlhjOy+tyC7v7TdhP6uGBuPEMCUXuy1c4O7t avMDDkMYaHi7r3eppgI2HoVRyNAxiTYvpiisrGng2hZn609pSm9uAgau+o0nDORZYyRF S7wrVb3HuSBn9M4f41ZLCyXDvAMNwS/bZz7rkfhFi0cBecwBe8GMG+PnCG4yV7bUUbDc Ao0Mz4cbNDXxNtB/sp/GBvFVqhBqNVJEX+E4dAwSxlI3qJwx9X2jbEroAcAGoVgsP7xa yaP2LVm/b9zkPJ9n/zYrm6TZ2OUzZBl1jPuIKCYquxUU5+taZlpjjC3jlL72wx4FYUiz 1mCA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1704916271; x=1705521071; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=8tQFXGB0UBE3yQVmYcImKXXjk/ehD/gF98AYs7jrXzE=; b=wCD0Tir6Sp4v+C4fNYdwJJa3FT8+ce5BPHqiBRrOGNRVPvzEOaJY5003bkp7AXAKEf JFgSkztujKEOUWYOa7QaZ/R1Li+KlfAOUrrj1Dm2Lgw/aDq5MLBS69CULajhaDUJ3A5M jIGPHjHW+P28MYg1baFs8Ym33e+0ebZKbzapnleocoHtaKLLaKIcGUwZJH4bpf/Slrus 9zYlsB2N6SGMNrbTFXzdECgbmFCpoxJNYMSN93qXND3+jQkUdoIuLKl3mL/O//JjOZxX 1SX66ny+/ZPwLiMv3lRm0++jdEOq7TZzVQmqD3/mU8m96Ix1kCc1hW0o36kl0dG+Ksds 7W3A== X-Gm-Message-State: AOJu0YyydR1qmxkvL1OgB611pD7h6iM274uRq+2+euF6TuqRpwWzOl/e kreZW3xxKgkJO3YbF295SkuxGCwxX6Nnfg== X-Received: by 2002:a05:6820:2382:b0:591:acf8:d08f with SMTP id co2-20020a056820238200b00591acf8d08fmr140554oob.11.1704916270980; Wed, 10 Jan 2024 11:51:10 -0800 (PST) Received: from freyr.lechnology.com (ip98-183-112-25.ok.ok.cox.net. [98.183.112.25]) by smtp.gmail.com with ESMTPSA id 187-20020a4a0dc4000000b00595b35927a3sm938513oob.39.2024.01.10.11.51.10 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 10 Jan 2024 11:51:10 -0800 (PST) From: David Lechner To: Mark Brown , Jonathan Cameron , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Michael Hennerich , =?utf-8?q?Nuno_S=C3=A1?= , Frank Rowand Cc: David Lechner , Thierry Reding , =?utf-8?q?Uwe_Kleine-K=C3=B6nig?= , Jonathan Corbet , linux-spi@vger.kernel.org, linux-iio@vger.kernel.org, devicetree@vger.kernel.org, linux-doc@vger.kernel.org, linux-pwm@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 02/13] scripts: dtc: checks: don't warn on SPI non-peripheral child nodes Date: Wed, 10 Jan 2024 13:49:43 -0600 Message-ID: <20240109-axi-spi-engine-series-3-v1-2-e42c6a986580@baylibre.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20240109-axi-spi-engine-series-3-v1-0-e42c6a986580@baylibre.com> References: <20240109-axi-spi-engine-series-3-v1-0-e42c6a986580@baylibre.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" X-Mailer: b4 0.12.4 Content-Transfer-Encoding: 8bit According to the spi-controller.yaml bindings, SPI peripheral child nodes match the pattern "^.*@[0-9a-f]+$". A SPI controller binding may require a child object node that is not a peripheral. For example, the adi,axi-spi-engine binding requires an "offloads" child node that is not a peripheral but rather a part of the controller itself. By checking for '@' in the node name, we can avoids a warnings like: Warning (spi_bus_reg): /example-0/spi@44a00000/offloads: missing or empty reg property for a binding like: spi { ... offloads { offload@0 { ... }; ... }; peripheral@0 { ... }; }; Signed-off-by: David Lechner --- scripts/dtc/checks.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/scripts/dtc/checks.c b/scripts/dtc/checks.c index 9f31d2607182..5af68642f231 100644 --- a/scripts/dtc/checks.c +++ b/scripts/dtc/checks.c @@ -1144,6 +1144,10 @@ static void check_spi_bus_reg(struct check *c, struct dt_info *dti, struct node if (!node->parent || (node->parent->bus != &spi_bus)) return; + /* only nodes with '@' in name are SPI devices */ + if (!strchr(unitname, '@')) + return; + if (get_property(node->parent, "spi-slave")) return; -- 2.43.0