aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorVivek Kasireddy <[email protected]>2020-01-17 16:58:48 -0800
committerJani Nikula <[email protected]>2020-02-09 18:30:41 +0200
commit1788fdf14e518e363bae9d18345d93102f4ee5ad (patch)
tree71a96509e2241f0350afdaf9653a7a3a8af23ea1
parent0887aa8744aea22c10cd4c36746596d67fa8da98 (diff)
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: 8cbf89db2941 ("drm/i915/dsi: Parse the I2C element from the VBT MIPI sequence block (v3)") Cc: Hans de Goede <[email protected]> Cc: Nabendu Maiti <[email protected]> Cc: Matt Roper <[email protected]> Cc: Bob Paauwe <[email protected]> Cc: Jani Nikula <[email protected]> Signed-off-by: Vivek Kasireddy <[email protected]> Signed-off-by: Jani Nikula <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected] (cherry picked from commit de409661c4c90d63cfc64579edbad0a6b10bd50d) Signed-off-by: Jani Nikula <[email protected]>
-rw-r--r--drivers/gpu/drm/i915/display/intel_dsi_vbt.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/gpu/drm/i915/display/intel_dsi_vbt.c b/drivers/gpu/drm/i915/display/intel_dsi_vbt.c
index 6ec35d975bd7..04f953ba8f00 100644
--- a/drivers/gpu/drm/i915/display/intel_dsi_vbt.c
+++ b/drivers/gpu/drm/i915/display/intel_dsi_vbt.c
@@ -394,8 +394,7 @@ static int i2c_adapter_lookup(struct acpi_resource *ares, void *data)
acpi_handle adapter_handle;
acpi_status status;
- if (intel_dsi->i2c_bus_num >= 0 ||
- !i2c_acpi_get_i2c_resource(ares, &sb))
+ if (!i2c_acpi_get_i2c_resource(ares, &sb))
return 1;
if (lookup->slave_addr != sb->slave_address)