From patchwork Mon Jul 24 09:53:56 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Johan Hovold X-Patchwork-Id: 9859057 X-Patchwork-Delegate: rjw@sisk.pl Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 6F7CA60385 for ; Mon, 24 Jul 2017 09:54:21 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 610E0274B4 for ; Mon, 24 Jul 2017 09:54:21 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 55ACA2818E; Mon, 24 Jul 2017 09:54:21 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.3 required=2.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_HI, RCVD_IN_SORBS_SPAM, T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id C00BC274B4 for ; Mon, 24 Jul 2017 09:54:20 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753682AbdGXJyS (ORCPT ); Mon, 24 Jul 2017 05:54:18 -0400 Received: from mail-lf0-f67.google.com ([209.85.215.67]:32977 "EHLO mail-lf0-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753211AbdGXJyR (ORCPT ); Mon, 24 Jul 2017 05:54:17 -0400 Received: by mail-lf0-f67.google.com with SMTP id k82so6522406lfg.0; Mon, 24 Jul 2017 02:54:17 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:cc:subject:date:message-id; bh=+i4T4HAPKw0ruM/PbHdv4/UGco9exQVxctKtb+iKgsU=; b=Zn+1hTCy6nCkCziGSz3FjSobNJ8JWLTNpAwMnTTdoyB17Z0BkrydW3GzptG34vAOp8 yxgvLRBRMLqycY2CTbJDOmqcnmHvkWJ59j+3NgWrc1spAtzbQkr7DhpFh+OAylWRgEYH meHG4ImW4lZl4y9mrg2ZoCXtyrxMSNtDybXZXy9YgmAfkWSS3GyjowWpjqxGNetmNBvg IUnrIq8zIwsnwMPi5aT4bW7GLidyNiE8vsU7OO6xQBQNFh3oJEo/ba7D2T1L4Wc6UOHV Q0H7nPxul3qvl6Jn5h4FI+uhQ8rUtWDD5aTDWp69GcwwxPu2n9FaUTmuxQADY7QoabzS xwxA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id; bh=+i4T4HAPKw0ruM/PbHdv4/UGco9exQVxctKtb+iKgsU=; b=QeDxil/IrMNqSGAv1OJ5rLKaXh49LILe0ybbucrQ5zkrH39pO2jm1rieuKJioJxLWj 0Er6kWK7fxiOzkYpWD6QjiLbKhSkayWI05NozURHD6Y5pS5A1k1rcSejATax3vMl2nGP 7jJlakHTRy1K1rZCfvfBPl5BtJSsZv/5RFG7DepOoVD6DteV1dJr/S+yZPTq/tvccDjk kPOSMFwfg5icMyZSnhLKJ1DQW6Luukq+09cwXnM+je/12j3Nw4RmDZWUiVOoXQgN/e4b iSggbFsNvmtPxD5xsPjm3u7nlMcOQPaP2vjyN4wimy/E79ahOX/SUs06mrMCrnNWNKbM ZI7Q== X-Gm-Message-State: AIVw1128yy9wkjgHrkO8aDg+GAml1raD+WEHqiNiZ6bEmGjaIZKgGvnf eCBBA7IdCUStVQ== X-Received: by 10.25.190.83 with SMTP id o80mr4254659lff.87.1500890056470; Mon, 24 Jul 2017 02:54:16 -0700 (PDT) Received: from xi.terra (c-42c8e255.07-184-6d6c6d4.cust.bredbandsbolaget.se. [85.226.200.66]) by smtp.gmail.com with ESMTPSA id m16sm2207278ljb.26.2017.07.24.02.54.15 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 24 Jul 2017 02:54:15 -0700 (PDT) Received: from johan by xi.terra with local (Exim 4.89) (envelope-from ) id 1dZa41-0005e9-Se; Mon, 24 Jul 2017 11:54:09 +0200 From: Johan Hovold To: "Rafael J. Wysocki" Cc: Len Brown , Pavel Machek , linux-pm@vger.kernel.org, linux-kernel@vger.kernel.org, Johan Hovold , Alan Stern , Tony Lindgren , Ulf Hansson Subject: [PATCH] PM / runtime: Document new pm_runtime_set_suspended constraint Date: Mon, 24 Jul 2017 11:53:56 +0200 Message-Id: <20170724095356.21667-1-johan@kernel.org> X-Mailer: git-send-email 2.13.3 Sender: linux-pm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-pm@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Since commit a8636c89648a ("PM / Runtime: Don't allow to suspend a device with an active child") it is no longer permitted to set RPM_SUSPENDED state for a device with active children unless power.ignore_children is set. Update the documentation to reflect this. Cc: Alan Stern Cc: Tony Lindgren Cc: Ulf Hansson Signed-off-by: Johan Hovold Reviewed-by: Ulf Hansson --- Documentation/power/runtime_pm.txt | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Documentation/power/runtime_pm.txt b/Documentation/power/runtime_pm.txt index 0fde3dcf077a..625549d4c74a 100644 --- a/Documentation/power/runtime_pm.txt +++ b/Documentation/power/runtime_pm.txt @@ -435,7 +435,8 @@ drivers/base/power/runtime.c and include/linux/pm_runtime.h: PM status to 'suspended' and update its parent's counter of 'active' children as appropriate (it is only valid to use this function if 'power.runtime_error' is set or 'power.disable_depth' is greater than - zero) + zero); it will fail and return an error code if the device has a child + which is active and the 'power.ignore_children' flag is unset bool pm_runtime_active(struct device *dev); - return true if the device's runtime PM status is 'active' or its