Re: [PATCH v4 2/4] crypto: support rsa-pss encoding

From: kernel test robot
Date: Thu Apr 08 2021 - 09:13:20 EST


Hi Hongbo,

Thank you for the patch! Yet something to improve:

[auto build test ERROR on cryptodev/master]
[also build test ERROR on crypto/master security/next-testing linus/master v5.12-rc6 next-20210407]
[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]

url: https://github.com/0day-ci/linux/commits/Hongbo-Li/crypto-add-rsa-pss-support-for-x509/20210407-214446
base: https://git.kernel.org/pub/scm/linux/kernel/git/herbert/cryptodev-2.6.git master
config: x86_64-randconfig-a006-20210408 (attached as .config)
compiler: gcc-9 (Debian 9.3.0-22) 9.3.0
reproduce (this is a W=1 build):
# https://github.com/0day-ci/linux/commit/16672847d0bd803ad40d0b2065125645c082585a
git remote add linux-review https://github.com/0day-ci/linux
git fetch --no-tags linux-review Hongbo-Li/crypto-add-rsa-pss-support-for-x509/20210407-214446
git checkout 16672847d0bd803ad40d0b2065125645c082585a
# save the attached .config to linux build tree
make W=1 ARCH=x86_64

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

All errors (new ones prefixed by >>):

ld: crypto/rsa_helper.o: in function `rsa_get_pss_hash':
>> crypto/rsa_helper.c:161: undefined reference to `look_up_OID'
ld: crypto/rsa_helper.o: in function `rsa_get_pss_mgf':
crypto/rsa_helper.c:195: undefined reference to `look_up_OID'
ld: crypto/rsa_helper.o: in function `rsa_get_pss_mgf_hash':
crypto/rsa_helper.c:212: undefined reference to `look_up_OID'


vim +161 crypto/rsa_helper.c

151
152 int rsa_get_pss_hash(void *context, size_t hdrlen, unsigned char tag,
153 const void *value, size_t vlen)
154 {
155 struct rsa_pss_ctx *ctx = context;
156 enum OID oid;
157
158 if (!value || !vlen)
159 return -EINVAL;
160
> 161 oid = look_up_OID(value, vlen);
162 switch (oid) {
163 case OID_sha1:
164 ctx->hash_algo = "sha1";
165 break;
166 case OID_sha224:
167 ctx->hash_algo = "sha224";
168 break;
169 case OID_sha256:
170 ctx->hash_algo = "sha256";
171 break;
172 case OID_sha384:
173 ctx->hash_algo = "sha384";
174 break;
175 case OID_sha512:
176 ctx->hash_algo = "sha512";
177 break;
178 default:
179 return -ENOPKG;
180
181 }
182
183 return 0;
184 }
185

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

Attachment: .config.gz
Description: application/gzip