Received: by 2002:a25:7ec1:0:0:0:0:0 with SMTP id z184csp3096478ybc; Thu, 21 Nov 2019 03:18:07 -0800 (PST) X-Google-Smtp-Source: APXvYqw5EofdHYCLI8mCb6al1fJtXtQs5oIIsLcZwrLCA0JWDw7SHG9sfMMiBiTqtUqijSrKgfNt X-Received: by 2002:a17:907:371:: with SMTP id rs17mr12116053ejb.0.1574335087045; Thu, 21 Nov 2019 03:18:07 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1574335087; cv=none; d=google.com; s=arc-20160816; b=B5MANnWwmD9UYWMniojb4EmPKmYESzX9lnMnaLJrOrA11nN804MZ9Aup3yGQq2ljlZ 35XoGQNnHXEz3yh5sowbXXJ/+e8DPuExoS8cJXCpBUCcdVLOnrVTl9yzZsGzhA4ngCdS IjZ9mFCICRPABrW6W/90zxTUJdnGuMi86UnaP/KhBCJDBCZjPhU4ZwQ85S8Ud2r08+Hr 7viCoUf7Tg4legV9AeEjT2+eUYnON46LGbwxBH6Dk+2xgeese8RTTrCun3StMqv6B6vH xLKJwSUYh9MQiLXaxh6PhLSHhqK9ZwXs4yHCoZYbd5askRCzgnBL0TQamF1jeK0PvmY3 qT4g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version; bh=aCewYooV+wiYd+qKmkInWmYxEycSQ/tK4iDINkYLKq0=; b=L4jGXklOO9EWOPAznwaMlqC4ebVnaRW+3A3VxFimK8UNs4NgWV2/yBHwXwe4dJoNe7 a6+nNzvWTDoZG/EA8yJIIagnNBuJ7MqnhOMuw/r4TCEnWjNg/6PxHLqr0GteBPNIa2RF I6i5oxS6Bn//kKE9RWvlSrwsDsrx2hYqmugJxchGLzJu5GgwV1IHaMEHLftLjy1++F/i EoHrgnjnJa9i/7ey6ZCOZfjo701ZU63RzmbXnn84EkxMrktKfZ5o95TZfD6D8HEfjNq4 ZwPD8YMahxBbuOtVIbcwUKRGDbdtGYb4XtZyhvhI4x3vjZOzRHMgwK2NzYHOCtj+wEqC guYA== 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=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id cb6si1451537ejb.359.2019.11.21.03.17.42; Thu, 21 Nov 2019 03:18:07 -0800 (PST) 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=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726698AbfKULPa (ORCPT + 99 others); Thu, 21 Nov 2019 06:15:30 -0500 Received: from mail-ot1-f68.google.com ([209.85.210.68]:44727 "EHLO mail-ot1-f68.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726165AbfKULPa (ORCPT ); Thu, 21 Nov 2019 06:15:30 -0500 Received: by mail-ot1-f68.google.com with SMTP id c19so2529338otr.11; Thu, 21 Nov 2019 03:15:29 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=aCewYooV+wiYd+qKmkInWmYxEycSQ/tK4iDINkYLKq0=; b=hS7JxECasvESu2njxtM3sHRY8Hc2IwPeo5jGN27//lyu1RteF7FDooGZ5KnI0WmwA/ Eqcn1hAL7pUJrjzFtXNUit5fhYAiGKCTCqddtIja2OHjPtVZa2tXdCnXu7sEGZ14TJLH fpLnna7gYNPLUjcos57dYazkv/R+XBalnXk43V89u4KeSoLqvjr/5FAspxtlebOOdVWU ZQdbra9lPXO5K5/9WpljP5ZyaYzFYURL5N3dmwkQ+yiaPlCzMxqnGZRD49lATJ+fvvpj Nl7HEorZw0Uny+hkEulRxurtIRMrT3IPpWT2SIEaEl7svuY1vyTn5lkQNrzqemSKaN2I wcsw== X-Gm-Message-State: APjAAAUeJVoyveGBCqSbBzj3QTwIl3h50/R83O/lYbWhfmRHnOoWYGmY 12glsXnCV5aAfJDRtlIdDMCJ9q0dZgJMBuYhVGU= X-Received: by 2002:a9d:7d01:: with SMTP id v1mr5729479otn.167.1574334929135; Thu, 21 Nov 2019 03:15:29 -0800 (PST) MIME-Version: 1.0 References: <20191120115127.GD11621@lahna.fi.intel.com> <20191120120913.GE11621@lahna.fi.intel.com> <20191120151542.GH11621@lahna.fi.intel.com> <20191120155301.GL11621@lahna.fi.intel.com> <20191120162306.GM11621@lahna.fi.intel.com> <20191121101423.GQ11621@lahna.fi.intel.com> In-Reply-To: From: "Rafael J. Wysocki" Date: Thu, 21 Nov 2019 12:15:17 +0100 Message-ID: Subject: Re: [PATCH v4] pci: prevent putting nvidia GPUs into lower device states on certain intel bridges To: Mika Westerberg Cc: Karol Herbst , "Rafael J. Wysocki" , Bjorn Helgaas , LKML , Lyude Paul , "Rafael J . Wysocki" , Linux PCI , Linux PM , dri-devel , nouveau , Dave Airlie , Mario Limonciello Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Nov 21, 2019 at 12:08 PM Rafael J. Wysocki wrote: > > On Thu, Nov 21, 2019 at 12:03 PM Rafael J. Wysocki wrote: > > > > On Thu, Nov 21, 2019 at 11:14 AM Mika Westerberg > > wrote: > > > > > > On Wed, Nov 20, 2019 at 10:36:31PM +0100, Karol Herbst wrote: > > > > with the branch and patch applied: > > > > https://gist.githubusercontent.com/karolherbst/03c4c8141b0fa292d781badfa186479e/raw/5c62640afbc57d6e69ea924c338bd2836e770d02/gistfile1.txt > > > > > > Thanks for testing. Too bad it did not help :( I suppose there is no > > > change if you increase the delay to say 1s? > > > > Well, look at the original patch in this thread. > > > > What it does is to prevent the device (GPU in this particular case) > > from going into a PCI low-power state before invoking AML to power it > > down (the AML is still invoked after this patch AFAICS), so why would > > that have anything to do with the delays? > > > > The only reason would be the AML running too early, but that doesn't > > seem likely. IMO more likely is that the AML does something which > > cannot be done to a device in a PCI low-power state. > > BTW, I'm wondering if anyone has tried to skip the AML instead of > skipping the PCI PM in this case (as of 5.4-rc that would be a similar > patch to skip the invocations of > __pci_start/complete_power_transition() in pci_set_power_state() for > the affected device). Moving the dev->broken_nv_runpm test into pci_platform_power_transition() (also for transitions into D0) would be sufficient for that test if I'm not mistaken.