From: Jani Nikula <jani.nikula@linux.intel.com>
To: Shashank Sharma <shashank.sharma@intel.com>,
intel-gfx@lists.freedesktop.org, ville.syrjala@linux.intel.com,
daniel.vetter@intel.com, paulo.r.zanoni@intel.com,
sonika.jindal@intel.com, sivakumar.thulasimani@intel.com
Subject: Re: [PATCH 12/12] DO_NOT_MERGE: drm/i915: Hack to enable lspcon initialization
Date: Wed, 06 Apr 2016 15:18:16 +0300 [thread overview]
Message-ID: <87zit7vsl3.fsf@intel.com> (raw)
In-Reply-To: <1459771308-4405-12-git-send-email-shashank.sharma@intel.com>
On Mon, 04 Apr 2016, Shashank Sharma <shashank.sharma@intel.com> wrote:
> This patch adds a hack to enable lspcon on GEN9 devices.
> This should not be merged, and the hack must be replaced
> by proper VBT parsing logic.
>
> Expecting this patch to enable lspcon bits in VBT:
> https://lists.freedesktop.org/archives/intel-gfx/2016-March/089541.html
FYI, an updated version of that patch has been pushed now.
BR,
Jani.
>
> Signed-off-by: Shashank Sharma <shashank.sharma@intel.com>
> ---
> drivers/gpu/drm/i915/intel_ddi.c | 15 +++++++++++++++
> drivers/gpu/drm/i915/intel_drv.h | 4 ++++
> drivers/gpu/drm/i915/intel_lspcon.c | 10 ++++++++++
> 3 files changed, 29 insertions(+)
>
> diff --git a/drivers/gpu/drm/i915/intel_ddi.c b/drivers/gpu/drm/i915/intel_ddi.c
> index 91654ff..f6c2869 100644
> --- a/drivers/gpu/drm/i915/intel_ddi.c
> +++ b/drivers/gpu/drm/i915/intel_ddi.c
> @@ -2169,6 +2169,21 @@ void intel_ddi_init(struct drm_device *dev, enum port port)
> intel_encoder->crtc_mask = (1 << 0) | (1 << 1) | (1 << 2);
> intel_encoder->cloneable = 0;
>
> +
> + /* Check if LSPCON is configured on this port */
> + if (is_lspcon_present_on_port(dev_priv, intel_dig_port->port)) {
> + if (!intel_lspcon_init_connector(intel_dig_port)) {
> + DRM_DEBUG_KMS("LSPCON configured for port %c\n",
> + port_name(intel_dig_port->port));
> + return;
> + } else {
> + DRM_ERROR("Can't set LSPCON(port %c), falling to DP/HDMI\n",
> + port_name(intel_dig_port->port));
> + init_dp = true;
> + init_hdmi = true;
> + }
> + }
> +
> if (init_dp) {
> if (!intel_ddi_init_dp_connector(intel_dig_port))
> goto err;
> diff --git a/drivers/gpu/drm/i915/intel_drv.h b/drivers/gpu/drm/i915/intel_drv.h
> index a6ec946..922852c 100644
> --- a/drivers/gpu/drm/i915/intel_drv.h
> +++ b/drivers/gpu/drm/i915/intel_drv.h
> @@ -1345,6 +1345,10 @@ void intel_dsi_init(struct drm_device *dev);
> /* intel_dvo.c */
> void intel_dvo_init(struct drm_device *dev);
>
> +/* intel_lspcon.c */
> +int intel_lspcon_init_connector(struct intel_digital_port *intel_dig_port);
> +bool is_lspcon_present_on_port(struct drm_i915_private * dev_priv,
> + enum port port);
>
> /* legacy fbdev emulation in intel_fbdev.c */
> #ifdef CONFIG_DRM_FBDEV_EMULATION
> diff --git a/drivers/gpu/drm/i915/intel_lspcon.c b/drivers/gpu/drm/i915/intel_lspcon.c
> index 20f90e0..96e4c71 100644
> --- a/drivers/gpu/drm/i915/intel_lspcon.c
> +++ b/drivers/gpu/drm/i915/intel_lspcon.c
> @@ -397,6 +397,16 @@ static const struct drm_connector_helper_funcs lspcon_connector_helper_funcs = {
> .best_encoder = intel_best_encoder,
> };
>
> +bool is_lspcon_present_on_port(struct drm_i915_private *dev_priv, enum port port)
> +{
> + /*
> + * TODO: HACK
> + * Replace this with proper VBT child dev config check
> + * logic once that patch is available in tree
> + */
> + return IS_GEN9(dev_priv->dev) && (port == PORT_B);
> +}
> +
> int intel_lspcon_init_connector(struct intel_digital_port *intel_dig_port)
> {
> int ret;
--
Jani Nikula, Intel Open Source Technology Center
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
next prev parent reply other threads:[~2016-04-06 12:18 UTC|newest]
Thread overview: 34+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-04-04 12:01 [PATCH 01/12] drm: Add helper for DP++ adaptors Shashank Sharma
2016-04-04 12:01 ` [PATCH 02/12] drm/i915: Respect DP++ adaptor TMDS clock limit Shashank Sharma
2016-04-04 12:01 ` [PATCH 03/12] drm/i915: Enable/disable TMDS output buffers in DP++ adaptor as needed Shashank Sharma
2016-04-04 12:01 ` [PATCH 04/12] drm/i915: Determine DP++ type 1 DVI adaptor presence based on VBT Shashank Sharma
2016-05-02 14:33 ` Jani Nikula
2016-05-02 14:39 ` Ville Syrjälä
2016-05-03 15:52 ` Sharma, Shashank
2016-04-04 12:01 ` [PATCH 05/12] drm/i915: Add lspcon data structures Shashank Sharma
2016-04-04 12:01 ` [PATCH 06/12] drm/i915: Add new lspcon file Shashank Sharma
2016-05-02 13:37 ` Ville Syrjälä
2016-05-03 15:39 ` Sharma, Shashank
2016-05-02 14:35 ` Jani Nikula
2016-05-03 15:53 ` Sharma, Shashank
2016-04-04 12:01 ` [PATCH 07/12] drm/i915: Add and initialize lspcon connector Shashank Sharma
2016-04-25 21:34 ` Zanoni, Paulo R
2016-04-04 12:01 ` [PATCH 08/12] drm: Add lspcon (custom type2 dp->hdmi) support Shashank Sharma
2016-05-02 13:49 ` Ville Syrjälä
2016-05-03 15:45 ` Sharma, Shashank
2016-05-03 15:59 ` Ville Syrjälä
2016-05-03 16:09 ` Sharma, Shashank
2016-05-03 17:19 ` Ville Syrjälä
2016-04-04 12:01 ` [PATCH 09/12] drm/i915: Add and register lspcon connector functions Shashank Sharma
2016-04-04 12:01 ` [PATCH 10/12] drm/i915: Add lspcon core functions Shashank Sharma
2016-05-02 13:51 ` Ville Syrjälä
2016-05-03 15:48 ` Sharma, Shashank
2016-05-03 16:09 ` Ville Syrjälä
2016-05-03 16:14 ` Sharma, Shashank
2016-05-04 21:09 ` Zanoni, Paulo R
2016-05-06 10:16 ` Ville Syrjälä
2016-04-04 12:01 ` [PATCH 11/12] drm/i915: Add lspcon hpd handler Shashank Sharma
2016-04-04 12:01 ` [PATCH 12/12] DO_NOT_MERGE: drm/i915: Hack to enable lspcon initialization Shashank Sharma
2016-04-06 12:18 ` Jani Nikula [this message]
2016-04-06 13:02 ` Sharma, Shashank
2016-04-04 13:33 ` ✗ Fi.CI.BAT: failure for series starting with [01/12] drm: Add helper for DP++ adaptors 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=87zit7vsl3.fsf@intel.com \
--to=jani.nikula@linux.intel.com \
--cc=daniel.vetter@intel.com \
--cc=intel-gfx@lists.freedesktop.org \
--cc=paulo.r.zanoni@intel.com \
--cc=shashank.sharma@intel.com \
--cc=sivakumar.thulasimani@intel.com \
--cc=sonika.jindal@intel.com \
--cc=ville.syrjala@linux.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