Received: by 2002:ac0:da4c:0:0:0:0:0 with SMTP id a12csp358185imi; Thu, 21 Jul 2022 02:17:09 -0700 (PDT) X-Google-Smtp-Source: AGRyM1s9XbDgXWrHomz1II8XY5smQCV5ZGX7eXqQfIicjnZtX8bja3cttyihn/stxxeEN4/1XXRB X-Received: by 2002:a63:d14b:0:b0:419:57b9:d444 with SMTP id c11-20020a63d14b000000b0041957b9d444mr38053232pgj.619.1658395029256; Thu, 21 Jul 2022 02:17:09 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1658395029; cv=none; d=google.com; s=arc-20160816; b=QusB3aoFgT6eWhu52VYzQowqpSOEiWW2efMlDdINnun9koNKQuzhHBL42lrCBG1Q63 QelHIRQ4IN35Y634B20DJEPIkIJQE1GHZKy7SnKbWx3yLkRZwXbl0crj56J4DKu9ObDu EvfzjebRmxhItZetzg5SAznIA0eQ3mW3d4G1zTfYHev9qj9iBnRJyHM5IVEbmKVCRpyY YKy9dXmdosmN05k605pd3f0CuHqdCWmgS3MfP1XMXEwehdW1ljpe5OGxOYFt8QsdwqlQ c/zzX/lApMNu2cWsLo+LzxSrkUTzVI2gwZwBO+hdXIUZ1NsQM9AtHQng4TD8cNVyDefD MyYQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:message-id:date:references :in-reply-to:subject:cc:to:from:dkim-signature; bh=/H+ubGz5dC0Dz+m1egBSS+mn3sw5UpB8w1f81HptlFo=; b=ZH1cB1OItqm9Oej1NjinjeyLup3xV2wX8fknc4DCHeiBGVi7u3Oz4Vl/Q+Q5g+xoru AzPFSipg+b1VuOI99im/5WmNjqb15lXEw6bSwXgjO4ZxDKyQWvGLK3gQJfKof5Zq/NLp wTBuowx36GwZWZ5+HzfZ2g1TUAJoTYwzyKYIvGMR4kvxdpcP0qMEasT56byVf6iE0nQx clVTfIvcVJcfugcVU3eF5XkZhDHb9Wk7u4WW1ud5dQjLvFYYJeArZ4uany4uzblE4o5n B/Zy73QEf+WjuDB2ahbnwi+T0NFnRQII9mlnzVJgTEKQX9xqXUOFaJwvOXeW5Ex24zq4 ypig== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@baylibre-com.20210112.gappssmtp.com header.s=20210112 header.b=D0wGWDqC; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id ob14-20020a17090b390e00b001f0671d0d3fsi6409728pjb.149.2022.07.21.02.16.53; Thu, 21 Jul 2022 02:17:09 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@baylibre-com.20210112.gappssmtp.com header.s=20210112 header.b=D0wGWDqC; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232768AbiGUJGs (ORCPT + 99 others); Thu, 21 Jul 2022 05:06:48 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:39792 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232435AbiGUJGq (ORCPT ); Thu, 21 Jul 2022 05:06:46 -0400 Received: from mail-wm1-x329.google.com (mail-wm1-x329.google.com [IPv6:2a00:1450:4864:20::329]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 5BA562F64C for ; Thu, 21 Jul 2022 02:06:45 -0700 (PDT) Received: by mail-wm1-x329.google.com with SMTP id a11so655608wmq.3 for ; Thu, 21 Jul 2022 02:06:45 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20210112.gappssmtp.com; s=20210112; h=from:to:cc:subject:in-reply-to:references:date:message-id :mime-version; bh=/H+ubGz5dC0Dz+m1egBSS+mn3sw5UpB8w1f81HptlFo=; b=D0wGWDqCWVf1ogvzp2scTFOcL/n/BMEgsTofv86DsSTkPtAJuQsI83k7g+ea2/xTwQ aI8aQ9xBbDoOqQ5HJIENAZCvvpuIuNc0skABIW5X+dF/ISz+o6oMNsblkkia9J5AZedK i1y3HXa+oWE2R64nyu9rYveTvuz0cb5odonsNSBEx+cwUiSPpkiGVPKv+peVdCd6QB3d OtgnnK4tBoOJsH602xwzjG1GygYAmo2MkVu23eWuqc5iZFp0sPMmFleasSQjSUwtBoAI yE+DInYb6Y7WwG1PbJk9v2V3UK6GMrfcKtTGnRUskE8dqSv80KIp37ZBuWUxeHQGh8H3 9VhQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:in-reply-to:references:date :message-id:mime-version; bh=/H+ubGz5dC0Dz+m1egBSS+mn3sw5UpB8w1f81HptlFo=; b=sYFbNvA2EpO9owP15p/DyWGhFwGv9gCnNngLvTGgqbxyyBCO8N1em0+JXahoH79JqM lDEcSQ9+GQ6vjySGHTCvW/4PQvcRrVt6OaB1Ete1JJZzhtd9w7nUV27vSuPLl6ij6ws/ Kiql7WkwLs7lV/cfrIVJr2df2h011LrKqQAnCTZxXdQAnuRHAyCDRWwztxIqMS5UsZcD thPYmRoho3Hby1Ml40VQ4ToJ9/CmaKW8r9vX3ACYU+oibpvAI9m1friJWtaSQNsSZGVc 4vCGf7n8nhe/1anlwVEnu8v5Fps6l/ZtpmjhQ7/TxM9VtOQh4tO8H9XJGnCS49sMQszx Y3rw== X-Gm-Message-State: AJIora+/mbhmWDEYO3dz119+SrsAiXHPIUKxJLj0G4Su5XuDUc6AfvwO KlfIwXZRaVm+yes7LgkM8vchhg== X-Received: by 2002:a05:600c:5006:b0:3a3:2dcd:8730 with SMTP id n6-20020a05600c500600b003a32dcd8730mr3710520wmr.99.1658394403779; Thu, 21 Jul 2022 02:06:43 -0700 (PDT) Received: from localhost ([82.66.159.240]) by smtp.gmail.com with ESMTPSA id q15-20020a5d658f000000b0021e48faed68sm1225231wru.97.2022.07.21.02.06.43 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 21 Jul 2022 02:06:43 -0700 (PDT) From: Mattijs Korpershoek To: Krzysztof Kozlowski , Rob Herring , Krzysztof Kozlowski , Dmitry Torokhov , Matthias Brugger Cc: linux-kernel@vger.kernel.org, linux-input@vger.kernel.org, Fabien Parent , devicetree@vger.kernel.org, linux-mediatek@lists.infradead.org, Fabien Parent , linux-arm-kernel@lists.infradead.org Subject: Re: [PATCH v1 2/6] dt-bindings: mediatek,mt6779-keypad: use unevaluatedProperties In-Reply-To: References: <20220720-mt8183-keypad-v1-0-ef9fc29dbff4@baylibre.com> <20220720-mt8183-keypad-v1-2-ef9fc29dbff4@baylibre.com> Date: Thu, 21 Jul 2022 11:06:42 +0200 Message-ID: <874jzaj0m5.fsf@baylibre.com> MIME-Version: 1.0 Content-Type: text/plain X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Jul 20, 2022 at 19:14, Krzysztof Kozlowski wrote: > On 20/07/2022 16:48, Mattijs Korpershoek wrote: >> writing-bindings.rst states: >>> - If schema includes other schema (e.g. /schemas/i2c/i2c-controller.yaml) use >>> "unevaluatedProperties:false". In other cases, usually use >>> "additionalProperties:false". >> >> mt6779-keypad includes matrix-keymap.yaml so replace additionalProperties:false >> by unevaluatedProperties:false. > > This is not sufficient explanation. You now allow all properties from > matrix-keymap.yaml, which might be desired or might be not (e.g. they > are not valid for this device). Please investigate it and mention the > outcome. Hi Krzysztof, Thank you for your prompt review. In mt6779_keypad_pdrv_probe(), we call * matrix_keypad_parse_properties() which requires keypad,num-rows and keypad,num-cols. * matrix_keypad_build_keymap() which uses linux,keymap Therefore, all properties from matrix-keymap.yaml are required by the mt6779-keypad driver. In v2, I will add the above justification and also add all 3 properties in the "required" list. Initially, I did not do this because from a dts/code perspective it seemed interesting to split out SoC specific keyboard node vs board specific key configuration: * [PATCH v1 5/6] arm64: dts: mediatek: mt8183: add keyboard node # SoC specific * [PATCH v1 6/6] arm64: dts: mediatek: mt8183-pumpkin: add keypad support # board specific What would be the recommend approach for above? I see at least 2: * "move the whole keyboard node into the board file (mt8183-pumpkin.dts)" even if it generates duplication between boards using the same SoC. * "add a "dummy keymap,row,cols" properties in the soc node which can be overriden in board file. For example, use rows and cols = 0 which would have the driver early exit. Thanks, Mattijs > > Best regards, > Krzysztof