drivers/gpib/ines/ines_gpib.c:917 ines_isa_attach() warn: 'config->ibbase' from __request_region() not released on lines: 913.
Dan Carpenter
build botBCC: [email protected]
CC: [email protected]
CC: [email protected]
TO: Dave Penkler <[email protected]>
Hi Dave,
First bad commit (maybe != root cause):
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master head: eb3f4b7426cfd2b79d65b7d37155480b32259a11 commit: e6ab504633e4c06e35377ecf3c8cbc304de79858 staging: gpib: Destage gpib date: 6 months ago
:::::: branch date: 8 hours ago
:::::: commit date: 6 months ago
config: alpha-randconfig-r071-20260527 (https://download.01.org/0day-ci/archive/20260527/[email protected]/config)
compiler: alpha-linux-gcc (GCC) 8.5.0
smatch: v0.5.0-9185-gbcc58b9c
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
| Fixes: e6ab504633e4 ("staging: gpib: Destage gpib")
| Reported-by: kernel test robot <[email protected]>
| Reported-by: Dan Carpenter <[email protected]>
| Closes: https://lore.kernel.org/r/[email protected]/New smatch warnings:drivers/gpib/ines/ines_gpib.c:917 ines_isa_attach() warn: 'config->ibbase' from __request_region() not released on lines: 913.
Old smatch warnings:
internal error: arch/alpha/include/asm/io_trivial.h:12 SQL error #2: near "and": syntax error
internal error: arch/alpha/include/asm/io_trivial.h:12 SQL: 'select * from return_states where and type = 1044 and parameter = -1 and key = '$' limit 1;'
vim +917 drivers/gpib/ines/ines_gpib.c
b8989f45d1ec0b drivers/staging/gpib/ines/ines_gpib.c Arnd Bergmann 2024-10-16 888
cfa6673eae0281 drivers/staging/gpib/ines/ines_gpib.c Dave Penkler 2025-05-02 889 static int ines_isa_attach(struct gpib_board *board, const struct gpib_board_config *config)
bb1bd92fa0f2c9 drivers/staging/gpib/ines/ines_gpib.c Dave Penkler 2024-09-18 890 {
bb1bd92fa0f2c9 drivers/staging/gpib/ines/ines_gpib.c Dave Penkler 2024-09-18 891 struct ines_priv *ines_priv;
bb1bd92fa0f2c9 drivers/staging/gpib/ines/ines_gpib.c Dave Penkler 2024-09-18 892 struct nec7210_priv *nec_priv;
bb1bd92fa0f2c9 drivers/staging/gpib/ines/ines_gpib.c Dave Penkler 2024-09-18 893 int isr_flags = 0;
bb1bd92fa0f2c9 drivers/staging/gpib/ines/ines_gpib.c Dave Penkler 2024-09-18 894 int retval;
bb1bd92fa0f2c9 drivers/staging/gpib/ines/ines_gpib.c Dave Penkler 2024-09-18 895
bb1bd92fa0f2c9 drivers/staging/gpib/ines/ines_gpib.c Dave Penkler 2024-09-18 896 retval = ines_generic_attach(board);
bb1bd92fa0f2c9 drivers/staging/gpib/ines/ines_gpib.c Dave Penkler 2024-09-18 897 if (retval)
bb1bd92fa0f2c9 drivers/staging/gpib/ines/ines_gpib.c Dave Penkler 2024-09-18 898 return retval;
bb1bd92fa0f2c9 drivers/staging/gpib/ines/ines_gpib.c Dave Penkler 2024-09-18 899
bb1bd92fa0f2c9 drivers/staging/gpib/ines/ines_gpib.c Dave Penkler 2024-09-18 900 ines_priv = board->private_data;
bb1bd92fa0f2c9 drivers/staging/gpib/ines/ines_gpib.c Dave Penkler 2024-09-18 901 nec_priv = &ines_priv->nec7210_priv;
bb1bd92fa0f2c9 drivers/staging/gpib/ines/ines_gpib.c Dave Penkler 2024-09-18 902
0de51244e7b7e3 drivers/staging/gpib/ines/ines_gpib.c Dave Penkler 2025-02-20 903 if (!request_region(config->ibbase, ines_isa_iosize, DRV_NAME)) {
0de51244e7b7e3 drivers/staging/gpib/ines/ines_gpib.c Dave Penkler 2025-02-20 904 dev_err(board->gpib_dev, "ioports at 0x%x already in use\n",
0de51244e7b7e3 drivers/staging/gpib/ines/ines_gpib.c Dave Penkler 2025-02-20 905 config->ibbase);
0de51244e7b7e3 drivers/staging/gpib/ines/ines_gpib.c Dave Penkler 2025-02-20 906 return -EBUSY;
bb1bd92fa0f2c9 drivers/staging/gpib/ines/ines_gpib.c Dave Penkler 2024-09-18 907 }
bb1bd92fa0f2c9 drivers/staging/gpib/ines/ines_gpib.c Dave Penkler 2024-09-18 908 nec_priv->iobase = config->ibbase;
bb1bd92fa0f2c9 drivers/staging/gpib/ines/ines_gpib.c Dave Penkler 2024-09-18 909 nec_priv->offset = 1;
bb1bd92fa0f2c9 drivers/staging/gpib/ines/ines_gpib.c Dave Penkler 2024-09-18 910 nec7210_board_reset(nec_priv, board);
0de51244e7b7e3 drivers/staging/gpib/ines/ines_gpib.c Dave Penkler 2025-02-20 911 if (request_irq(config->ibirq, ines_pci_interrupt, isr_flags, DRV_NAME, board)) {
0de51244e7b7e3 drivers/staging/gpib/ines/ines_gpib.c Dave Penkler 2025-02-20 912 dev_err(board->gpib_dev, "failed to allocate IRQ %d\n", config->ibirq);
bb1bd92fa0f2c9 drivers/staging/gpib/ines/ines_gpib.c Dave Penkler 2024-09-18 913 return -1;
bb1bd92fa0f2c9 drivers/staging/gpib/ines/ines_gpib.c Dave Penkler 2024-09-18 914 }
bb1bd92fa0f2c9 drivers/staging/gpib/ines/ines_gpib.c Dave Penkler 2024-09-18 915 ines_priv->irq = config->ibirq;
bb1bd92fa0f2c9 drivers/staging/gpib/ines/ines_gpib.c Dave Penkler 2024-09-18 916 ines_online(ines_priv, board, 1);
bb1bd92fa0f2c9 drivers/staging/gpib/ines/ines_gpib.c Dave Penkler 2024-09-18 @917 return 0;
bb1bd92fa0f2c9 drivers/staging/gpib/ines/ines_gpib.c Dave Penkler 2024-09-18 918 }
bb1bd92fa0f2c9 drivers/staging/gpib/ines/ines_gpib.c Dave Penkler 2024-09-18 919 :::::: The code at line 917 was first introduced by commit
:::::: bb1bd92fa0f2c9c39c5766e3ea81f26d7e8355a4 staging: gpib: Add ines GPIB driver
:::::: TO: Dave Penkler <[email protected]> :::::: CC: Greg Kroah-Hartman <[email protected]>
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
Huh, Tony Btw fixed this before I reported it... No ines_generic_attach() cleanup, though?
I still got a Reported-by tag so that's what counts.
regards,
dan carpenter