[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <202410172126.EXJ0sOkP-lkp@intel.com>
Date: Thu, 17 Oct 2024 19:28:03 +0800
From: kernel test robot <lkp@...el.com>
To: Christian Marangi <ansuelsmth@...il.com>,
Olivia Mackall <olivia@...enic.com>,
Herbert Xu <herbert@...dor.apana.org.au>,
Rob Herring <robh@...nel.org>,
Krzysztof Kozlowski <krzk@...nel.org>,
Conor Dooley <conor+dt@...nel.org>,
Francesco Dolcini <francesco.dolcini@...adex.com>,
Daniel Golle <daniel@...rotopia.org>,
Aurelien Jarno <aurelien@...el32.net>,
Linus Walleij <linus.walleij@...aro.org>,
linux-crypto@...r.kernel.org, devicetree@...r.kernel.org,
linux-kernel@...r.kernel.org, Lorenzo Bianconi <lorenzo@...nel.org>,
upstream@...oha.com
Cc: llvm@...ts.linux.dev, oe-kbuild-all@...ts.linux.dev
Subject: Re: [PATCH 2/2] hwrng: add support for Airoha EN7581 TRNG
Hi Christian,
kernel test robot noticed the following build errors:
[auto build test ERROR on char-misc/char-misc-testing]
[also build test ERROR on char-misc/char-misc-next char-misc/char-misc-linus robh/for-next herbert-cryptodev-2.6/master linus/master v6.12-rc3 next-20241017]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch#_base_tree_information]
url: https://github.com/intel-lab-lkp/linux/commits/Christian-Marangi/hwrng-add-support-for-Airoha-EN7581-TRNG/20241016-232144
base: char-misc/char-misc-testing
patch link: https://lore.kernel.org/r/20241016151845.23712-2-ansuelsmth%40gmail.com
patch subject: [PATCH 2/2] hwrng: add support for Airoha EN7581 TRNG
config: i386-buildonly-randconfig-003-20241017 (https://download.01.org/0day-ci/archive/20241017/202410172126.EXJ0sOkP-lkp@intel.com/config)
compiler: clang version 18.1.8 (https://github.com/llvm/llvm-project 3b5b5c1ec4a3095ab096dd780e84d7ab81f3d7ff)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20241017/202410172126.EXJ0sOkP-lkp@intel.com/reproduce)
If you fix the issue in a separate patch/commit (i.e. not just a new version of
the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <lkp@...el.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202410172126.EXJ0sOkP-lkp@intel.com/
All errors (new ones prefixed by >>):
>> drivers/char/hw_random/airoha-trng.c:115:6: error: call to undeclared function 'FIELD_GET'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]
115 | FIELD_GET(CNT_TRANS, val) == TRNG_CNT_TRANS_VALID,
| ^
>> drivers/char/hw_random/airoha-trng.c:115:6: error: call to undeclared function 'FIELD_GET'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]
2 errors generated.
vim +/FIELD_GET +115 drivers/char/hw_random/airoha-trng.c
75
76 static int airoha_trng_init(struct hwrng *rng)
77 {
78 struct airoha_trng *trng = container_of(rng, struct airoha_trng, rng);
79 int ret;
80 u32 val;
81
82 val = readl(trng->base + TRNG_NS_SEK_AND_DAT_EN);
83 val |= RNG_EN;
84 writel(val, trng->base + TRNG_NS_SEK_AND_DAT_EN);
85
86 /* Set out of SW Reset */
87 airoha_trng_irq_unmask(trng);
88 writel(0, trng->base + TRNG_HEALTH_TEST_SW_RST);
89
90 ret = wait_for_completion_timeout(&trng->rng_op_done, BUSY_LOOP_TIMEOUT);
91 if (ret <= 0) {
92 dev_err(trng->dev, "Timeout waiting for Health Check\n");
93 airoha_trng_irq_mask(trng);
94 return -ENODEV;
95 }
96
97 /* Check if Health Test Failed */
98 val = readl(trng->base + TRNG_HEALTH_TEST_STATUS);
99 if (val & (RST_STARTUP_AP_TEST_FAIL | RST_STARTUP_RC_TEST_FAIL)) {
100 dev_err(trng->dev, "Health Check fail: %s test fail\n",
101 val & RST_STARTUP_AP_TEST_FAIL ? "AP" : "RC");
102 return -ENODEV;
103 }
104
105 /* Check if IP is ready */
106 ret = readl_poll_timeout(trng->base + TRNG_IP_RDY, val,
107 val & SAMPLE_RDY, 10, 1000);
108 if (ret < 0) {
109 dev_err(trng->dev, "Timeout waiting for IP ready");
110 return -ENODEV;
111 }
112
113 /* CNT_TRANS must be 0x80 for IP to be considered ready */
114 ret = readl_poll_timeout(trng->base + TRNG_IP_RDY, val,
> 115 FIELD_GET(CNT_TRANS, val) == TRNG_CNT_TRANS_VALID,
116 10, 1000);
117 if (ret < 0) {
118 dev_err(trng->dev, "Timeout waiting for IP ready");
119 return -ENODEV;
120 }
121
122 return 0;
123 }
124
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
Powered by blists - more mailing lists