12 #if CONFIG(HAVE_ACPI_TABLES)
14 #define NAU8825_ACPI_NAME "NAU8"
15 #define NAU8825_ACPI_HID "10508825"
17 #define NAU8825_DP_INT(key,val) \
18 acpi_dp_add_integer(dp, "nuvoton," key, (val))
20 static void nau8825_fill_ssdt(
const struct device *dev)
50 if (
config->irq_gpio.pin_count)
58 NAU8825_DP_INT(
"jkdet-enable",
config->jkdet_enable);
59 NAU8825_DP_INT(
"jkdet-pull-enable",
config->jkdet_pull_enable);
60 NAU8825_DP_INT(
"jkdet-pull-up",
config->jkdet_pull_up);
61 NAU8825_DP_INT(
"jkdet-polarity",
config->jkdet_polarity);
62 NAU8825_DP_INT(
"vref-impedance",
config->vref_impedance);
63 NAU8825_DP_INT(
"micbias-voltage",
config->micbias_voltage);
64 NAU8825_DP_INT(
"sar-hysteresis",
config->sar_hysteresis);
65 NAU8825_DP_INT(
"sar-voltage",
config->sar_voltage);
66 NAU8825_DP_INT(
"sar-compare-time",
config->sar_compare_time);
67 NAU8825_DP_INT(
"sar-sampling-time",
config->sar_sampling_time);
68 NAU8825_DP_INT(
"short-key-debounce",
config->short_key_debounce);
69 NAU8825_DP_INT(
"jack-insert-debounce",
config->jack_insert_debounce);
70 NAU8825_DP_INT(
"jack-eject-deboune",
config->jack_eject_debounce);
71 NAU8825_DP_INT(
"sar-threshold-num",
config->sar_threshold_num);
84 static const char *nau8825_acpi_name(
const struct device *dev)
86 return NAU8825_ACPI_NAME;
93 #if CONFIG(HAVE_ACPI_TABLES)
94 .acpi_name = nau8825_acpi_name,
95 .acpi_fill_ssdt = nau8825_fill_ssdt,
void acpi_device_write_gpio(const struct acpi_gpio *gpio)
const char * acpi_device_path(const struct device *dev)
struct acpi_dp * acpi_dp_add_integer_array(struct acpi_dp *dp, const char *name, const uint64_t *array, int len)
void acpi_device_write_interrupt(const struct acpi_irq *irq)
void acpi_device_write_i2c(const struct acpi_i2c *i2c)
void acpi_dp_write(struct acpi_dp *table)
int acpi_device_status(const struct device *dev)
const char * acpi_device_name(const struct device *dev)
struct acpi_dp * acpi_dp_new_table(const char *name)
const char * acpi_device_scope(const struct device *dev)
void acpigen_pop_len(void)
void acpigen_write_scope(const char *name)
void acpigen_write_resourcetemplate_footer(void)
void acpigen_write_name_integer(const char *name, uint64_t val)
void acpigen_write_STA(uint8_t status)
void acpigen_write_resourcetemplate_header(void)
void acpigen_write_device(const char *name)
void acpigen_write_name(const char *name)
void acpigen_write_name_string(const char *name, const char *string)
#define printk(level,...)
#define NAU8825_MAX_BUTTONS
static void noop_read_resources(struct device *dev)
Standard device operations function pointers shims.
static void noop_set_resources(struct device *dev)
#define BIOS_INFO
BIOS_INFO - Expected events.
static struct device_operations nau8825_ops
struct chip_operations drivers_i2c_nau8825_ops
static void nau8825_enable(struct device *dev)
void(* read_resources)(struct device *dev)
struct chip_operations * chip_ops
struct device_operations * ops
DEVTREE_CONST void * chip_info