diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2022-08-05 09:58:58 -0700 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2022-08-05 09:58:58 -0700 |
commit | 8db4a0291b09be667ba72584e1aeb7aaf8b497bd (patch) | |
tree | ab0856292c58769ddc4df6d7f0589a5b11a2e5eb /drivers | |
parent | 98586bd6dce3690d8ae8d8561383d9ecc715e3c2 (diff) | |
parent | e61b3125a4f036b3c6b87ffd656fc1ab00440ae9 (diff) |
Merge tag 'for-5.20/parisc-1' of git://git.kernel.org/pub/scm/linux/kernel/git/deller/parisc-linux
Pull parisc updates from Helge Deller:
"One real bugfix to change the io_pgetevents_time64() syscall to use
the compat implementation when running in compat mode, otherwise the
signed int32 parameters min_nr and nr will be incorrectly handled as
unsigned int64 values.
Other than that just small cleanups:
- hardware database housekeeping and proper /proc/iomem output
- add proper function exit code if probe functions fail
- drop stale variables (pa_swapper_pg_lock)
- drop unneccessary zero-initializations
- typo fixes in comments"
* tag 'for-5.20/parisc-1' of git://git.kernel.org/pub/scm/linux/kernel/git/deller/parisc-linux:
Input: gscps2 - check return value of ioremap() in gscps2_probe()
parisc: io_pgetevents_time64() needs compat syscall in 32-bit compat mode
parisc: Drop zero variable initialisations in mm/init.c
parisc: Do not initialise statics to 0
parisc: Check the return value of ioremap() in lba_driver_probe()
parisc: Drop pa_swapper_pg_lock spinlock
parisc: Fix comment typo in fault.c
parisc: Fix device names in /proc/iomem
parisc: Clean up names in hardware database
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/input/serio/gscps2.c | 4 | ||||
-rw-r--r-- | drivers/parisc/lba_pci.c | 6 |
2 files changed, 9 insertions, 1 deletions
diff --git a/drivers/input/serio/gscps2.c b/drivers/input/serio/gscps2.c index a9065c6ab550..da2c67cb8642 100644 --- a/drivers/input/serio/gscps2.c +++ b/drivers/input/serio/gscps2.c @@ -350,6 +350,10 @@ static int __init gscps2_probe(struct parisc_device *dev) ps2port->port = serio; ps2port->padev = dev; ps2port->addr = ioremap(hpa, GSC_STATUS + 4); + if (!ps2port->addr) { + ret = -ENOMEM; + goto fail_nomem; + } spin_lock_init(&ps2port->lock); gscps2_reset(ps2port); diff --git a/drivers/parisc/lba_pci.c b/drivers/parisc/lba_pci.c index 732b516c7bf8..afc6e66ddc31 100644 --- a/drivers/parisc/lba_pci.c +++ b/drivers/parisc/lba_pci.c @@ -1476,9 +1476,13 @@ lba_driver_probe(struct parisc_device *dev) u32 func_class; void *tmp_obj; char *version; - void __iomem *addr = ioremap(dev->hpa.start, 4096); + void __iomem *addr; int max; + addr = ioremap(dev->hpa.start, 4096); + if (addr == NULL) + return -ENOMEM; + /* Read HW Rev First */ func_class = READ_REG32(addr + LBA_FCLASS); |