arch/mips/sgi-ip22/ip22-mc.c:80:18: sparse: sparse: cast removes address space '__iomem' of expression

From: kernel test robot
Date: Tue Aug 11 2020 - 06:10:16 EST


tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: 00e4db51259a5f936fec1424b884f029479d3981
commit: 670d0a4b10704667765f7d18f7592993d02783aa sparse: use identifiers to define address spaces
date: 8 weeks ago
config: mips-randconfig-s032-20200811 (attached as .config)
compiler: mips64-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-168-g9554805c-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=mips

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


sparse warnings: (new ones prefixed by >>)

>> arch/mips/sgi-ip22/ip22-mc.c:80:18: sparse: sparse: cast removes address space '__iomem' of expression
--
>> arch/mips/sgi-ip22/ip22-hpc.c:35:19: sparse: sparse: cast removes address space '__iomem' of expression
arch/mips/sgi-ip22/ip22-hpc.c:37:19: sparse: sparse: cast removes address space '__iomem' of expression
--
>> arch/mips/sgi-ip22/ip22-time.c:48:64: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] __iomem *mem @@ got unsigned char volatile * @@
>> arch/mips/sgi-ip22/ip22-time.c:48:64: sparse: expected void volatile [noderef] __iomem *mem
arch/mips/sgi-ip22/ip22-time.c:48:64: sparse: got unsigned char volatile *
>> arch/mips/sgi-ip22/ip22-time.c:49:31: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] __iomem *mem @@ got unsigned char volatile * @@
>> arch/mips/sgi-ip22/ip22-time.c:49:31: sparse: expected void const volatile [noderef] __iomem *mem
arch/mips/sgi-ip22/ip22-time.c:49:31: sparse: got unsigned char volatile *
arch/mips/sgi-ip22/ip22-time.c:50:30: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] __iomem *mem @@ got unsigned char volatile * @@
arch/mips/sgi-ip22/ip22-time.c:50:30: sparse: expected void const volatile [noderef] __iomem *mem
arch/mips/sgi-ip22/ip22-time.c:50:30: sparse: got unsigned char volatile *
arch/mips/sgi-ip22/ip22-time.c:56:17: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] __iomem *mem @@ got unsigned char volatile * @@
arch/mips/sgi-ip22/ip22-time.c:56:17: sparse: expected void volatile [noderef] __iomem *mem
arch/mips/sgi-ip22/ip22-time.c:56:17: sparse: got unsigned char volatile *
--
>> arch/mips/sgi-ip22/ip22-nvram.c:82:34: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] __iomem *mem @@ got unsigned int *ctrl @@
>> arch/mips/sgi-ip22/ip22-nvram.c:82:34: sparse: expected void const volatile [noderef] __iomem *mem
arch/mips/sgi-ip22/ip22-nvram.c:82:34: sparse: got unsigned int *ctrl
>> arch/mips/sgi-ip22/ip22-nvram.c:82:57: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] __iomem *mem @@ got unsigned int *ctrl @@
>> arch/mips/sgi-ip22/ip22-nvram.c:82:57: sparse: expected void volatile [noderef] __iomem *mem
arch/mips/sgi-ip22/ip22-nvram.c:82:57: sparse: got unsigned int *ctrl
arch/mips/sgi-ip22/ip22-nvram.c:83:9: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] __iomem *mem @@ got unsigned int *ctrl @@
arch/mips/sgi-ip22/ip22-nvram.c:83:9: sparse: expected void const volatile [noderef] __iomem *mem
arch/mips/sgi-ip22/ip22-nvram.c:83:9: sparse: got unsigned int *ctrl
arch/mips/sgi-ip22/ip22-nvram.c:83:9: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] __iomem *mem @@ got unsigned int *ctrl @@
arch/mips/sgi-ip22/ip22-nvram.c:83:9: sparse: expected void volatile [noderef] __iomem *mem
arch/mips/sgi-ip22/ip22-nvram.c:83:9: sparse: got unsigned int *ctrl
arch/mips/sgi-ip22/ip22-nvram.c:83:9: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] __iomem *mem @@ got unsigned int *ctrl @@
arch/mips/sgi-ip22/ip22-nvram.c:83:9: sparse: expected void const volatile [noderef] __iomem *mem
arch/mips/sgi-ip22/ip22-nvram.c:83:9: sparse: got unsigned int *ctrl
arch/mips/sgi-ip22/ip22-nvram.c:83:9: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] __iomem *mem @@ got unsigned int *ctrl @@
arch/mips/sgi-ip22/ip22-nvram.c:83:9: sparse: expected void volatile [noderef] __iomem *mem
arch/mips/sgi-ip22/ip22-nvram.c:83:9: sparse: got unsigned int *ctrl
arch/mips/sgi-ip22/ip22-nvram.c:83:9: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] __iomem *mem @@ got unsigned int *ctrl @@
arch/mips/sgi-ip22/ip22-nvram.c:83:9: sparse: expected void const volatile [noderef] __iomem *mem
arch/mips/sgi-ip22/ip22-nvram.c:83:9: sparse: got unsigned int *ctrl
arch/mips/sgi-ip22/ip22-nvram.c:83:9: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] __iomem *mem @@ got unsigned int *ctrl @@
arch/mips/sgi-ip22/ip22-nvram.c:83:9: sparse: expected void volatile [noderef] __iomem *mem
arch/mips/sgi-ip22/ip22-nvram.c:83:9: sparse: got unsigned int *ctrl
arch/mips/sgi-ip22/ip22-nvram.c:83:9: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] __iomem *mem @@ got unsigned int *ctrl @@
arch/mips/sgi-ip22/ip22-nvram.c:83:9: sparse: expected void const volatile [noderef] __iomem *mem
arch/mips/sgi-ip22/ip22-nvram.c:83:9: sparse: got unsigned int *ctrl
arch/mips/sgi-ip22/ip22-nvram.c:83:9: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] __iomem *mem @@ got unsigned int *ctrl @@
arch/mips/sgi-ip22/ip22-nvram.c:83:9: sparse: expected void volatile [noderef] __iomem *mem
arch/mips/sgi-ip22/ip22-nvram.c:83:9: sparse: got unsigned int *ctrl
arch/mips/sgi-ip22/ip22-nvram.c:83:9: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] __iomem *mem @@ got unsigned int *ctrl @@
arch/mips/sgi-ip22/ip22-nvram.c:83:9: sparse: expected void const volatile [noderef] __iomem *mem
arch/mips/sgi-ip22/ip22-nvram.c:83:9: sparse: got unsigned int *ctrl
arch/mips/sgi-ip22/ip22-nvram.c:83:9: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] __iomem *mem @@ got unsigned int *ctrl @@
arch/mips/sgi-ip22/ip22-nvram.c:83:9: sparse: expected void volatile [noderef] __iomem *mem
arch/mips/sgi-ip22/ip22-nvram.c:83:9: sparse: got unsigned int *ctrl
arch/mips/sgi-ip22/ip22-nvram.c:88:42: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] __iomem *mem @@ got unsigned int *ctrl @@
arch/mips/sgi-ip22/ip22-nvram.c:88:42: sparse: expected void const volatile [noderef] __iomem *mem
arch/mips/sgi-ip22/ip22-nvram.c:88:42: sparse: got unsigned int *ctrl
arch/mips/sgi-ip22/ip22-nvram.c:88:64: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] __iomem *mem @@ got unsigned int *ctrl @@
arch/mips/sgi-ip22/ip22-nvram.c:88:64: sparse: expected void volatile [noderef] __iomem *mem
arch/mips/sgi-ip22/ip22-nvram.c:88:64: sparse: got unsigned int *ctrl
arch/mips/sgi-ip22/ip22-nvram.c:90:42: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] __iomem *mem @@ got unsigned int *ctrl @@
arch/mips/sgi-ip22/ip22-nvram.c:90:42: sparse: expected void const volatile [noderef] __iomem *mem
arch/mips/sgi-ip22/ip22-nvram.c:90:42: sparse: got unsigned int *ctrl
arch/mips/sgi-ip22/ip22-nvram.c:90:63: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] __iomem *mem @@ got unsigned int *ctrl @@
arch/mips/sgi-ip22/ip22-nvram.c:90:63: sparse: expected void volatile [noderef] __iomem *mem
arch/mips/sgi-ip22/ip22-nvram.c:90:63: sparse: got unsigned int *ctrl
arch/mips/sgi-ip22/ip22-nvram.c:93:33: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] __iomem *mem @@ got unsigned int *ctrl @@
arch/mips/sgi-ip22/ip22-nvram.c:93:33: sparse: expected void const volatile [noderef] __iomem *mem
arch/mips/sgi-ip22/ip22-nvram.c:93:33: sparse: got unsigned int *ctrl
arch/mips/sgi-ip22/ip22-nvram.c:97:9: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] __iomem *mem @@ got unsigned int *ctrl @@
arch/mips/sgi-ip22/ip22-nvram.c:97:9: sparse: expected void const volatile [noderef] __iomem *mem
arch/mips/sgi-ip22/ip22-nvram.c:97:9: sparse: got unsigned int *ctrl
arch/mips/sgi-ip22/ip22-nvram.c:97:9: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] __iomem *mem @@ got unsigned int *ctrl @@
arch/mips/sgi-ip22/ip22-nvram.c:97:9: sparse: expected void volatile [noderef] __iomem *mem
arch/mips/sgi-ip22/ip22-nvram.c:97:9: sparse: got unsigned int *ctrl
arch/mips/sgi-ip22/ip22-nvram.c:97:9: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] __iomem *mem @@ got unsigned int *ctrl @@
arch/mips/sgi-ip22/ip22-nvram.c:97:9: sparse: expected void const volatile [noderef] __iomem *mem
arch/mips/sgi-ip22/ip22-nvram.c:97:9: sparse: got unsigned int *ctrl
arch/mips/sgi-ip22/ip22-nvram.c:97:9: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] __iomem *mem @@ got unsigned int *ctrl @@
arch/mips/sgi-ip22/ip22-nvram.c:97:9: sparse: expected void volatile [noderef] __iomem *mem
arch/mips/sgi-ip22/ip22-nvram.c:97:9: sparse: got unsigned int *ctrl
arch/mips/sgi-ip22/ip22-nvram.c:97:9: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] __iomem *mem @@ got unsigned int *ctrl @@
arch/mips/sgi-ip22/ip22-nvram.c:97:9: sparse: expected void const volatile [noderef] __iomem *mem
arch/mips/sgi-ip22/ip22-nvram.c:97:9: sparse: got unsigned int *ctrl
arch/mips/sgi-ip22/ip22-nvram.c:97:9: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] __iomem *mem @@ got unsigned int *ctrl @@
arch/mips/sgi-ip22/ip22-nvram.c:97:9: sparse: expected void volatile [noderef] __iomem *mem
arch/mips/sgi-ip22/ip22-nvram.c:97:9: sparse: got unsigned int *ctrl
arch/mips/sgi-ip22/ip22-nvram.c:97:9: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] __iomem *mem @@ got unsigned int *ctrl @@
arch/mips/sgi-ip22/ip22-nvram.c:97:9: sparse: expected void const volatile [noderef] __iomem *mem
arch/mips/sgi-ip22/ip22-nvram.c:97:9: sparse: got unsigned int *ctrl
arch/mips/sgi-ip22/ip22-nvram.c:97:9: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] __iomem *mem @@ got unsigned int *ctrl @@
arch/mips/sgi-ip22/ip22-nvram.c:97:9: sparse: expected void volatile [noderef] __iomem *mem
arch/mips/sgi-ip22/ip22-nvram.c:97:9: sparse: got unsigned int *ctrl
arch/mips/sgi-ip22/ip22-nvram.c:64:50: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] __iomem *mem @@ got unsigned int *ctrl @@
arch/mips/sgi-ip22/ip22-nvram.c:64:50: sparse: expected void const volatile [noderef] __iomem *mem
arch/mips/sgi-ip22/ip22-nvram.c:64:50: sparse: got unsigned int *ctrl
arch/mips/sgi-ip22/ip22-nvram.c:64:71: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] __iomem *mem @@ got unsigned int *ctrl @@
arch/mips/sgi-ip22/ip22-nvram.c:64:71: sparse: expected void volatile [noderef] __iomem *mem
arch/mips/sgi-ip22/ip22-nvram.c:64:71: sparse: got unsigned int *ctrl
arch/mips/sgi-ip22/ip22-nvram.c:66:50: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] __iomem *mem @@ got unsigned int *ctrl @@
arch/mips/sgi-ip22/ip22-nvram.c:66:50: sparse: expected void const volatile [noderef] __iomem *mem
arch/mips/sgi-ip22/ip22-nvram.c:66:50: sparse: got unsigned int *ctrl
arch/mips/sgi-ip22/ip22-nvram.c:66:72: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] __iomem *mem @@ got unsigned int *ctrl @@
arch/mips/sgi-ip22/ip22-nvram.c:66:72: sparse: expected void volatile [noderef] __iomem *mem
arch/mips/sgi-ip22/ip22-nvram.c:66:72: sparse: got unsigned int *ctrl
arch/mips/sgi-ip22/ip22-nvram.c:67:42: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] __iomem *mem @@ got unsigned int *ctrl @@
arch/mips/sgi-ip22/ip22-nvram.c:67:42: sparse: expected void const volatile [noderef] __iomem *mem
arch/mips/sgi-ip22/ip22-nvram.c:67:42: sparse: got unsigned int *ctrl
arch/mips/sgi-ip22/ip22-nvram.c:67:64: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] __iomem *mem @@ got unsigned int *ctrl @@
arch/mips/sgi-ip22/ip22-nvram.c:67:64: sparse: expected void volatile [noderef] __iomem *mem
arch/mips/sgi-ip22/ip22-nvram.c:67:64: sparse: got unsigned int *ctrl
arch/mips/sgi-ip22/ip22-nvram.c:69:42: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] __iomem *mem @@ got unsigned int *ctrl @@
arch/mips/sgi-ip22/ip22-nvram.c:69:42: sparse: expected void const volatile [noderef] __iomem *mem
arch/mips/sgi-ip22/ip22-nvram.c:69:42: sparse: got unsigned int *ctrl
arch/mips/sgi-ip22/ip22-nvram.c:69:63: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] __iomem *mem @@ got unsigned int *ctrl @@
arch/mips/sgi-ip22/ip22-nvram.c:69:63: sparse: expected void volatile [noderef] __iomem *mem
arch/mips/sgi-ip22/ip22-nvram.c:69:63: sparse: got unsigned int *ctrl
arch/mips/sgi-ip22/ip22-nvram.c:74:34: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] __iomem *mem @@ got unsigned int *ctrl @@
arch/mips/sgi-ip22/ip22-nvram.c:74:34: sparse: expected void const volatile [noderef] __iomem *mem
arch/mips/sgi-ip22/ip22-nvram.c:74:34: sparse: got unsigned int *ctrl
arch/mips/sgi-ip22/ip22-nvram.c:74:56: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] __iomem *mem @@ got unsigned int *ctrl @@
arch/mips/sgi-ip22/ip22-nvram.c:74:56: sparse: expected void volatile [noderef] __iomem *mem
arch/mips/sgi-ip22/ip22-nvram.c:74:56: sparse: got unsigned int *ctrl

vim +/__iomem +80 arch/mips/sgi-ip22/ip22-mc.c

^1da177e4c3f41 Linus Torvalds 2005-04-16 74
^1da177e4c3f41 Linus Torvalds 2005-04-16 75 void __init sgimc_init(void)
^1da177e4c3f41 Linus Torvalds 2005-04-16 76 {
^1da177e4c3f41 Linus Torvalds 2005-04-16 77 u32 tmp;
^1da177e4c3f41 Linus Torvalds 2005-04-16 78
^1da177e4c3f41 Linus Torvalds 2005-04-16 79 /* ioremap can't fail */
^1da177e4c3f41 Linus Torvalds 2005-04-16 @80 sgimc = (struct sgimc_regs *)
^1da177e4c3f41 Linus Torvalds 2005-04-16 81 ioremap(SGIMC_BASE, sizeof(struct sgimc_regs));
^1da177e4c3f41 Linus Torvalds 2005-04-16 82
^1da177e4c3f41 Linus Torvalds 2005-04-16 83 printk(KERN_INFO "MC: SGI memory controller Revision %d\n",
^1da177e4c3f41 Linus Torvalds 2005-04-16 84 (int) sgimc->systemid & SGIMC_SYSID_MASKREV);
^1da177e4c3f41 Linus Torvalds 2005-04-16 85
^1da177e4c3f41 Linus Torvalds 2005-04-16 86 /* Place the MC into a known state. This must be done before
^1da177e4c3f41 Linus Torvalds 2005-04-16 87 * interrupts are first enabled etc.
^1da177e4c3f41 Linus Torvalds 2005-04-16 88 */
^1da177e4c3f41 Linus Torvalds 2005-04-16 89
^1da177e4c3f41 Linus Torvalds 2005-04-16 90 /* Step 0: Make sure we turn off the watchdog in case it's
^1da177e4c3f41 Linus Torvalds 2005-04-16 91 * still running (which might be the case after a
^1da177e4c3f41 Linus Torvalds 2005-04-16 92 * soft reboot).
^1da177e4c3f41 Linus Torvalds 2005-04-16 93 */
^1da177e4c3f41 Linus Torvalds 2005-04-16 94 tmp = sgimc->cpuctrl0;
^1da177e4c3f41 Linus Torvalds 2005-04-16 95 tmp &= ~SGIMC_CCTRL0_WDOG;
^1da177e4c3f41 Linus Torvalds 2005-04-16 96 sgimc->cpuctrl0 = tmp;
^1da177e4c3f41 Linus Torvalds 2005-04-16 97
^1da177e4c3f41 Linus Torvalds 2005-04-16 98 /* Step 1: The CPU/GIO error status registers will not latch
^1da177e4c3f41 Linus Torvalds 2005-04-16 99 * up a new error status until the register has been
^1da177e4c3f41 Linus Torvalds 2005-04-16 100 * cleared by the cpu. These status registers are
^1da177e4c3f41 Linus Torvalds 2005-04-16 101 * cleared by writing any value to them.
^1da177e4c3f41 Linus Torvalds 2005-04-16 102 */
^1da177e4c3f41 Linus Torvalds 2005-04-16 103 sgimc->cstat = sgimc->gstat = 0;
^1da177e4c3f41 Linus Torvalds 2005-04-16 104
^1da177e4c3f41 Linus Torvalds 2005-04-16 105 /* Step 2: Enable all parity checking in cpu control register
^1da177e4c3f41 Linus Torvalds 2005-04-16 106 * zero.
^1da177e4c3f41 Linus Torvalds 2005-04-16 107 */
e2defae5a9b4f8 Thomas Bogendoerfer 2007-12-02 108 /* don't touch parity settings for IP28 */
^1da177e4c3f41 Linus Torvalds 2005-04-16 109 tmp = sgimc->cpuctrl0;
e84de0c6190503 Thomas Bogendoerfer 2011-11-22 110 #ifndef CONFIG_SGI_IP28
e84de0c6190503 Thomas Bogendoerfer 2011-11-22 111 tmp |= SGIMC_CCTRL0_EPERRGIO | SGIMC_CCTRL0_EPERRMEM;
e2defae5a9b4f8 Thomas Bogendoerfer 2007-12-02 112 #endif
e84de0c6190503 Thomas Bogendoerfer 2011-11-22 113 tmp |= SGIMC_CCTRL0_R4KNOCHKPARR;
^1da177e4c3f41 Linus Torvalds 2005-04-16 114 sgimc->cpuctrl0 = tmp;
^1da177e4c3f41 Linus Torvalds 2005-04-16 115
^1da177e4c3f41 Linus Torvalds 2005-04-16 116 /* Step 3: Setup the MC write buffer depth, this is controlled
^1da177e4c3f41 Linus Torvalds 2005-04-16 117 * in cpu control register 1 in the lower 4 bits.
^1da177e4c3f41 Linus Torvalds 2005-04-16 118 */
^1da177e4c3f41 Linus Torvalds 2005-04-16 119 tmp = sgimc->cpuctrl1;
^1da177e4c3f41 Linus Torvalds 2005-04-16 120 tmp &= ~0xf;
^1da177e4c3f41 Linus Torvalds 2005-04-16 121 tmp |= 0xd;
^1da177e4c3f41 Linus Torvalds 2005-04-16 122 sgimc->cpuctrl1 = tmp;
^1da177e4c3f41 Linus Torvalds 2005-04-16 123
^1da177e4c3f41 Linus Torvalds 2005-04-16 124 /* Step 4: Initialize the RPSS divider register to run as fast
^1da177e4c3f41 Linus Torvalds 2005-04-16 125 * as it can correctly operate. The register is laid
^1da177e4c3f41 Linus Torvalds 2005-04-16 126 * out as follows:
^1da177e4c3f41 Linus Torvalds 2005-04-16 127 *
^1da177e4c3f41 Linus Torvalds 2005-04-16 128 * ----------------------------------------
^1da177e4c3f41 Linus Torvalds 2005-04-16 129 * | RESERVED | INCREMENT | DIVIDER |
^1da177e4c3f41 Linus Torvalds 2005-04-16 130 * ----------------------------------------
^1da177e4c3f41 Linus Torvalds 2005-04-16 131 * 31 16 15 8 7 0
^1da177e4c3f41 Linus Torvalds 2005-04-16 132 *
^1da177e4c3f41 Linus Torvalds 2005-04-16 133 * DIVIDER determines how often a 'tick' happens,
^1da177e4c3f41 Linus Torvalds 2005-04-16 134 * INCREMENT determines by how the RPSS increment
^1da177e4c3f41 Linus Torvalds 2005-04-16 135 * registers value increases at each 'tick'. Thus,
^1da177e4c3f41 Linus Torvalds 2005-04-16 136 * for IP22 we get INCREMENT=1, DIVIDER=1 == 0x101
^1da177e4c3f41 Linus Torvalds 2005-04-16 137 */
^1da177e4c3f41 Linus Torvalds 2005-04-16 138 sgimc->divider = 0x101;
^1da177e4c3f41 Linus Torvalds 2005-04-16 139
^1da177e4c3f41 Linus Torvalds 2005-04-16 140 /* Step 5: Initialize GIO64 arbitrator configuration register.
^1da177e4c3f41 Linus Torvalds 2005-04-16 141 *
^1da177e4c3f41 Linus Torvalds 2005-04-16 142 * NOTE: HPC init code in sgihpc_init() must run before us because
^1da177e4c3f41 Linus Torvalds 2005-04-16 143 * we need to know Guiness vs. FullHouse and the board
^1da177e4c3f41 Linus Torvalds 2005-04-16 144 * revision on this machine. You have been warned.
^1da177e4c3f41 Linus Torvalds 2005-04-16 145 */
^1da177e4c3f41 Linus Torvalds 2005-04-16 146
^1da177e4c3f41 Linus Torvalds 2005-04-16 147 /* First the basic invariants across all GIO64 implementations. */
e84de0c6190503 Thomas Bogendoerfer 2011-11-22 148 tmp = sgimc->giopar & SGIMC_GIOPAR_GFX64; /* keep gfx 64bit settings */
e84de0c6190503 Thomas Bogendoerfer 2011-11-22 149 tmp |= SGIMC_GIOPAR_HPC64; /* All 1st HPC's interface at 64bits */
^1da177e4c3f41 Linus Torvalds 2005-04-16 150 tmp |= SGIMC_GIOPAR_ONEBUS; /* Only one physical GIO bus exists */
^1da177e4c3f41 Linus Torvalds 2005-04-16 151
^1da177e4c3f41 Linus Torvalds 2005-04-16 152 if (ip22_is_fullhouse()) {
^1da177e4c3f41 Linus Torvalds 2005-04-16 153 /* Fullhouse specific settings. */
^1da177e4c3f41 Linus Torvalds 2005-04-16 154 if (SGIOC_SYSID_BOARDREV(sgioc->sysid) < 2) {
^1da177e4c3f41 Linus Torvalds 2005-04-16 155 tmp |= SGIMC_GIOPAR_HPC264; /* 2nd HPC at 64bits */
^1da177e4c3f41 Linus Torvalds 2005-04-16 156 tmp |= SGIMC_GIOPAR_PLINEEXP0; /* exp0 pipelines */
^1da177e4c3f41 Linus Torvalds 2005-04-16 157 tmp |= SGIMC_GIOPAR_MASTEREXP1; /* exp1 masters */
^1da177e4c3f41 Linus Torvalds 2005-04-16 158 tmp |= SGIMC_GIOPAR_RTIMEEXP0; /* exp0 is realtime */
^1da177e4c3f41 Linus Torvalds 2005-04-16 159 } else {
^1da177e4c3f41 Linus Torvalds 2005-04-16 160 tmp |= SGIMC_GIOPAR_HPC264; /* 2nd HPC 64bits */
^1da177e4c3f41 Linus Torvalds 2005-04-16 161 tmp |= SGIMC_GIOPAR_PLINEEXP0; /* exp[01] pipelined */
^1da177e4c3f41 Linus Torvalds 2005-04-16 162 tmp |= SGIMC_GIOPAR_PLINEEXP1;
^1da177e4c3f41 Linus Torvalds 2005-04-16 163 tmp |= SGIMC_GIOPAR_MASTEREISA; /* EISA masters */
^1da177e4c3f41 Linus Torvalds 2005-04-16 164 }
^1da177e4c3f41 Linus Torvalds 2005-04-16 165 } else {
^1da177e4c3f41 Linus Torvalds 2005-04-16 166 /* Guiness specific settings. */
^1da177e4c3f41 Linus Torvalds 2005-04-16 167 tmp |= SGIMC_GIOPAR_EISA64; /* MC talks to EISA at 64bits */
^1da177e4c3f41 Linus Torvalds 2005-04-16 168 tmp |= SGIMC_GIOPAR_MASTEREISA; /* EISA bus can act as master */
^1da177e4c3f41 Linus Torvalds 2005-04-16 169 }
^1da177e4c3f41 Linus Torvalds 2005-04-16 170 sgimc->giopar = tmp; /* poof */
^1da177e4c3f41 Linus Torvalds 2005-04-16 171
^1da177e4c3f41 Linus Torvalds 2005-04-16 172 probe_memory();
^1da177e4c3f41 Linus Torvalds 2005-04-16 173 }
^1da177e4c3f41 Linus Torvalds 2005-04-16 174

:::::: The code at line 80 was first introduced by commit
:::::: 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2 Linux-2.6.12-rc2

:::::: TO: Linus Torvalds <torvalds@xxxxxxxxxxxxxxx>
:::::: CC: Linus Torvalds <torvalds@xxxxxxxxxxxxxxx>

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

Attachment: .config.gz
Description: application/gzip