lkml.org 
[lkml]   [2021]   [Jul]   [12]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH v10 7/8] PCI: Add support for ACPI _RST reset method
From
Date
Hi Alex,

On 7/12/21 6:09 PM, Alex Williamson wrote:
>> +/**
>> + * pci_dev_acpi_reset - do a function level reset using _RST method
>> + * @dev: device to reset
>> + * @probe: check if _RST method is included in the acpi_device context.
>> + */
>> +int pci_dev_acpi_reset(struct pci_dev *dev, int probe)
>> +{
>> + acpi_handle handle = ACPI_HANDLE(&dev->dev);
>> +
>> + if (!handle || !acpi_has_method(handle, "_RST"))
>> + return -ENOTTY;
>> +
>> + if (probe)
>> + return 0;
>> +
>> + if (ACPI_FAILURE(acpi_evaluate_object(handle, "_RST", NULL, NULL))) {
>> + pci_warn(dev, "ACPI _RST failed\n");
>> + return -EINVAL;
> Should we return -ENOTTY here instead to give a possible secondary
> reset method a chance? Thanks,
Thanks for reviewing patches.

ACPI/AML _RST method type is VOID. The only possibility of failure would be
either system is running out of memory or bugs in ACPICA. There is no strong
reason not to return -NOTTY.

I'll fix in the next version. Is there opportunity to include reset feature in v5.14-rc2?

Can I add your reviewed-by since no other comments to this patch?

-Shanker



\
 
 \ /
  Last update: 2021-07-13 02:53    [W:0.059 / U:0.280 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site