From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751753AbdG0Iue (ORCPT ); Thu, 27 Jul 2017 04:50:34 -0400 Received: from mga04.intel.com ([192.55.52.120]:27597 "EHLO mga04.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751427AbdG0Iua (ORCPT ); Thu, 27 Jul 2017 04:50:30 -0400 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.40,419,1496127600"; d="scan'208";a="1176937576" Date: Thu, 27 Jul 2017 11:50:11 +0300 From: Mika Westerberg To: "Rafael J. Wysocki" Cc: LKML , Linux PM , Andreas Noever , Michael Jamet , Greg Kroah-Hartman Subject: Re: [RFC][PATCH] thunderbolt: icm: Ignore mailbox errors in icm_suspend() Message-ID: <20170727085011.GY2369@lahna.fi.intel.com> References: <4063610.TqANq0McE8@aspire.rjw.lan> <2817723.OEn9Hxcbhj@aspire.rjw.lan> <20170726131259.GM2369@lahna.fi.intel.com> <4165239.xHgWvuTePe@aspire.rjw.lan> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <4165239.xHgWvuTePe@aspire.rjw.lan> Organization: Intel Finland Oy - BIC 0357606-4 - Westendinkatu 7, 02160 Espoo User-Agent: Mutt/1.7.1 (2016-10-04) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Jul 26, 2017 at 07:05:01PM +0200, Rafael J. Wysocki wrote: > On Wednesday, July 26, 2017 04:12:59 PM Mika Westerberg wrote: > > On Wed, Jul 26, 2017 at 02:48:54PM +0200, Rafael J. Wysocki wrote: > > > On Wednesday, July 26, 2017 11:32:44 AM Mika Westerberg wrote: > > > > On Tue, Jul 25, 2017 at 06:10:57PM +0200, Rafael J. Wysocki wrote: > > > > > On Tuesday, July 25, 2017 01:00:12 PM Mika Westerberg wrote: > > > > > > On Tue, Jul 25, 2017 at 01:31:00AM +0200, Rafael J. Wysocki wrote: > > > > > > > From: Rafael J. Wysocki > > > > > > > > > > > > > > On one of my test machines nhi_mailbox_cmd() called from icm_suspend() > > > > > > > times out and returnes an error which then is propagated to the > > > > > > > caller and causes the entire system suspend to be aborted which isn't > > > > > > > very useful. > > > > > > > > > > > > > > Instead of aborting system suspend, print the error into the log > > > > > > > and continue. > > > > > > > > > > > > I agree, it should not prevent suspend but I wonder why it fails in the > > > > > > first place? Can you check what is the return value? > > > > > > > > > > As per the above, the error is a timeout, ie. -ETIMEDOUT. > > > > > > > > Ah, right I somehow missed that. > > > > > > > > Does it have Falcon Ridge controller or Alpine Ridge? > > > > > > I'll check later today, but i guess you'll know (see below). > > > > No need to check, it is Alpine Ridge (since it is Dell 9360). > > > > > > Just to make sure, can you increase the timeout in nhi_mailbox_cmd() > > > > to 1000ms or so. It should not take that long though but better to check. > > > > > > Well, I can do that, but I don't think it will help. > > > > > > It just looks like the chip is not responding at all at that point. > > > > I see. > > > > Then I think we should apply your patch now and we can investigate this > > further offline and hopefully find the root cause for the problem. > > > > For this patch: > > > > Acked-by: Mika Westerberg > > OK > > I guess I can apply it, then, or if anyone else in the CC wants to do that, > please let me know. Greg typically takes these but I'm fine either way. (Eventually we should probably establish Thunderbolt tree/branch in kernel.org where we gather all Thunderbolt related patches and just send pull request to Greg or something like that). > > > > Which system this is BTW? > > > > > > It's the Dell 9360. :-) > > > > > > Sometimes after a reboot or a power cycle it starts in a state in which the > > > TBT controller and a USB one (which seem to be somehow connected) > > > appear to be dead or at least really flaky. Basically, the box needs to be > > > power-cycled again to get rid of this condition and then everything works. > > > > The xHCI controller is part of the Thunderbolt controller so whenever > > you have normal USB-C device connected there, you should also see the > > Alpine Ridge hierarchy in lspci output but the Thunderbolt host > > controller is not there. > > I don't have any USB-C devices, though, so I can't really test it this way ATM. > > It's jjust never used now. :-) OK. We have one 9365 which I think should be pretty similar. I'll give it a try once I find it ;-)