On 2013-9-14 4:16, Moore, Robert wrote: > > >> -----Original Message----- >> From: Moore, Robert >> Sent: Friday, September 13, 2013 6:08 AM >> To: Hanjun Guo; Rafael J. Wysocki; Len Brown >> Cc: Zheng, Lv; linux-acpi@xxxxxxxxxxxxxxx; patches@xxxxxxxxxx; linaro- >> kernel@xxxxxxxxxxxxxxxx; linaro-acpi@xxxxxxxxxxxxxxxx >> Subject: RE: [PATCH] ACPICA / hwreg: Use acpi_gbl_reduced_hardware to >> prevent accessing PM registers >> >> NOT_IMPLEMENTED refers to the software only; therefore AE_SUPPORT should >> be returned. >> >> Otherwise, seems like this may be a good idea. > > > On the other hand, could one not argue that the host OS should darn well know that > it is executing on a hardware-reduced platform and not call these functions in the > first place? Well, there is a macro ACPI_REDUCED_HARDWARE and used to switch off the compiling of these functions on hardware-reduced platform, if ACPI_REDUCED_HARDWARE is TRUE, those functions will never be called. But is that reasonable? When somebody want to use the ACPI code on hardware-reduced platform, they should introduce a patch just like: - #define ACPI_REDUCED_HARDWARE FALSE + #define ACPI_REDUCED_HARDWARE TRUE in include/acpi/acconfig.h and this patch does not exist in upstream, and it will never be accepted by upstream too, it is weird. so we should proposal another way. I thought about introducing a kernel config such as CONFIG_ACPI_REDUCED_HARDWARE to enable ACPI_REDUCED_HARDWARE, but it is just the same as a macro, and I drop it. So, this is a problem should be solved for hardware-reduced platform, use falg acpi_gbl_reduced_hardware seems a good solution. Thanks Hanjun > > Bob -- To unsubscribe from this list: send the line "unsubscribe linux-acpi" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html