* [asahilinux:bits/240-isp 20/53] drivers/media/platform/apple/isp/isp-fw.c:295:61: warning: right shift count >= width of type
@ 2026-06-29 5:51 kernel test robot
0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2026-06-29 5:51 UTC (permalink / raw)
To: Asahi Lina; +Cc: oe-kbuild-all, Janne Grunau
tree: https://github.com/AsahiLinux/linux bits/240-isp
head: df907add385f43a49d493c59afd3762ae1598548
commit: f295ca6ad4b4662ba63cfb311d4582352cd03132 [20/53] media: apple: isp: Support >32bit VAs for t602x
config: m68k-allmodconfig (https://download.01.org/0day-ci/archive/20260629/202606291315.bBStSTEP-lkp@intel.com/config)
compiler: m68k-linux-gcc (GCC) 16.1.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20260629/202606291315.bBStSTEP-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@intel.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202606291315.bBStSTEP-lkp@intel.com/
All warnings (new ones prefixed by >>):
In file included from include/linux/bvec.h:10,
from include/linux/blk_types.h:10,
from include/linux/writeback.h:13,
from include/linux/memcontrol.h:23,
from include/linux/swap.h:9,
from include/linux/suspend.h:5,
from include/linux/regulator/consumer.h:35,
from include/linux/i2c.h:19,
from include/media/v4l2-common.h:106,
from include/media/v4l2-subdev.h:15,
from include/media/v4l2-device.h:13,
from drivers/media/platform/apple/isp/isp-drv.h:13,
from drivers/media/platform/apple/isp/isp-cmd.h:7,
from drivers/media/platform/apple/isp/isp-fw.c:8:
include/linux/highmem.h: In function 'clear_user_pages':
include/linux/highmem.h:234:63: warning: parameter 'vaddr' set but not used [-Wunused-but-set-parameter=]
234 | static inline void clear_user_pages(void *addr, unsigned long vaddr,
| ~~~~~~~~~~~~~~^~~~~
drivers/media/platform/apple/isp/isp-fw.c: In function 'isp_firmware_boot_stage2':
>> drivers/media/platform/apple/isp/isp-fw.c:295:61: warning: right shift count >= width of type [-Wshift-count-overflow]
295 | isp_gpio_write32(isp, ISP_GPIO_1, args_iova >> 32);
| ^~
vim +295 drivers/media/platform/apple/isp/isp-fw.c
246
247 static int isp_firmware_boot_stage2(struct apple_isp *isp)
248 {
249 struct isp_firmware_bootargs args;
250 dma_addr_t args_iova;
251 int err, retries;
252
253 u32 num_ipc_chans = isp_gpio_read32(isp, ISP_GPIO_0);
254 u32 args_offset = isp_gpio_read32(isp, ISP_GPIO_1);
255 u32 extra_size = isp_gpio_read32(isp, ISP_GPIO_3);
256 isp->num_ipc_chans = num_ipc_chans;
257
258 if (!isp->num_ipc_chans) {
259 dev_err(isp->dev, "No IPC channels found\n");
260 return -ENODEV;
261 }
262
263 if (isp->num_ipc_chans != 7)
264 dev_warn(isp->dev, "unexpected channel count (%d)\n",
265 num_ipc_chans);
266
267 isp->extra_surf = isp_alloc_surface_vmap(isp, extra_size);
268 if (!isp->extra_surf) {
269 isp_err(isp, "failed to alloc surface for extra heap\n");
270 return -ENOMEM;
271 }
272
273 args_iova = isp->ipc_surf->iova + args_offset + 0x40;
274 isp->cmd_iova = args_iova + sizeof(args) + 0x40;
275
276 memset(&args, 0, sizeof(args));
277 args.ipc_iova = isp->ipc_surf->iova;
278 args.ipc_size = isp->ipc_surf->size;
279 args.shared_base = isp->fw.heap_top & 0xffffffff;
280 args.shared_size = 0x10000000UL - args.shared_base;
281 args.extra_iova = isp->extra_surf->iova;
282 args.extra_size = isp->extra_surf->size;
283 args.platform_id = isp->hw->platform_id;
284 args.unk5 = 0x40;
285 args.unk7 = 0x1;
286 args.unk_iova1 = args_iova + sizeof(args) - 0xc;
287 args.unk9 = 0x3;
288 isp_iowrite(isp, args_iova, &args, sizeof(args));
289
290 isp_gpio_write32(isp, ISP_GPIO_0, args_iova);
291 /* TODO: handle this via Kconfig depends? hardware is only present on
292 * 64-bit SoCs.
293 */
294 if (IS_ENABLED(CONFIG_ARCH_DMA_ADDR_T_64BIT))
> 295 isp_gpio_write32(isp, ISP_GPIO_1, args_iova >> 32);
296 wmb();
297
298 /* Wait for ISP_GPIO_7 to 0xf7fbdff9 -> 0x8042006 */
299 isp_gpio_write32(isp, ISP_GPIO_7, 0xf7fbdff9);
300
301 for (retries = 0; retries < ISP_FIRMWARE_MAX_TRIES; retries++) {
302 u32 val = isp_gpio_read32(isp, ISP_GPIO_7);
303 if (val == 0x8042006) {
304 isp_dbg(isp,
305 "got second magic number (0x%x) from firmware\n",
306 val);
307 break;
308 }
309 mdelay(ISP_FIRMWARE_MDELAY);
310 }
311 if (retries >= ISP_FIRMWARE_MAX_TRIES) {
312 isp_err(isp,
313 "never received second magic number from firmware\n");
314 err = -ENODEV;
315 goto free_extra;
316 }
317
318 return 0;
319
320 free_extra:
321 isp_free_surface(isp, isp->extra_surf);
322 return err;
323 }
324
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2026-06-29 5:52 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-06-29 5:51 [asahilinux:bits/240-isp 20/53] drivers/media/platform/apple/isp/isp-fw.c:295:61: warning: right shift count >= width of type kernel test robot
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.