From: "Lee, Shawn C" <shawn.c.lee@intel.com>
To: intel-gfx@lists.freedesktop.org
Cc: Jani Nikula <jani.nikula@intel.com>,
Cooper Chiou <cooper.chiou@intel.com>,
Lee@freedesktop.org
Subject: [PATCH] drm/i915: Backlight control via VESA eDP aux interface
Date: Mon, 10 Jun 2019 01:40:55 -0700 [thread overview]
Message-ID: <1560156055-10451-1-git-send-email-shawn.c.lee@intel.com> (raw)
The latest VBT support backlight control via aux. We have to
check VBT's setting before doing backlight initialization.
Then Driver will assign correct callback function for eDP
backlight control.
Cc: Jani Nikula <jani.nikula@intel.com>
Cc: Jose Roberto de Souza <jose.souza@intel.com>
Cc: Cooper Chiou <cooper.chiou@intel.com>
Signed-off-by: Lee, Shawn C <shawn.c.lee@intel.com>
---
drivers/gpu/drm/i915/intel_bios.c | 3 ++-
drivers/gpu/drm/i915/intel_vbt_defs.h | 6 ++++--
2 files changed, 6 insertions(+), 3 deletions(-)
diff --git a/drivers/gpu/drm/i915/intel_bios.c b/drivers/gpu/drm/i915/intel_bios.c
index 1c037dfa83f5..27bda45520ec 100644
--- a/drivers/gpu/drm/i915/intel_bios.c
+++ b/drivers/gpu/drm/i915/intel_bios.c
@@ -317,7 +317,8 @@ parse_lfp_backlight(struct drm_i915_private *dev_priv,
entry = &backlight_data->data[panel_type];
- dev_priv->vbt.backlight.present = entry->type == BDB_BACKLIGHT_TYPE_PWM;
+ dev_priv->vbt.backlight.present = (entry->type == BDB_BACKLIGHT_TYPE_PWM_SOC ||
+ entry->type == BDB_BACKLIGHT_TYPE_PWM_VESA_EDP_AUX);
if (!dev_priv->vbt.backlight.present) {
DRM_DEBUG_KMS("PWM backlight not present in VBT (type %u)\n",
entry->type);
diff --git a/drivers/gpu/drm/i915/intel_vbt_defs.h b/drivers/gpu/drm/i915/intel_vbt_defs.h
index 89ef14cafb6b..710f539f17de 100644
--- a/drivers/gpu/drm/i915/intel_vbt_defs.h
+++ b/drivers/gpu/drm/i915/intel_vbt_defs.h
@@ -760,8 +760,10 @@ struct bdb_lvds_lfp_data {
* Block 43 - LFP Backlight Control Data Block
*/
-#define BDB_BACKLIGHT_TYPE_NONE 0
-#define BDB_BACKLIGHT_TYPE_PWM 2
+#define BDB_BACKLIGHT_TYPE_NONE 0
+#define BDB_BACKLIGHT_TYPE_PWM_SOC 2
+#define BDB_BACKLIGHT_TYPE_PWM_PANEL_DRIVER_OLED 4
+#define BDB_BACKLIGHT_TYPE_PWM_VESA_EDP_AUX 5
struct lfp_backlight_data_entry {
u8 type:2;
--
2.7.4
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
next reply other threads:[~2019-06-10 8:11 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-06-10 8:40 Lee, Shawn C [this message]
2019-06-10 9:48 ` [PATCH] drm/i915: Backlight control via VESA eDP aux interface Jani Nikula
2019-06-10 9:51 ` Jani Nikula
2019-06-10 12:22 ` ✓ Fi.CI.BAT: success for " Patchwork
2019-06-11 3:07 ` ✓ Fi.CI.IGT: " Patchwork
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1560156055-10451-1-git-send-email-shawn.c.lee@intel.com \
--to=shawn.c.lee@intel.com \
--cc=Lee@freedesktop.org \
--cc=cooper.chiou@intel.com \
--cc=intel-gfx@lists.freedesktop.org \
--cc=jani.nikula@intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox