Received: by 10.213.65.68 with SMTP id h4csp1671697imn; Thu, 15 Mar 2018 06:29:58 -0700 (PDT) X-Google-Smtp-Source: AG47ELsO7VPlnKz9UPxDZ/NkM4mi3JrqFt5Z/gW5wux3sYYasA960MEbZkQTsAfTzW52V1qJO4z2 X-Received: by 2002:a17:902:a9c7:: with SMTP id b7-v6mr7982893plr.190.1521120598600; Thu, 15 Mar 2018 06:29:58 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1521120598; cv=none; d=google.com; s=arc-20160816; b=yCcbQWfJWsPt3/eo00PTZb58QzzUIyzvqwI4xEYLVYPNe10xfwCZDIpvxNxtpwAtbX jiQZayHlcFF+o8iEpCarVKVB9HuJGEVk0h7Ka0puIee0nqnpmtCi3gnVla9kzs4N8Thl qUbsSjr/1Ay7UrMVqMsNID5ghPZuOg/0eVqdrmcccv21LVrsz5wph/bMwJxQGjB1gRN4 vi5d5eMmRwEhV27RjkAQD2R6FsukQlkba0diEoDj/n42lo/gV8eqTC1Epsn0t9ufjUNi Cs/05Ff/Z866113OiCsnPYKjybcwvGjo6XAdFqUNy/bpJ0ShDwgA6iF2fAtmBGuhZOFz ODnw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:cc:to:subject :message-id:date:from:references:in-reply-to:mime-version :dkim-signature:arc-authentication-results; bh=NOiA2IRMusa669mftKTicxII6KFxlvjnMdmD8qfzyx8=; b=QVzqgIiOmYFcNap6Wwgpti01d/tAl7V4QM0nnegBcAGmyiJ+5pLPL8cKbbDzhwYj1V VzcJW/UPnWUpBEP6tdAlpT6swd+coXO4juJVDTSgAVz3HvE1ZAfBYy4NxLcBc9d76eLh CeQw0mLxv2F5jcfqYTiwIiivxNMR8/eEoyhxtADR6OHiRe1uRFdcRpATwL+L/W0o8CJv ViImhXUDa2OUHzTmLMuflv06RffXQ1sX/NNV8weEqyTIYbAt4Z67PckBM0FlL3qTGylb 8Ac4++tAX4OCkmfi53msmaO/4ZTVnIgw080GFCBkpJ6VBFq/sI6N1brRpvq0vgdiTrcK Ozlg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@endlessm-com.20150623.gappssmtp.com header.s=20150623 header.b=cd/4nunS; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 71-v6si3953006plf.575.2018.03.15.06.29.44; Thu, 15 Mar 2018 06:29:58 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@endlessm-com.20150623.gappssmtp.com header.s=20150623 header.b=cd/4nunS; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751680AbeCON2L (ORCPT + 99 others); Thu, 15 Mar 2018 09:28:11 -0400 Received: from mail-wm0-f43.google.com ([74.125.82.43]:56300 "EHLO mail-wm0-f43.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751480AbeCON2K (ORCPT ); Thu, 15 Mar 2018 09:28:10 -0400 Received: by mail-wm0-f43.google.com with SMTP id q83so10522833wme.5 for ; Thu, 15 Mar 2018 06:28:09 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=endlessm-com.20150623.gappssmtp.com; s=20150623; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc:content-transfer-encoding; bh=NOiA2IRMusa669mftKTicxII6KFxlvjnMdmD8qfzyx8=; b=cd/4nunSRs+MMQmYjHgMFOvTSwpPt5khcV69zMzWp29rKMXuKGWoIhLZKo8Pw8JFty YHiJ25AEfYNFlkGkMcmHOuM1wI3oWz72av7xRaJdyt/oQE7Uzq7aq0FStrKcu0nvxVK3 QVnEHxBSB34IraFGbuR4lrl7AQhvVeKLN3/GTbk81+Nfpl+HROmkMCBq1Z2q/66QIaWv 82l/g+pEFz2NHbLPAqk88U8moZPDwCQgUDqfdYmKYQCEIuTXvPZmGdn1jJ6AFo0El0Y2 WbIpCcBbYelLVckzebc+nURtvSK2fg37OgnU2YuMdfvTcBjm13pexGrZyycZm6VHq7P8 oyaQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc:content-transfer-encoding; bh=NOiA2IRMusa669mftKTicxII6KFxlvjnMdmD8qfzyx8=; b=rJrXCgX0H6cCKpbAMIoFo0Mf/cam+Pg/RYf3xxaUArQGic7kGcVRNCxGhQMgrCBiuy Z/0itxG6C3QhX8e5BDGw5fsl1JPIY/DYR3fZrsq2dF7bT6bpJrwFuKNGCgM29qXsy1T1 mZYZN4gkPssMtE9/pIP9y1aDpirvm4ENo++qe1/BatgH+BJNPTcCl1oFOYZ8+PtWG/77 Vcl1Nv62KR5WcvPMIpv3LWl2PiYb3XUs1eRnQeQ4Wfx+Wb1TY33Xw/A7U5w9g4coUM/K ecYhXx7DAflOrWB7tZypYpR7hrPK+R/h3aPKQ9V8UAfqPZjFaoGd4cHbc1pI7y+808IY NzfA== X-Gm-Message-State: AElRT7GhsG4CeHMyvV3xaTxF31ZxhRlXELceN0+/bGSKJgLcyoFX5dlN peryNnFV9Umf4/yzFwLyGqlJNHFaLXjogMc/DtfPmw== X-Received: by 10.80.162.38 with SMTP id 35mr8878534edl.157.1521120488893; Thu, 15 Mar 2018 06:28:08 -0700 (PDT) MIME-Version: 1.0 Received: by 10.80.177.253 with HTTP; Thu, 15 Mar 2018 06:28:08 -0700 (PDT) In-Reply-To: <6c8df688-b456-6f07-9325-6f4dfd8f0883@linux.intel.com> References: <6c8df688-b456-6f07-9325-6f4dfd8f0883@linux.intel.com> From: Chris Chiu Date: Thu, 15 Mar 2018 21:28:08 +0800 Message-ID: Subject: Re: Intel GemniLake xHCI connected devices can never wake up the system from suspend To: Mathias Nyman Cc: mathias.nyman@intel.com, gregkh@linuxfoundation.org, linux-usb@vger.kernel.org, Linux Kernel , Linux Upstreaming Team Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Mar 15, 2018 at 7:46 PM, Mathias Nyman wrote: > On 15.03.2018 06:40, Chris Chiu wrote: >> >> Hi, >> I have a ASUS AIO V222GA and another Acer Desktop XC-830 both >> have Intel CPU J5005 and they both hit the same problem. The XHCI >> connected USB keyboard/mouse can never wakeup the system from suspend. >> It reminds me that similiar thing happens on ApolloLake too which >> needs the XHCI_PME_STUCK_QUIRK to get it work. It's also mentioned in >> >> https://www.intel.com/content/dam/www/public/us/en/documents/specificati= on-updates/pentium-celeron-n-series-spec-update.pdf >> page #14 for N-seris intel CPU. And I also find the same problem >> description in >> https://www.intel.com/content/dam/www/public/us/en/documents/product-bri= efs/silver-celeron-spec-update.pdf >> page #16 for J-series Intel CPU. Seems that they have different >> workaround so I can not simply apply XHCI_PME_STUCK_QUIRK to make it >> work. >> >> Anyone can help here? >> > > N-Series > CHP8: USB xHCI Controller May Not Re-Enter D3 State After a USB Wake Even= t > - needs XHCI_PME_STUCK_QUIRK in driver (sets bit 28 at offset 80a4) > > Intel=C2=AE Pentium=C2=AE Silver N5000 > Intel=C2=AE Pentium=C2=AE Silver J5005 > Intel=C2=AE Celeron=C2=AE N4000 and N4100 > Intel=C2=AE Celeron=C2=AE J4105 and J4005 > > USB xHCI Controller May Not Re-enter a D3 State After a USB Wake Even > Need to clear PME_EN bit of of the standard PCI PM_CSR register. > I think Linux does this anyway (clears enabling PME when reaching D0) > So if I remember correct there was no specific workaround needed for this= . > > what is the PCI ID of your xhci controller? (lspci -nn) They're both 8086:31a8. So you mean from the workaround description, it sho= uld work w/o any extra code? "Software should clear bit 8 (PME_EN) of PM_CSR" h= as been handled somewhere else? > > One other possible cause is that xHCI never reaches PCI device D3 suspend > state during system suspend. > xHC can't generate PME# wake event from normal running PCI device D0 stat= e. > > PCI code in Linux will check with ACPI about the lowest possible D state > when suspending, > If there is something missing from the xHCI entry in ACPI DSDT table it > might select D0. > as the suspend state, causing wake failure. > Here's the DSDT ASL of the ASUS machine. https://gist.github.com/mschiu77/8e9c8a0e5a98b70a6dfff45620340bf1 Don't know if the "lspci -vvv" output for the USB xHCI controller provide any useful information. There's "PME(D0-,D1-,D2-,D3hot+,D3cold+)" in the following lspci log https://gist.github.com/mschiu77/8cf523f0e564c1fca44398ebeb21b7bc > Is there a BIOS update available for your ASUS and Acer? > > -Mathias ASUS said the BIOS has no problem on USB wakeup under Windows so I don't th= ink there's any update. Anything else could be cause for this?