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 C11B1C25B0F for ; Sat, 13 Aug 2022 16:18:57 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S240026AbiHMQS4 (ORCPT ); Sat, 13 Aug 2022 12:18:56 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60806 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S239847AbiHMQSy (ORCPT ); Sat, 13 Aug 2022 12:18:54 -0400 Received: from metis.ext.pengutronix.de (metis.ext.pengutronix.de [IPv6:2001:67c:670:201:290:27ff:fe1d:cc33]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id D7A8C1277C for ; Sat, 13 Aug 2022 09:18:53 -0700 (PDT) Received: from ptx.hi.pengutronix.de ([2001:67c:670:100:1d::c0]) by metis.ext.pengutronix.de with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1oMtqd-0004Hp-N9; Sat, 13 Aug 2022 18:18:51 +0200 Received: from ore by ptx.hi.pengutronix.de with local (Exim 4.92) (envelope-from ) id 1oMtqc-0005va-Da; Sat, 13 Aug 2022 18:18:50 +0200 Date: Sat, 13 Aug 2022 18:18:50 +0200 From: Oleksij Rempel To: Andrew Lunn Cc: Woojung Huh , Florian Fainelli , netdev@vger.kernel.org, linux-kernel@vger.kernel.org, Vivien Didelot , UNGLinuxDriver@microchip.com, Eric Dumazet , Paolo Abeni , kernel@pengutronix.de, Jakub Kicinski , Vladimir Oltean , "David S. Miller" Subject: Re: [PATCH net-next v1 07/10] net: dsa: microchip: warn about not supported synclko properties on KSZ9893 chips Message-ID: <20220813161850.GB12534@pengutronix.de> References: <20220729130346.2961889-1-o.rempel@pengutronix.de> <20220729130346.2961889-8-o.rempel@pengutronix.de> <20220802113633.73rxlb2kmihivwpx@skbuf> <20220805115601.GB10667@pengutronix.de> <20220805134234.ps4qfjiachzm7jv4@skbuf> <20220813143215.GA12534@pengutronix.de> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: X-Sent-From: Pengutronix Hildesheim X-URL: http://www.pengutronix.de/ X-Accept-Language: de,en X-Accept-Content-Type: text/plain User-Agent: Mutt/1.10.1 (2018-07-13) X-SA-Exim-Connect-IP: 2001:67c:670:100:1d::c0 X-SA-Exim-Mail-From: ore@pengutronix.de X-SA-Exim-Scanned: No (on metis.ext.pengutronix.de); SAEximRunCond expanded to false X-PTX-Original-Recipient: linux-kernel@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Sat, Aug 13, 2022 at 05:11:45PM +0200, Andrew Lunn wrote: > On Sat, Aug 13, 2022 at 04:32:15PM +0200, Oleksij Rempel wrote: > > On Fri, Aug 05, 2022 at 04:42:34PM +0300, Vladimir Oltean wrote: > > > On Fri, Aug 05, 2022 at 01:56:01PM +0200, Oleksij Rempel wrote: > > > > Hm, if we will have any random not support OF property in the switch > > > > node. We won't be able to warn about it anyway. So, if it is present > > > > but not supported, we will just ignore it. > > > > > > > > I'll drop this patch. > > > > > > To continue, I think the right way to go about this is to edit the > > > dt-schema to say that these properties are only applicable to certain > > > compatible strings, rather than for all. Then due to the > > > "unevaluatedProperties: false", you'd get the warnings you want, at > > > validation time. > > > > Hm, with "unevaluatedProperties: false" i have no warnings. Even if I > > create examples with random strings as properties. Are there some new > > json libraries i should use? > > Try > > additionalProperties: False Yes, it works. But in this case I'll do more changes. Just wont to make sure I do not fix not broken things. Regards, Oleksij -- Pengutronix e.K. | | Steuerwalder Str. 21 | http://www.pengutronix.de/ | 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 | Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 |