From patchwork Thu Sep 3 11:55:01 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: David Henningsson X-Patchwork-Id: 514010 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from huckleberry.canonical.com (huckleberry.canonical.com [91.189.94.19]) by ozlabs.org (Postfix) with ESMTP id 9FBCC14028F; Thu, 3 Sep 2015 21:55:27 +1000 (AEST) Received: from localhost ([127.0.0.1] helo=huckleberry.canonical.com) by huckleberry.canonical.com with esmtp (Exim 4.76) (envelope-from ) id 1ZXT6x-0006aV-2M; Thu, 03 Sep 2015 11:55:23 +0000 Received: from youngberry.canonical.com ([91.189.89.112]) by huckleberry.canonical.com with esmtp (Exim 4.76) (envelope-from ) id 1ZXT6g-0006U8-Gk for kernel-team@lists.ubuntu.com; Thu, 03 Sep 2015 11:55:06 +0000 Received: from c83-254-154-239.bredband.comhem.se ([83.254.154.239] helo=localhost.localdomain) by youngberry.canonical.com with esmtpsa (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.76) (envelope-from ) id 1ZXT6g-0005cs-Db; Thu, 03 Sep 2015 11:55:06 +0000 From: David Henningsson To: kernel-team@lists.ubuntu.com Subject: [PATCH v2 1/6] drm/i915: Add audio pin sense / ELD callback Date: Thu, 3 Sep 2015 13:55:01 +0200 Message-Id: <1441281306-1481-2-git-send-email-david.henningsson@canonical.com> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1441281306-1481-1-git-send-email-david.henningsson@canonical.com> References: <1441281306-1481-1-git-send-email-david.henningsson@canonical.com> Cc: jerry.kao@canonical.com X-BeenThere: kernel-team@lists.ubuntu.com X-Mailman-Version: 2.1.14 Precedence: list List-Id: Kernel team discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: kernel-team-bounces@lists.ubuntu.com Sender: kernel-team-bounces@lists.ubuntu.com This callback will be called by the i915 driver to notify the hda driver that its HDMI information needs to be refreshed, i e, that audio output is now available (or unavailable) - usually as a result of a monitor being plugged in (or unplugged). Signed-off-by: David Henningsson --- include/drm/i915_component.h | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/include/drm/i915_component.h b/include/drm/i915_component.h index c9a8b64..c0f4d45 100644 --- a/include/drm/i915_component.h +++ b/include/drm/i915_component.h @@ -34,6 +34,22 @@ struct i915_audio_component { void (*codec_wake_override)(struct device *, bool enable); int (*get_cdclk_freq)(struct device *); } *ops; + + const struct i915_audio_component_audio_ops { + /** + * @audio_ptr: + * + * Pointer to pass when calling pin_eld_notify. + */ + void *audio_ptr; + /** + * @pin_eld_notify: + * + * Called from i915 driver, notifying the HDA driver that + * pin sense and/or ELD information has changed. + */ + void (*pin_eld_notify)(void *audio_ptr, int port); + } *audio_ops; }; #endif /* _I915_COMPONENT_H_ */