All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jani Nikula <jani.nikula@intel.com>
To: intel-gfx@lists.freedesktop.org
Cc: Deepak M <m.deepak@intel.com>, jani.nikula@intel.com
Subject: [PATCH 01/11] drm/i915: Add Intel opregion mailbox 5 structure
Date: Mon, 14 Dec 2015 12:50:45 +0200	[thread overview]
Message-ID: <c2d4009659fca32280d9859ec34a62f45b86d895.1450089383.git.jani.nikula@intel.com> (raw)
In-Reply-To: <cover.1450089383.git.jani.nikula@intel.com>
In-Reply-To: <cover.1450089383.git.jani.nikula@intel.com>

From: Deepak M <m.deepak@intel.com>

Mailbox 5 is BIOS to Driver Notification mailbox is intended
to support BIOS to Driver event notification or data storage
for BIOS to Driver data synchronization purpose. Mailbox 5 is
the extension of mailbox 3.

v4 by Jani:
 - don't add asle_ext to dev_priv as it's unused
 - use u8 for bddc and rsvd fields in asle ext struct
 - add BUILD_BUG_ON the asle ext struct size
 - debug logging for asle ext present

Cc: Jani Nikula <jani.nikula@intel.com>
Signed-off-by: Deepak M <m.deepak@intel.com>
Signed-off-by: Jani Nikula <jani.nikula@intel.com>
---
 drivers/gpu/drm/i915/intel_opregion.c | 13 +++++++++++++
 1 file changed, 13 insertions(+)

diff --git a/drivers/gpu/drm/i915/intel_opregion.c b/drivers/gpu/drm/i915/intel_opregion.c
index 64efedfad879..cd97b9a5df57 100644
--- a/drivers/gpu/drm/i915/intel_opregion.c
+++ b/drivers/gpu/drm/i915/intel_opregion.c
@@ -46,6 +46,7 @@
 #define OPREGION_SWSCI_OFFSET  0x200
 #define OPREGION_ASLE_OFFSET   0x300
 #define OPREGION_VBT_OFFSET    0x400
+#define OPREGION_ASLE_EXT_OFFSET	0x1C00
 
 #define OPREGION_SIGNATURE "IntelGraphicsMem"
 #define MBOX_ACPI      (1<<0)
@@ -125,6 +126,13 @@ struct opregion_asle {
 	u8 rsvd[58];
 } __packed;
 
+/* OpRegion mailbox #5: ASLE ext */
+struct opregion_asle_ext {
+	u32 phed;	/* Panel Header */
+	u8 bddc[256];	/* Panel EDID */
+	u8 rsvd[764];
+} __packed;
+
 /* Driver readiness indicator */
 #define ASLE_ARDY_READY		(1 << 0)
 #define ASLE_ARDY_NOT_READY	(0 << 0)
@@ -909,6 +917,7 @@ int intel_opregion_setup(struct drm_device *dev)
 	BUILD_BUG_ON(sizeof(struct opregion_acpi) != 0x100);
 	BUILD_BUG_ON(sizeof(struct opregion_swsci) != 0x100);
 	BUILD_BUG_ON(sizeof(struct opregion_asle) != 0x100);
+	BUILD_BUG_ON(sizeof(struct opregion_asle_ext) != 0x400);
 
 	pci_read_config_dword(dev->pdev, PCI_ASLS, &asls);
 	DRM_DEBUG_DRIVER("graphic opregion physical addr: 0x%x\n", asls);
@@ -948,6 +957,7 @@ int intel_opregion_setup(struct drm_device *dev)
 		opregion->swsci = base + OPREGION_SWSCI_OFFSET;
 		swsci_setup(dev);
 	}
+
 	if (mboxes & MBOX_ASLE) {
 		DRM_DEBUG_DRIVER("ASLE supported\n");
 		opregion->asle = base + OPREGION_ASLE_OFFSET;
@@ -955,6 +965,9 @@ int intel_opregion_setup(struct drm_device *dev)
 		opregion->asle->ardy = ASLE_ARDY_NOT_READY;
 	}
 
+	if (mboxes & MBOX_ASLE_EXT)
+		DRM_DEBUG_DRIVER("ASLE extension supported\n");
+
 	return 0;
 
 err_out:
-- 
2.1.4

_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/intel-gfx

  reply	other threads:[~2015-12-14 10:50 UTC|newest]

Thread overview: 33+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-12-14 10:50 [PATCH 00/11] drm/i915: VBT/opregion refactor to support >6 KB VBT Jani Nikula
2015-12-14 10:50 ` Jani Nikula [this message]
2015-12-14 10:50 ` [PATCH 02/11] drm/i915: move "no VBT in opregion" quirk to intel_opregion_setup() Jani Nikula
2015-12-14 10:50 ` [PATCH 03/11] drm/i915/bios: have functions return vbt, not bdb, header pointer Jani Nikula
2015-12-14 10:50 ` [PATCH 04/11] drm/i915/bios: move debug logging about VBT source to intel_parse_bios() Jani Nikula
2015-12-15 11:14   ` [PATCH v2 " Jani Nikula
2015-12-14 10:50 ` [PATCH 05/11] drm/i915/bios: rename intel_parse_bios to intel_bios_init Jani Nikula
2015-12-14 10:50 ` [PATCH 06/11] drm/i915: refactor VBT validation Jani Nikula
2015-12-14 13:41   ` Ville Syrjälä
2015-12-14 14:34     ` Jani Nikula
2015-12-14 14:42       ` Ville Syrjälä
2015-12-15 11:16   ` [PATCH v2 " Jani Nikula
2015-12-14 10:50 ` [PATCH 07/11] drm/i915/opregion: make VBT size limit more strict Jani Nikula
2015-12-14 10:50 ` [PATCH 08/11] drm/i915/opregion: make VBT pointer a const Jani Nikula
2015-12-14 10:50 ` [PATCH 09/11] drm/i915: don't use a temp buffer for opregion debugfs file Jani Nikula
2015-12-14 13:45   ` Ville Syrjälä
2015-12-14 14:38     ` Jani Nikula
2015-12-14 14:45       ` Ville Syrjälä
2015-12-14 10:50 ` [PATCH 10/11] drm/i915/debugfs: add a separate debugfs file for VBT Jani Nikula
2015-12-14 10:57   ` Chris Wilson
2015-12-14 11:06     ` Jani Nikula
2015-12-14 11:29       ` Chris Wilson
2015-12-14 13:20   ` [PATCH v2 " Jani Nikula
2015-12-15 11:17     ` [PATCH v3 " Jani Nikula
2015-12-14 10:50 ` [PATCH 11/11] drm/i915/opregion: handle VBT sizes bigger than 6 KB Jani Nikula
2015-12-14 14:19   ` Ville Syrjälä
2015-12-14 14:34     ` Ville Syrjälä
2015-12-15 14:02       ` Ville Syrjälä
2015-12-16  9:37         ` Jani Nikula
2015-12-14 14:40     ` Jani Nikula
2015-12-15 11:18   ` [PATCH v2 " Jani Nikula
2015-12-17  7:30   ` [PATCH " Mika Kahola
2015-12-17  9:46     ` Jani Nikula

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=c2d4009659fca32280d9859ec34a62f45b86d895.1450089383.git.jani.nikula@intel.com \
    --to=jani.nikula@intel.com \
    --cc=intel-gfx@lists.freedesktop.org \
    --cc=m.deepak@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 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.