Segfault after mounting a partition 128 times.
Closed this issue · 1 comments
zvin commented
You can mount a partition 127 times.
The 128th try will cause a SEGFAULT in lkl_disk_add
.
More precisely in lkl_sys_virtio_mmio_device_add
with
dev->base
being negative (it is calculated inregister_iomem
and overflows)dev->irq
=129
This is problematic because node-lkl calls lkl_disk_add
for each partition it mounts (even one on a disk which already has a partition mounted) and never calls lkl_disk_remove
I've added a test that causes this segfault in the segfault-on-128th-mount
branch