From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753211AbbJUCuA (ORCPT ); Tue, 20 Oct 2015 22:50:00 -0400 Received: from bh-25.webhostbox.net ([208.91.199.152]:58346 "EHLO bh-25.webhostbox.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751578AbbJUCt7 (ORCPT ); Tue, 20 Oct 2015 22:49:59 -0400 Subject: Re: [PATCH v2 05/10] hwmon: (fam15h_power) Add compute unit accumulated power To: Huang Rui References: <1445308109-17970-6-git-send-email-ray.huang@amd.com> <201510201509.U8tGXwCz%fengguang.wu@intel.com> <20151021014214.GA26968@hr-amur2> <5626F53D.2090009@roeck-us.net> <20151021024002.GB26968@hr-amur2> Cc: kbuild test robot , Yuanhan Liu , Fengguang Wu , kbuild-all@01.org, Borislav Petkov , Peter Zijlstra , Jean Delvare , Andy Lutomirski , Andreas Herrmann , Thomas Gleixner , Ingo Molnar , "Rafael J. Wysocki" , Len Brown , John Stultz , =?UTF-8?B?RnLvv71k77+9cmljIFdlaXNiZWNrZXI=?= , lm-sensors@lm-sensors.org, linux-kernel@vger.kernel.org, x86@kernel.org, Andreas Herrmann , Aravind Gopalakrishnan , Borislav Petkov , Aaron Lu , Tony Li From: Guenter Roeck Message-ID: <5626FD51.4090402@roeck-us.net> Date: Tue, 20 Oct 2015 19:49:53 -0700 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.3.0 MIME-Version: 1.0 In-Reply-To: <20151021024002.GB26968@hr-amur2> Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit X-Authenticated_sender: linux@roeck-us.net X-OutGoing-Spam-Status: No, score=0.0 X-AntiAbuse: This header was added to track abuse, please include it with any abuse report X-AntiAbuse: Primary Hostname - bh-25.webhostbox.net X-AntiAbuse: Original Domain - vger.kernel.org X-AntiAbuse: Originator/Caller UID/GID - [47 12] / [47 12] X-AntiAbuse: Sender Address Domain - roeck-us.net X-Get-Message-Sender-Via: bh-25.webhostbox.net: authenticated_id: linux@roeck-us.net X-Source: X-Source-Args: X-Source-Dir: Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 10/20/2015 07:40 PM, Huang Rui wrote: > On Tue, Oct 20, 2015 at 07:15:25PM -0700, Guenter Roeck wrote: >> On 10/20/2015 06:42 PM, Huang Rui wrote: >>> On Tue, Oct 20, 2015 at 03:24:09PM +0800, kbuild test robot wrote: >>>> Hi Huang, >>>> >>>> [auto build test ERROR on hwmon/hwmon-next -- if it's inappropriate base, please suggest rules for selecting the more suitable base] >>>> >>>> url: https://github.com/0day-ci/linux/commits/Huang-Rui/hwmon-fam15h_power-Introduce-an-accumulated-power-reporting-algorithm/20151020-110712 >>>> config: x86_64-randconfig-s2-10201413 (attached as .config) >>>> reproduce: >>>> # save the attached .config to linux build tree >>>> make ARCH=x86_64 >>>> >>>> All errors (new ones prefixed by >>): >>>> >>>> drivers/built-in.o: In function `fam15h_power_probe': >>>>>> fam15h_power.c:(.text+0x26e3a3): undefined reference to `amd_get_cores_per_cu' >>>> fam15h_power.c:(.text+0x26e41e): undefined reference to `amd_get_cores_per_cu' >>>> >>> >>> Thanks to report this issue. :) >>> The root cause is that the test config doesn't enable >>> CONFIG_CPU_SUP_AMD. >>> >>> How about below fix: >>> >> >> Guess you don't have a choice. >> > > Yes, if I use test config, fam15h_power isn't chosen. :) > > And if I use the "select" flag like below, fam15h_power can be built > successfully. > That is another possibility, though that isn't how CPU_SUP_AMD is handled by its other users. Matter of philosophy, I guess. Guenter > --- > diff --git a/drivers/hwmon/Kconfig b/drivers/hwmon/Kconfig > index 796569ee..50b4fef 100644 > --- a/drivers/hwmon/Kconfig > +++ b/drivers/hwmon/Kconfig > @@ -289,6 +289,7 @@ config SENSORS_K10TEMP > config SENSORS_FAM15H_POWER > tristate "AMD Family 15h processor power" > depends on X86 && PCI > + select CPU_SUP_AMD > help > If you say yes here you get support for processor power > information of your AMD family 15h CPU. > --- > > Thanks, > Rui >