[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <CAHp75VdrPp0D6sq82TR=MA2zwz=LPr6Lpd3DxPtSVaBnM6tsng@mail.gmail.com>
Date: Sun, 3 Sep 2017 15:34:09 +0300
From: Andy Shevchenko <andy.shevchenko@...il.com>
To: Kuppuswamy Sathyanarayanan
<sathyanarayanan.kuppuswamy@...ux.intel.com>
Cc: Souvik Kumar Chakravarty <souvik.k.chakravarty@...el.com>,
"x86@...nel.org" <x86@...nel.org>, Ingo Molnar <mingo@...hat.com>,
Zha Qipeng <qipeng.zha@...el.com>,
"H. Peter Anvin" <hpa@...or.com>,
"dvhart@...radead.org" <dvhart@...radead.org>,
Thomas Gleixner <tglx@...utronix.de>,
Lee Jones <lee.jones@...aro.org>,
Andy Shevchenko <andy@...radead.org>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
Platform Driver <platform-driver-x86@...r.kernel.org>,
Sathyanarayanan Kuppuswamy Natarajan <sathyaosid@...il.com>
Subject: Re: [RFC v2 1/6] platform/x86: intel_pmc_ipc: Use devm_* calls in
driver probe function
On Sun, Sep 3, 2017 at 4:24 AM,
<sathyanarayanan.kuppuswamy@...ux.intel.com> wrote:
> From: Kuppuswamy Sathyanarayanan <sathyanarayanan.kuppuswamy@...ux.intel.com>
>
> This patch cleans up unnecessary free/alloc calls in ipc_plat_probe(),
> ipc_pci_probe() and ipc_plat_get_res() functions by using devm_*
> calls.
>
> This patch also adds proper error handling for failure cases in
> ipc_pci_probe() function.
> ret = pci_enable_device(pdev);
> if (ret)
> - return ret;
> + goto release_device;
Instead you should use PCI managed function(s).
--
With Best Regards,
Andy Shevchenko
Powered by blists - more mailing lists