fs/qnx6/inode.c | 26 +++++++++++++++++++++----- fs/qnx6/namei.c | 5 ++++- 2 files changed, 25 insertions(+), 6 deletions(-)
This series addresses buffer head leaks, a double brelse(), and bounds-check failures in the qnx6 filesystem driver: 1. Validate di_filelevels <= QNX6_PTR_MAX_LEVELS in qnx6_iget() before accessing inode level pointers to prevent array bounds overflow. 2. Release bh via brelse() on error path in qnx6_block_map(). 3. Avoid double brelse(sb_buf) on error path in qnx6_fill_super(). 4. Release sb_buf on mmi_fs error path in qnx6_fill_super() when probing MMI superblocks. 5. Abort mount on superblock magic mismatch when silent is set. 6. Validate sb_blocksize before dividing in qnx6_mmi_fill_super() to prevent divide-by-zero. Changes in v3: - Add Tested-by and Reviewed-by tags from Matthias Goergens across all patches in the series. Changes in v2: - Split into a 6-patch series as requested by maintainer review. Hui Peng (6): qnx6: validate di_filelevels in qnx6_iget() before accessing level pointers qnx6: release bh on error path in qnx6_block_map() qnx6: avoid double brelse() on error path in qnx6_fill_super() qnx6: release sb_buf on mmi_fs error path in qnx6_fill_super() qnx6: abort mount on superblock magic mismatch when silent is set qnx6: validate sb_blocksize before dividing in qnx6_mmi_fill_super() fs/qnx6/inode.c | 26 +++++++++++++++++++++----- fs/qnx6/namei.c | 5 ++++- 2 files changed, 25 insertions(+), 6 deletions(-)
Hi Hui, Thanks for picking up my tags so quickly. I tried to test v3 as well, but it doesn't apply to mainline (40288c9206c1) or on top of v2, and its context has code that isn't in fs/qnx6 in mainline or linux-next, for example qnx6_inode->di_ptr in 1/6 and the out_sbl1/out_sbl2 labels in 3/6. My Tested-by and Reviewed-by were for v2 as posted [1], so please drop them from v3 for now. Which tree is v3 based on? If you can point me at it, or rebase onto mainline, I'm happy to review and test it again and send the tags for the new version. One small thing for the respin: the 1/6 commit message says QNX6_PTR_MAX_LEVELS is 3, but include/linux/qnx6_fs.h defines it as 5. Thanks, Matthias [1] https://lore.kernel.org/all/20260921042511.1473629-1-benquike@gmail.com/
© 2016 - 2026 Red Hat, Inc.