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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 82C3BECAAD3 for ; Wed, 31 Aug 2022 07:38:06 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230048AbiHaHiE (ORCPT ); Wed, 31 Aug 2022 03:38:04 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:38788 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229978AbiHaHh6 (ORCPT ); Wed, 31 Aug 2022 03:37:58 -0400 Received: from mail-lf1-x133.google.com (mail-lf1-x133.google.com [IPv6:2a00:1450:4864:20::133]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 77644B8F05 for ; Wed, 31 Aug 2022 00:37:55 -0700 (PDT) Received: by mail-lf1-x133.google.com with SMTP id g7so1789450lfe.11 for ; Wed, 31 Aug 2022 00:37:55 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=content-transfer-encoding:in-reply-to:from:references:cc:to :content-language:subject:user-agent:mime-version:date:message-id :from:to:cc; bh=yV0Q/B0XwshgejdYWiZZL4lEpfYH4+n29m2VXh7RRNk=; b=Mpb/fFsJGrIPxVaNtfFLx695Ajlwkj/6pjPubbDa2vX34HXKOSRtX3pH/roJ8thsWJ 7ki51ZrQSa6VVJ9k5Gy6PJtbf5WaVlRNIT2ewDJEh3THVRNGSsRA3j4hGh0fnh/z60lG xYl00kkiMj+a2JvQxVKmmKJnfDEa9IR+ooAC1W8YKqQdR2CyEEti0xXZESkMhGoNy0Nk RFfjs0TvU9V5pCPHUMlukGeR4Zknvb5dc5dlPJgSAJ4XJmxtoJbbMmSqAna14kt88YMi RtFtKN1m9JjpvH9+Lm8cwO+PZgifUid5rXz3oK9cbOWI7ZslDU7EPO86NNbJ+YTeTA0v gBvQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:in-reply-to:from:references:cc:to :content-language:subject:user-agent:mime-version:date:message-id :x-gm-message-state:from:to:cc; bh=yV0Q/B0XwshgejdYWiZZL4lEpfYH4+n29m2VXh7RRNk=; b=5ErVgIBUwvzbMqHshY++qQfTMrWl0XW+IW0zQBcOosmWo+3Qu4zvDuJBU9WxSQ78BZ OkpoyYrj3W5QjIrobtzF3GHUCFIZ/PlRknjL/0+aU0aogGYOqjiSX2hOppQMUYZ/fYpp nhZBPje93Cj1coZo/yuXtL0pB3KpNrGAzSoIapzEcWOH6CgpVYhCiQh4Auo5o37rK/q+ 9k4aNJxlfWPj+UigYHjzum3HD/i8B6f3Ns96Q5P+anzbu7/9fbe/TNXQAD5Qd7Pxa5jq efgUZKZbcBQBRw51zybBgaZQieTNwstg6SH5INdVznhUcbLG6MtaSxm5gIPFZJhWL5FT Mgmw== X-Gm-Message-State: ACgBeo3kBfREPLVQGjU1khS+zzXW7xDR0C2paohrDdEY6+Mfzk1TP0QJ Ecx1qZSDLl9h6pqjVrRKKWdO3g== X-Google-Smtp-Source: AA6agR5boSacIQqXB/d2C7VV98i93eO6195dqw6oNKs9ez+yXfxtG4ZM3h9pwXz9k+QFVj5F3myy2w== X-Received: by 2002:a05:6512:92f:b0:494:7095:135f with SMTP id f15-20020a056512092f00b004947095135fmr3223951lft.242.1661931473787; Wed, 31 Aug 2022 00:37:53 -0700 (PDT) Received: from [192.168.28.124] (balticom-73-99-134.balticom.lv. [109.73.99.134]) by smtp.gmail.com with ESMTPSA id a3-20020ac25e63000000b004947fbc5d28sm434943lfr.303.2022.08.31.00.37.52 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Wed, 31 Aug 2022 00:37:53 -0700 (PDT) Message-ID: Date: Wed, 31 Aug 2022 10:37:51 +0300 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.13.0 Subject: Re: [PATCH v1 08/14] dt-bindings: mtd: relax the nvmem compatible string Content-Language: en-US To: Michael Walle , Miquel Raynal , Richard Weinberger , Vignesh Raghavendra , Rob Herring , Krzysztof Kozlowski , Srinivas Kandagatla , Shawn Guo , Li Yang , =?UTF-8?B?UmFmYcWCIE1pxYJlY2tp?= , "David S . Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , Frank Rowand Cc: linux-mtd@lists.infradead.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, netdev@vger.kernel.org, Ahmad Fatoum References: <20220825214423.903672-1-michael@walle.cc> <20220825214423.903672-9-michael@walle.cc> From: Krzysztof Kozlowski In-Reply-To: <20220825214423.903672-9-michael@walle.cc> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 26/08/2022 00:44, Michael Walle wrote: > The "user-otp" and "factory-otp" compatible string just depicts a > generic NVMEM device. But an actual device tree node might as well > contain a more specific compatible string. Make it possible to add > more specific binding elsewere and just match part of the compatibles typo: elsewhere > here. > > Signed-off-by: Michael Walle > --- > Documentation/devicetree/bindings/mtd/mtd.yaml | 7 ++++--- > 1 file changed, 4 insertions(+), 3 deletions(-) > > diff --git a/Documentation/devicetree/bindings/mtd/mtd.yaml b/Documentation/devicetree/bindings/mtd/mtd.yaml > index 376b679cfc70..0291e439b6a6 100644 > --- a/Documentation/devicetree/bindings/mtd/mtd.yaml > +++ b/Documentation/devicetree/bindings/mtd/mtd.yaml > @@ -33,9 +33,10 @@ patternProperties: > > properties: > compatible: > - enum: > - - user-otp > - - factory-otp > + contains: > + enum: > + - user-otp > + - factory-otp This does not work in the "elsewhere" place. You need to use similar approach as we do for syscon or primecell. > > required: > - compatible Best regards, Krzysztof