Skip to content

Commit

Permalink
i2c: designware: Read counters from ACPI for PCI driver
Browse files Browse the repository at this point in the history
PCI devices may have been backed with ACPI handle which supplies
an additional information to the drivers, such as counters.

Call for ACPI configuration from PCI driver in order to utilize counters
provided by ACPI.

Signed-off-by: Andy Shevchenko <[email protected]>
Acked-by: Jarkko Nikula <[email protected]>
Signed-off-by: Wolfram Sang <[email protected]>
  • Loading branch information
andy-shev authored and wsakernel committed May 22, 2020
1 parent f9288fc commit 64d0a07
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions drivers/i2c/busses/i2c-designware-pcidrv.c
Original file line number Diff line number Diff line change
Expand Up @@ -255,6 +255,17 @@ static int i2c_dw_pci_probe(struct pci_dev *pdev,
}
}

i2c_dw_acpi_adjust_bus_speed(&pdev->dev);

if (has_acpi_companion(&pdev->dev))
i2c_dw_acpi_configure(&pdev->dev);

r = i2c_dw_validate_speed(dev);
if (r) {
pci_free_irq_vectors(pdev);
return r;
}

i2c_dw_configure(dev);

if (controller->scl_sda_cfg) {
Expand Down

0 comments on commit 64d0a07

Please sign in to comment.