From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S933546AbcFQSTM (ORCPT ); Fri, 17 Jun 2016 14:19:12 -0400 Received: from mail.skyhub.de ([78.46.96.112]:58928 "EHLO mail.skyhub.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S933078AbcFQSTK (ORCPT ); Fri, 17 Jun 2016 14:19:10 -0400 Date: Fri, 17 Jun 2016 20:19:06 +0200 From: Borislav Petkov To: Vince Weaver , Huang Rui Cc: linux-kernel@vger.kernel.org, Peter Zijlstra , Ingo Molnar , Arnaldo Carvalho de Melo , Alexander Shishkin Subject: Re: [patch] events/amd/power add support for fam16h model30h Message-ID: <20160617181906.GM3912@pd.tnic> References: <20160616211218.GC4002@pd.tnic> <20160617100746.GC13900@hr-amur2> <20160617103156.GA15997@pd.tnic> <20160617162728.GC3912@pd.tnic> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.24 (2015-08-30) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Jun 17, 2016 at 01:38:44PM -0400, Vince Weaver wrote: > F15hM02h > > fam15h_power-pci-00c4 > Adapter: PCI adapter > power1: 105.64 W (crit = 115.17 W) > > fam15h_power-pci-00d4 > Adapter: PCI adapter > power1: 105.59 W (crit = 115.17 W) Is that a dual-socket machine? Because I have only the fam15h_power-pci-00c4 adapter. And mine goes between 20W and 40W in idle. > The whole system only uses 167W total at idle (according to a > wall-outlet power meter), so the two packages each drawing 105W seems > a bit off. Or is that an MCM box? I.e., a Multi-node CPU? Because: Documentation/hwmon/fam15h_power: "On multi-node processors the calculated value is for the entire package and not for a single node. Thus the driver creates sysfs attributes only for internal node0 of a multi-node processor." And I remember Andreas did that should_load_on_this_node() thing. If so, then 105W vs 167W should fit. > I also have a F15hM13h system but it doesn't seem to support TDP > measurement. That's Trinity. That PCI device ID is not even in the kernel - I'm guessing no one has even thought of enabling fam15_power on it. I don't know even whether it supports the different PCI interfaces like TDP, TDP limit, etc. IOW, something like that might not really help. Rui, you could take a look if you feel bored and if you have a TN system somewhere lying around. --- diff --git a/drivers/hwmon/fam15h_power.c b/drivers/hwmon/fam15h_power.c index eb97a9241d17..b31ef2779aac 100644 --- a/drivers/hwmon/fam15h_power.c +++ b/drivers/hwmon/fam15h_power.c @@ -503,6 +503,7 @@ static int fam15h_power_probe(struct pci_dev *pdev, static const struct pci_device_id fam15h_power_id_table[] = { { PCI_VDEVICE(AMD, PCI_DEVICE_ID_AMD_15H_NB_F4) }, + { PCI_VDEVICE(AMD, PCI_DEVICE_ID_AMD_15H_M10H_F4) }, { PCI_VDEVICE(AMD, PCI_DEVICE_ID_AMD_15H_M30H_NB_F4) }, { PCI_VDEVICE(AMD, PCI_DEVICE_ID_AMD_15H_M60H_NB_F4) }, { PCI_VDEVICE(AMD, PCI_DEVICE_ID_AMD_15H_M70H_NB_F4) }, diff --git a/include/linux/pci_ids.h b/include/linux/pci_ids.h index c58752fe16c4..f7385ed3d5f1 100644 --- a/include/linux/pci_ids.h +++ b/include/linux/pci_ids.h @@ -521,6 +521,7 @@ #define PCI_DEVICE_ID_AMD_11H_NB_MISC 0x1303 #define PCI_DEVICE_ID_AMD_11H_NB_LINK 0x1304 #define PCI_DEVICE_ID_AMD_15H_M10H_F3 0x1403 +#define PCI_DEVICE_ID_AMD_15H_M10H_F4 0x1404 #define PCI_DEVICE_ID_AMD_15H_M30H_NB_F3 0x141d #define PCI_DEVICE_ID_AMD_15H_M30H_NB_F4 0x141e #define PCI_DEVICE_ID_AMD_15H_M60H_NB_F3 0x1573 -- Regards/Gruss, Boris. ECO tip #101: Trim your mails when you reply.