[PATCH] parisc: fix incorrect resource flags assignment in eisa_probe()

From: zhangjiao2

Date: Fri Dec 04 2026 - 04:41:06 EST


From: zhang jiao <zhangjiao2@xxxxxxxxxxxxxxxxxxxx>

The eisa_probe() function has a copy-paste error on line 318 where
lmmio_space.flags is incorrectly set to IORESOURCE_IO instead of
io_space.flags. This results in:

1. lmmio_space.flags being overwritten from the correct
IORESOURCE_MEM to IORESOURCE_IO.
2. io_space.flags remaining uninitialized (0), causing the
request_resource(&ioport_resource, ...) call to operate on an
io_space resource with incorrect flags.

Fix by assigning IORESOURCE_IO to the correct io_space.flags field.

Signed-off-by: zhang jiao <zhangjiao2@xxxxxxxxxxxxxxxxxxxx>
---
drivers/parisc/eisa.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/parisc/eisa.c b/drivers/parisc/eisa.c
index b5b5413bfd1e..ce0c75dbf2d2 100644
--- a/drivers/parisc/eisa.c
+++ b/drivers/parisc/eisa.c
@@ -315,7 +315,7 @@ static int __init eisa_probe(struct parisc_device *dev)
eisa_dev.hba.io_space.name = "EISA";
eisa_dev.hba.io_space.start = 0;
eisa_dev.hba.io_space.end = 0xffff;
- eisa_dev.hba.lmmio_space.flags = IORESOURCE_IO;
+ eisa_dev.hba.io_space.flags = IORESOURCE_IO;
result = request_resource(&ioport_resource, &eisa_dev.hba.io_space);
if (result < 0) {
printk(KERN_ERR "EISA: failed to claim EISA Bus port space!\n");
--
2.33.0