Commit 1788fdf1 authored by Vivek Kasireddy's avatar Vivek Kasireddy Committed by Jani Nikula

drm/i915/dsi: Ensure that the ACPI adapter lookup overrides the bus num

Remove the i2c_bus_num >= 0 check from the adapter lookup function
as this would prevent ACPI bus number override. This check was mainly
there to return early if the bus number has already been found but we
anyway return in the next line if the slave address does not match.

Fixes: 8cbf89db ("drm/i915/dsi: Parse the I2C element from the VBT MIPI sequence block (v3)")
Cc: Hans de Goede <hdegoede@redhat.com>
Cc: Nabendu Maiti <nabendu.bikash.maiti@intel.com>
Cc: Matt Roper <matthew.d.roper@intel.com>
Cc: Bob Paauwe <bob.j.paauwe@intel.com>
Cc: Jani Nikula <jani.nikula@intel.com>
Signed-off-by: default avatarVivek Kasireddy <vivek.kasireddy@intel.com>
Signed-off-by: default avatarJani Nikula <jani.nikula@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20200118005848.20382-1-vivek.kasireddy@intel.com
(cherry picked from commit de409661)
Signed-off-by: default avatarJani Nikula <jani.nikula@intel.com>
parent 0887aa87
...@@ -394,8 +394,7 @@ static int i2c_adapter_lookup(struct acpi_resource *ares, void *data) ...@@ -394,8 +394,7 @@ static int i2c_adapter_lookup(struct acpi_resource *ares, void *data)
acpi_handle adapter_handle; acpi_handle adapter_handle;
acpi_status status; acpi_status status;
if (intel_dsi->i2c_bus_num >= 0 || if (!i2c_acpi_get_i2c_resource(ares, &sb))
!i2c_acpi_get_i2c_resource(ares, &sb))
return 1; return 1;
if (lookup->slave_addr != sb->slave_address) if (lookup->slave_addr != sb->slave_address)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment