Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1714872 > unrolled thread

Re: [RFC v1 1/6] platform/x86: intel_pmc_ipc: Fix error handling in ipc_pci_probe()

Started byAndy Shevchenko <andy.shevchenko@gmail.com>
First post2017-08-18 14:30 +0200
Last post2017-08-22 07:10 +0200
Articles 2 — 2 participants

Back to article view | Back to linux.kernel

This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by below is the oldest one visible, not the original post.


Contents

  Re: [RFC v1 1/6] platform/x86: intel_pmc_ipc: Fix error handling in ipc_pci_probe() Andy Shevchenko <andy.shevchenko@gmail.com> - 2017-08-18 14:30 +0200
    Re: [RFC v1 1/6] platform/x86: intel_pmc_ipc: Fix error handling in  ipc_pci_probe() sathya <sathyaosid@gmail.com> - 2017-08-22 07:10 +0200

#1714872 — Re: [RFC v1 1/6] platform/x86: intel_pmc_ipc: Fix error handling in ipc_pci_probe()

FromAndy Shevchenko <andy.shevchenko@gmail.com>
Date2017-08-18 14:30 +0200
SubjectRe: [RFC v1 1/6] platform/x86: intel_pmc_ipc: Fix error handling in ipc_pci_probe()
Message-ID<ufOzx-3Ek-29@gated-at.bofh.it>
On Tue, Aug 1, 2017 at 9:13 PM,
<sathyanarayanan.kuppuswamy@linux.intel.com> wrote:
> From: Kuppuswamy Sathyanarayanan <sathyanarayanan.kuppuswamy@linux.intel.com>
>
> This patch adds proper error handling for failure cases in
> ipc_pci_probe() function.
>
> Signed-off-by: Kuppuswamy Sathyanarayanan <sathyanarayanan.kuppuswamy@linux.intel.com>
> ---
>  drivers/platform/x86/intel_pmc_ipc.c | 23 ++++++++++++++++++-----
>  1 file changed, 18 insertions(+), 5 deletions(-)
>
> diff --git a/drivers/platform/x86/intel_pmc_ipc.c b/drivers/platform/x86/intel_pmc_ipc.c
> index bb792a5..7b65237 100644
> --- a/drivers/platform/x86/intel_pmc_ipc.c
> +++ b/drivers/platform/x86/intel_pmc_ipc.c
> @@ -489,33 +489,46 @@ static int ipc_pci_probe(struct pci_dev *pdev, const struct pci_device_id *id)
>
>         ret = pci_enable_device(pdev);
>         if (ret)
> -               return ret;
> +               goto release_device;

Instead of doing this way and ping-ponging code in the same series,
better to switch to managed PCI functions in the first place.

-- 
With Best Regards,
Andy Shevchenko

[toc] | [next] | [standalone]


#1717023 — Re: [RFC v1 1/6] platform/x86: intel_pmc_ipc: Fix error handling in ipc_pci_probe()

Fromsathya <sathyaosid@gmail.com>
Date2017-08-22 07:10 +0200
SubjectRe: [RFC v1 1/6] platform/x86: intel_pmc_ipc: Fix error handling in ipc_pci_probe()
Message-ID<uh9BT-694-13@gated-at.bofh.it>
In reply to#1714872
Hi Andy,


On 08/18/2017 05:22 AM, Andy Shevchenko wrote:
> On Tue, Aug 1, 2017 at 9:13 PM,
> <sathyanarayanan.kuppuswamy@linux.intel.com> wrote:
>> From: Kuppuswamy Sathyanarayanan <sathyanarayanan.kuppuswamy@linux.intel.com>
>>
>> This patch adds proper error handling for failure cases in
>> ipc_pci_probe() function.
>>
>> Signed-off-by: Kuppuswamy Sathyanarayanan <sathyanarayanan.kuppuswamy@linux.intel.com>
>> ---
>>   drivers/platform/x86/intel_pmc_ipc.c | 23 ++++++++++++++++++-----
>>   1 file changed, 18 insertions(+), 5 deletions(-)
>>
>> diff --git a/drivers/platform/x86/intel_pmc_ipc.c b/drivers/platform/x86/intel_pmc_ipc.c
>> index bb792a5..7b65237 100644
>> --- a/drivers/platform/x86/intel_pmc_ipc.c
>> +++ b/drivers/platform/x86/intel_pmc_ipc.c
>> @@ -489,33 +489,46 @@ static int ipc_pci_probe(struct pci_dev *pdev, const struct pci_device_id *id)
>>
>>          ret = pci_enable_device(pdev);
>>          if (ret)
>> -               return ret;
>> +               goto release_device;
> Instead of doing this way and ping-ponging code in the same series,
> better to switch to managed PCI functions in the first place.
ok. I will merge this patch and "Use devm_* calls in driver probe" patch 
into a single patch.

>

-
Sathya

[toc] | [prev] | [standalone]


Back to top | Article view | linux.kernel


csiph-web