Received: by 10.213.65.68 with SMTP id h4csp33822imn; Thu, 15 Mar 2018 08:45:27 -0700 (PDT) X-Google-Smtp-Source: AG47ELvc43EoinNig4XZdnEFCXZj7HI6soGQLmR1DLFGDox3nTkDlY0SFIDXy63bdYMTFp+9Xwf7 X-Received: by 10.98.157.2 with SMTP id i2mr5175044pfd.44.1521128727414; Thu, 15 Mar 2018 08:45:27 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1521128727; cv=none; d=google.com; s=arc-20160816; b=qsxWqkwFgoTD4F9kzXAlq2KfDi50bmvZu7HyBdTlKtDoycR+ucv+SfooByQ1VsbhET TvLVCER6+9DhuUMkJRdrSgxRxwb571t0Fw4Ig1YbAJWKHnbhmB75Ug0FnOe9YmO6zeLt fTh6LLanPuyelgVeg763PE3W8FsoDQkqrMPdyUZmAWOJeuaNZQyZFdibOlU7gkBP5dcv nUihIEzdXwmpL9kysHu1t/Njuzrih8Qmxnh12kepvcTe46Xjldf/Jh8te5VZpSdYl3BR A0jRdJBIKlMVJO7Fx2B9CjsR9/5rbWr2JX5nxDpjcvk78IKJmnh3qurTrAyqEUBVQUQx fmZA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-language :content-transfer-encoding:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject:dkim-signature :arc-authentication-results; bh=SDoRb44djW6JWpXp5WTzhhj16IZjymVE6Ef4p4H6qq4=; b=nO1mEASTXTvU4Q8ZSIgYNin2KtmCHjR2dkZXnRvWtHg20xP/0M44EcSW5Ff1vDCd9l KuN2l3pu/1dJrcppRSXNRbVheGplG7RdRVioCy+f8vCou/KC/6qQTqgTT4dXq6oLmPof kGOJSeKoFcjUOlrbnm8KhO+BU4ZKuh3xPDaHaliJdhSIjAnaTVs3ITj+HOSkPCzmcrOp GKXKSbsqy09cNpDriMOs7FAWAICO8GzPtegSelR2l2atQn6CrOHGiXdLyJ79739+Wdqq 4H4+BJP1bjmJ0sReAcazrXLAbAdUeWSrFcUp1mFDw26RZ+ltCePUtjOOyHpDWddTaPUu JvlQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@oracle.com header.s=corp-2017-10-26 header.b=Ge8Dg+Oh; 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=pass (p=NONE sp=NONE dis=NONE) header.from=oracle.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id h13si3274713pfh.182.2018.03.15.08.45.13; Thu, 15 Mar 2018 08:45:27 -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=@oracle.com header.s=corp-2017-10-26 header.b=Ge8Dg+Oh; 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=pass (p=NONE sp=NONE dis=NONE) header.from=oracle.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752804AbeCOPns (ORCPT + 99 others); Thu, 15 Mar 2018 11:43:48 -0400 Received: from aserp2120.oracle.com ([141.146.126.78]:38896 "EHLO aserp2120.oracle.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752722AbeCOPno (ORCPT ); Thu, 15 Mar 2018 11:43:44 -0400 Received: from pps.filterd (aserp2120.oracle.com [127.0.0.1]) by aserp2120.oracle.com (8.16.0.22/8.16.0.22) with SMTP id w2FFe5Yn058001; Thu, 15 Mar 2018 15:43:33 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.com; h=subject : to : cc : references : from : message-id : date : mime-version : in-reply-to : content-type : content-transfer-encoding; s=corp-2017-10-26; bh=SDoRb44djW6JWpXp5WTzhhj16IZjymVE6Ef4p4H6qq4=; b=Ge8Dg+OhA47BYnF0Sr+htBKzsx3je0cE9UzS6no1YhP1JTgN4QR1IDtiGpTBA5KUJOdw aA/Qzpurf2Wj4bMz8/Cu7fRql/Eo7BYxUgBp7Z9B1AZAb4O+lNAYzaZFIHvL+mwLRqGL Kpx4ez/37bOjomKEEctgNS5jgxda1RgN+FSsBSIBWKAT90b6+5K4XRA9tQdp8VtLERl3 YDNAj/OjfLyC/wsucWGMnYGeqHyNwc+qIK7jiC7lx5QNRCslhwluzPsgJrGHYW8GPZNR E0ofwmP/rpLZkqIHMpW/AYgrWDmzVIrq+dwzxtp9kkF0oy8/QDXxy/LIFA16a8jEEtNX OA== Received: from aserv0021.oracle.com (aserv0021.oracle.com [141.146.126.233]) by aserp2120.oracle.com with ESMTP id 2gqunyg0ur-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Thu, 15 Mar 2018 15:43:33 +0000 Received: from aserv0122.oracle.com (aserv0122.oracle.com [141.146.126.236]) by aserv0021.oracle.com (8.14.4/8.14.4) with ESMTP id w2FFhV94004546 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Thu, 15 Mar 2018 15:43:31 GMT Received: from abhmp0007.oracle.com (abhmp0007.oracle.com [141.146.116.13]) by aserv0122.oracle.com (8.14.4/8.14.4) with ESMTP id w2FFhUg3019728; Thu, 15 Mar 2018 15:43:30 GMT Received: from dhcp-burlington7-2nd-B-east-10-152-55-162.usdhcp.oraclecorp.com (/10.152.32.65) by default (Oracle Beehive Gateway v4.0) with ESMTP ; Thu, 15 Mar 2018 08:43:30 -0700 Subject: Re: [PATCH v3] xen/acpi: upload _PSD info for non Dom0 CPUs too To: Joao Martins , linux-kernel@vger.kernel.org Cc: Juergen Gross , "Rafael J. Wysocki" , Len Brown , Robert Moore , Erik Schmauss , xen-devel@lists.xenproject.org, linux-acpi@vger.kernel.org, devel@acpica.org References: <20180315142205.15839-1-joao.m.martins@oracle.com> From: Boris Ostrovsky Message-ID: Date: Thu, 15 Mar 2018 11:45:01 -0400 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.6.0 MIME-Version: 1.0 In-Reply-To: <20180315142205.15839-1-joao.m.martins@oracle.com> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit Content-Language: en-US X-Proofpoint-Virus-Version: vendor=nai engine=5900 definitions=8832 signatures=668690 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 suspectscore=0 malwarescore=0 phishscore=0 bulkscore=0 spamscore=0 mlxscore=0 mlxlogscore=999 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1711220000 definitions=main-1803150169 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 03/15/2018 10:22 AM, Joao Martins wrote: > All uploaded PM data from non-dom0 CPUs takes the info from vCPU 0 and > changing only the acpi_id. For processors which P-state coordination type > is HW_ALL (0xFD) it is OK to upload bogus P-state dependency information > (_PSD), because Xen will ignore any cpufreq domains created for past CPUs. > > Albeit for platforms which expose coordination types as SW_ANY or SW_ALL, > this will have some unintended side effects. Effectively, it will look at > the P-state domain existence and *if it already exists* it will skip the > acpi-cpufreq initialization and thus inherit the policy from the first CPU > in the cpufreq domain. This will finally lead to the original cpu not > changing target freq to P0 other than the first in the domain. Which will > make turbo boost not getting enabled (e.g. for 'performance' governor) for > all cpus. > > This patch fixes that, by also evaluating _PSD when we enumerate all ACPI > processors and thus always uploading the correct info to Xen. We export > acpi_processor_get_psd() for that this purpose, but change signature > to not assume an existent of acpi_processor given that ACPI isn't creating > an acpi_processor for non-dom0 CPUs. > > Signed-off-by: Joao Martins Reviewed-by: Boris Ostrovsky