[<prev] [next>] [day] [month] [year] [list]
Message-ID: <202402011648.cZGj77Kw-lkp@intel.com>
Date: Thu, 1 Feb 2024 16:51:20 +0800
From: kernel test robot <lkp@...el.com>
To: Johannes Berg <johannes.berg@...el.com>
Cc: oe-kbuild-all@...ts.linux.dev, linux-kernel@...r.kernel.org,
Richard Weinberger <richard@....at>
Subject: lib/iomap.c:145:5: warning: no previous prototype for
'ioread64_lo_hi'
Hi Johannes,
First bad commit (maybe != root cause):
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: 6764c317b6bb91bd806ef79adf6d9c0e428b191e
commit: 68f5d3f3b6543266b29e047cfaf9842333019b4c um: add PCI over virtio emulation driver
date: 2 years, 8 months ago
config: um-randconfig-r063-20240107 (https://download.01.org/0day-ci/archive/20240201/202402011648.cZGj77Kw-lkp@intel.com/config)
compiler: gcc-12 (Debian 12.2.0-14) 12.2.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20240201/202402011648.cZGj77Kw-lkp@intel.com/reproduce)
If you fix the issue in a separate patch/commit (i.e. not just a new version of
the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <lkp@...el.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202402011648.cZGj77Kw-lkp@intel.com/
All warnings (new ones prefixed by >>):
>> lib/iomap.c:145:5: warning: no previous prototype for 'ioread64_lo_hi' [-Wmissing-prototypes]
145 | u64 ioread64_lo_hi(const void __iomem *addr)
| ^~~~~~~~~~~~~~
>> lib/iomap.c:151:5: warning: no previous prototype for 'ioread64_hi_lo' [-Wmissing-prototypes]
151 | u64 ioread64_hi_lo(const void __iomem *addr)
| ^~~~~~~~~~~~~~
>> lib/iomap.c:157:5: warning: no previous prototype for 'ioread64be_lo_hi' [-Wmissing-prototypes]
157 | u64 ioread64be_lo_hi(const void __iomem *addr)
| ^~~~~~~~~~~~~~~~
>> lib/iomap.c:164:5: warning: no previous prototype for 'ioread64be_hi_lo' [-Wmissing-prototypes]
164 | u64 ioread64be_hi_lo(const void __iomem *addr)
| ^~~~~~~~~~~~~~~~
>> lib/iomap.c:240:6: warning: no previous prototype for 'iowrite64_lo_hi' [-Wmissing-prototypes]
240 | void iowrite64_lo_hi(u64 val, void __iomem *addr)
| ^~~~~~~~~~~~~~~
>> lib/iomap.c:246:6: warning: no previous prototype for 'iowrite64_hi_lo' [-Wmissing-prototypes]
246 | void iowrite64_hi_lo(u64 val, void __iomem *addr)
| ^~~~~~~~~~~~~~~
>> lib/iomap.c:252:6: warning: no previous prototype for 'iowrite64be_lo_hi' [-Wmissing-prototypes]
252 | void iowrite64be_lo_hi(u64 val, void __iomem *addr)
| ^~~~~~~~~~~~~~~~~
>> lib/iomap.c:258:6: warning: no previous prototype for 'iowrite64be_hi_lo' [-Wmissing-prototypes]
258 | void iowrite64be_hi_lo(u64 val, void __iomem *addr)
| ^~~~~~~~~~~~~~~~~
vim +/ioread64_lo_hi +145 lib/iomap.c
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 144
8f28ca6bd82112 Krzysztof Kozlowski 2020-08-14 @145 u64 ioread64_lo_hi(const void __iomem *addr)
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 146 {
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 147 IO_COND(addr, return pio_read64_lo_hi(port), return readq(addr));
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 148 return 0xffffffffffffffffULL;
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 149 }
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 150
8f28ca6bd82112 Krzysztof Kozlowski 2020-08-14 @151 u64 ioread64_hi_lo(const void __iomem *addr)
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 152 {
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 153 IO_COND(addr, return pio_read64_hi_lo(port), return readq(addr));
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 154 return 0xffffffffffffffffULL;
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 155 }
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 156
8f28ca6bd82112 Krzysztof Kozlowski 2020-08-14 @157 u64 ioread64be_lo_hi(const void __iomem *addr)
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 158 {
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 159 IO_COND(addr, return pio_read64be_lo_hi(port),
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 160 return mmio_read64be(addr));
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 161 return 0xffffffffffffffffULL;
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 162 }
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 163
8f28ca6bd82112 Krzysztof Kozlowski 2020-08-14 @164 u64 ioread64be_hi_lo(const void __iomem *addr)
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 165 {
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 166 IO_COND(addr, return pio_read64be_hi_lo(port),
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 167 return mmio_read64be(addr));
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 168 return 0xffffffffffffffffULL;
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 169 }
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 170
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 171 EXPORT_SYMBOL(ioread64_lo_hi);
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 172 EXPORT_SYMBOL(ioread64_hi_lo);
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 173 EXPORT_SYMBOL(ioread64be_lo_hi);
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 174 EXPORT_SYMBOL(ioread64be_hi_lo);
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 175
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 176 #endif /* readq */
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 177
34ba8a5cd0b0d5 Linus Torvalds 2006-11-11 178 #ifndef pio_write16be
34ba8a5cd0b0d5 Linus Torvalds 2006-11-11 179 #define pio_write16be(val,port) outw(swab16(val),port)
34ba8a5cd0b0d5 Linus Torvalds 2006-11-11 180 #define pio_write32be(val,port) outl(swab32(val),port)
34ba8a5cd0b0d5 Linus Torvalds 2006-11-11 181 #endif
34ba8a5cd0b0d5 Linus Torvalds 2006-11-11 182
34ba8a5cd0b0d5 Linus Torvalds 2006-11-11 183 #ifndef mmio_write16be
aecc787c06f430 Logan Gunthorpe 2019-01-16 184 #define mmio_write16be(val,port) writew(swab16(val),port)
aecc787c06f430 Logan Gunthorpe 2019-01-16 185 #define mmio_write32be(val,port) writel(swab32(val),port)
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 186 #define mmio_write64be(val,port) writeq(swab64(val),port)
34ba8a5cd0b0d5 Linus Torvalds 2006-11-11 187 #endif
34ba8a5cd0b0d5 Linus Torvalds 2006-11-11 188
9f741cb8fecef9 Harvey Harrison 2008-02-08 189 void iowrite8(u8 val, void __iomem *addr)
^1da177e4c3f41 Linus Torvalds 2005-04-16 190 {
^1da177e4c3f41 Linus Torvalds 2005-04-16 191 IO_COND(addr, outb(val,port), writeb(val, addr));
^1da177e4c3f41 Linus Torvalds 2005-04-16 192 }
9f741cb8fecef9 Harvey Harrison 2008-02-08 193 void iowrite16(u16 val, void __iomem *addr)
^1da177e4c3f41 Linus Torvalds 2005-04-16 194 {
^1da177e4c3f41 Linus Torvalds 2005-04-16 195 IO_COND(addr, outw(val,port), writew(val, addr));
^1da177e4c3f41 Linus Torvalds 2005-04-16 196 }
9f741cb8fecef9 Harvey Harrison 2008-02-08 197 void iowrite16be(u16 val, void __iomem *addr)
dae409a2778877 James Bottomley 2005-04-16 198 {
34ba8a5cd0b0d5 Linus Torvalds 2006-11-11 199 IO_COND(addr, pio_write16be(val,port), mmio_write16be(val, addr));
dae409a2778877 James Bottomley 2005-04-16 200 }
9f741cb8fecef9 Harvey Harrison 2008-02-08 201 void iowrite32(u32 val, void __iomem *addr)
^1da177e4c3f41 Linus Torvalds 2005-04-16 202 {
^1da177e4c3f41 Linus Torvalds 2005-04-16 203 IO_COND(addr, outl(val,port), writel(val, addr));
^1da177e4c3f41 Linus Torvalds 2005-04-16 204 }
9f741cb8fecef9 Harvey Harrison 2008-02-08 205 void iowrite32be(u32 val, void __iomem *addr)
dae409a2778877 James Bottomley 2005-04-16 206 {
34ba8a5cd0b0d5 Linus Torvalds 2006-11-11 207 IO_COND(addr, pio_write32be(val,port), mmio_write32be(val, addr));
dae409a2778877 James Bottomley 2005-04-16 208 }
^1da177e4c3f41 Linus Torvalds 2005-04-16 209 EXPORT_SYMBOL(iowrite8);
^1da177e4c3f41 Linus Torvalds 2005-04-16 210 EXPORT_SYMBOL(iowrite16);
dae409a2778877 James Bottomley 2005-04-16 211 EXPORT_SYMBOL(iowrite16be);
^1da177e4c3f41 Linus Torvalds 2005-04-16 212 EXPORT_SYMBOL(iowrite32);
dae409a2778877 James Bottomley 2005-04-16 213 EXPORT_SYMBOL(iowrite32be);
^1da177e4c3f41 Linus Torvalds 2005-04-16 214
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 215 #ifdef writeq
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 216 static void pio_write64_lo_hi(u64 val, unsigned long port)
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 217 {
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 218 outl(val, port);
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 219 outl(val >> 32, port + sizeof(u32));
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 220 }
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 221
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 222 static void pio_write64_hi_lo(u64 val, unsigned long port)
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 223 {
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 224 outl(val >> 32, port + sizeof(u32));
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 225 outl(val, port);
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 226 }
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 227
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 228 static void pio_write64be_lo_hi(u64 val, unsigned long port)
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 229 {
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 230 pio_write32be(val, port + sizeof(u32));
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 231 pio_write32be(val >> 32, port);
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 232 }
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 233
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 234 static void pio_write64be_hi_lo(u64 val, unsigned long port)
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 235 {
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 236 pio_write32be(val >> 32, port);
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 237 pio_write32be(val, port + sizeof(u32));
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 238 }
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 239
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 @240 void iowrite64_lo_hi(u64 val, void __iomem *addr)
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 241 {
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 242 IO_COND(addr, pio_write64_lo_hi(val, port),
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 243 writeq(val, addr));
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 244 }
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 245
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 @246 void iowrite64_hi_lo(u64 val, void __iomem *addr)
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 247 {
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 248 IO_COND(addr, pio_write64_hi_lo(val, port),
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 249 writeq(val, addr));
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 250 }
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 251
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 @252 void iowrite64be_lo_hi(u64 val, void __iomem *addr)
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 253 {
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 254 IO_COND(addr, pio_write64be_lo_hi(val, port),
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 255 mmio_write64be(val, addr));
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 256 }
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 257
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 @258 void iowrite64be_hi_lo(u64 val, void __iomem *addr)
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 259 {
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 260 IO_COND(addr, pio_write64be_hi_lo(val, port),
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 261 mmio_write64be(val, addr));
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 262 }
79bf0cbd86ac48 Logan Gunthorpe 2019-01-16 263
:::::: The code at line 145 was first introduced by commit
:::::: 8f28ca6bd8211214faf717677bbffe375c2a6072 iomap: constify ioreadX() iomem argument (as in generic implementation)
:::::: TO: Krzysztof Kozlowski <krzk@...nel.org>
:::::: CC: Linus Torvalds <torvalds@...ux-foundation.org>
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
Powered by blists - more mailing lists