From patchwork Thu Nov 27 13:49:55 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jani Nikula X-Patchwork-Id: 5396431 Return-Path: X-Original-To: patchwork-intel-gfx@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork2.web.kernel.org (Postfix) with ESMTP id D62A4C11AC for ; Thu, 27 Nov 2014 13:49:49 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id ED3DF201EF for ; Thu, 27 Nov 2014 13:49:48 +0000 (UTC) Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) by mail.kernel.org (Postfix) with ESMTP id CD0FD201E4 for ; Thu, 27 Nov 2014 13:49:47 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 364046E986; Thu, 27 Nov 2014 05:49:47 -0800 (PST) X-Original-To: intel-gfx@lists.freedesktop.org Delivered-To: intel-gfx@lists.freedesktop.org Received: from mga01.intel.com (mga01.intel.com [192.55.52.88]) by gabe.freedesktop.org (Postfix) with ESMTP id 0A9416E981; Thu, 27 Nov 2014 05:49:46 -0800 (PST) Received: from fmsmga001.fm.intel.com ([10.253.24.23]) by fmsmga101.fm.intel.com with ESMTP; 27 Nov 2014 05:49:45 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.07,469,1413270000"; d="scan'208";a="629192502" Received: from jnikula-mobl.fi.intel.com (HELO localhost) ([10.237.72.56]) by fmsmga001.fm.intel.com with ESMTP; 27 Nov 2014 05:49:43 -0800 From: Jani Nikula To: Dave Airlie , dri-devel@lists.freedesktop.org, intel-gfx@lists.freedesktop.org In-Reply-To: <1416972325-3137-1-git-send-email-airlied@gmail.com> Organization: Intel Finland Oy - BIC 0357606-4 - Westendinkatu 7, 02160 Espoo References: <1416972325-3137-1-git-send-email-airlied@gmail.com> User-Agent: Notmuch/0.19~rc1+1~g08b4944 (http://notmuchmail.org) Emacs/24.4.1 (x86_64-pc-linux-gnu) Date: Thu, 27 Nov 2014 15:49:55 +0200 Message-ID: <87r3wo3g8s.fsf@intel.com> MIME-Version: 1.0 Subject: Re: [Intel-gfx] [PATCH] drm/dp: retry AUX transactions 32 times (v1.1) X-BeenThere: intel-gfx@lists.freedesktop.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: Intel graphics driver community testing & development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: intel-gfx-bounces@lists.freedesktop.org Sender: "Intel-gfx" X-Spam-Status: No, score=-4.2 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_MED, T_RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP On Wed, 26 Nov 2014, Dave Airlie wrote: > From: Dave Airlie > > At least on two MST devices I've tested with, when > they are link training downstream, they are totally > unable to handle aux ch msgs, so they defer like nuts. > I tried 16, it wasn't enough, 32 seems better. > > This fixes one Dell 4k monitor and one of the > MST hubs. > > v1.1: fixup comment (Tom). Missed this version, see my reply to v1: http://mid.gmane.org/87k32iqppg.fsf@intel.com Also, what if you avoid sink dpms off with: Does it make a difference? BR, Jani. > > Signed-off-by: Dave Airlie > --- > drivers/gpu/drm/drm_dp_helper.c | 7 ++++--- > 1 file changed, 4 insertions(+), 3 deletions(-) > > diff --git a/drivers/gpu/drm/drm_dp_helper.c b/drivers/gpu/drm/drm_dp_helper.c > index 959e207..79968e3 100644 > --- a/drivers/gpu/drm/drm_dp_helper.c > +++ b/drivers/gpu/drm/drm_dp_helper.c > @@ -186,10 +186,11 @@ static int drm_dp_dpcd_access(struct drm_dp_aux *aux, u8 request, > > /* > * The specification doesn't give any recommendation on how often to > - * retry native transactions, so retry 7 times like for I2C-over-AUX > - * transactions. > + * retry native transactions. We used to retry 7 times like for > + * aux i2c transactions but real world devices this wasn't > + * sufficient, bump to 32 which makes Dell 4k monitors happier. > */ > - for (retry = 0; retry < 7; retry++) { > + for (retry = 0; retry < 32; retry++) { > > mutex_lock(&aux->hw_mutex); > err = aux->transfer(aux, &msg); > -- > 2.1.0 > > _______________________________________________ > dri-devel mailing list > dri-devel@lists.freedesktop.org > http://lists.freedesktop.org/mailman/listinfo/dri-devel diff --git a/drivers/gpu/drm/i915/intel_dp.c b/drivers/gpu/drm/i915/intel_dp.c index 70bb8d0b9695..768b1bfaea78 100644 --- a/drivers/gpu/drm/i915/intel_dp.c +++ b/drivers/gpu/drm/i915/intel_dp.c @@ -1932,7 +1932,7 @@ void intel_dp_sink_dpms(struct intel_dp *intel_dp, int mode) if (mode != DRM_MODE_DPMS_ON) { ret = drm_dp_dpcd_writeb(&intel_dp->aux, DP_SET_POWER, - DP_SET_POWER_D3); + DP_SET_POWER_D0); } else { /* * When turning on, we need to retry for 1ms to give the sink