Re: [PATCH v2 1/2] crypto: caam - reduce page 0 regs access to minimum

From: kernel test robot
Date: Wed Mar 29 2023 - 11:52:44 EST


Hi,

Thank you for the patch! Perhaps something to improve:

[auto build test WARNING on herbert-cryptodev-2.6/master]
[also build test WARNING on herbert-crypto-2.6/master linus/master v6.3-rc4 next-20230329]
[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/meenakshi-aggarwal-nxp-com/crypto-caam-OP-TEE-firmware-support/20230322-151746
base: https://git.kernel.org/pub/scm/linux/kernel/git/herbert/cryptodev-2.6.git master
patch link: https://lore.kernel.org/r/20230322061716.3195841-2-meenakshi.aggarwal%40nxp.com
patch subject: [PATCH v2 1/2] crypto: caam - reduce page 0 regs access to minimum
config: powerpc-randconfig-s051-20230329 (https://download.01.org/0day-ci/archive/20230329/202303292311.eRQf8n1I-lkp@xxxxxxxxx/config)
compiler: powerpc-linux-gcc (GCC) 12.1.0
reproduce:
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# apt-get install sparse
# sparse version: v0.6.4-39-gce1a6720-dirty
# https://github.com/intel-lab-lkp/linux/commit/627d651dccbe8862582b68f0ceab5c40460dd281
git remote add linux-review https://github.com/intel-lab-lkp/linux
git fetch --no-tags linux-review meenakshi-aggarwal-nxp-com/crypto-caam-OP-TEE-firmware-support/20230322-151746
git checkout 627d651dccbe8862582b68f0ceab5c40460dd281
# save the config file
mkdir build_dir && cp config build_dir/.config
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-12.1.0 make.cross C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' O=build_dir ARCH=powerpc olddefconfig
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-12.1.0 make.cross C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' O=build_dir ARCH=powerpc SHELL=/bin/bash drivers/crypto/caam/ drivers/media/i2c/ drivers/phy/

If you fix the issue, kindly add following tag where applicable
| Reported-by: kernel test robot <lkp@xxxxxxxxx>
| Link: https://lore.kernel.org/oe-kbuild-all/202303292311.eRQf8n1I-lkp@xxxxxxxxx/

sparse warnings: (new ones prefixed by >>)
>> drivers/crypto/caam/debugfs.c:58:30: sparse: sparse: incorrect type in argument 4 (different address spaces) @@ expected void *data @@ got unsigned long long [noderef] __iomem * @@
drivers/crypto/caam/debugfs.c:58:30: sparse: expected void *data
drivers/crypto/caam/debugfs.c:58:30: sparse: got unsigned long long [noderef] __iomem *
drivers/crypto/caam/debugfs.c:60:30: sparse: sparse: incorrect type in argument 4 (different address spaces) @@ expected void *data @@ got unsigned long long [noderef] __iomem * @@
drivers/crypto/caam/debugfs.c:60:30: sparse: expected void *data
drivers/crypto/caam/debugfs.c:60:30: sparse: got unsigned long long [noderef] __iomem *
drivers/crypto/caam/debugfs.c:62:30: sparse: sparse: incorrect type in argument 4 (different address spaces) @@ expected void *data @@ got unsigned long long [noderef] __iomem * @@
drivers/crypto/caam/debugfs.c:62:30: sparse: expected void *data
drivers/crypto/caam/debugfs.c:62:30: sparse: got unsigned long long [noderef] __iomem *
drivers/crypto/caam/debugfs.c:64:30: sparse: sparse: incorrect type in argument 4 (different address spaces) @@ expected void *data @@ got unsigned long long [noderef] __iomem * @@
drivers/crypto/caam/debugfs.c:64:30: sparse: expected void *data
drivers/crypto/caam/debugfs.c:64:30: sparse: got unsigned long long [noderef] __iomem *
drivers/crypto/caam/debugfs.c:66:30: sparse: sparse: incorrect type in argument 4 (different address spaces) @@ expected void *data @@ got unsigned long long [noderef] __iomem * @@
drivers/crypto/caam/debugfs.c:66:30: sparse: expected void *data
drivers/crypto/caam/debugfs.c:66:30: sparse: got unsigned long long [noderef] __iomem *
drivers/crypto/caam/debugfs.c:68:30: sparse: sparse: incorrect type in argument 4 (different address spaces) @@ expected void *data @@ got unsigned long long [noderef] __iomem * @@
drivers/crypto/caam/debugfs.c:68:30: sparse: expected void *data
drivers/crypto/caam/debugfs.c:68:30: sparse: got unsigned long long [noderef] __iomem *
drivers/crypto/caam/debugfs.c:70:30: sparse: sparse: incorrect type in argument 4 (different address spaces) @@ expected void *data @@ got unsigned long long [noderef] __iomem * @@
drivers/crypto/caam/debugfs.c:70:30: sparse: expected void *data
drivers/crypto/caam/debugfs.c:70:30: sparse: got unsigned long long [noderef] __iomem *
drivers/crypto/caam/debugfs.c:74:30: sparse: sparse: incorrect type in argument 4 (different address spaces) @@ expected void *data @@ got unsigned long long [noderef] __iomem * @@
drivers/crypto/caam/debugfs.c:74:30: sparse: expected void *data
drivers/crypto/caam/debugfs.c:74:30: sparse: got unsigned long long [noderef] __iomem *
>> drivers/crypto/caam/debugfs.c:76:30: sparse: sparse: incorrect type in argument 4 (different address spaces) @@ expected void *data @@ got unsigned int [noderef] __iomem * @@
drivers/crypto/caam/debugfs.c:76:30: sparse: expected void *data
drivers/crypto/caam/debugfs.c:76:30: sparse: got unsigned int [noderef] __iomem *
drivers/crypto/caam/debugfs.c:78:30: sparse: sparse: incorrect type in argument 4 (different address spaces) @@ expected void *data @@ got unsigned int [noderef] __iomem * @@
drivers/crypto/caam/debugfs.c:78:30: sparse: expected void *data
drivers/crypto/caam/debugfs.c:78:30: sparse: got unsigned int [noderef] __iomem *

vim +58 drivers/crypto/caam/debugfs.c

abd9875497ba47 Horia Geantă 2020-08-06 44
627d651dccbe88 Horia GeantA 2023-03-22 45 void caam_debugfs_init(struct caam_drv_private *ctrlpriv,
627d651dccbe88 Horia GeantA 2023-03-22 46 struct caam_perfmon __iomem *perfmon,
627d651dccbe88 Horia GeantA 2023-03-22 47 struct dentry *root)
abd9875497ba47 Horia Geantă 2020-08-06 48 {
abd9875497ba47 Horia Geantă 2020-08-06 49 /*
abd9875497ba47 Horia Geantă 2020-08-06 50 * FIXME: needs better naming distinction, as some amalgamation of
abd9875497ba47 Horia Geantă 2020-08-06 51 * "caam" and nprop->full_name. The OF name isn't distinctive,
abd9875497ba47 Horia Geantă 2020-08-06 52 * but does separate instances
abd9875497ba47 Horia Geantă 2020-08-06 53 */
abd9875497ba47 Horia Geantă 2020-08-06 54
abd9875497ba47 Horia Geantă 2020-08-06 55 ctrlpriv->ctl = debugfs_create_dir("ctl", root);
abd9875497ba47 Horia Geantă 2020-08-06 56
abd9875497ba47 Horia Geantă 2020-08-06 57 debugfs_create_file("rq_dequeued", 0444, ctrlpriv->ctl,
abd9875497ba47 Horia Geantă 2020-08-06 @58 &perfmon->req_dequeued, &caam_fops_u64_ro);
abd9875497ba47 Horia Geantă 2020-08-06 59 debugfs_create_file("ob_rq_encrypted", 0444, ctrlpriv->ctl,
abd9875497ba47 Horia Geantă 2020-08-06 60 &perfmon->ob_enc_req, &caam_fops_u64_ro);
abd9875497ba47 Horia Geantă 2020-08-06 61 debugfs_create_file("ib_rq_decrypted", 0444, ctrlpriv->ctl,
abd9875497ba47 Horia Geantă 2020-08-06 62 &perfmon->ib_dec_req, &caam_fops_u64_ro);
abd9875497ba47 Horia Geantă 2020-08-06 63 debugfs_create_file("ob_bytes_encrypted", 0444, ctrlpriv->ctl,
abd9875497ba47 Horia Geantă 2020-08-06 64 &perfmon->ob_enc_bytes, &caam_fops_u64_ro);
abd9875497ba47 Horia Geantă 2020-08-06 65 debugfs_create_file("ob_bytes_protected", 0444, ctrlpriv->ctl,
abd9875497ba47 Horia Geantă 2020-08-06 66 &perfmon->ob_prot_bytes, &caam_fops_u64_ro);
abd9875497ba47 Horia Geantă 2020-08-06 67 debugfs_create_file("ib_bytes_decrypted", 0444, ctrlpriv->ctl,
abd9875497ba47 Horia Geantă 2020-08-06 68 &perfmon->ib_dec_bytes, &caam_fops_u64_ro);
abd9875497ba47 Horia Geantă 2020-08-06 69 debugfs_create_file("ib_bytes_validated", 0444, ctrlpriv->ctl,
abd9875497ba47 Horia Geantă 2020-08-06 70 &perfmon->ib_valid_bytes, &caam_fops_u64_ro);
abd9875497ba47 Horia Geantă 2020-08-06 71
abd9875497ba47 Horia Geantă 2020-08-06 72 /* Controller level - global status values */
abd9875497ba47 Horia Geantă 2020-08-06 73 debugfs_create_file("fault_addr", 0444, ctrlpriv->ctl,
abd9875497ba47 Horia Geantă 2020-08-06 74 &perfmon->faultaddr, &caam_fops_u32_ro);
abd9875497ba47 Horia Geantă 2020-08-06 75 debugfs_create_file("fault_detail", 0444, ctrlpriv->ctl,
abd9875497ba47 Horia Geantă 2020-08-06 @76 &perfmon->faultdetail, &caam_fops_u32_ro);

--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests