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 bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 1BF93CCA479 for ; Mon, 18 Jul 2022 13:28:37 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:References: Message-ID:Subject:Cc:To:From:Date:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=CPQ/oRVWQhki7+ZUif4TDWqYxJUKEi8QixuqmQGlUqM=; b=noYoySpT0BlaP8 zXAiYRjEN6ShdVZZRo3BtnMnnTYvIElSLVi2ZXgE9HFTjF+jcgr1O1CQs2gGtSEXIE2BGMHFI79vc 2+ALlgrhnznKyu9gmgpmRzAMAFKllp2DmMl1CbRpINPFsi7fh7x0scMiIQJuFZ4eDifjg58p3e71S 8BCzdCXA1kVEwgL2Kt2GK+SpfDkEMp5LIbnqTE1D1pzkmIcPump3h/TkHWff6L1pmEd8JPk4oVEWo /SSlyCehscaL0hZ/LAeVpL/pAa47ze+0dJWOpNjgY3XiMjJ4bXt4DXS1fTCbb6gVby2mZ9GRlQoic 4sZjG6F+xsrggr3ZZoSg==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1oDQmd-00Djkc-Vp; Mon, 18 Jul 2022 13:27:36 +0000 Received: from pandora.armlinux.org.uk ([2001:4d48:ad52:32c8:5054:ff:fe00:142]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1oDQmb-00Djii-8g; Mon, 18 Jul 2022 13:27:34 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=armlinux.org.uk; s=pandora-2019; h=Sender:In-Reply-To:Content-Type: MIME-Version:References:Message-ID:Subject:Cc:To:From:Date:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Id: List-Help:List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=xnndy+tzJJ9DKS5PKCaEQE+56Udg782oVxUbz2xpr04=; b=jk3zLMKUfv+vWKjX2rijuqfmBh YCfXuxqqdDz3iuvOGXmsr6GMg8lsHX2PPdP915etsIBjWqjQoCTjWUAEWkwgKqJYpDCL3hQnXQ2rd cVroglYBdxInFWLTbiAHhv0RClizxhEhZNSw8TJZFoKDqn1GjCsvc6tJeJ0P5jzExj0K16iFlMBON V2s5ckFa3tuSiqWOtM7FrqRBoQ+Spt782Pk+FlR9q6//kptMkkYc6mhwLnB+X+ohYchMNvsCFUVXd 2LUa3dKEb4gXC3BIXfTwLLISi0wsOyXlXTZw+G7+GzCYHfHwo8zUOaxV/Zhm+6dxSecD1qrBeLlCu HserpU4w==; Received: from shell.armlinux.org.uk ([fd8f:7570:feb6:1:5054:ff:fe00:4ec]:33412) by pandora.armlinux.org.uk with esmtpsa (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1oDQm9-0001d9-GH; Mon, 18 Jul 2022 14:27:05 +0100 Received: from linux by shell.armlinux.org.uk with local (Exim 4.94.2) (envelope-from ) id 1oDQm6-0001zu-AM; Mon, 18 Jul 2022 14:27:02 +0100 Date: Mon, 18 Jul 2022 14:27:02 +0100 From: "Russell King (Oracle)" To: Andy Shevchenko Cc: Vladimir Oltean , Andrew Lunn , Heiner Kallweit , Alexandre Belloni , Alvin __ipraga , Claudiu Manoil , Daniel Scally , "David S. Miller" , DENG Qingfang , Eric Dumazet , Florian Fainelli , George McCollister , Greg Kroah-Hartman , Hauke Mehrtens , Heikki Krogerus , Jakub Kicinski , Kurt Kanzenbach , Landen Chao , Linus Walleij , linux-acpi@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-mediatek@lists.infradead.org, Matthias Brugger , netdev@vger.kernel.org, Paolo Abeni , "Rafael J. Wysocki" , Sakari Ailus , Sean Wang , UNGLinuxDriver@microchip.com, Vivien Didelot , Woojung Huh , Marek =?iso-8859-1?Q?Beh=FAn?= Subject: Re: [PATCH net-next 2/6] software node: allow named software node to be created Message-ID: References: <20220715201715.foea4rifegmnti46@skbuf> <20220715204841.pwhvnue2atrkc2fx@skbuf> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20220718_062733_343515_DCF28245 X-CRM114-Status: GOOD ( 16.42 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On Mon, Jul 18, 2022 at 03:29:52PM +0300, Andy Shevchenko wrote: > On Fri, Jul 15, 2022 at 11:48:41PM +0300, Vladimir Oltean wrote: > > So won't kobject_init_and_add() fail on namespace collision? Is it the > > problem that it's going to fail, or that it's not trivial to statically > > determine whether it'll fail? > > > > Sorry, but I don't see something actionable about this. > > I'm talking about validation before a runtime. But if you think that is fine, > let's fail it at runtime, okay, and consume more backtraces in the future. Is there any sane way to do validation of this namespace before runtime? The problem in this instance is we need a node named "fixed-link" that is attached to the parent node as that is defined in the binding doc, and we're creating swnodes to provide software generated nodes for this binding. There could be several such nodes scattered around, but in this instance they are very short-lived before they are destroyed, they don't even need to be published to userspace (and its probably a waste of CPU cycles for them to be published there.) So, for this specific case, is this the best approach, or is there some better way to achieve what we need here? Thanks. -- RMK's Patch system: https://www.armlinux.org.uk/developer/patches/ FTTP is here! 40Mbps down 10Mbps up. Decent connectivity at last! _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel