Received: by 2002:a25:4158:0:0:0:0:0 with SMTP id o85csp2643939yba; Mon, 8 Apr 2019 01:17:19 -0700 (PDT) X-Google-Smtp-Source: APXvYqyNEmCX1gpVlmwTH4f5OtdwMhIb8GWiYF+IH2S2CBT8dPJ/f9No9jkReHuUfz6DK8DZQ1g1 X-Received: by 2002:a63:2e87:: with SMTP id u129mr26482503pgu.321.1554711439464; Mon, 08 Apr 2019 01:17:19 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1554711439; cv=none; d=google.com; s=arc-20160816; b=qqdQqJNeDpvX2Kyc/a5Ie9JaXItnVE2Vc3tcSvT1NKX+q96VbDyoYVQhmg1N39k498 WCqkB1sCd32Cfuuz27p23LPJgu/IBIoG1gTJculoov4GH2/a+5A4ijjcMByIMeL5Jjoi 7CSI8u1iGylXp2UH2khR8Kb9NC1xMPKyYLnQa8Qswt0yGxzwf13/SyJqSPbSDoQ6mTW/ Hfsz1XL7kSNdhu5LlWlBcImKK+dQN20Yif/+I/DgfU/L2/KHUSDuFgUofQJjEsoT97Ra QHR/p5+aRspc+2phbgBmtsislzDsKNgHWMTNNOLt6RAGcKBzyf/L8r6WGCNtDgc+5soK 9Rmg== 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 :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject; bh=3jdec/y4d1M3n4G3sJX8VFOgMY2jpDnSCJj4KB3r7us=; b=RAtZnKjKSHiBa8qA7Hr148KlY+vUWvcfbEqwhyQfrEO4l3lU5tm6rvpujTzG+s05UM Ywcw/dh2mPX5V75FBk0hWJzTMDw9LQgUzshIy2K1ayJP6jlVj2naTdqoLEtbo04+VtUO gB3q+QUhJ4glsnmAiALgKqeJs1O7H487Mc78fBdVeLxEvpMIZ0oNQqjdxfJg3hIhR2Ct IgEJ9PJ21SOMvbvqonQ+qcvHrkT+5/5jhHlb99YBT52jbX5paJ0MW3FgCFR4JmsDkd1y FAN5gALL/q/aaTN1ZeReBQ0Isq9/PN4MYsDJP+GPt1pi+S9NptDCvsjXXP3kJry7PkeA 7/Iw== ARC-Authentication-Results: i=1; mx.google.com; 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id h191si8121740pge.342.2019.04.08.01.17.03; Mon, 08 Apr 2019 01:17:19 -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; 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726545AbfDHIQ0 (ORCPT + 99 others); Mon, 8 Apr 2019 04:16:26 -0400 Received: from mail-ed1-f67.google.com ([209.85.208.67]:44393 "EHLO mail-ed1-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726343AbfDHIQ0 (ORCPT ); Mon, 8 Apr 2019 04:16:26 -0400 Received: by mail-ed1-f67.google.com with SMTP id d11so10794867edp.11 for ; Mon, 08 Apr 2019 01:16:25 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:cc:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=3jdec/y4d1M3n4G3sJX8VFOgMY2jpDnSCJj4KB3r7us=; b=ae7uCPVHCPaa5ivyFbMApiXqrjviYgHF9Si6ohX7M563ztBQQpwN4w2/NA7j9LFTnu YkyNcdIpH5moabmBHFMBuwm9EYv1eiadX6w/iyb5ucnu/OgglFBve0z86cu4II7d7tgD Z4F/2Gmy1KH0w53va+SYwc8z2lwWTpkodG9GrvqaMN7NADnRBOjgeFMNc95ng38Jaf4s aXMbGO+PrS6mQbtZMNSNZN+U6Qm6LLB4Gk62GUtWvP4JNkUUxLPU2Uvikckj3JP3LkBM M9jvfzKLTC6wa3DhJt7Mnwd7kptjyp3P1BqVgnZAZ67Lcb8BuFnUQXPw84r2KCoTHczr eVxg== X-Gm-Message-State: APjAAAVdPjgcsHi7pZN6SlNy+lAjhIarK80YtsDtVzt8tfyA5nWlXZba +tn0zPZy2ioXDkXEcRuCmWaGRBL5lw4= X-Received: by 2002:a50:cf49:: with SMTP id d9mr18395485edk.214.1554711384082; Mon, 08 Apr 2019 01:16:24 -0700 (PDT) Received: from shalem.localdomain (84-106-84-65.cable.dynamic.v4.ziggo.nl. [84.106.84.65]) by smtp.gmail.com with ESMTPSA id e9sm5280381ejl.14.2019.04.08.01.16.23 (version=TLS1_3 cipher=AEAD-AES128-GCM-SHA256 bits=128/128); Mon, 08 Apr 2019 01:16:23 -0700 (PDT) Subject: Re: [PATCH] ACPI / LPSS: Don't skip late system PM ops for hibernate on BYT/CHT To: "Robert R. Howell" , Kai-Heng Feng , "rjw@rjwysocki.net" Cc: "lenb@kernel.org" , "linux-acpi@vger.kernel.org" , "linux-kernel@vger.kernel.org" References: <20190403054352.30120-1-kai.heng.feng@canonical.com> From: Hans de Goede Message-ID: Date: Mon, 8 Apr 2019 10:16:22 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.6.1 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi, On 07-04-19 22:58, Robert R. Howell wrote: > On 4/3/19 2:54 AM, Hans de Goede wrote: > >> >> Hi, >> >> On 03-04-19 07:43, Kai-Heng Feng wrote: >>> i2c-designware-platdrv fails to work after the system restored from >>> hibernation: >>> [ 272.775692] i2c_designware 80860F41:00: Unknown Synopsys component type: 0xffffffff >>> >>> Commit 48402cee6889 ("ACPI / LPSS: Resume BYT/CHT I2C controllers from >>> resume_noirq") makes acpi_lpss_{suspend_late,resume_early}() bail early >>> on BYT/CHT as resume_from_noirq is set. This means dw_i2c_plat_resume() >>> doesn't gets called by acpi_lpss_resume_early(), and this causes the >>> issue. >>> > ... >> >> The ordering problem fixed by commit 48402cee6889 can hit hibernate too, >> so I think it would be better to do this instead to fix this problem: >> >> diff --git a/drivers/acpi/acpi_lpss.c b/drivers/acpi/acpi_lpss.c >> index 1e2a10a06b9d..cf768608437e 100644 > ... >> If people affected by the problem can give my version of the fix a test, >> then that would be great. >> >> Regards, >> >> Hans > > I did try applying your (Hans') patch to a 5.0.0 and a 5.1-rc3 kernel, instead of what I had > been doing previously, which was reverting commit 02e45646d53b. I tested it on an ASUS T100TA > and unfortunately with both kernels after resume from hibernation I still get errors like those > listed below, and sound no longer works. I also tried applying the patch from Kai-Heng Feng > (instead of Hans' patch or my revert) on both kernels and again in both cases I get these same errors. > > In contrast, on the 5.0.0 kernel when I revert 02e45646d53b, the problem is fixed. Because > of changes in adjacent code in 5.1-rc3, I haven't yet found a way to merge the new code > and the 02e45646d53b revert without causing worse problems. But that's probably because > I don't really understand the details of that code. > > [ 120.690428] i2c_designware 80860F41:01: timeout waiting for bus ready > [ 120.690442] rt5640 i2c-10EC5640:00: Failed to write 13d = 3600: -110 > [ 120.712860] i2c_designware 80860F41:01: timeout waiting for bus ready > [ 120.737389] i2c_designware 80860F41:01: timeout waiting for bus ready > [ 120.759657] i2c_designware 80860F41:01: timeout waiting for bus ready > [ 120.781797] i2c_designware 80860F41:01: timeout waiting for bus ready > [ 120.804153] i2c_designware 80860F41:01: timeout waiting for bus ready > [ 120.826467] i2c_designware 80860F41:01: timeout waiting for bus ready > [ 121.965886] i2c_designware 80860F41:01: timeout in disabling adapter > ..... > [ 132.782634] i2c_designware 80860F41:01: controller timed out > [ 133.806538] i2c_designware 80860F41:01: controller timed out > [ 134.830991] i2c_designware 80860F41:01: controller timed out > [ 135.855183] i2c_designware 80860F41:01: controller timed out > > Let me know if I can do any other testing to help. Hmm, interesting so you have hibernation working on a T100TA (with 5.0 + 02e45646d53b reverted), right ? I must admit I never try hibernation myself, in experience it tends to have more issues then regular suspend/resume and there are already enough other issues to worry about on Bay and Cherry Trail based devices. But if it works on the T100TA and 02e45646d53b broke it then I will try to fix this, I've a T100TA myself. Currently my T100TA is at my local hackerspace, so I will not have access to it until coming Friday. Regards, Hans