ACPI / processor: Introduce invalid_logical_cpuid()
authorHanjun Guo <hanjun.guo@linaro.org>
Mon, 11 May 2015 04:17:13 +0000 (12:17 +0800)
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>
Wed, 13 May 2015 21:28:14 +0000 (23:28 +0200)
commit25956b6612601cf36022392ffa83f6bf97939bcd
treef3b8efbce1c45c7ccf5796e38046f13477d22a76
parent030bbdbf4c833bc69f502eae58498bc5572db736
ACPI / processor: Introduce invalid_logical_cpuid()

In ACPI processor drivers, we use direct comparisons of cpu logical
id with -1 which are error prone in case logical cpuid is accidentally
assinged an error code and prevents us from returning an error-encoding
cpuid directly in some cases.

So introduce invalid_logical_cpuid() to identify cpu with invalid
logical cpu num, then it will be used to replace the direct comparisons
with -1.

Signed-off-by: Hanjun Guo <hanjun.guo@linaro.org>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
drivers/acpi/acpi_processor.c
drivers/acpi/processor_pdc.c
include/linux/acpi.h