Re: [PATCH] loop: Increase bsize variable from unsigned short to unsigned int

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, Aug 27, 2024 at 3:20 PM John Garry <john.g.garry@xxxxxxxxxx> wrote:
>
> On 27/08/2024 04:22, Li Wang wrote:
>
> +linux-block, Jens
>
> > This change allows the loopback driver to handle larger block sizes
>
> larger than what? PAGE_SIZE?

Yes, system should return EINVAL when the tested bsize is larger than PAGE_SIZE.
But due to the loop_reconfigure_limits() cast it to 'unsined short' that
never gets an expected error when testing invalid logical block size.

That's why LTP/ioctl_loop06 failed on a system with 64k (ppc64le) pagesize
(since kernel-v6.11-rc1 with patches):

  9423c653fe6110 ("loop: Don't bother validating blocksize")
  fe3d508ba95bc6 ("block: Validate logical block size in blk_validate_limits()")



--
Regards,
Li Wang






[Index of Archives]     [Linux RAID]     [Linux SCSI]     [Linux ATA RAID]     [IDE]     [Linux Wireless]     [Linux Kernel]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Device Mapper]

  Powered by Linux