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 10FB0C00528 for ; Sat, 5 Aug 2023 18:06:08 +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:MIME-Version:References:In-Reply-To: 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=eXO9C/qMFwxKl5+fyGzF1tUDPJEu2caJsfZPXWo2X2w=; b=FFEE2oidOssn6H 6WigKJZhKrbdaSpTtBU0J/Tb/Hf8HsXwksHQXfiDN1V5cmeICdoltnuMjKwJrfJoXts86msDtjqQ2 Rc8qoRTvMSV/PmL+4ldMVBt+7OwI1omtT699+Aax/1SSSZZUJqasWr0pTlWx1+qdc3XkZNg3j9VCt qTXX4ceClAq/mTFmI7qopyXd1M0BsfcM655jTwO/mb8yAauRAugW/JczqIpFPn84DcLetWQIfJU6H F0JgVOhzTxUCwuc57Q6qmPkEbSABkSCefCQmZ3LpLMEtVn6hRTlCveOHUe3otRCPzYst/ecCFUISo ULzVh8uEo+2v8REak9vA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.96 #2 (Red Hat Linux)) id 1qSLej-00EQgf-0q; Sat, 05 Aug 2023 18:05:37 +0000 Received: from dfw.source.kernel.org ([2604:1380:4641:c500::1]) by bombadil.infradead.org with esmtps (Exim 4.96 #2 (Red Hat Linux)) id 1qSLeg-00EQfy-0y for linux-arm-kernel@lists.infradead.org; Sat, 05 Aug 2023 18:05:35 +0000 Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id A30CD60D3E; Sat, 5 Aug 2023 18:05:33 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id B80FEC433C7; Sat, 5 Aug 2023 18:05:29 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1691258733; bh=6ngnT+YpvhD93TEqzBDpiBPquP2+w46b9BGTWjyu8w0=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=ltdF/niLESAi+aozfLjIa4kbuIJibRedI0s7K6xJq4WCpejM8K0nuWsnKRFVtQmXT bh5uEipChE7m5I0WIVZY/LqNHWKYVOcC067ocbBGMcePhrmbZA4OOMKkx2g/41CsMt wubx6QngdGf/sGnMeUxZIjqv8ltjliF1eh+udig+gI/vCqOLqfXU3wywGd4PuVLcR7 QF/SbUyQ/hmzYtHViN9wVgVuXMiHslBRxFE/h3jXj4UxkRCfxDrd6BXsdWY3oFfmh3 Fj/qMb4sxyv9dnBTnOOvc8WGkJB1s/iW8ESC/apFjnq421auhVGFVUBTlSOSZYc1Qa qcE823d/JH3rA== Date: Sat, 5 Aug 2023 19:05:24 +0100 From: Jonathan Cameron To: Andrei Coardos Cc: linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-stm32@st-md-mailman.stormreply.com, linux-iio@vger.kernel.org, alexandre.torgue@foss.st.com, mcoquelin.stm32@gmail.com, lars@metafoo.de, Alexandru Ardelean Subject: Re: [PATCH v2] iio: trigger: stm32-lptimer-trigger: remove unneeded platform_set_drvdata() Message-ID: <20230805190524.5dc00883@jic23-huawei> In-Reply-To: <20230802133509.29381-1-aboutphysycs@gmail.com> References: <20230802133509.29381-1-aboutphysycs@gmail.com> X-Mailer: Claws Mail 4.1.1 (GTK 3.24.38; x86_64-pc-linux-gnu) MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20230805_110534_386921_92CA8AF8 X-CRM114-Status: GOOD ( 22.33 ) 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 Wed, 2 Aug 2023 16:35:09 +0300 Andrei Coardos wrote: > This function call was found to be unnecessary as there is no equivalent > platform_get_drvdata() call to access the private data of the driver. Also, > the private data is defined in this driver, so there is no risk of it being > accessed outside of this driver file. > > Reviewed-by: Alexandru Ardelean > Signed-off-by: Andrei Coardos Oops. Missed there was a v2. Ah well, end result the same ;) Thanks, Jonathan > --- > > Changelog V1->V2: > > * https://lore.kernel.org/linux-iio/CAH3L5QpuoDYU6qvWH7_z5Yx0cW2qPMbCA8AFEYAPsiEkSzCiwQ@mail.gmail.com/T/#t > * Adjusted the returning values of the function > > > drivers/iio/trigger/stm32-lptimer-trigger.c | 6 +----- > 1 file changed, 1 insertion(+), 5 deletions(-) > > diff --git a/drivers/iio/trigger/stm32-lptimer-trigger.c b/drivers/iio/trigger/stm32-lptimer-trigger.c > index df2416e33375..ab1cc6a05f26 100644 > --- a/drivers/iio/trigger/stm32-lptimer-trigger.c > +++ b/drivers/iio/trigger/stm32-lptimer-trigger.c > @@ -88,11 +88,7 @@ static int stm32_lptim_trigger_probe(struct platform_device *pdev) > priv->dev = &pdev->dev; > priv->trg = stm32_lptim_triggers[index]; > > - ret = stm32_lptim_setup_trig(priv); > - if (ret) > - return ret; > - > - return 0; > + return stm32_lptim_setup_trig(priv); > } > > static const struct of_device_id stm32_lptim_trig_of_match[] = { _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel