Re: [PATCH v9 04/19] ACPI: processor: Return an error if acpi_processor_get_info() fails in processor_add()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 5/1/24 00:24, Jonathan Cameron wrote:
Rafael observed [1] that returning 0 from processor_add() will result in
acpi_default_enumeration() being called which will attempt to create a
platform device, but that makes little sense when the processor is known
to be not available.  So just return the error code from acpi_processor_get_info()
instead.

Link: https://lore.kernel.org/all/CAJZ5v0iKU8ra9jR+EmgxbuNm=Uwx2m1-8vn_RAZ+aCiUVLe3Pw@xxxxxxxxxxxxxx/ [1]
Suggested-by: Rafael J. Wysocki <rafael@xxxxxxxxxx>
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@xxxxxxxxxx>

---
v9: New patch following through from Gavin pointing out a memory leak later
     in the series.
---
  drivers/acpi/acpi_processor.c | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)


Reviewed-by: Gavin Shan <gshan@xxxxxxxxxx>





[Index of Archives]     [Linux IBM ACPI]     [Linux Power Management]     [Linux Kernel]     [Linux Laptop]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]     [Linux Resources]
  Powered by Linux