From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753634Ab1LINAA (ORCPT ); Fri, 9 Dec 2011 08:00:00 -0500 Received: from mga03.intel.com ([143.182.124.21]:31189 "EHLO mga03.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753512Ab1LIM77 (ORCPT ); Fri, 9 Dec 2011 07:59:59 -0500 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="4.71,315,1320652800"; d="scan'208";a="83996298" Message-Id: <20111209124556.231744875@intel.com> User-Agent: quilt/0.48-1 Date: Fri, 09 Dec 2011 20:42:21 +0800 From: Wu Fengguang To: Keith Packard cc: Takashi Iwai , Wu Fengguang Cc: Sander Jansen , Christopher White , "intel-gfx@lists.freedesktop.org" , "Pierre-louis Bossart " , "Zhenyu Wang" , Jeremy Bush Cc: LKML Subject: [PATCH 5/5] drm/i915: DisplayPort hot remove notification to audio driver References: <20111209124216.701131933@intel.com> Content-Disposition: inline; filename=dp-eld-hot-disable Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On DP monitor hot remove, clear DP_AUDIO_OUTPUT_ENABLE accordingly, so that the audio driver will receive hot plug events and take action to refresh its device state and ELD contents. Note that the DP_AUDIO_OUTPUT_ENABLE bit may be enabled or disabled only when the link training is complete and set to "Normal". Tested OK for both hot plug/remove and DPMS on/off. Signed-off-by: Wu Fengguang --- drivers/gpu/drm/i915/intel_dp.c | 1 + 1 file changed, 1 insertion(+) --- linux.orig/drivers/gpu/drm/i915/intel_dp.c 2011-12-09 16:51:21.000000000 +0800 +++ linux/drivers/gpu/drm/i915/intel_dp.c 2011-12-09 16:59:45.000000000 +0800 @@ -1771,6 +1771,7 @@ intel_dp_link_down(struct intel_dp *inte intel_wait_for_vblank(dev, to_intel_crtc(crtc)->pipe); } + DP &= ~DP_AUDIO_OUTPUT_ENABLE; I915_WRITE(intel_dp->output_reg, DP & ~DP_PORT_EN); POSTING_READ(intel_dp->output_reg); msleep(intel_dp->panel_power_down_delay);