From patchwork Tue Jul 19 11:49:57 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Paolo Bonzini X-Patchwork-Id: 9236855 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 27A8C60574 for ; Tue, 19 Jul 2016 11:50:07 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 1691A20265 for ; Tue, 19 Jul 2016 11:50:07 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 08162205AF; Tue, 19 Jul 2016 11:50:07 +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.8 required=2.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_HI,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 E8B3F20265 for ; Tue, 19 Jul 2016 11:50:05 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753161AbcGSLuE (ORCPT ); Tue, 19 Jul 2016 07:50:04 -0400 Received: from mail-wm0-f65.google.com ([74.125.82.65]:34377 "EHLO mail-wm0-f65.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752979AbcGSLuD (ORCPT ); Tue, 19 Jul 2016 07:50:03 -0400 Received: by mail-wm0-f65.google.com with SMTP id q128so2564941wma.1; Tue, 19 Jul 2016 04:50:02 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=sender:from:to:cc:subject:date:message-id; bh=03qPPobtRgOOj73ksTDO98byq7L9bsJTKodKlIT8z1U=; b=kdhv6U9oVYMr/JwTt0J7zRxgLNPKN5K7XIJESS2Mvb7652kc5h/+BJQHt/r4ZPe3A+ zuQAyTyVmWwfLFVrv/5rIjqIR4o+pA+AhFStFgrkhmBEp2AgUaN7gff9dI3EYg0bJ0sz e/hcC0P+Y10IEZ3Ute5ooJ2EKwgCIe2pr164iowEPbWs67Km5dt5vpKOiRv76VA5PPDU FOq/Mwvp/bWzzrCTcGS9+8doVt10jz15bT2knF+VzC9Ylekvvo9oFq/QpRwGBlvpzHoA ZdSXfVnVfEuk4A+kJCfcH01GibNJVZIDPNROmSpHwZ+LO9AQe7ikJBihjgPHOEqvAkcZ IQFg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id; bh=03qPPobtRgOOj73ksTDO98byq7L9bsJTKodKlIT8z1U=; b=SCKrnqtoClnumW+wa5t0Bn9Y9USTpRuA0ZSxgwjm6ALngvbirt2HbVW2EOpqhMQtLe ldfaE3A6cizpChxDaOvbUJuSrS1MDZZkNYWZI8x+fQqoM4h/9Q+sMKaBkXOw97eRR23H UpCy/l5E2/9oDZ8unXNGHG+o8II9fAzfE+CsQS5MwOV3r9l1ne34N7PakDONZLU3lw/U 8MwgzQYR7ft3cb3GYBPaz91DTNMigDJNNiUsOqCWFsINu+j01/DOx5pcJ8gSielTqBlE 09eauNrPfTcKudDi3St9eGuyrFXzU20Wc3YD9tse/7h/IX9KqS3XfUm/sGZJjMWLhGna GkoQ== X-Gm-Message-State: ALyK8tI4U2MVDdUVGbqn7ZHF+UAs4SOS/rgDL6JZVR/Dmfb9yycfDBTR3LK/oIIV1+I+BQ== X-Received: by 10.28.191.14 with SMTP id p14mr3599213wmf.39.1468928999922; Tue, 19 Jul 2016 04:49:59 -0700 (PDT) Received: from donizetti.redhat.com (94-39-158-5.adsl-ull.clienti.tiscali.it. [94.39.158.5]) by smtp.gmail.com with ESMTPSA id q187sm22265190wma.17.2016.07.19.04.49.57 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 19 Jul 2016 04:49:58 -0700 (PDT) From: Paolo Bonzini To: linux-kernel@vger.kernel.org Cc: Thomas Renninger , Peter Zijlstra , rjw@rjwysocki.net, linux-pm@vger.kernel.org, Jacob Pan , Andy Lutomirski Subject: [PATCH resend] intel_rapl: downgrade message if no RAPL domains found in a VM Date: Tue, 19 Jul 2016 13:49:57 +0200 Message-Id: <1468928997-20431-1-git-send-email-pbonzini@redhat.com> X-Mailer: git-send-email 2.7.4 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 People complain about the driver saying there's no valid RAPL domains in a VM, and doing so at KERN_ERR severity. Downgrade this to KERN_INFO if running on a hypervisor, since it is basically stating the obvious. Suggested-by: Peter Zijlstra Cc: Jacob Pan Cc: Andy Lutomirski Signed-off-by: Paolo Bonzini Acked-by: Jacob Pan --- First sent out about a year ago. :) drivers/powercap/intel_rapl.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/drivers/powercap/intel_rapl.c b/drivers/powercap/intel_rapl.c index b2766b867b0e..0a0b09910116 100644 --- a/drivers/powercap/intel_rapl.c +++ b/drivers/powercap/intel_rapl.c @@ -1392,7 +1392,9 @@ static int rapl_detect_domains(struct rapl_package *rp, int cpu) } rp->nr_domains = bitmap_weight(&rp->domain_map, RAPL_DOMAIN_MAX); if (!rp->nr_domains) { - pr_err("no valid rapl domains found in package %d\n", rp->id); + printk("%sNo valid RAPL domains found in package %d\n", + boot_cpu_has(X86_FEATURE_HYPERVISOR) ? KERN_INFO : KERN_ERR, + rp->id); ret = -ENODEV; goto done; }