All of lore.kernel.org
 help / color / mirror / Atom feed
* [linux-next:master 9945/11483] drivers/platform/x86/amd-pmc.c:428:30: error: use of undeclared identifier 'CONFIG_RTC_SYSTOHC_DEVICE'
@ 2021-10-27 12:02 ` kernel test robot
  0 siblings, 0 replies; 2+ messages in thread
From: kernel test robot @ 2021-10-27 12:02 UTC (permalink / raw)
  To: Mario Limonciello
  Cc: llvm, kbuild-all, Linux Memory Management List, Hans de Goede

[-- Attachment #1: Type: text/plain, Size: 3170 bytes --]

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git master
head:   2376e5fe91bcad74b997d2cc0535abff79ec73c5
commit: 59348401ebed9f0e8ffe2d5b9cf1de30ecb24dde [9945/11483] platform/x86: amd-pmc: Add special handling for timer based S0i3 wakeup
config: x86_64-randconfig-a003-20211027 (attached as .config)
compiler: clang version 14.0.0 (https://github.com/llvm/llvm-project 5db7568a6a1fcb408eb8988abdaff2a225a8eb72)
reproduce (this is a W=1 build):
        wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        # https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git/commit/?id=59348401ebed9f0e8ffe2d5b9cf1de30ecb24dde
        git remote add linux-next https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git
        git fetch --no-tags linux-next master
        git checkout 59348401ebed9f0e8ffe2d5b9cf1de30ecb24dde
        # save the attached .config to linux build tree
        mkdir build_dir
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 O=build_dir ARCH=x86_64 SHELL=/bin/bash

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>

All errors (new ones prefixed by >>):

>> drivers/platform/x86/amd-pmc.c:428:30: error: use of undeclared identifier 'CONFIG_RTC_SYSTOHC_DEVICE'
           rtc_device = rtc_class_open(CONFIG_RTC_SYSTOHC_DEVICE);
                                       ^
   1 error generated.


vim +/CONFIG_RTC_SYSTOHC_DEVICE +428 drivers/platform/x86/amd-pmc.c

   416	
   417	static int amd_pmc_verify_czn_rtc(struct amd_pmc_dev *pdev, u32 *arg)
   418	{
   419		struct rtc_device *rtc_device;
   420		time64_t then, now, duration;
   421		struct rtc_wkalrm alarm;
   422		struct rtc_time tm;
   423		int rc;
   424	
   425		if (pdev->major < 64 || (pdev->major == 64 && pdev->minor < 53))
   426			return 0;
   427	
 > 428		rtc_device = rtc_class_open(CONFIG_RTC_SYSTOHC_DEVICE);
   429		if (!rtc_device)
   430			return 0;
   431		rc = rtc_read_alarm(rtc_device, &alarm);
   432		if (rc)
   433			return rc;
   434		if (!alarm.enabled) {
   435			dev_dbg(pdev->dev, "alarm not enabled\n");
   436			return 0;
   437		}
   438		rc = rtc_valid_tm(&alarm.time);
   439		if (rc)
   440			return rc;
   441		rc = rtc_read_time(rtc_device, &tm);
   442		if (rc)
   443			return rc;
   444		then = rtc_tm_to_time64(&alarm.time);
   445		now = rtc_tm_to_time64(&tm);
   446		duration = then-now;
   447	
   448		/* in the past */
   449		if (then < now)
   450			return 0;
   451	
   452		/* will be stored in upper 16 bits of s0i3 hint argument,
   453		 * so timer wakeup from s0i3 is limited to ~18 hours or less
   454		 */
   455		if (duration <= 4 || duration > U16_MAX)
   456			return -EINVAL;
   457	
   458		*arg |= (duration << 16);
   459		rc = rtc_alarm_irq_enable(rtc_device, 0);
   460		dev_info(pdev->dev, "wakeup timer programmed for %lld seconds\n", duration);
   461	
   462		return rc;
   463	}
   464	

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org

[-- Attachment #2: .config.gz --]
[-- Type: application/gzip, Size: 40504 bytes --]

^ permalink raw reply	[flat|nested] 2+ messages in thread

* [linux-next:master 9945/11483] drivers/platform/x86/amd-pmc.c:428:30: error: use of undeclared identifier 'CONFIG_RTC_SYSTOHC_DEVICE'
@ 2021-10-27 12:02 ` kernel test robot
  0 siblings, 0 replies; 2+ messages in thread
From: kernel test robot @ 2021-10-27 12:02 UTC (permalink / raw)
  To: kbuild-all

[-- Attachment #1: Type: text/plain, Size: 3254 bytes --]

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git master
head:   2376e5fe91bcad74b997d2cc0535abff79ec73c5
commit: 59348401ebed9f0e8ffe2d5b9cf1de30ecb24dde [9945/11483] platform/x86: amd-pmc: Add special handling for timer based S0i3 wakeup
config: x86_64-randconfig-a003-20211027 (attached as .config)
compiler: clang version 14.0.0 (https://github.com/llvm/llvm-project 5db7568a6a1fcb408eb8988abdaff2a225a8eb72)
reproduce (this is a W=1 build):
        wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        # https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git/commit/?id=59348401ebed9f0e8ffe2d5b9cf1de30ecb24dde
        git remote add linux-next https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git
        git fetch --no-tags linux-next master
        git checkout 59348401ebed9f0e8ffe2d5b9cf1de30ecb24dde
        # save the attached .config to linux build tree
        mkdir build_dir
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 O=build_dir ARCH=x86_64 SHELL=/bin/bash

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>

All errors (new ones prefixed by >>):

>> drivers/platform/x86/amd-pmc.c:428:30: error: use of undeclared identifier 'CONFIG_RTC_SYSTOHC_DEVICE'
           rtc_device = rtc_class_open(CONFIG_RTC_SYSTOHC_DEVICE);
                                       ^
   1 error generated.


vim +/CONFIG_RTC_SYSTOHC_DEVICE +428 drivers/platform/x86/amd-pmc.c

   416	
   417	static int amd_pmc_verify_czn_rtc(struct amd_pmc_dev *pdev, u32 *arg)
   418	{
   419		struct rtc_device *rtc_device;
   420		time64_t then, now, duration;
   421		struct rtc_wkalrm alarm;
   422		struct rtc_time tm;
   423		int rc;
   424	
   425		if (pdev->major < 64 || (pdev->major == 64 && pdev->minor < 53))
   426			return 0;
   427	
 > 428		rtc_device = rtc_class_open(CONFIG_RTC_SYSTOHC_DEVICE);
   429		if (!rtc_device)
   430			return 0;
   431		rc = rtc_read_alarm(rtc_device, &alarm);
   432		if (rc)
   433			return rc;
   434		if (!alarm.enabled) {
   435			dev_dbg(pdev->dev, "alarm not enabled\n");
   436			return 0;
   437		}
   438		rc = rtc_valid_tm(&alarm.time);
   439		if (rc)
   440			return rc;
   441		rc = rtc_read_time(rtc_device, &tm);
   442		if (rc)
   443			return rc;
   444		then = rtc_tm_to_time64(&alarm.time);
   445		now = rtc_tm_to_time64(&tm);
   446		duration = then-now;
   447	
   448		/* in the past */
   449		if (then < now)
   450			return 0;
   451	
   452		/* will be stored in upper 16 bits of s0i3 hint argument,
   453		 * so timer wakeup from s0i3 is limited to ~18 hours or less
   454		 */
   455		if (duration <= 4 || duration > U16_MAX)
   456			return -EINVAL;
   457	
   458		*arg |= (duration << 16);
   459		rc = rtc_alarm_irq_enable(rtc_device, 0);
   460		dev_info(pdev->dev, "wakeup timer programmed for %lld seconds\n", duration);
   461	
   462		return rc;
   463	}
   464	

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all(a)lists.01.org

[-- Attachment #2: config.gz --]
[-- Type: application/gzip, Size: 40504 bytes --]

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2021-10-27 12:02 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-10-27 12:02 [linux-next:master 9945/11483] drivers/platform/x86/amd-pmc.c:428:30: error: use of undeclared identifier 'CONFIG_RTC_SYSTOHC_DEVICE' kernel test robot
2021-10-27 12:02 ` kernel test robot

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.