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 12F5BC77B75 for ; Tue, 18 Apr 2023 16:27:34 +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=h82+sZDlgPrXuDDa7hZA2shS4/YaTe4suObGpQco9Vo=; b=II7U+zpcvWWKmd sXpJkVavmgcvLfJrl5vMx8z3440x4UY/KKVB6PvQEJU4b503iEsArylOW8eQa4NNRBsZdYowRHfdn Uj6xomLcDp1hLeJGHYqM9q48PB+pTLFYva7s41D8JQcET+UAv6lviU3gvNgW+mFRCpMmJ4H4Nfhfd TSrUInXqa42IAOkb6nFCCOSJq0GNyfp+FJQr6IL40vvtdrlbT6O1xRR5rXG3HDOPwtoG11iej/goS Q3HmTydYEjBkQnqAtqMlTlJGtdiFhkwgfoATajBcUUOpWKB5T5nqQUr7i6ox9EtHWjzjHRNPkAUBJ lfHVMscq90l8J81z9zig==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.96 #2 (Red Hat Linux)) id 1pooAE-002lkz-0M; Tue, 18 Apr 2023 16:26:42 +0000 Received: from mail-ot1-f43.google.com ([209.85.210.43]) by bombadil.infradead.org with esmtps (Exim 4.96 #2 (Red Hat Linux)) id 1pooAC-002lkP-02 for linux-arm-kernel@lists.infradead.org; Tue, 18 Apr 2023 16:26:41 +0000 Received: by mail-ot1-f43.google.com with SMTP id 46e09a7af769-6a5ecdb455bso330500a34.0 for ; Tue, 18 Apr 2023 09:26:38 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1681835198; x=1684427198; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=fjH/hStSCiVLtQLuqVajFztpwIunoyCsP3iwDrSgpHg=; b=bvmumgayPLAO4EV0NikDzwUTP4OBNG8lI+3sulc0oVvJohe4/sfhGqs4ABOjpVUe1R fYx85G4NDs6qfVzJjjDr/6u30p05n2nciLNMxoWzs3bdOr0B7JssJ5AWw+4K70VT1Qkh EWUNqYDi3XyyYowsOpxdXSJXhJ8xO+q/dneJD/I+y2j/0Sd/DUuDghY3VSIpQ+ylXW0Y joxr0hdEPvex1c9fEr9cdupKn1Y0pQP0Acu3WGE6EUQ8jz+dCmOM9S1/L/THphrUQOIZ jcKe/4UMCDMOj3tJNfSTOV1QBneOTxU1O4ubwOKH2rzgG3DStMgeyDfB03s4p+I9Mr53 wH9Q== X-Gm-Message-State: AAQBX9c25WqZt4hUl9+3Z5B/iTs+/9WbJOu1a+664WYrON9WRMPZiDGd fBhL3g//H9719Zvd3HY/2YKzTkMFtQ== X-Google-Smtp-Source: AKy350bEpph6yuJMXQ4ijSo0Yo4pU5RYjIe5g/2kLLvB2C5rB5LOQKRaMTTBKZ7Fy10XJv3tGSVurw== X-Received: by 2002:a9d:7454:0:b0:6a5:f8b6:cccf with SMTP id p20-20020a9d7454000000b006a5f8b6cccfmr1548078otk.16.1681835197867; Tue, 18 Apr 2023 09:26:37 -0700 (PDT) Received: from robh_at_kernel.org (66-90-144-107.dyn.grandenetworks.net. [66.90.144.107]) by smtp.gmail.com with ESMTPSA id t27-20020a0568301e3b00b0069436b64bb1sm5639720otr.79.2023.04.18.09.26.36 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 18 Apr 2023 09:26:37 -0700 (PDT) Received: (nullmailer pid 1809366 invoked by uid 1000); Tue, 18 Apr 2023 16:26:35 -0000 Date: Tue, 18 Apr 2023 11:26:35 -0500 From: Rob Herring To: Patrice Chotard , Bjorn Andersson , Mathieu Poirier Cc: devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-remoteproc@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH] remoteproc: st: Use of_property_present() for testing DT property presence Message-ID: <20230418162635.GE1764573-robh@kernel.org> References: <20230310144736.1546972-1-robh@kernel.org> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <20230310144736.1546972-1-robh@kernel.org> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20230418_092640_048622_165ACDA3 X-CRM114-Status: GOOD ( 20.48 ) 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 Fri, Mar 10, 2023 at 08:47:35AM -0600, Rob Herring wrote: > It is preferred to use typed property access functions (i.e. > of_property_read_ functions) rather than low-level > of_get_property/of_find_property functions for reading properties. As > part of this, convert of_get_property/of_find_property calls to the > recently added of_property_present() helper when we just want to test > for presence of a property and nothing more. > > Signed-off-by: Rob Herring > --- > drivers/remoteproc/st_remoteproc.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) Ping! > > diff --git a/drivers/remoteproc/st_remoteproc.c b/drivers/remoteproc/st_remoteproc.c > index a3268d95a50e..50ef40671652 100644 > --- a/drivers/remoteproc/st_remoteproc.c > +++ b/drivers/remoteproc/st_remoteproc.c > @@ -379,7 +379,7 @@ static int st_rproc_probe(struct platform_device *pdev) > clk_set_rate(ddata->clk, ddata->clk_rate); > } > > - if (of_get_property(np, "mbox-names", NULL)) { > + if (of_property_present(np, "mbox-names")) { > ddata->mbox_client_vq0.dev = dev; > ddata->mbox_client_vq0.tx_done = NULL; > ddata->mbox_client_vq0.tx_block = false; > -- > 2.39.2 > > > _______________________________________________ > linux-arm-kernel mailing list > linux-arm-kernel@lists.infradead.org > http://lists.infradead.org/mailman/listinfo/linux-arm-kernel _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel