* [PATCH v3] drm/i915: Fix not finding the VBT when it overlaps with OPREGION_ASLE_EXT
@ 2017-02-14 16:12 Jani Nikula
2017-02-14 19:51 ` ✓ Fi.CI.BAT: success for " Patchwork
2017-02-15 8:58 ` Hans de Goede
0 siblings, 2 replies; 5+ messages in thread
From: Jani Nikula @ 2017-02-14 16:12 UTC (permalink / raw)
To: intel-gfx; +Cc: jani.nikula, Hans de Goede, Ville Syrjälä, stable
From: Hans de Goede <hdegoede@redhat.com>
If there is no OPREGION_ASLE_EXT then a VBT stored in mailbox #4 may
use the ASLE_EXT parts of the opregion. Adjust the vbt_size calculation
for a vbt in mailbox #4 for this.
This fixes the driver not finding the VBT on a jumper ezpad mini3
cherrytrail tablet and on a ACER SW5_017 machine.
Cc: stable@vger.kernel.org
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Jani Nikula <jani.nikula@intel.com>
---
Hans, I'm resending because for some reason our CI didn't pick this
up. Fixed a s/one/on/ typo in the comment while at it.
---
drivers/gpu/drm/i915/intel_opregion.c | 13 ++++++++++++-
1 file changed, 12 insertions(+), 1 deletion(-)
diff --git a/drivers/gpu/drm/i915/intel_opregion.c b/drivers/gpu/drm/i915/intel_opregion.c
index f4429f67a4e3..4a862a358c70 100644
--- a/drivers/gpu/drm/i915/intel_opregion.c
+++ b/drivers/gpu/drm/i915/intel_opregion.c
@@ -982,7 +982,18 @@ int intel_opregion_setup(struct drm_i915_private *dev_priv)
opregion->vbt_size = vbt_size;
} else {
vbt = base + OPREGION_VBT_OFFSET;
- vbt_size = OPREGION_ASLE_EXT_OFFSET - OPREGION_VBT_OFFSET;
+ /*
+ * The VBT specification says that if the ASLE ext
+ * mailbox is not used its area is reserved, but
+ * on some CHT boards the VBT extends into the
+ * ASLE ext area. Allow this even though it is
+ * against the spec, so we do not end up rejecting
+ * the VBT on those boards (and end up not finding the
+ * LCD panel because of this).
+ */
+ vbt_size = (mboxes & MBOX_ASLE_EXT) ?
+ OPREGION_ASLE_EXT_OFFSET : OPREGION_SIZE;
+ vbt_size -= OPREGION_VBT_OFFSET;
if (intel_bios_is_valid_vbt(vbt, vbt_size)) {
DRM_DEBUG_KMS("Found valid VBT in ACPI OpRegion (Mailbox #4)\n");
opregion->vbt = vbt;
--
2.1.4
^ permalink raw reply related [flat|nested] 5+ messages in thread
* ✓ Fi.CI.BAT: success for drm/i915: Fix not finding the VBT when it overlaps with OPREGION_ASLE_EXT
2017-02-14 16:12 [PATCH v3] drm/i915: Fix not finding the VBT when it overlaps with OPREGION_ASLE_EXT Jani Nikula
@ 2017-02-14 19:51 ` Patchwork
2017-02-15 8:58 ` Hans de Goede
1 sibling, 0 replies; 5+ messages in thread
From: Patchwork @ 2017-02-14 19:51 UTC (permalink / raw)
To: Jani Nikula; +Cc: intel-gfx
== Series Details ==
Series: drm/i915: Fix not finding the VBT when it overlaps with OPREGION_ASLE_EXT
URL : https://patchwork.freedesktop.org/series/19645/
State : success
== Summary ==
Series 19645v1 drm/i915: Fix not finding the VBT when it overlaps with OPREGION_ASLE_EXT
https://patchwork.freedesktop.org/api/1.0/series/19645/revisions/1/mbox/
fi-bdw-5557u total:252 pass:241 dwarn:0 dfail:0 fail:0 skip:11
fi-bsw-n3050 total:252 pass:213 dwarn:0 dfail:0 fail:0 skip:39
fi-bxt-j4205 total:252 pass:233 dwarn:0 dfail:0 fail:0 skip:19
fi-bxt-t5700 total:83 pass:70 dwarn:0 dfail:0 fail:0 skip:12
fi-byt-j1900 total:252 pass:225 dwarn:0 dfail:0 fail:0 skip:27
fi-byt-n2820 total:252 pass:221 dwarn:0 dfail:0 fail:0 skip:31
fi-hsw-4770 total:252 pass:236 dwarn:0 dfail:0 fail:0 skip:16
fi-hsw-4770r total:252 pass:236 dwarn:0 dfail:0 fail:0 skip:16
fi-ilk-650 total:252 pass:202 dwarn:0 dfail:0 fail:0 skip:50
fi-ivb-3520m total:252 pass:234 dwarn:0 dfail:0 fail:0 skip:18
fi-ivb-3770 total:252 pass:234 dwarn:0 dfail:0 fail:0 skip:18
fi-kbl-7500u total:252 pass:234 dwarn:0 dfail:0 fail:0 skip:18
fi-skl-6260u total:252 pass:242 dwarn:0 dfail:0 fail:0 skip:10
fi-skl-6700hq total:252 pass:235 dwarn:0 dfail:0 fail:0 skip:17
fi-skl-6700k total:252 pass:230 dwarn:4 dfail:0 fail:0 skip:18
fi-skl-6770hq total:252 pass:242 dwarn:0 dfail:0 fail:0 skip:10
fi-snb-2520m total:252 pass:224 dwarn:0 dfail:0 fail:0 skip:28
fi-snb-2600 total:252 pass:223 dwarn:0 dfail:0 fail:0 skip:29
7b80cb5504b3b3cebaea944d35f25e27415e89a6 drm-tip: 2017y-02m-14d-14h-36m-43s UTC integration manifest
78afa55 drm/i915: Fix not finding the VBT when it overlaps with OPREGION_ASLE_EXT
== Logs ==
For more details see: https://intel-gfx-ci.01.org/CI/Patchwork_3811/
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH v3] drm/i915: Fix not finding the VBT when it overlaps with OPREGION_ASLE_EXT
2017-02-14 16:12 [PATCH v3] drm/i915: Fix not finding the VBT when it overlaps with OPREGION_ASLE_EXT Jani Nikula
@ 2017-02-15 8:58 ` Hans de Goede
2017-02-15 8:58 ` Hans de Goede
1 sibling, 0 replies; 5+ messages in thread
From: Hans de Goede @ 2017-02-15 8:58 UTC (permalink / raw)
To: Jani Nikula, intel-gfx; +Cc: Ville Syrjälä, stable
Hi,
On 14-02-17 17:12, Jani Nikula wrote:
> From: Hans de Goede <hdegoede@redhat.com>
>
> If there is no OPREGION_ASLE_EXT then a VBT stored in mailbox #4 may
> use the ASLE_EXT parts of the opregion. Adjust the vbt_size calculation
> for a vbt in mailbox #4 for this.
>
> This fixes the driver not finding the VBT on a jumper ezpad mini3
> cherrytrail tablet and on a ACER SW5_017 machine.
>
> Cc: stable@vger.kernel.org
> Signed-off-by: Hans de Goede <hdegoede@redhat.com>
> Signed-off-by: Jani Nikula <jani.nikula@intel.com>
>
> ---
>
> Hans, I'm resending because for some reason our CI didn't pick this
> up. Fixed a s/one/on/ typo in the comment while at it.
Ok. Let me know if you need me to do anything to move this forward.
Regards,
Hans
> ---
> drivers/gpu/drm/i915/intel_opregion.c | 13 ++++++++++++-
> 1 file changed, 12 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/gpu/drm/i915/intel_opregion.c b/drivers/gpu/drm/i915/intel_opregion.c
> index f4429f67a4e3..4a862a358c70 100644
> --- a/drivers/gpu/drm/i915/intel_opregion.c
> +++ b/drivers/gpu/drm/i915/intel_opregion.c
> @@ -982,7 +982,18 @@ int intel_opregion_setup(struct drm_i915_private *dev_priv)
> opregion->vbt_size = vbt_size;
> } else {
> vbt = base + OPREGION_VBT_OFFSET;
> - vbt_size = OPREGION_ASLE_EXT_OFFSET - OPREGION_VBT_OFFSET;
> + /*
> + * The VBT specification says that if the ASLE ext
> + * mailbox is not used its area is reserved, but
> + * on some CHT boards the VBT extends into the
> + * ASLE ext area. Allow this even though it is
> + * against the spec, so we do not end up rejecting
> + * the VBT on those boards (and end up not finding the
> + * LCD panel because of this).
> + */
> + vbt_size = (mboxes & MBOX_ASLE_EXT) ?
> + OPREGION_ASLE_EXT_OFFSET : OPREGION_SIZE;
> + vbt_size -= OPREGION_VBT_OFFSET;
> if (intel_bios_is_valid_vbt(vbt, vbt_size)) {
> DRM_DEBUG_KMS("Found valid VBT in ACPI OpRegion (Mailbox #4)\n");
> opregion->vbt = vbt;
>
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH v3] drm/i915: Fix not finding the VBT when it overlaps with OPREGION_ASLE_EXT
@ 2017-02-15 8:58 ` Hans de Goede
0 siblings, 0 replies; 5+ messages in thread
From: Hans de Goede @ 2017-02-15 8:58 UTC (permalink / raw)
To: Jani Nikula, intel-gfx; +Cc: stable
Hi,
On 14-02-17 17:12, Jani Nikula wrote:
> From: Hans de Goede <hdegoede@redhat.com>
>
> If there is no OPREGION_ASLE_EXT then a VBT stored in mailbox #4 may
> use the ASLE_EXT parts of the opregion. Adjust the vbt_size calculation
> for a vbt in mailbox #4 for this.
>
> This fixes the driver not finding the VBT on a jumper ezpad mini3
> cherrytrail tablet and on a ACER SW5_017 machine.
>
> Cc: stable@vger.kernel.org
> Signed-off-by: Hans de Goede <hdegoede@redhat.com>
> Signed-off-by: Jani Nikula <jani.nikula@intel.com>
>
> ---
>
> Hans, I'm resending because for some reason our CI didn't pick this
> up. Fixed a s/one/on/ typo in the comment while at it.
Ok. Let me know if you need me to do anything to move this forward.
Regards,
Hans
> ---
> drivers/gpu/drm/i915/intel_opregion.c | 13 ++++++++++++-
> 1 file changed, 12 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/gpu/drm/i915/intel_opregion.c b/drivers/gpu/drm/i915/intel_opregion.c
> index f4429f67a4e3..4a862a358c70 100644
> --- a/drivers/gpu/drm/i915/intel_opregion.c
> +++ b/drivers/gpu/drm/i915/intel_opregion.c
> @@ -982,7 +982,18 @@ int intel_opregion_setup(struct drm_i915_private *dev_priv)
> opregion->vbt_size = vbt_size;
> } else {
> vbt = base + OPREGION_VBT_OFFSET;
> - vbt_size = OPREGION_ASLE_EXT_OFFSET - OPREGION_VBT_OFFSET;
> + /*
> + * The VBT specification says that if the ASLE ext
> + * mailbox is not used its area is reserved, but
> + * on some CHT boards the VBT extends into the
> + * ASLE ext area. Allow this even though it is
> + * against the spec, so we do not end up rejecting
> + * the VBT on those boards (and end up not finding the
> + * LCD panel because of this).
> + */
> + vbt_size = (mboxes & MBOX_ASLE_EXT) ?
> + OPREGION_ASLE_EXT_OFFSET : OPREGION_SIZE;
> + vbt_size -= OPREGION_VBT_OFFSET;
> if (intel_bios_is_valid_vbt(vbt, vbt_size)) {
> DRM_DEBUG_KMS("Found valid VBT in ACPI OpRegion (Mailbox #4)\n");
> opregion->vbt = vbt;
>
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH v3] drm/i915: Fix not finding the VBT when it overlaps with OPREGION_ASLE_EXT
2017-02-15 8:58 ` Hans de Goede
(?)
@ 2017-02-15 9:31 ` Jani Nikula
-1 siblings, 0 replies; 5+ messages in thread
From: Jani Nikula @ 2017-02-15 9:31 UTC (permalink / raw)
To: Hans de Goede, intel-gfx; +Cc: Ville Syrjälä, stable
On Wed, 15 Feb 2017, Hans de Goede <hdegoede@redhat.com> wrote:
> Hi,
>
> On 14-02-17 17:12, Jani Nikula wrote:
>> From: Hans de Goede <hdegoede@redhat.com>
>>
>> If there is no OPREGION_ASLE_EXT then a VBT stored in mailbox #4 may
>> use the ASLE_EXT parts of the opregion. Adjust the vbt_size calculation
>> for a vbt in mailbox #4 for this.
>>
>> This fixes the driver not finding the VBT on a jumper ezpad mini3
>> cherrytrail tablet and on a ACER SW5_017 machine.
>>
>> Cc: stable@vger.kernel.org
>> Signed-off-by: Hans de Goede <hdegoede@redhat.com>
>> Signed-off-by: Jani Nikula <jani.nikula@intel.com>
>>
>> ---
>>
>> Hans, I'm resending because for some reason our CI didn't pick this
>> up. Fixed a s/one/on/ typo in the comment while at it.
>
> Ok. Let me know if you need me to do anything to move this forward.
No, just sit back. Pushed to drm-intel-next-queued, thanks for the
patch.
BR,
Jani.
>
> Regards,
>
> Hans
>
>
>> ---
>> drivers/gpu/drm/i915/intel_opregion.c | 13 ++++++++++++-
>> 1 file changed, 12 insertions(+), 1 deletion(-)
>>
>> diff --git a/drivers/gpu/drm/i915/intel_opregion.c b/drivers/gpu/drm/i915/intel_opregion.c
>> index f4429f67a4e3..4a862a358c70 100644
>> --- a/drivers/gpu/drm/i915/intel_opregion.c
>> +++ b/drivers/gpu/drm/i915/intel_opregion.c
>> @@ -982,7 +982,18 @@ int intel_opregion_setup(struct drm_i915_private *dev_priv)
>> opregion->vbt_size = vbt_size;
>> } else {
>> vbt = base + OPREGION_VBT_OFFSET;
>> - vbt_size = OPREGION_ASLE_EXT_OFFSET - OPREGION_VBT_OFFSET;
>> + /*
>> + * The VBT specification says that if the ASLE ext
>> + * mailbox is not used its area is reserved, but
>> + * on some CHT boards the VBT extends into the
>> + * ASLE ext area. Allow this even though it is
>> + * against the spec, so we do not end up rejecting
>> + * the VBT on those boards (and end up not finding the
>> + * LCD panel because of this).
>> + */
>> + vbt_size = (mboxes & MBOX_ASLE_EXT) ?
>> + OPREGION_ASLE_EXT_OFFSET : OPREGION_SIZE;
>> + vbt_size -= OPREGION_VBT_OFFSET;
>> if (intel_bios_is_valid_vbt(vbt, vbt_size)) {
>> DRM_DEBUG_KMS("Found valid VBT in ACPI OpRegion (Mailbox #4)\n");
>> opregion->vbt = vbt;
>>
--
Jani Nikula, Intel Open Source Technology Center
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2017-02-15 9:31 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-02-14 16:12 [PATCH v3] drm/i915: Fix not finding the VBT when it overlaps with OPREGION_ASLE_EXT Jani Nikula
2017-02-14 19:51 ` ✓ Fi.CI.BAT: success for " Patchwork
2017-02-15 8:58 ` [PATCH v3] " Hans de Goede
2017-02-15 8:58 ` Hans de Goede
2017-02-15 9:31 ` Jani Nikula
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.