drivers/i2c/rx6110sa: Add a Kconfig switch to disable ACPI support
In commit b64db833d6
a basic ACPI support was added to the driver.
With this support an SSDT-entry is created for this RTC and it is now
visible to the OS via ACPI. In Linux the PNP-devices, which are
reported over ACPI, are scanned rather early and if the entry is found,
the device is claimed even if there is no driver available yet.
In this case, when the native RTC-driver without ACPI-support is loaded
and tries to register this device, the RTC is already blocked by the
PNP-drivers and cannot be used anymore. This leads to a non-usable RTC
on kernels where the needed ACPI-extension is not yet merged into the
RTC driver.
This patch provides a way to disable the ACPI-support for the RTC if
needed.
Change-Id: Ic65794d409d13a78d17275c86ec14ee6f04cd2a6
Signed-off-by: Werner Zeh <werner.zeh@siemens.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/55003
Reviewed-by: Mario Scheithauer <mario.scheithauer@siemens.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
This commit is contained in:
parent
50e9d3860b
commit
964948d97f
|
@ -3,3 +3,10 @@ config DRIVERS_I2C_RX6110SA
|
||||||
default n
|
default n
|
||||||
help
|
help
|
||||||
Enable support for external RTC chip RX6110 SA.
|
Enable support for external RTC chip RX6110 SA.
|
||||||
|
|
||||||
|
config RX6110SA_DISABLE_ACPI
|
||||||
|
bool
|
||||||
|
default n
|
||||||
|
help
|
||||||
|
Disable the generation of an ACPI entry for this RTC. This is helpful
|
||||||
|
when the native driver for this RTC in OS does not have ACPI support enabled.
|
||||||
|
|
|
@ -166,7 +166,7 @@ static void rx6110sa_init(struct device *dev)
|
||||||
rx6110sa_write(dev, CTRL_REG, reg);
|
rx6110sa_write(dev, CTRL_REG, reg);
|
||||||
}
|
}
|
||||||
|
|
||||||
#if CONFIG(HAVE_ACPI_TABLES)
|
#if CONFIG(HAVE_ACPI_TABLES) && !CONFIG(RX6110SA_DISABLE_ACPI)
|
||||||
static void rx6110sa_fill_ssdt(const struct device *dev)
|
static void rx6110sa_fill_ssdt(const struct device *dev)
|
||||||
{
|
{
|
||||||
struct drivers_i2c_rx6110sa_config *config = dev->chip_info;
|
struct drivers_i2c_rx6110sa_config *config = dev->chip_info;
|
||||||
|
@ -227,7 +227,7 @@ static struct device_operations rx6110sa_ops = {
|
||||||
.set_resources = noop_set_resources,
|
.set_resources = noop_set_resources,
|
||||||
.init = rx6110sa_init,
|
.init = rx6110sa_init,
|
||||||
.final = rx6110sa_final,
|
.final = rx6110sa_final,
|
||||||
#if CONFIG(HAVE_ACPI_TABLES)
|
#if CONFIG(HAVE_ACPI_TABLES) && !CONFIG(RX6110SA_DISABLE_ACPI)
|
||||||
.acpi_name = rx6110sa_acpi_name,
|
.acpi_name = rx6110sa_acpi_name,
|
||||||
.acpi_fill_ssdt = rx6110sa_fill_ssdt,
|
.acpi_fill_ssdt = rx6110sa_fill_ssdt,
|
||||||
#endif
|
#endif
|
||||||
|
|
Loading…
Reference in New Issue