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 7BC6BC7EE23 for ; Mon, 12 Jun 2023 07:56:34 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234580AbjFLH4c (ORCPT ); Mon, 12 Jun 2023 03:56:32 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:33578 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S236093AbjFLH4C (ORCPT ); Mon, 12 Jun 2023 03:56:02 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [IPv6:2604:1380:4641:c500::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 0CBE3170D for ; Mon, 12 Jun 2023 00:55:12 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 01D22613E9 for ; Mon, 12 Jun 2023 07:54:56 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id E6333C433D2; Mon, 12 Jun 2023 07:54:54 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1686556495; bh=RkpI8fT67p75Z512wRXhJISmUqOe2UC4PFsDjKP+0rE=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=vMq3IMn/lJflObHlgaHgNOM22T5OnHAMuAsr0cFIaifjLYWRtKQtgT8I+fpInH7/U C5xRKjOIc/vWh6RxhAVXLvQaG4575SVtWtAkpEEv/HPzVyq1FeM6lvYO2YxrPz98Mr 1Y2Kn4evSV9v+fu72Du4cpYh4fMz/O6QmbGpkj3rLOGP37a6MeqAdE8NnNOFFTVqWS T8ADhgCFvcfJOFrG5m755SoEHJ5d3Iwl0qdigidYFYGJ1Bw+xkeJbf2j6R3dsfd35u R2aTTf6yxkrd16BZxdoAyMHU8quZyXMHoCFkzjtSUJpa+vz74fhyPLm6Qio8QWSZIj z5AzTsjQ4a8/g== Date: Mon, 12 Jun 2023 09:54:52 +0200 From: Andi Shyti To: Geert Uytterhoeven Cc: Linux I2C , Wolfram Sang , Geert Uytterhoeven , Magnus Damm Subject: Re: [PATCH 01/15] i2c: busses: emev2: Use devm_clk_get_enabled() Message-ID: <20230612075452.xfjhtz5mfwja544i@intel.intel> References: <20230611225702.891856-1-andi.shyti@kernel.org> <20230611225702.891856-2-andi.shyti@kernel.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Precedence: bulk List-ID: X-Mailing-List: linux-i2c@vger.kernel.org Hi Geert, > > --- a/drivers/i2c/busses/i2c-emev2.c > > +++ b/drivers/i2c/busses/i2c-emev2.c > > @@ -373,14 +373,10 @@ static int em_i2c_probe(struct platform_device *pdev) > > > > strscpy(priv->adap.name, "EMEV2 I2C", sizeof(priv->adap.name)); > > > > - priv->sclk = devm_clk_get(&pdev->dev, "sclk"); > > + priv->sclk = devm_clk_get_enabled(&pdev->dev, "sclk"); > > if (IS_ERR(priv->sclk)) > > return PTR_ERR(priv->sclk); > > After this, priv->sclk is unused, so you can replace em_i2c_device.sclk > by a local variable. good point! Will send it again. Thanks! Andi