Received: by 2002:a05:6a10:5bc5:0:0:0:0 with SMTP id os5csp1839047pxb; Thu, 28 Oct 2021 10:59:10 -0700 (PDT) X-Google-Smtp-Source: ABdhPJz8OJZMVj0Jh2Bmh52ak4vhvbkAST25bHs9KCHVCtLbMZORT0cxl4rnPpuxqyNsGfwYrSn8 X-Received: by 2002:a05:6a00:ac6:b029:374:a33b:a74 with SMTP id c6-20020a056a000ac6b0290374a33b0a74mr5734232pfl.51.1635443949941; Thu, 28 Oct 2021 10:59:09 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1635443949; cv=none; d=google.com; s=arc-20160816; b=RTJJBInmbcWD083rZaZzvsrRZl8+x2v7VCGbCamKD4dqBa+nbNj5LUYjio1U0o3Uwm an9gFMyFc23kRUaM1Lw5gvKLEzRsfbcKTjw9eVqQEAMCWuelyA5tIypbf0EurHiAxvRf 2k6DujovG/J/nD7e/uy66JAKqHdlTgT3M8NCxlmNTDeHebEASlWVkmK/negzAbfeI3q2 WG6AhOczUl+Pr7/h0PjI59Z/D6OjieNnNp35t/9vbw0YVc8VwEomUAizUedyKjMozdk5 bJlCq0M86ERFi6TNscG3m1vq6bZiwxFZlCk3fBIB184XdbivoE9tohRDeIjEk0Oj+2y/ l0rQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version; bh=I8S1RsJjseOxeamOtCHDWEESw385GgbZxMc0otlNFT4=; b=epZAnjBKQkLJdIVWany6fAxwRPEUB4XwLSn+8XrJh5aNedJOfQD1FkoZJSfAi4dYrk 1iR76S/YcyK/FBN2CXtI+hGhMvdTugAD74o4U0j5QJD8NwRaq4y4oruLiclGQMwCBFnR GxciwVYnsKS8EjukSGnsGwyCb7ks3skx3rGK/iOELXkrsmkftVogoeZQN4EyfkBY4bU6 4lCQ7XgWd4DCsv5TlBfPuuDZIxeqsWsNnyF2iEG3UVWWvb5pDyxb74kyXlY+Gb8kUSgb MncQ7cUySD4puT2RMykud0xoxJ7hJhknYz/IApe5tUl7eL/zFR2kYVj8bIvSvxryedYe QnkA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id l8si4753545pfd.212.2021.10.28.10.58.55; Thu, 28 Oct 2021 10:59:09 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230410AbhJ1R7t (ORCPT + 99 others); Thu, 28 Oct 2021 13:59:49 -0400 Received: from mail-ot1-f51.google.com ([209.85.210.51]:45968 "EHLO mail-ot1-f51.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230258AbhJ1R7s (ORCPT ); Thu, 28 Oct 2021 13:59:48 -0400 Received: by mail-ot1-f51.google.com with SMTP id l16-20020a9d6a90000000b0054e7ab56f27so9686509otq.12; Thu, 28 Oct 2021 10:57:21 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=I8S1RsJjseOxeamOtCHDWEESw385GgbZxMc0otlNFT4=; b=omyGcgqioCUdNHKmUBsDXPGb4ZZ4rHvN8dVT5ZvmRbFM7FnpXAM0v3gOYZW+k+VyZo G8nVZbtSMaIB4ED5DGpn+bcAjfpKdwV9DJbasAD30t/mRZP58U7e9X1j7TW6T+A1Q72M oYuHZkjpNDLICSaH4oRpRjBJlQL3YrqdvckJ/DrpkFDRh3rXQa8rtQgw/kMdJd2hsTGb Oi94U6yA5noaEw2KkUX/Nuyr5G+wSPU9IrVTqKWwngEJr+uFQ/PSuxO0DrRI7S+kUUX+ h37j+tBCVVnsWu6pJYrvqQYOWoK2CkRu5AQeqPZSbFGpQts14/7COO0FDwIAzY2fUFoE L9SQ== X-Gm-Message-State: AOAM5333UTFNmDU4J0lBg/DZpQBZQybWlFqGc0l3S+h3OcKNVu3XoeeK /1ESNvN0sRQBQu3cz8jbnDbrvgoC4loLRb2Gv3U= X-Received: by 2002:a9d:65c1:: with SMTP id z1mr4562340oth.198.1635443840953; Thu, 28 Oct 2021 10:57:20 -0700 (PDT) MIME-Version: 1.0 References: In-Reply-To: From: "Rafael J. Wysocki" Date: Thu, 28 Oct 2021 19:57:09 +0200 Message-ID: Subject: Re: problem in changing from active to passive mode To: Julia Lawall Cc: Doug Smythies , Srinivas Pandruvada , Len Brown , "Rafael J. Wysocki" , Viresh Kumar , Linux PM list , Linux Kernel Mailing List Content-Type: multipart/mixed; boundary="00000000000030c37305cf6d71b9" Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org --00000000000030c37305cf6d71b9 Content-Type: text/plain; charset="UTF-8" On Thu, Oct 28, 2021 at 7:29 PM Rafael J. Wysocki wrote: > > On Thu, Oct 28, 2021 at 7:10 PM Julia Lawall wrote: > > > > > Now, for your graph 3, are you saying this pseudo > > > code of the process is repeatable?: > > > > > > Power up the system, booting kernel 5.9 > > > switch to passive/schedutil. > > > wait X minutes for system to settle > > > do benchmark, result ~13 seconds > > > re-boot to kernel 5.15-RC > > > switch to passive/schedutil. > > > wait X minutes for system to settle > > > do benchmark, result ~40 seconds > > > re-boot to kernel 5.9 > > > switch to passive/schedutil. > > > wait X minutes for system to settle > > > do benchmark, result ~28 seconds > > > > In the first boot of 5.9, the des (desired?) field of the HWP_REQUEST > > register is 0 and in the second boot (after booting 5.15 and entering > > passive mode) it is 10. I don't know though if this is a bug or a > > feature... > > It looks like a bug. > > I think that the desired value is not cleared on driver exit which > should happen. Let me see if I can do a quick patch for that. Please check the behavior with the attached patch applied. --00000000000030c37305cf6d71b9 Content-Type: text/x-patch; charset="US-ASCII"; name="intel_pstate-clear-desired-on-offline.patch" Content-Disposition: attachment; filename="intel_pstate-clear-desired-on-offline.patch" Content-Transfer-Encoding: base64 Content-ID: X-Attachment-Id: f_kvb8zh900 LS0tCiBkcml2ZXJzL2NwdWZyZXEvaW50ZWxfcHN0YXRlLmMgfCAgICAzICsrKwogMSBmaWxlIGNo YW5nZWQsIDMgaW5zZXJ0aW9ucygrKQoKSW5kZXg6IGxpbnV4LXBtL2RyaXZlcnMvY3B1ZnJlcS9p bnRlbF9wc3RhdGUuYwo9PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09 PT09PT09PT09PT09PT09PT09PT09PT09Ci0tLSBsaW51eC1wbS5vcmlnL2RyaXZlcnMvY3B1ZnJl cS9pbnRlbF9wc3RhdGUuYworKysgbGludXgtcG0vZHJpdmVycy9jcHVmcmVxL2ludGVsX3BzdGF0 ZS5jCkBAIC0xMDE1LDYgKzEwMTUsOSBAQCBzdGF0aWMgdm9pZCBpbnRlbF9wc3RhdGVfaHdwX29m ZmxpbmUoc3RyCiAJdmFsdWUgfD0gSFdQX01BWF9QRVJGKG1pbl9wZXJmKTsKIAl2YWx1ZSB8PSBI V1BfTUlOX1BFUkYobWluX3BlcmYpOwogCisJLyogQ2xlYXIgREVTSVJFRF9QRVJGICovCisJdmFs dWUgJj0gfkhXUF9ERVNJUkVEX1BFUkYofjBMKTsKKwogCS8qIFNldCBFUFAgdG8gbWluICovCiAJ aWYgKGJvb3RfY3B1X2hhcyhYODZfRkVBVFVSRV9IV1BfRVBQKSkKIAkJdmFsdWUgfD0gSFdQX0VO RVJHWV9QRVJGX1BSRUZFUkVOQ0UoSFdQX0VQUF9QT1dFUlNBVkUpOwo= --00000000000030c37305cf6d71b9--