lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [day] [month] [year] [list]
Message-ID: <202007300754.hEKdCT4Y%lkp@intel.com>
Date:   Thu, 30 Jul 2020 07:07:58 +0800
From:   kernel test robot <lkp@...el.com>
To:     Luc Van Oostenryck <luc.vanoostenryck@...il.com>
Cc:     kbuild-all@...ts.01.org, linux-kernel@...r.kernel.org
Subject: arch/powerpc/sysdev/fsl_rcpm.c:32:9: sparse: sparse: incorrect type
 in argument 1 (different base types)

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head:   d3590ebf6f91350192737dd1d1b219c05277f067
commit: 670d0a4b10704667765f7d18f7592993d02783aa sparse: use identifiers to define address spaces
date:   6 weeks ago
config: powerpc-randconfig-s031-20200729 (attached as .config)
compiler: powerpc64-linux-gcc (GCC) 9.3.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.2-97-gee4aea9a-dirty
        git checkout 670d0a4b10704667765f7d18f7592993d02783aa
        # save the attached .config to linux build tree
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' ARCH=powerpc 

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


sparse warnings: (new ones prefixed by >>)

>> arch/powerpc/sysdev/fsl_rcpm.c:32:9: sparse: sparse: incorrect type in argument 1 (different base types) @@     expected unsigned int volatile [noderef] [usertype] __iomem *addr @@     got restricted __be32 [noderef] __iomem * @@
>> arch/powerpc/sysdev/fsl_rcpm.c:32:9: sparse:     expected unsigned int volatile [noderef] [usertype] __iomem *addr
>> arch/powerpc/sysdev/fsl_rcpm.c:32:9: sparse:     got restricted __be32 [noderef] __iomem *
>> arch/powerpc/sysdev/fsl_rcpm.c:32:9: sparse: sparse: incorrect type in argument 1 (different base types) @@     expected unsigned int const volatile [noderef] [usertype] __iomem *addr @@     got restricted __be32 [noderef] __iomem * @@
>> arch/powerpc/sysdev/fsl_rcpm.c:32:9: sparse:     expected unsigned int const volatile [noderef] [usertype] __iomem *addr
>> arch/powerpc/sysdev/fsl_rcpm.c:32:9: sparse:     got restricted __be32 [noderef] __iomem *
   arch/powerpc/sysdev/fsl_rcpm.c:33:9: sparse: sparse: incorrect type in argument 1 (different base types) @@     expected unsigned int volatile [noderef] [usertype] __iomem *addr @@     got restricted __be32 [noderef] __iomem * @@
   arch/powerpc/sysdev/fsl_rcpm.c:33:9: sparse:     expected unsigned int volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:33:9: sparse:     got restricted __be32 [noderef] __iomem *
   arch/powerpc/sysdev/fsl_rcpm.c:33:9: sparse: sparse: incorrect type in argument 1 (different base types) @@     expected unsigned int const volatile [noderef] [usertype] __iomem *addr @@     got restricted __be32 [noderef] __iomem * @@
   arch/powerpc/sysdev/fsl_rcpm.c:33:9: sparse:     expected unsigned int const volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:33:9: sparse:     got restricted __be32 [noderef] __iomem *
   arch/powerpc/sysdev/fsl_rcpm.c:34:9: sparse: sparse: incorrect type in argument 1 (different base types) @@     expected unsigned int volatile [noderef] [usertype] __iomem *addr @@     got restricted __be32 [noderef] __iomem * @@
   arch/powerpc/sysdev/fsl_rcpm.c:34:9: sparse:     expected unsigned int volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:34:9: sparse:     got restricted __be32 [noderef] __iomem *
   arch/powerpc/sysdev/fsl_rcpm.c:34:9: sparse: sparse: incorrect type in argument 1 (different base types) @@     expected unsigned int const volatile [noderef] [usertype] __iomem *addr @@     got restricted __be32 [noderef] __iomem * @@
   arch/powerpc/sysdev/fsl_rcpm.c:34:9: sparse:     expected unsigned int const volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:34:9: sparse:     got restricted __be32 [noderef] __iomem *
   arch/powerpc/sysdev/fsl_rcpm.c:35:9: sparse: sparse: incorrect type in argument 1 (different base types) @@     expected unsigned int volatile [noderef] [usertype] __iomem *addr @@     got restricted __be32 [noderef] __iomem * @@
   arch/powerpc/sysdev/fsl_rcpm.c:35:9: sparse:     expected unsigned int volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:35:9: sparse:     got restricted __be32 [noderef] __iomem *
   arch/powerpc/sysdev/fsl_rcpm.c:35:9: sparse: sparse: incorrect type in argument 1 (different base types) @@     expected unsigned int const volatile [noderef] [usertype] __iomem *addr @@     got restricted __be32 [noderef] __iomem * @@
   arch/powerpc/sysdev/fsl_rcpm.c:35:9: sparse:     expected unsigned int const volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:35:9: sparse:     got restricted __be32 [noderef] __iomem *
   arch/powerpc/sysdev/fsl_rcpm.c:43:9: sparse: sparse: incorrect type in argument 1 (different base types) @@     expected unsigned int volatile [noderef] [usertype] __iomem *addr @@     got restricted __be32 [noderef] __iomem * @@
   arch/powerpc/sysdev/fsl_rcpm.c:43:9: sparse:     expected unsigned int volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:43:9: sparse:     got restricted __be32 [noderef] __iomem *
   arch/powerpc/sysdev/fsl_rcpm.c:43:9: sparse: sparse: incorrect type in argument 1 (different base types) @@     expected unsigned int const volatile [noderef] [usertype] __iomem *addr @@     got restricted __be32 [noderef] __iomem * @@
   arch/powerpc/sysdev/fsl_rcpm.c:43:9: sparse:     expected unsigned int const volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:43:9: sparse:     got restricted __be32 [noderef] __iomem *
   arch/powerpc/sysdev/fsl_rcpm.c:44:9: sparse: sparse: incorrect type in argument 1 (different base types) @@     expected unsigned int volatile [noderef] [usertype] __iomem *addr @@     got restricted __be32 [noderef] __iomem * @@
   arch/powerpc/sysdev/fsl_rcpm.c:44:9: sparse:     expected unsigned int volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:44:9: sparse:     got restricted __be32 [noderef] __iomem *
   arch/powerpc/sysdev/fsl_rcpm.c:44:9: sparse: sparse: incorrect type in argument 1 (different base types) @@     expected unsigned int const volatile [noderef] [usertype] __iomem *addr @@     got restricted __be32 [noderef] __iomem * @@
   arch/powerpc/sysdev/fsl_rcpm.c:44:9: sparse:     expected unsigned int const volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:44:9: sparse:     got restricted __be32 [noderef] __iomem *
   arch/powerpc/sysdev/fsl_rcpm.c:45:9: sparse: sparse: incorrect type in argument 1 (different base types) @@     expected unsigned int volatile [noderef] [usertype] __iomem *addr @@     got restricted __be32 [noderef] __iomem * @@
   arch/powerpc/sysdev/fsl_rcpm.c:45:9: sparse:     expected unsigned int volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:45:9: sparse:     got restricted __be32 [noderef] __iomem *
   arch/powerpc/sysdev/fsl_rcpm.c:45:9: sparse: sparse: incorrect type in argument 1 (different base types) @@     expected unsigned int const volatile [noderef] [usertype] __iomem *addr @@     got restricted __be32 [noderef] __iomem * @@
   arch/powerpc/sysdev/fsl_rcpm.c:45:9: sparse:     expected unsigned int const volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:45:9: sparse:     got restricted __be32 [noderef] __iomem *
   arch/powerpc/sysdev/fsl_rcpm.c:46:9: sparse: sparse: incorrect type in argument 1 (different base types) @@     expected unsigned int volatile [noderef] [usertype] __iomem *addr @@     got restricted __be32 [noderef] __iomem * @@
   arch/powerpc/sysdev/fsl_rcpm.c:46:9: sparse:     expected unsigned int volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:46:9: sparse:     got restricted __be32 [noderef] __iomem *
   arch/powerpc/sysdev/fsl_rcpm.c:46:9: sparse: sparse: incorrect type in argument 1 (different base types) @@     expected unsigned int const volatile [noderef] [usertype] __iomem *addr @@     got restricted __be32 [noderef] __iomem * @@
   arch/powerpc/sysdev/fsl_rcpm.c:46:9: sparse:     expected unsigned int const volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:46:9: sparse:     got restricted __be32 [noderef] __iomem *
   arch/powerpc/sysdev/fsl_rcpm.c:54:9: sparse: sparse: incorrect type in argument 1 (different base types) @@     expected unsigned int volatile [noderef] [usertype] __iomem *addr @@     got restricted __be32 [noderef] __iomem * @@
   arch/powerpc/sysdev/fsl_rcpm.c:54:9: sparse:     expected unsigned int volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:54:9: sparse:     got restricted __be32 [noderef] __iomem *
   arch/powerpc/sysdev/fsl_rcpm.c:54:9: sparse: sparse: incorrect type in argument 1 (different base types) @@     expected unsigned int const volatile [noderef] [usertype] __iomem *addr @@     got restricted __be32 [noderef] __iomem * @@
   arch/powerpc/sysdev/fsl_rcpm.c:54:9: sparse:     expected unsigned int const volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:54:9: sparse:     got restricted __be32 [noderef] __iomem *
   arch/powerpc/sysdev/fsl_rcpm.c:55:9: sparse: sparse: incorrect type in argument 1 (different base types) @@     expected unsigned int volatile [noderef] [usertype] __iomem *addr @@     got restricted __be32 [noderef] __iomem * @@
   arch/powerpc/sysdev/fsl_rcpm.c:55:9: sparse:     expected unsigned int volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:55:9: sparse:     got restricted __be32 [noderef] __iomem *
   arch/powerpc/sysdev/fsl_rcpm.c:55:9: sparse: sparse: incorrect type in argument 1 (different base types) @@     expected unsigned int const volatile [noderef] [usertype] __iomem *addr @@     got restricted __be32 [noderef] __iomem * @@
   arch/powerpc/sysdev/fsl_rcpm.c:55:9: sparse:     expected unsigned int const volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:55:9: sparse:     got restricted __be32 [noderef] __iomem *
   arch/powerpc/sysdev/fsl_rcpm.c:56:9: sparse: sparse: incorrect type in argument 1 (different base types) @@     expected unsigned int volatile [noderef] [usertype] __iomem *addr @@     got restricted __be32 [noderef] __iomem * @@
   arch/powerpc/sysdev/fsl_rcpm.c:56:9: sparse:     expected unsigned int volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:56:9: sparse:     got restricted __be32 [noderef] __iomem *
   arch/powerpc/sysdev/fsl_rcpm.c:56:9: sparse: sparse: incorrect type in argument 1 (different base types) @@     expected unsigned int const volatile [noderef] [usertype] __iomem *addr @@     got restricted __be32 [noderef] __iomem * @@
   arch/powerpc/sysdev/fsl_rcpm.c:56:9: sparse:     expected unsigned int const volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:56:9: sparse:     got restricted __be32 [noderef] __iomem *
   arch/powerpc/sysdev/fsl_rcpm.c:57:9: sparse: sparse: incorrect type in argument 1 (different base types) @@     expected unsigned int volatile [noderef] [usertype] __iomem *addr @@     got restricted __be32 [noderef] __iomem * @@
   arch/powerpc/sysdev/fsl_rcpm.c:57:9: sparse:     expected unsigned int volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:57:9: sparse:     got restricted __be32 [noderef] __iomem *
   arch/powerpc/sysdev/fsl_rcpm.c:57:9: sparse: sparse: incorrect type in argument 1 (different base types) @@     expected unsigned int const volatile [noderef] [usertype] __iomem *addr @@     got restricted __be32 [noderef] __iomem * @@
   arch/powerpc/sysdev/fsl_rcpm.c:57:9: sparse:     expected unsigned int const volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:57:9: sparse:     got restricted __be32 [noderef] __iomem *
   arch/powerpc/sysdev/fsl_rcpm.c:65:9: sparse: sparse: incorrect type in argument 1 (different base types) @@     expected unsigned int volatile [noderef] [usertype] __iomem *addr @@     got restricted __be32 [noderef] __iomem * @@
   arch/powerpc/sysdev/fsl_rcpm.c:65:9: sparse:     expected unsigned int volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:65:9: sparse:     got restricted __be32 [noderef] __iomem *
   arch/powerpc/sysdev/fsl_rcpm.c:65:9: sparse: sparse: incorrect type in argument 1 (different base types) @@     expected unsigned int const volatile [noderef] [usertype] __iomem *addr @@     got restricted __be32 [noderef] __iomem * @@
   arch/powerpc/sysdev/fsl_rcpm.c:65:9: sparse:     expected unsigned int const volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:65:9: sparse:     got restricted __be32 [noderef] __iomem *
   arch/powerpc/sysdev/fsl_rcpm.c:66:9: sparse: sparse: incorrect type in argument 1 (different base types) @@     expected unsigned int volatile [noderef] [usertype] __iomem *addr @@     got restricted __be32 [noderef] __iomem * @@
   arch/powerpc/sysdev/fsl_rcpm.c:66:9: sparse:     expected unsigned int volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:66:9: sparse:     got restricted __be32 [noderef] __iomem *
   arch/powerpc/sysdev/fsl_rcpm.c:66:9: sparse: sparse: incorrect type in argument 1 (different base types) @@     expected unsigned int const volatile [noderef] [usertype] __iomem *addr @@     got restricted __be32 [noderef] __iomem * @@
   arch/powerpc/sysdev/fsl_rcpm.c:66:9: sparse:     expected unsigned int const volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:66:9: sparse:     got restricted __be32 [noderef] __iomem *
   arch/powerpc/sysdev/fsl_rcpm.c:67:9: sparse: sparse: incorrect type in argument 1 (different base types) @@     expected unsigned int volatile [noderef] [usertype] __iomem *addr @@     got restricted __be32 [noderef] __iomem * @@
   arch/powerpc/sysdev/fsl_rcpm.c:67:9: sparse:     expected unsigned int volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:67:9: sparse:     got restricted __be32 [noderef] __iomem *
   arch/powerpc/sysdev/fsl_rcpm.c:67:9: sparse: sparse: incorrect type in argument 1 (different base types) @@     expected unsigned int const volatile [noderef] [usertype] __iomem *addr @@     got restricted __be32 [noderef] __iomem * @@
   arch/powerpc/sysdev/fsl_rcpm.c:67:9: sparse:     expected unsigned int const volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:67:9: sparse:     got restricted __be32 [noderef] __iomem *
   arch/powerpc/sysdev/fsl_rcpm.c:68:9: sparse: sparse: incorrect type in argument 1 (different base types) @@     expected unsigned int volatile [noderef] [usertype] __iomem *addr @@     got restricted __be32 [noderef] __iomem * @@
   arch/powerpc/sysdev/fsl_rcpm.c:68:9: sparse:     expected unsigned int volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:68:9: sparse:     got restricted __be32 [noderef] __iomem *
   arch/powerpc/sysdev/fsl_rcpm.c:68:9: sparse: sparse: incorrect type in argument 1 (different base types) @@     expected unsigned int const volatile [noderef] [usertype] __iomem *addr @@     got restricted __be32 [noderef] __iomem * @@
   arch/powerpc/sysdev/fsl_rcpm.c:68:9: sparse:     expected unsigned int const volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:68:9: sparse:     got restricted __be32 [noderef] __iomem *
   arch/powerpc/sysdev/fsl_rcpm.c:74:17: sparse: sparse: incorrect type in argument 1 (different base types) @@     expected unsigned int volatile [noderef] [usertype] __iomem *addr @@     got restricted __be32 [noderef] __iomem * @@
   arch/powerpc/sysdev/fsl_rcpm.c:74:17: sparse:     expected unsigned int volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:74:17: sparse:     got restricted __be32 [noderef] __iomem *
   arch/powerpc/sysdev/fsl_rcpm.c:74:17: sparse: sparse: incorrect type in argument 1 (different base types) @@     expected unsigned int const volatile [noderef] [usertype] __iomem *addr @@     got restricted __be32 [noderef] __iomem * @@
   arch/powerpc/sysdev/fsl_rcpm.c:74:17: sparse:     expected unsigned int const volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:74:17: sparse:     got restricted __be32 [noderef] __iomem *
   arch/powerpc/sysdev/fsl_rcpm.c:76:17: sparse: sparse: incorrect type in argument 1 (different base types) @@     expected unsigned int volatile [noderef] [usertype] __iomem *addr @@     got restricted __be32 [noderef] __iomem * @@
   arch/powerpc/sysdev/fsl_rcpm.c:76:17: sparse:     expected unsigned int volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:76:17: sparse:     got restricted __be32 [noderef] __iomem *
   arch/powerpc/sysdev/fsl_rcpm.c:76:17: sparse: sparse: incorrect type in argument 1 (different base types) @@     expected unsigned int const volatile [noderef] [usertype] __iomem *addr @@     got restricted __be32 [noderef] __iomem * @@
   arch/powerpc/sysdev/fsl_rcpm.c:76:17: sparse:     expected unsigned int const volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:76:17: sparse:     got restricted __be32 [noderef] __iomem *
   arch/powerpc/sysdev/fsl_rcpm.c:82:17: sparse: sparse: incorrect type in argument 1 (different base types) @@     expected unsigned int volatile [noderef] [usertype] __iomem *addr @@     got restricted __be32 [noderef] __iomem * @@
   arch/powerpc/sysdev/fsl_rcpm.c:82:17: sparse:     expected unsigned int volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:82:17: sparse:     got restricted __be32 [noderef] __iomem *
   arch/powerpc/sysdev/fsl_rcpm.c:82:17: sparse: sparse: incorrect type in argument 1 (different base types) @@     expected unsigned int const volatile [noderef] [usertype] __iomem *addr @@     got restricted __be32 [noderef] __iomem * @@
   arch/powerpc/sysdev/fsl_rcpm.c:82:17: sparse:     expected unsigned int const volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:82:17: sparse:     got restricted __be32 [noderef] __iomem *
   arch/powerpc/sysdev/fsl_rcpm.c:84:17: sparse: sparse: incorrect type in argument 1 (different base types) @@     expected unsigned int volatile [noderef] [usertype] __iomem *addr @@     got restricted __be32 [noderef] __iomem * @@
   arch/powerpc/sysdev/fsl_rcpm.c:84:17: sparse:     expected unsigned int volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:84:17: sparse:     got restricted __be32 [noderef] __iomem *
   arch/powerpc/sysdev/fsl_rcpm.c:84:17: sparse: sparse: incorrect type in argument 1 (different base types) @@     expected unsigned int const volatile [noderef] [usertype] __iomem *addr @@     got restricted __be32 [noderef] __iomem * @@
   arch/powerpc/sysdev/fsl_rcpm.c:84:17: sparse:     expected unsigned int const volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:84:17: sparse:     got restricted __be32 [noderef] __iomem *
   arch/powerpc/sysdev/fsl_rcpm.c:94:17: sparse: sparse: incorrect type in argument 1 (different base types) @@     expected unsigned int volatile [noderef] [usertype] __iomem *addr @@     got restricted __be32 [noderef] __iomem * @@
   arch/powerpc/sysdev/fsl_rcpm.c:94:17: sparse:     expected unsigned int volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:94:17: sparse:     got restricted __be32 [noderef] __iomem *
   arch/powerpc/sysdev/fsl_rcpm.c:94:17: sparse: sparse: incorrect type in argument 1 (different base types) @@     expected unsigned int const volatile [noderef] [usertype] __iomem *addr @@     got restricted __be32 [noderef] __iomem * @@
   arch/powerpc/sysdev/fsl_rcpm.c:94:17: sparse:     expected unsigned int const volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:94:17: sparse:     got restricted __be32 [noderef] __iomem *
   arch/powerpc/sysdev/fsl_rcpm.c:97:17: sparse: sparse: incorrect type in argument 1 (different base types) @@     expected unsigned int volatile [noderef] [usertype] __iomem *addr @@     got restricted __be32 [noderef] __iomem * @@
   arch/powerpc/sysdev/fsl_rcpm.c:97:17: sparse:     expected unsigned int volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:97:17: sparse:     got restricted __be32 [noderef] __iomem *
   arch/powerpc/sysdev/fsl_rcpm.c:97:17: sparse: sparse: incorrect type in argument 1 (different base types) @@     expected unsigned int const volatile [noderef] [usertype] __iomem *addr @@     got restricted __be32 [noderef] __iomem * @@
   arch/powerpc/sysdev/fsl_rcpm.c:97:17: sparse:     expected unsigned int const volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:97:17: sparse:     got restricted __be32 [noderef] __iomem *
   arch/powerpc/sysdev/fsl_rcpm.c:113:17: sparse: sparse: incorrect type in argument 1 (different base types) @@     expected unsigned int volatile [noderef] [usertype] __iomem *addr @@     got restricted __be32 [noderef] __iomem * @@
   arch/powerpc/sysdev/fsl_rcpm.c:113:17: sparse:     expected unsigned int volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:113:17: sparse:     got restricted __be32 [noderef] __iomem *
   arch/powerpc/sysdev/fsl_rcpm.c:113:17: sparse: sparse: incorrect type in argument 1 (different base types) @@     expected unsigned int const volatile [noderef] [usertype] __iomem *addr @@     got restricted __be32 [noderef] __iomem * @@
   arch/powerpc/sysdev/fsl_rcpm.c:113:17: sparse:     expected unsigned int const volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:113:17: sparse:     got restricted __be32 [noderef] __iomem *
   arch/powerpc/sysdev/fsl_rcpm.c:116:17: sparse: sparse: incorrect type in argument 1 (different base types) @@     expected unsigned int volatile [noderef] [usertype] __iomem *addr @@     got restricted __be32 [noderef] __iomem * @@
   arch/powerpc/sysdev/fsl_rcpm.c:116:17: sparse:     expected unsigned int volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:116:17: sparse:     got restricted __be32 [noderef] __iomem *
   arch/powerpc/sysdev/fsl_rcpm.c:116:17: sparse: sparse: incorrect type in argument 1 (different base types) @@     expected unsigned int const volatile [noderef] [usertype] __iomem *addr @@     got restricted __be32 [noderef] __iomem * @@
   arch/powerpc/sysdev/fsl_rcpm.c:116:17: sparse:     expected unsigned int const volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:116:17: sparse:     got restricted __be32 [noderef] __iomem *
   arch/powerpc/sysdev/fsl_rcpm.c:119:17: sparse: sparse: incorrect type in argument 1 (different base types) @@     expected unsigned int volatile [noderef] [usertype] __iomem *addr @@     got restricted __be32 [noderef] __iomem * @@
   arch/powerpc/sysdev/fsl_rcpm.c:119:17: sparse:     expected unsigned int volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:119:17: sparse:     got restricted __be32 [noderef] __iomem *
   arch/powerpc/sysdev/fsl_rcpm.c:119:17: sparse: sparse: incorrect type in argument 1 (different base types) @@     expected unsigned int const volatile [noderef] [usertype] __iomem *addr @@     got restricted __be32 [noderef] __iomem * @@
   arch/powerpc/sysdev/fsl_rcpm.c:119:17: sparse:     expected unsigned int const volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:119:17: sparse:     got restricted __be32 [noderef] __iomem *
   arch/powerpc/sysdev/fsl_rcpm.c:122:17: sparse: sparse: incorrect type in argument 1 (different base types) @@     expected unsigned int volatile [noderef] [usertype] __iomem *addr @@     got restricted __be32 [noderef] __iomem * @@
   arch/powerpc/sysdev/fsl_rcpm.c:122:17: sparse:     expected unsigned int volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:122:17: sparse:     got restricted __be32 [noderef] __iomem *
   arch/powerpc/sysdev/fsl_rcpm.c:122:17: sparse: sparse: incorrect type in argument 1 (different base types) @@     expected unsigned int const volatile [noderef] [usertype] __iomem *addr @@     got restricted __be32 [noderef] __iomem * @@
   arch/powerpc/sysdev/fsl_rcpm.c:122:17: sparse:     expected unsigned int const volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:122:17: sparse:     got restricted __be32 [noderef] __iomem *
   arch/powerpc/sysdev/fsl_rcpm.c:171:17: sparse: sparse: incorrect type in argument 1 (different base types) @@     expected unsigned int volatile [noderef] [usertype] __iomem *addr @@     got restricted __be32 [noderef] __iomem * @@
   arch/powerpc/sysdev/fsl_rcpm.c:171:17: sparse:     expected unsigned int volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:171:17: sparse:     got restricted __be32 [noderef] __iomem *
   arch/powerpc/sysdev/fsl_rcpm.c:171:17: sparse: sparse: incorrect type in argument 1 (different base types) @@     expected unsigned int const volatile [noderef] [usertype] __iomem *addr @@     got restricted __be32 [noderef] __iomem * @@
   arch/powerpc/sysdev/fsl_rcpm.c:171:17: sparse:     expected unsigned int const volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:171:17: sparse:     got restricted __be32 [noderef] __iomem *
   arch/powerpc/sysdev/fsl_rcpm.c:174:17: sparse: sparse: incorrect type in argument 1 (different base types) @@     expected unsigned int volatile [noderef] [usertype] __iomem *addr @@     got restricted __be32 [noderef] __iomem * @@
   arch/powerpc/sysdev/fsl_rcpm.c:174:17: sparse:     expected unsigned int volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:174:17: sparse:     got restricted __be32 [noderef] __iomem *
   arch/powerpc/sysdev/fsl_rcpm.c:174:17: sparse: sparse: incorrect type in argument 1 (different base types) @@     expected unsigned int const volatile [noderef] [usertype] __iomem *addr @@     got restricted __be32 [noderef] __iomem * @@
   arch/powerpc/sysdev/fsl_rcpm.c:174:17: sparse:     expected unsigned int const volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:174:17: sparse:     got restricted __be32 [noderef] __iomem *
   arch/powerpc/sysdev/fsl_rcpm.c:195:17: sparse: sparse: incorrect type in argument 1 (different base types) @@     expected unsigned int volatile [noderef] [usertype] __iomem *addr @@     got restricted __be32 [noderef] __iomem * @@
   arch/powerpc/sysdev/fsl_rcpm.c:195:17: sparse:     expected unsigned int volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:195:17: sparse:     got restricted __be32 [noderef] __iomem *
   arch/powerpc/sysdev/fsl_rcpm.c:195:17: sparse: sparse: incorrect type in argument 1 (different base types) @@     expected unsigned int const volatile [noderef] [usertype] __iomem *addr @@     got restricted __be32 [noderef] __iomem * @@
   arch/powerpc/sysdev/fsl_rcpm.c:195:17: sparse:     expected unsigned int const volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:195:17: sparse:     got restricted __be32 [noderef] __iomem *
   arch/powerpc/sysdev/fsl_rcpm.c:198:17: sparse: sparse: incorrect type in argument 1 (different base types) @@     expected unsigned int volatile [noderef] [usertype] __iomem *addr @@     got restricted __be32 [noderef] __iomem * @@
   arch/powerpc/sysdev/fsl_rcpm.c:198:17: sparse:     expected unsigned int volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:198:17: sparse:     got restricted __be32 [noderef] __iomem *
   arch/powerpc/sysdev/fsl_rcpm.c:198:17: sparse: sparse: incorrect type in argument 1 (different base types) @@     expected unsigned int const volatile [noderef] [usertype] __iomem *addr @@     got restricted __be32 [noderef] __iomem * @@
   arch/powerpc/sysdev/fsl_rcpm.c:198:17: sparse:     expected unsigned int const volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:198:17: sparse:     got restricted __be32 [noderef] __iomem *
   arch/powerpc/sysdev/fsl_rcpm.c:201:17: sparse: sparse: incorrect type in argument 1 (different base types) @@     expected unsigned int volatile [noderef] [usertype] __iomem *addr @@     got restricted __be32 [noderef] __iomem * @@
   arch/powerpc/sysdev/fsl_rcpm.c:201:17: sparse:     expected unsigned int volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:201:17: sparse:     got restricted __be32 [noderef] __iomem *
   arch/powerpc/sysdev/fsl_rcpm.c:201:17: sparse: sparse: incorrect type in argument 1 (different base types) @@     expected unsigned int const volatile [noderef] [usertype] __iomem *addr @@     got restricted __be32 [noderef] __iomem * @@
   arch/powerpc/sysdev/fsl_rcpm.c:201:17: sparse:     expected unsigned int const volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:201:17: sparse:     got restricted __be32 [noderef] __iomem *
   arch/powerpc/sysdev/fsl_rcpm.c:204:17: sparse: sparse: incorrect type in argument 1 (different base types) @@     expected unsigned int volatile [noderef] [usertype] __iomem *addr @@     got restricted __be32 [noderef] __iomem * @@
   arch/powerpc/sysdev/fsl_rcpm.c:204:17: sparse:     expected unsigned int volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:204:17: sparse:     got restricted __be32 [noderef] __iomem *
   arch/powerpc/sysdev/fsl_rcpm.c:204:17: sparse: sparse: incorrect type in argument 1 (different base types) @@     expected unsigned int const volatile [noderef] [usertype] __iomem *addr @@     got restricted __be32 [noderef] __iomem * @@
   arch/powerpc/sysdev/fsl_rcpm.c:204:17: sparse:     expected unsigned int const volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:204:17: sparse:     got restricted __be32 [noderef] __iomem *
>> arch/powerpc/sysdev/fsl_rcpm.c:219:27: sparse: sparse: incorrect type in initializer (different base types) @@     expected unsigned int [usertype] *pmcsr_reg @@     got restricted __be32 [noderef] __iomem * @@
   arch/powerpc/sysdev/fsl_rcpm.c:219:27: sparse:     expected unsigned int [usertype] *pmcsr_reg
   arch/powerpc/sysdev/fsl_rcpm.c:219:27: sparse:     got restricted __be32 [noderef] __iomem *
>> arch/powerpc/sysdev/fsl_rcpm.c:225:17: sparse: sparse: incorrect type in argument 1 (different address spaces) @@     expected unsigned int volatile [noderef] [usertype] __iomem *addr @@     got unsigned int [usertype] *pmcsr_reg @@
   arch/powerpc/sysdev/fsl_rcpm.c:225:17: sparse:     expected unsigned int volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:225:17: sparse:     got unsigned int [usertype] *pmcsr_reg
>> arch/powerpc/sysdev/fsl_rcpm.c:225:17: sparse: sparse: incorrect type in argument 1 (different address spaces) @@     expected unsigned int const volatile [noderef] [usertype] __iomem *addr @@     got unsigned int [usertype] *pmcsr_reg @@
   arch/powerpc/sysdev/fsl_rcpm.c:225:17: sparse:     expected unsigned int const volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:225:17: sparse:     got unsigned int [usertype] *pmcsr_reg
   arch/powerpc/sysdev/fsl_rcpm.c:228:26: sparse: sparse: incorrect type in argument 1 (different address spaces) @@     expected unsigned int const volatile [noderef] [usertype] __iomem *addr @@     got unsigned int [usertype] *pmcsr_reg @@
   arch/powerpc/sysdev/fsl_rcpm.c:228:26: sparse:     expected unsigned int const volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:228:26: sparse:     got unsigned int [usertype] *pmcsr_reg
   arch/powerpc/sysdev/fsl_rcpm.c:228:26: sparse: sparse: incorrect type in argument 1 (different address spaces) @@     expected unsigned int const volatile [noderef] [usertype] __iomem *addr @@     got unsigned int [usertype] *pmcsr_reg @@
   arch/powerpc/sysdev/fsl_rcpm.c:228:26: sparse:     expected unsigned int const volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:228:26: sparse:     got unsigned int [usertype] *pmcsr_reg
   arch/powerpc/sysdev/fsl_rcpm.c:228:26: sparse: sparse: incorrect type in argument 1 (different address spaces) @@     expected unsigned int const volatile [noderef] [usertype] __iomem *addr @@     got unsigned int [usertype] *pmcsr_reg @@
   arch/powerpc/sysdev/fsl_rcpm.c:228:26: sparse:     expected unsigned int const volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:228:26: sparse:     got unsigned int [usertype] *pmcsr_reg
   arch/powerpc/sysdev/fsl_rcpm.c:228:26: sparse: sparse: incorrect type in argument 1 (different address spaces) @@     expected unsigned int const volatile [noderef] [usertype] __iomem *addr @@     got unsigned int [usertype] *pmcsr_reg @@
   arch/powerpc/sysdev/fsl_rcpm.c:228:26: sparse:     expected unsigned int const volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:228:26: sparse:     got unsigned int [usertype] *pmcsr_reg
   arch/powerpc/sysdev/fsl_rcpm.c:245:27: sparse: sparse: incorrect type in initializer (different base types) @@     expected unsigned int [usertype] *pmcsr_reg @@     got restricted __be32 [noderef] __iomem * @@
   arch/powerpc/sysdev/fsl_rcpm.c:245:27: sparse:     expected unsigned int [usertype] *pmcsr_reg
   arch/powerpc/sysdev/fsl_rcpm.c:245:27: sparse:     got restricted __be32 [noderef] __iomem *
   arch/powerpc/sysdev/fsl_rcpm.c:252:17: sparse: sparse: incorrect type in argument 1 (different address spaces) @@     expected unsigned int volatile [noderef] [usertype] __iomem *addr @@     got unsigned int [usertype] *pmcsr_reg @@
   arch/powerpc/sysdev/fsl_rcpm.c:252:17: sparse:     expected unsigned int volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:252:17: sparse:     got unsigned int [usertype] *pmcsr_reg
   arch/powerpc/sysdev/fsl_rcpm.c:252:17: sparse: sparse: incorrect type in argument 1 (different address spaces) @@     expected unsigned int const volatile [noderef] [usertype] __iomem *addr @@     got unsigned int [usertype] *pmcsr_reg @@
   arch/powerpc/sysdev/fsl_rcpm.c:252:17: sparse:     expected unsigned int const volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:252:17: sparse:     got unsigned int [usertype] *pmcsr_reg
   arch/powerpc/sysdev/fsl_rcpm.c:254:17: sparse: sparse: incorrect type in argument 1 (different address spaces) @@     expected unsigned int volatile [noderef] [usertype] __iomem *addr @@     got unsigned int [usertype] *pmcsr_reg @@
   arch/powerpc/sysdev/fsl_rcpm.c:254:17: sparse:     expected unsigned int volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:254:17: sparse:     got unsigned int [usertype] *pmcsr_reg
   arch/powerpc/sysdev/fsl_rcpm.c:254:17: sparse: sparse: incorrect type in argument 1 (different address spaces) @@     expected unsigned int const volatile [noderef] [usertype] __iomem *addr @@     got unsigned int [usertype] *pmcsr_reg @@
   arch/powerpc/sysdev/fsl_rcpm.c:254:17: sparse:     expected unsigned int const volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:254:17: sparse:     got unsigned int [usertype] *pmcsr_reg
   arch/powerpc/sysdev/fsl_rcpm.c:259:26: sparse: sparse: incorrect type in argument 1 (different address spaces) @@     expected unsigned int const volatile [noderef] [usertype] __iomem *addr @@     got unsigned int [usertype] *pmcsr_reg @@
   arch/powerpc/sysdev/fsl_rcpm.c:259:26: sparse:     expected unsigned int const volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:259:26: sparse:     got unsigned int [usertype] *pmcsr_reg
   arch/powerpc/sysdev/fsl_rcpm.c:259:26: sparse: sparse: incorrect type in argument 1 (different address spaces) @@     expected unsigned int const volatile [noderef] [usertype] __iomem *addr @@     got unsigned int [usertype] *pmcsr_reg @@
   arch/powerpc/sysdev/fsl_rcpm.c:259:26: sparse:     expected unsigned int const volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:259:26: sparse:     got unsigned int [usertype] *pmcsr_reg
   arch/powerpc/sysdev/fsl_rcpm.c:259:26: sparse: sparse: incorrect type in argument 1 (different address spaces) @@     expected unsigned int const volatile [noderef] [usertype] __iomem *addr @@     got unsigned int [usertype] *pmcsr_reg @@
   arch/powerpc/sysdev/fsl_rcpm.c:259:26: sparse:     expected unsigned int const volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:259:26: sparse:     got unsigned int [usertype] *pmcsr_reg
   arch/powerpc/sysdev/fsl_rcpm.c:259:26: sparse: sparse: incorrect type in argument 1 (different address spaces) @@     expected unsigned int const volatile [noderef] [usertype] __iomem *addr @@     got unsigned int [usertype] *pmcsr_reg @@
   arch/powerpc/sysdev/fsl_rcpm.c:259:26: sparse:     expected unsigned int const volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:259:26: sparse:     got unsigned int [usertype] *pmcsr_reg
>> arch/powerpc/sysdev/fsl_rcpm.c:289:32: sparse: sparse: incorrect type in argument 1 (different address spaces) @@     expected unsigned int const volatile [noderef] [usertype] __iomem *addr @@     got unsigned int [usertype] *tben_reg @@
   arch/powerpc/sysdev/fsl_rcpm.c:289:32: sparse:     expected unsigned int const volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:289:32: sparse:     got unsigned int [usertype] *tben_reg
>> arch/powerpc/sysdev/fsl_rcpm.c:290:17: sparse: sparse: incorrect type in argument 1 (different address spaces) @@     expected unsigned int volatile [noderef] [usertype] __iomem *addr @@     got unsigned int [usertype] *tben_reg @@
   arch/powerpc/sysdev/fsl_rcpm.c:290:17: sparse:     expected unsigned int volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:290:17: sparse:     got unsigned int [usertype] *tben_reg
   arch/powerpc/sysdev/fsl_rcpm.c:290:17: sparse: sparse: incorrect type in argument 1 (different address spaces) @@     expected unsigned int const volatile [noderef] [usertype] __iomem *addr @@     got unsigned int [usertype] *tben_reg @@
   arch/powerpc/sysdev/fsl_rcpm.c:290:17: sparse:     expected unsigned int const volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:290:17: sparse:     got unsigned int [usertype] *tben_reg
   arch/powerpc/sysdev/fsl_rcpm.c:292:17: sparse: sparse: incorrect type in argument 1 (different address spaces) @@     expected unsigned int volatile [noderef] [usertype] __iomem *addr @@     got unsigned int [usertype] *tben_reg @@
   arch/powerpc/sysdev/fsl_rcpm.c:292:17: sparse:     expected unsigned int volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:292:17: sparse:     got unsigned int [usertype] *tben_reg
   arch/powerpc/sysdev/fsl_rcpm.c:292:17: sparse: sparse: incorrect type in argument 1 (different address spaces) @@     expected unsigned int const volatile [noderef] [usertype] __iomem *addr @@     got unsigned int [usertype] *tben_reg @@
   arch/powerpc/sysdev/fsl_rcpm.c:292:17: sparse:     expected unsigned int const volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:292:17: sparse:     got unsigned int [usertype] *tben_reg
   arch/powerpc/sysdev/fsl_rcpm.c:296:17: sparse: sparse: incorrect type in argument 1 (different address spaces) @@     expected unsigned int const volatile [noderef] [usertype] __iomem *addr @@     got unsigned int [usertype] *tben_reg @@
   arch/powerpc/sysdev/fsl_rcpm.c:296:17: sparse:     expected unsigned int const volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/sysdev/fsl_rcpm.c:296:17: sparse:     got unsigned int [usertype] *tben_reg
>> arch/powerpc/sysdev/fsl_rcpm.c:301:39: sparse: sparse: incorrect type in argument 1 (different base types) @@     expected unsigned int [usertype] *tben_reg @@     got restricted __be32 [noderef] __iomem * @@
   arch/powerpc/sysdev/fsl_rcpm.c:301:39: sparse:     expected unsigned int [usertype] *tben_reg
   arch/powerpc/sysdev/fsl_rcpm.c:301:39: sparse:     got restricted __be32 [noderef] __iomem *
   arch/powerpc/sysdev/fsl_rcpm.c:306:39: sparse: sparse: incorrect type in argument 1 (different base types) @@     expected unsigned int [usertype] *tben_reg @@     got restricted __be32 [noderef] __iomem * @@
   arch/powerpc/sysdev/fsl_rcpm.c:306:39: sparse:     expected unsigned int [usertype] *tben_reg
   arch/powerpc/sysdev/fsl_rcpm.c:306:39: sparse:     got restricted __be32 [noderef] __iomem *
--
>> arch/powerpc/platforms/85xx/smp.c:218:28: sparse: sparse: incorrect type in assignment (different address spaces) @@     expected struct epapr_spin_table [noderef] __iomem *[assigned] spin_table @@     got void * @@
>> arch/powerpc/platforms/85xx/smp.c:218:28: sparse:     expected struct epapr_spin_table [noderef] __iomem *[assigned] spin_table
   arch/powerpc/platforms/85xx/smp.c:218:28: sparse:     got void *
>> arch/powerpc/platforms/85xx/smp.c:227:36: sparse: sparse: incorrect type in argument 1 (different address spaces) @@     expected void *spin_table @@     got struct epapr_spin_table [noderef] __iomem *[assigned] spin_table @@
   arch/powerpc/platforms/85xx/smp.c:227:36: sparse:     expected void *spin_table
>> arch/powerpc/platforms/85xx/smp.c:227:36: sparse:     got struct epapr_spin_table [noderef] __iomem *[assigned] spin_table
   arch/powerpc/platforms/85xx/smp.c:239:22: sparse: sparse: incorrect type in argument 1 (different address spaces) @@     expected void *spin_table @@     got struct epapr_spin_table [noderef] __iomem *[assigned] spin_table @@
   arch/powerpc/platforms/85xx/smp.c:239:22: sparse:     expected void *spin_table
   arch/powerpc/platforms/85xx/smp.c:239:22: sparse:     got struct epapr_spin_table [noderef] __iomem *[assigned] spin_table
   arch/powerpc/platforms/85xx/smp.c:239:22: sparse: sparse: incorrect type in argument 1 (different address spaces) @@     expected void *spin_table @@     got struct epapr_spin_table [noderef] __iomem *[assigned] spin_table @@
   arch/powerpc/platforms/85xx/smp.c:239:22: sparse:     expected void *spin_table
   arch/powerpc/platforms/85xx/smp.c:239:22: sparse:     got struct epapr_spin_table [noderef] __iomem *[assigned] spin_table
   arch/powerpc/platforms/85xx/smp.c:239:22: sparse: sparse: incorrect type in argument 1 (different address spaces) @@     expected void *spin_table @@     got struct epapr_spin_table [noderef] __iomem *[assigned] spin_table @@
   arch/powerpc/platforms/85xx/smp.c:239:22: sparse:     expected void *spin_table
   arch/powerpc/platforms/85xx/smp.c:239:22: sparse:     got struct epapr_spin_table [noderef] __iomem *[assigned] spin_table
   arch/powerpc/platforms/85xx/smp.c:239:22: sparse: sparse: incorrect type in argument 1 (different address spaces) @@     expected void *spin_table @@     got struct epapr_spin_table [noderef] __iomem *[assigned] spin_table @@
   arch/powerpc/platforms/85xx/smp.c:239:22: sparse:     expected void *spin_table
   arch/powerpc/platforms/85xx/smp.c:239:22: sparse:     got struct epapr_spin_table [noderef] __iomem *[assigned] spin_table
   arch/powerpc/platforms/85xx/smp.c:249:26: sparse: sparse: incorrect type in argument 1 (different address spaces) @@     expected void *spin_table @@     got struct epapr_spin_table [noderef] __iomem *[assigned] spin_table @@
   arch/powerpc/platforms/85xx/smp.c:249:26: sparse:     expected void *spin_table
   arch/powerpc/platforms/85xx/smp.c:249:26: sparse:     got struct epapr_spin_table [noderef] __iomem *[assigned] spin_table
>> arch/powerpc/platforms/85xx/smp.c:252:19: sparse: sparse: cast removes address space '__iomem' of expression
>> arch/powerpc/platforms/85xx/smp.c:252:19: sparse: sparse: incorrect type in argument 1 (different address spaces) @@     expected unsigned long long volatile [noderef] [usertype] __iomem *addr @@     got unsigned long long [usertype] * @@
>> arch/powerpc/platforms/85xx/smp.c:252:19: sparse:     expected unsigned long long volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/platforms/85xx/smp.c:252:19: sparse:     got unsigned long long [usertype] *
   arch/powerpc/platforms/85xx/smp.c:266:26: sparse: sparse: incorrect type in argument 1 (different address spaces) @@     expected void *spin_table @@     got struct epapr_spin_table [noderef] __iomem *[assigned] spin_table @@
   arch/powerpc/platforms/85xx/smp.c:266:26: sparse:     expected void *spin_table
   arch/powerpc/platforms/85xx/smp.c:266:26: sparse:     got struct epapr_spin_table [noderef] __iomem *[assigned] spin_table
   arch/powerpc/platforms/85xx/smp.c:387:6: sparse: sparse: symbol 'mpc85xx_smp_kexec_cpu_down' was not declared. Should it be static?
>> arch/powerpc/platforms/85xx/smp.c:173:27: sparse: sparse: incorrect type in argument 1 (different address spaces) @@     expected unsigned int const volatile [noderef] [usertype] __iomem *addr @@     got unsigned int * @@
>> arch/powerpc/platforms/85xx/smp.c:173:27: sparse:     expected unsigned int const volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/platforms/85xx/smp.c:173:27: sparse:     got unsigned int *
>> arch/powerpc/platforms/85xx/smp.c:173:27: sparse: sparse: incorrect type in argument 1 (different address spaces) @@     expected unsigned int const volatile [noderef] [usertype] __iomem *addr @@     got unsigned int * @@
>> arch/powerpc/platforms/85xx/smp.c:173:27: sparse:     expected unsigned int const volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/platforms/85xx/smp.c:173:27: sparse:     got unsigned int *
>> arch/powerpc/platforms/85xx/smp.c:173:27: sparse: sparse: incorrect type in argument 1 (different address spaces) @@     expected unsigned int const volatile [noderef] [usertype] __iomem *addr @@     got unsigned int * @@
>> arch/powerpc/platforms/85xx/smp.c:173:27: sparse:     expected unsigned int const volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/platforms/85xx/smp.c:173:27: sparse:     got unsigned int *
>> arch/powerpc/platforms/85xx/smp.c:173:27: sparse: sparse: incorrect type in argument 1 (different address spaces) @@     expected unsigned int const volatile [noderef] [usertype] __iomem *addr @@     got unsigned int * @@
>> arch/powerpc/platforms/85xx/smp.c:173:27: sparse:     expected unsigned int const volatile [noderef] [usertype] __iomem *addr
   arch/powerpc/platforms/85xx/smp.c:173:27: sparse:     got unsigned int *
--
   drivers/usb/host/ehci-hcd.c: note: in included file:
   drivers/usb/host/ehci-q.c:1389:27: sparse: sparse: incorrect type in assignment (different base types) @@     expected restricted __le32 [usertype] old_current @@     got int @@
   drivers/usb/host/ehci-q.c:1389:27: sparse:     expected restricted __le32 [usertype] old_current
   drivers/usb/host/ehci-q.c:1389:27: sparse:     got int
   drivers/usb/host/ehci-hcd.c:566:27: sparse: sparse: incorrect type in assignment (different base types) @@     expected restricted __le32 [usertype] old_current @@     got int @@
   drivers/usb/host/ehci-hcd.c:566:27: sparse:     expected restricted __le32 [usertype] old_current
   drivers/usb/host/ehci-hcd.c:566:27: sparse:     got int
   drivers/usb/host/ehci-hcd.c: note: in included file:
>> drivers/usb/host/ehci-ppc-of.c:140:47: sparse: sparse: incorrect type in assignment (different address spaces) @@     expected restricted __le32 [usertype] *ohci_hcctrl_reg @@     got void [noderef] __iomem * @@
   drivers/usb/host/ehci-ppc-of.c:140:47: sparse:     expected restricted __le32 [usertype] *ohci_hcctrl_reg
   drivers/usb/host/ehci-ppc-of.c:140:47: sparse:     got void [noderef] __iomem *

vim +32 arch/powerpc/sysdev/fsl_rcpm.c

d17799f9c10e283 chenhui zhao 2015-11-20   26  
d17799f9c10e283 chenhui zhao 2015-11-20   27  static void rcpm_v1_irq_mask(int cpu)
d17799f9c10e283 chenhui zhao 2015-11-20   28  {
d17799f9c10e283 chenhui zhao 2015-11-20   29  	int hw_cpu = get_hard_smp_processor_id(cpu);
d17799f9c10e283 chenhui zhao 2015-11-20   30  	unsigned int mask = 1 << hw_cpu;
d17799f9c10e283 chenhui zhao 2015-11-20   31  
d17799f9c10e283 chenhui zhao 2015-11-20  @32  	setbits32(&rcpm_v1_regs->cpmimr, mask);
d17799f9c10e283 chenhui zhao 2015-11-20   33  	setbits32(&rcpm_v1_regs->cpmcimr, mask);
d17799f9c10e283 chenhui zhao 2015-11-20   34  	setbits32(&rcpm_v1_regs->cpmmcmr, mask);
d17799f9c10e283 chenhui zhao 2015-11-20   35  	setbits32(&rcpm_v1_regs->cpmnmimr, mask);
d17799f9c10e283 chenhui zhao 2015-11-20   36  }
d17799f9c10e283 chenhui zhao 2015-11-20   37  
d17799f9c10e283 chenhui zhao 2015-11-20   38  static void rcpm_v2_irq_mask(int cpu)
d17799f9c10e283 chenhui zhao 2015-11-20   39  {
d17799f9c10e283 chenhui zhao 2015-11-20   40  	int hw_cpu = get_hard_smp_processor_id(cpu);
d17799f9c10e283 chenhui zhao 2015-11-20   41  	unsigned int mask = 1 << hw_cpu;
d17799f9c10e283 chenhui zhao 2015-11-20   42  
d17799f9c10e283 chenhui zhao 2015-11-20   43  	setbits32(&rcpm_v2_regs->tpmimr0, mask);
d17799f9c10e283 chenhui zhao 2015-11-20   44  	setbits32(&rcpm_v2_regs->tpmcimr0, mask);
d17799f9c10e283 chenhui zhao 2015-11-20   45  	setbits32(&rcpm_v2_regs->tpmmcmr0, mask);
d17799f9c10e283 chenhui zhao 2015-11-20   46  	setbits32(&rcpm_v2_regs->tpmnmimr0, mask);
d17799f9c10e283 chenhui zhao 2015-11-20   47  }
d17799f9c10e283 chenhui zhao 2015-11-20   48  
d17799f9c10e283 chenhui zhao 2015-11-20   49  static void rcpm_v1_irq_unmask(int cpu)
d17799f9c10e283 chenhui zhao 2015-11-20   50  {
d17799f9c10e283 chenhui zhao 2015-11-20   51  	int hw_cpu = get_hard_smp_processor_id(cpu);
d17799f9c10e283 chenhui zhao 2015-11-20   52  	unsigned int mask = 1 << hw_cpu;
d17799f9c10e283 chenhui zhao 2015-11-20   53  
d17799f9c10e283 chenhui zhao 2015-11-20   54  	clrbits32(&rcpm_v1_regs->cpmimr, mask);
d17799f9c10e283 chenhui zhao 2015-11-20   55  	clrbits32(&rcpm_v1_regs->cpmcimr, mask);
d17799f9c10e283 chenhui zhao 2015-11-20   56  	clrbits32(&rcpm_v1_regs->cpmmcmr, mask);
d17799f9c10e283 chenhui zhao 2015-11-20   57  	clrbits32(&rcpm_v1_regs->cpmnmimr, mask);
d17799f9c10e283 chenhui zhao 2015-11-20   58  }
d17799f9c10e283 chenhui zhao 2015-11-20   59  
d17799f9c10e283 chenhui zhao 2015-11-20   60  static void rcpm_v2_irq_unmask(int cpu)
d17799f9c10e283 chenhui zhao 2015-11-20   61  {
d17799f9c10e283 chenhui zhao 2015-11-20   62  	int hw_cpu = get_hard_smp_processor_id(cpu);
d17799f9c10e283 chenhui zhao 2015-11-20   63  	unsigned int mask = 1 << hw_cpu;
d17799f9c10e283 chenhui zhao 2015-11-20   64  
d17799f9c10e283 chenhui zhao 2015-11-20   65  	clrbits32(&rcpm_v2_regs->tpmimr0, mask);
d17799f9c10e283 chenhui zhao 2015-11-20   66  	clrbits32(&rcpm_v2_regs->tpmcimr0, mask);
d17799f9c10e283 chenhui zhao 2015-11-20   67  	clrbits32(&rcpm_v2_regs->tpmmcmr0, mask);
d17799f9c10e283 chenhui zhao 2015-11-20   68  	clrbits32(&rcpm_v2_regs->tpmnmimr0, mask);
d17799f9c10e283 chenhui zhao 2015-11-20   69  }
d17799f9c10e283 chenhui zhao 2015-11-20   70  
d17799f9c10e283 chenhui zhao 2015-11-20   71  static void rcpm_v1_set_ip_power(bool enable, u32 mask)
d17799f9c10e283 chenhui zhao 2015-11-20   72  {
d17799f9c10e283 chenhui zhao 2015-11-20   73  	if (enable)
d17799f9c10e283 chenhui zhao 2015-11-20   74  		setbits32(&rcpm_v1_regs->ippdexpcr, mask);
d17799f9c10e283 chenhui zhao 2015-11-20   75  	else
d17799f9c10e283 chenhui zhao 2015-11-20   76  		clrbits32(&rcpm_v1_regs->ippdexpcr, mask);
d17799f9c10e283 chenhui zhao 2015-11-20   77  }
d17799f9c10e283 chenhui zhao 2015-11-20   78  
d17799f9c10e283 chenhui zhao 2015-11-20   79  static void rcpm_v2_set_ip_power(bool enable, u32 mask)
d17799f9c10e283 chenhui zhao 2015-11-20   80  {
d17799f9c10e283 chenhui zhao 2015-11-20   81  	if (enable)
d17799f9c10e283 chenhui zhao 2015-11-20   82  		setbits32(&rcpm_v2_regs->ippdexpcr[0], mask);
d17799f9c10e283 chenhui zhao 2015-11-20   83  	else
d17799f9c10e283 chenhui zhao 2015-11-20   84  		clrbits32(&rcpm_v2_regs->ippdexpcr[0], mask);
d17799f9c10e283 chenhui zhao 2015-11-20   85  }
d17799f9c10e283 chenhui zhao 2015-11-20   86  
d17799f9c10e283 chenhui zhao 2015-11-20   87  static void rcpm_v1_cpu_enter_state(int cpu, int state)
d17799f9c10e283 chenhui zhao 2015-11-20   88  {
d17799f9c10e283 chenhui zhao 2015-11-20   89  	int hw_cpu = get_hard_smp_processor_id(cpu);
d17799f9c10e283 chenhui zhao 2015-11-20   90  	unsigned int mask = 1 << hw_cpu;
d17799f9c10e283 chenhui zhao 2015-11-20   91  
d17799f9c10e283 chenhui zhao 2015-11-20   92  	switch (state) {
d17799f9c10e283 chenhui zhao 2015-11-20   93  	case E500_PM_PH10:
d17799f9c10e283 chenhui zhao 2015-11-20   94  		setbits32(&rcpm_v1_regs->cdozcr, mask);
d17799f9c10e283 chenhui zhao 2015-11-20   95  		break;
d17799f9c10e283 chenhui zhao 2015-11-20   96  	case E500_PM_PH15:
d17799f9c10e283 chenhui zhao 2015-11-20   97  		setbits32(&rcpm_v1_regs->cnapcr, mask);
d17799f9c10e283 chenhui zhao 2015-11-20   98  		break;
d17799f9c10e283 chenhui zhao 2015-11-20   99  	default:
d17799f9c10e283 chenhui zhao 2015-11-20  100  		pr_warn("Unknown cpu PM state (%d)\n", state);
d17799f9c10e283 chenhui zhao 2015-11-20  101  		break;
d17799f9c10e283 chenhui zhao 2015-11-20  102  	}
d17799f9c10e283 chenhui zhao 2015-11-20  103  }
d17799f9c10e283 chenhui zhao 2015-11-20  104  
d17799f9c10e283 chenhui zhao 2015-11-20  105  static void rcpm_v2_cpu_enter_state(int cpu, int state)
d17799f9c10e283 chenhui zhao 2015-11-20  106  {
d17799f9c10e283 chenhui zhao 2015-11-20  107  	int hw_cpu = get_hard_smp_processor_id(cpu);
d17799f9c10e283 chenhui zhao 2015-11-20  108  	u32 mask = 1 << cpu_core_index_of_thread(cpu);
d17799f9c10e283 chenhui zhao 2015-11-20  109  
d17799f9c10e283 chenhui zhao 2015-11-20  110  	switch (state) {
d17799f9c10e283 chenhui zhao 2015-11-20  111  	case E500_PM_PH10:
d17799f9c10e283 chenhui zhao 2015-11-20  112  		/* one bit corresponds to one thread for PH10 of 6500 */
d17799f9c10e283 chenhui zhao 2015-11-20  113  		setbits32(&rcpm_v2_regs->tph10setr0, 1 << hw_cpu);
d17799f9c10e283 chenhui zhao 2015-11-20  114  		break;
d17799f9c10e283 chenhui zhao 2015-11-20  115  	case E500_PM_PH15:
d17799f9c10e283 chenhui zhao 2015-11-20  116  		setbits32(&rcpm_v2_regs->pcph15setr, mask);
d17799f9c10e283 chenhui zhao 2015-11-20  117  		break;
d17799f9c10e283 chenhui zhao 2015-11-20  118  	case E500_PM_PH20:
d17799f9c10e283 chenhui zhao 2015-11-20  119  		setbits32(&rcpm_v2_regs->pcph20setr, mask);
d17799f9c10e283 chenhui zhao 2015-11-20  120  		break;
d17799f9c10e283 chenhui zhao 2015-11-20  121  	case E500_PM_PH30:
d17799f9c10e283 chenhui zhao 2015-11-20  122  		setbits32(&rcpm_v2_regs->pcph30setr, mask);
d17799f9c10e283 chenhui zhao 2015-11-20  123  		break;
d17799f9c10e283 chenhui zhao 2015-11-20  124  	default:
d17799f9c10e283 chenhui zhao 2015-11-20  125  		pr_warn("Unknown cpu PM state (%d)\n", state);
d17799f9c10e283 chenhui zhao 2015-11-20  126  	}
d17799f9c10e283 chenhui zhao 2015-11-20  127  }
d17799f9c10e283 chenhui zhao 2015-11-20  128  
d17799f9c10e283 chenhui zhao 2015-11-20  129  static void rcpm_v1_cpu_die(int cpu)
d17799f9c10e283 chenhui zhao 2015-11-20  130  {
d17799f9c10e283 chenhui zhao 2015-11-20  131  	rcpm_v1_cpu_enter_state(cpu, E500_PM_PH15);
d17799f9c10e283 chenhui zhao 2015-11-20  132  }
d17799f9c10e283 chenhui zhao 2015-11-20  133  
d17799f9c10e283 chenhui zhao 2015-11-20  134  #ifdef CONFIG_PPC64
d17799f9c10e283 chenhui zhao 2015-11-20  135  static void qoriq_disable_thread(int cpu)
d17799f9c10e283 chenhui zhao 2015-11-20  136  {
d17799f9c10e283 chenhui zhao 2015-11-20  137  	int thread = cpu_thread_in_core(cpu);
d17799f9c10e283 chenhui zhao 2015-11-20  138  
d17799f9c10e283 chenhui zhao 2015-11-20  139  	book3e_stop_thread(thread);
d17799f9c10e283 chenhui zhao 2015-11-20  140  }
d17799f9c10e283 chenhui zhao 2015-11-20  141  #endif
d17799f9c10e283 chenhui zhao 2015-11-20  142  
d17799f9c10e283 chenhui zhao 2015-11-20  143  static void rcpm_v2_cpu_die(int cpu)
d17799f9c10e283 chenhui zhao 2015-11-20  144  {
d17799f9c10e283 chenhui zhao 2015-11-20  145  #ifdef CONFIG_PPC64
d17799f9c10e283 chenhui zhao 2015-11-20  146  	int primary;
d17799f9c10e283 chenhui zhao 2015-11-20  147  
d17799f9c10e283 chenhui zhao 2015-11-20  148  	if (threads_per_core == 2) {
d17799f9c10e283 chenhui zhao 2015-11-20  149  		primary = cpu_first_thread_sibling(cpu);
d17799f9c10e283 chenhui zhao 2015-11-20  150  		if (cpu_is_offline(primary) && cpu_is_offline(primary + 1)) {
d17799f9c10e283 chenhui zhao 2015-11-20  151  			/* if both threads are offline, put the cpu in PH20 */
d17799f9c10e283 chenhui zhao 2015-11-20  152  			rcpm_v2_cpu_enter_state(cpu, E500_PM_PH20);
d17799f9c10e283 chenhui zhao 2015-11-20  153  		} else {
d17799f9c10e283 chenhui zhao 2015-11-20  154  			/* if only one thread is offline, disable the thread */
d17799f9c10e283 chenhui zhao 2015-11-20  155  			qoriq_disable_thread(cpu);
d17799f9c10e283 chenhui zhao 2015-11-20  156  		}
d17799f9c10e283 chenhui zhao 2015-11-20  157  	}
d17799f9c10e283 chenhui zhao 2015-11-20  158  #endif
d17799f9c10e283 chenhui zhao 2015-11-20  159  
d17799f9c10e283 chenhui zhao 2015-11-20  160  	if (threads_per_core == 1)
d17799f9c10e283 chenhui zhao 2015-11-20  161  		rcpm_v2_cpu_enter_state(cpu, E500_PM_PH20);
d17799f9c10e283 chenhui zhao 2015-11-20  162  }
d17799f9c10e283 chenhui zhao 2015-11-20  163  
d17799f9c10e283 chenhui zhao 2015-11-20  164  static void rcpm_v1_cpu_exit_state(int cpu, int state)
d17799f9c10e283 chenhui zhao 2015-11-20  165  {
d17799f9c10e283 chenhui zhao 2015-11-20  166  	int hw_cpu = get_hard_smp_processor_id(cpu);
d17799f9c10e283 chenhui zhao 2015-11-20  167  	unsigned int mask = 1 << hw_cpu;
d17799f9c10e283 chenhui zhao 2015-11-20  168  
d17799f9c10e283 chenhui zhao 2015-11-20  169  	switch (state) {
d17799f9c10e283 chenhui zhao 2015-11-20  170  	case E500_PM_PH10:
d17799f9c10e283 chenhui zhao 2015-11-20  171  		clrbits32(&rcpm_v1_regs->cdozcr, mask);
d17799f9c10e283 chenhui zhao 2015-11-20  172  		break;
d17799f9c10e283 chenhui zhao 2015-11-20  173  	case E500_PM_PH15:
d17799f9c10e283 chenhui zhao 2015-11-20  174  		clrbits32(&rcpm_v1_regs->cnapcr, mask);
d17799f9c10e283 chenhui zhao 2015-11-20  175  		break;
d17799f9c10e283 chenhui zhao 2015-11-20  176  	default:
d17799f9c10e283 chenhui zhao 2015-11-20  177  		pr_warn("Unknown cpu PM state (%d)\n", state);
d17799f9c10e283 chenhui zhao 2015-11-20  178  		break;
d17799f9c10e283 chenhui zhao 2015-11-20  179  	}
d17799f9c10e283 chenhui zhao 2015-11-20  180  }
d17799f9c10e283 chenhui zhao 2015-11-20  181  
d17799f9c10e283 chenhui zhao 2015-11-20  182  static void rcpm_v1_cpu_up_prepare(int cpu)
d17799f9c10e283 chenhui zhao 2015-11-20  183  {
d17799f9c10e283 chenhui zhao 2015-11-20  184  	rcpm_v1_cpu_exit_state(cpu, E500_PM_PH15);
d17799f9c10e283 chenhui zhao 2015-11-20  185  	rcpm_v1_irq_unmask(cpu);
d17799f9c10e283 chenhui zhao 2015-11-20  186  }
d17799f9c10e283 chenhui zhao 2015-11-20  187  
d17799f9c10e283 chenhui zhao 2015-11-20  188  static void rcpm_v2_cpu_exit_state(int cpu, int state)
d17799f9c10e283 chenhui zhao 2015-11-20  189  {
d17799f9c10e283 chenhui zhao 2015-11-20  190  	int hw_cpu = get_hard_smp_processor_id(cpu);
d17799f9c10e283 chenhui zhao 2015-11-20  191  	u32 mask = 1 << cpu_core_index_of_thread(cpu);
d17799f9c10e283 chenhui zhao 2015-11-20  192  
d17799f9c10e283 chenhui zhao 2015-11-20  193  	switch (state) {
d17799f9c10e283 chenhui zhao 2015-11-20  194  	case E500_PM_PH10:
d17799f9c10e283 chenhui zhao 2015-11-20  195  		setbits32(&rcpm_v2_regs->tph10clrr0, 1 << hw_cpu);
d17799f9c10e283 chenhui zhao 2015-11-20  196  		break;
d17799f9c10e283 chenhui zhao 2015-11-20  197  	case E500_PM_PH15:
d17799f9c10e283 chenhui zhao 2015-11-20  198  		setbits32(&rcpm_v2_regs->pcph15clrr, mask);
d17799f9c10e283 chenhui zhao 2015-11-20  199  		break;
d17799f9c10e283 chenhui zhao 2015-11-20  200  	case E500_PM_PH20:
d17799f9c10e283 chenhui zhao 2015-11-20 @201  		setbits32(&rcpm_v2_regs->pcph20clrr, mask);
d17799f9c10e283 chenhui zhao 2015-11-20  202  		break;
d17799f9c10e283 chenhui zhao 2015-11-20  203  	case E500_PM_PH30:
d17799f9c10e283 chenhui zhao 2015-11-20 @204  		setbits32(&rcpm_v2_regs->pcph30clrr, mask);
d17799f9c10e283 chenhui zhao 2015-11-20  205  		break;
d17799f9c10e283 chenhui zhao 2015-11-20  206  	default:
d17799f9c10e283 chenhui zhao 2015-11-20  207  		pr_warn("Unknown cpu PM state (%d)\n", state);
d17799f9c10e283 chenhui zhao 2015-11-20  208  	}
d17799f9c10e283 chenhui zhao 2015-11-20  209  }
d17799f9c10e283 chenhui zhao 2015-11-20  210  
d17799f9c10e283 chenhui zhao 2015-11-20  211  static void rcpm_v2_cpu_up_prepare(int cpu)
d17799f9c10e283 chenhui zhao 2015-11-20  212  {
d17799f9c10e283 chenhui zhao 2015-11-20  213  	rcpm_v2_cpu_exit_state(cpu, E500_PM_PH20);
d17799f9c10e283 chenhui zhao 2015-11-20  214  	rcpm_v2_irq_unmask(cpu);
d17799f9c10e283 chenhui zhao 2015-11-20  215  }
d17799f9c10e283 chenhui zhao 2015-11-20  216  
d17799f9c10e283 chenhui zhao 2015-11-20  217  static int rcpm_v1_plat_enter_state(int state)
d17799f9c10e283 chenhui zhao 2015-11-20  218  {
d17799f9c10e283 chenhui zhao 2015-11-20 @219  	u32 *pmcsr_reg = &rcpm_v1_regs->powmgtcsr;
d17799f9c10e283 chenhui zhao 2015-11-20  220  	int ret = 0;
d17799f9c10e283 chenhui zhao 2015-11-20  221  	int result;
d17799f9c10e283 chenhui zhao 2015-11-20  222  
d17799f9c10e283 chenhui zhao 2015-11-20  223  	switch (state) {
d17799f9c10e283 chenhui zhao 2015-11-20  224  	case PLAT_PM_SLEEP:
d17799f9c10e283 chenhui zhao 2015-11-20 @225  		setbits32(pmcsr_reg, RCPM_POWMGTCSR_SLP);
d17799f9c10e283 chenhui zhao 2015-11-20  226  
d17799f9c10e283 chenhui zhao 2015-11-20  227  		/* Upon resume, wait for RCPM_POWMGTCSR_SLP bit to be clear. */
d17799f9c10e283 chenhui zhao 2015-11-20  228  		result = spin_event_timeout(
d17799f9c10e283 chenhui zhao 2015-11-20  229  		  !(in_be32(pmcsr_reg) & RCPM_POWMGTCSR_SLP), 10000, 10);
d17799f9c10e283 chenhui zhao 2015-11-20  230  		if (!result) {
d17799f9c10e283 chenhui zhao 2015-11-20  231  			pr_err("timeout waiting for SLP bit to be cleared\n");
d17799f9c10e283 chenhui zhao 2015-11-20  232  			ret = -ETIMEDOUT;
d17799f9c10e283 chenhui zhao 2015-11-20  233  		}
d17799f9c10e283 chenhui zhao 2015-11-20  234  		break;
d17799f9c10e283 chenhui zhao 2015-11-20  235  	default:
d17799f9c10e283 chenhui zhao 2015-11-20  236  		pr_warn("Unknown platform PM state (%d)", state);
d17799f9c10e283 chenhui zhao 2015-11-20  237  		ret = -EINVAL;
d17799f9c10e283 chenhui zhao 2015-11-20  238  	}
d17799f9c10e283 chenhui zhao 2015-11-20  239  
d17799f9c10e283 chenhui zhao 2015-11-20  240  	return ret;
d17799f9c10e283 chenhui zhao 2015-11-20  241  }
d17799f9c10e283 chenhui zhao 2015-11-20  242  

:::::: The code at line 32 was first introduced by commit
:::::: d17799f9c10e283cccd4d598d3416e6fac336ab9 powerpc/rcpm: add RCPM driver

:::::: TO: chenhui zhao <chenhui.zhao@...escale.com>
:::::: CC: Scott Wood <oss@...error.net>

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

Download attachment ".config.gz" of type "application/gzip" (28829 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ