Skip to content

Commit cd55a1f

Browse files
andy-shevjnikula
authored andcommitted
drm/i915/bxt: use NULL for GPIO connection ID
The commit 213e08a ("drm/i915/bxt: add bxt dsi gpio element support") enables GPIO support for Broxton based platforms. While using that API we might get into troubles in the future, because we can't rely on label name in the driver since vendor firmware might provide any GPIO pin there, e.g. "reset", and even mark it in _DSD (in which case the request will fail). To avoid inconsistency and potential issues we have two options: a) generate GPIO ACPI mapping table and supply it via acpi_dev_add_driver_gpios(), or b) just pass NULL as connection ID. The b) approach is much simpler and would work since the driver relies on GPIO indices only. Moreover, the _CRS fallback mechanism, when requesting GPIO, has been made stricter, and supplying non-NULL connection ID when neither _DSD, nor GPIO ACPI mapping is present, is making request fail. Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=101921 Fixes: f10e4bf ("gpio: acpi: Even more tighten up ACPI GPIO lookups") Cc: Mika Kahola <mika.kahola@intel.com> Cc: Jani Nikula <jani.nikula@intel.com> Tested-by: Mika Kahola <mika.kahola@intel.com> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Jani Nikula <jani.nikula@intel.com> Link: https://patchwork.freedesktop.org/patch/msgid/20170817105541.63914-1-andriy.shevchenko@linux.intel.com
1 parent 636918f commit cd55a1f

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

‎drivers/gpu/drm/i915/intel_dsi_vbt.c‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -306,7 +306,7 @@ static void bxt_exec_gpio(struct drm_i915_private *dev_priv,
306306

307307
if (!gpio_desc) {
308308
gpio_desc = devm_gpiod_get_index(dev_priv->drm.dev,
309-
"panel", gpio_index,
309+
NULL, gpio_index,
310310
value ? GPIOD_OUT_LOW :
311311
GPIOD_OUT_HIGH);
312312

0 commit comments

Comments
 (0)