ACPI: Provide /sys/kernel/debug/ec/...
This patch provides the same information through debugfs, which previously was provided through /proc/acpi/embedded_controller/*/info This is the gpe the EC is connected to and whether the global lock gets used. The io ports used are added to /proc/ioports in another patch. Beside the fact that /proc/acpi is deprecated for quite some time, this info is not needed for applications and thus can be moved to debugfs instead of a public interface like /sys. Signed-off-by: Thomas Renninger <trenn@suse.de> CC: Alexey Starikovskiy <astarikovskiy@suse.de> CC: Len Brown <lenb@kernel.org> CC: linux-kernel@vger.kernel.org CC: linux-acpi@vger.kernel.org CC: Bjorn Helgaas <bjorn.helgaas@hp.com> CC: platform-driver-x86@vger.kernel.org Signed-off-by: Matthew Garrett <mjg@redhat.com>
This commit is contained in:
committed by
Matthew Garrett
parent
cd89e08fa0
commit
1195a09816
@@ -43,10 +43,13 @@
|
||||
#include <acpi/acpi_drivers.h>
|
||||
#include <linux/dmi.h>
|
||||
|
||||
#include "internal.h"
|
||||
|
||||
#define ACPI_EC_CLASS "embedded_controller"
|
||||
#define ACPI_EC_DEVICE_NAME "Embedded Controller"
|
||||
#define ACPI_EC_FILE_INFO "info"
|
||||
|
||||
#undef PREFIX
|
||||
#define PREFIX "ACPI: EC: "
|
||||
|
||||
/* EC status register */
|
||||
@@ -104,19 +107,8 @@ struct transaction {
|
||||
bool done;
|
||||
};
|
||||
|
||||
static struct acpi_ec {
|
||||
acpi_handle handle;
|
||||
unsigned long gpe;
|
||||
unsigned long command_addr;
|
||||
unsigned long data_addr;
|
||||
unsigned long global_lock;
|
||||
unsigned long flags;
|
||||
struct mutex lock;
|
||||
wait_queue_head_t wait;
|
||||
struct list_head list;
|
||||
struct transaction *curr;
|
||||
spinlock_t curr_lock;
|
||||
} *boot_ec, *first_ec;
|
||||
struct acpi_ec *boot_ec, *first_ec;
|
||||
EXPORT_SYMBOL(first_ec);
|
||||
|
||||
static int EC_FLAGS_MSI; /* Out-of-spec MSI controller */
|
||||
static int EC_FLAGS_VALIDATE_ECDT; /* ASUStec ECDTs need to be validated */
|
||||
|
Reference in New Issue
Block a user