Linux Test Project
 help / color / mirror / Atom feed
* [LTP] [linux-next:master] [block/bdev] 47dd675323: ltp.ioctl_loop06.fail
@ 2025-03-10  7:40 kernel test robot
  2025-03-10  8:36 ` Li Wang
  0 siblings, 1 reply; 7+ messages in thread
From: kernel test robot @ 2025-03-10  7:40 UTC (permalink / raw)
  To: Luis Chamberlain
  Cc: Christian Brauner, lkp, Matthew Wilcox (Oracle), linux-block,
	oliver.sang, Hannes Reinecke, oe-lkp, ltp



Hello,

kernel test robot noticed "ltp.ioctl_loop06.fail" on:

commit: 47dd67532303803a87f43195e088b3b4bcf0454d ("block/bdev: lift block size restrictions to 64k")
https://git.kernel.org/cgit/linux/kernel/git/next/linux-next.git master

in testcase: ltp
version: ltp-x86_64-0f9d817a3-1_20250222
with following parameters:

	disk: 1HDD
	fs: xfs
	test: syscalls-01/ioctl_loop06



config: x86_64-rhel-9.4-ltp
compiler: gcc-12
test machine: 4 threads 1 sockets Intel(R) Core(TM) i3-3220 CPU @ 3.30GHz (Ivy Bridge) with 8G memory

(please refer to attached dmesg/kmsg for entire log/backtrace)




If you fix the issue in a separate patch/commit (i.e. not just a new version of
the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <lkp@intel.com>
| Closes: https://lore.kernel.org/oe-lkp/202503101538.84c33cd4-lkp@intel.com


Running tests.......
<<<test_start>>>
tag=ioctl_loop06 stime=1741322388
cmdline="ioctl_loop06"
contacts=""
analysis=exit
<<<test_output>>>
tst_tmpdir.c:316: TINFO: Using /fs/sda2/tmpdir/ltp-f5uEC1THVm/LTP_iocbBycpj as tmpdir (xfs filesystem)
tst_test.c:1900: TINFO: LTP version: 20250130-118-g0f9d817a3
tst_test.c:1904: TINFO: Tested kernel: 6.14.0-rc1-00007-g47dd67532303 #1 SMP PREEMPT_DYNAMIC Fri Mar  7 11:25:50 CST 2025 x86_64
tst_kconfig.c:88: TINFO: Parsing kernel config '/proc/config.gz'
tst_kconfig.c:676: TINFO: CONFIG_KASAN kernel option detected which might slow the execution
tst_test.c:1722: TINFO: Overall timeout per run is 0h 10m 00s
tst_device.c:97: TINFO: Found free device 0 '/dev/loop0'
ioctl_loop06.c:74: TINFO: Using LOOP_SET_BLOCK_SIZE with arg < 512
ioctl_loop06.c:65: TPASS: Set block size failed as expected: EINVAL (22)
ioctl_loop06.c:74: TINFO: Using LOOP_SET_BLOCK_SIZE with arg > PAGE_SIZE
ioctl_loop06.c:57: TFAIL: Set block size succeed unexpectedly
ioctl_loop06.c:74: TINFO: Using LOOP_SET_BLOCK_SIZE with arg != power_of_2
ioctl_loop06.c:65: TPASS: Set block size failed as expected: EINVAL (22)
ioctl_loop06.c:74: TINFO: Using LOOP_CONFIGURE with block_size < 512
ioctl_loop06.c:65: TPASS: Set block size failed as expected: EINVAL (22)
ioctl_loop06.c:74: TINFO: Using LOOP_CONFIGURE with block_size > PAGE_SIZE
ioctl_loop06.c:57: TFAIL: Set block size succeed unexpectedly
ioctl_loop06.c:74: TINFO: Using LOOP_CONFIGURE with block_size != power_of_2
ioctl_loop06.c:65: TPASS: Set block size failed as expected: EINVAL (22)

Summary:
passed   4
failed   2
broken   0
skipped  0
warnings 0
incrementing stop
<<<execution_status>>>
initiation_status="ok"
duration=1 termination_type=exited termination_id=1 corefile=no
cutime=0 cstime=6
<<<test_end>>>
INFO: ltp-pan reported some tests FAIL
LTP Version: 20250130-118-g0f9d817a3

       ###############################################################

            Done executing testcases.
            LTP Version:  20250130-118-g0f9d817a3
       ###############################################################




The kernel config and materials to reproduce are available at:
https://download.01.org/0day-ci/archive/20250310/202503101538.84c33cd4-lkp@intel.com



-- 
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki


-- 
Mailing list info: https://lists.linux.it/listinfo/ltp

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [LTP] [linux-next:master] [block/bdev] 47dd675323: ltp.ioctl_loop06.fail
  2025-03-10  7:40 [LTP] [linux-next:master] [block/bdev] 47dd675323: ltp.ioctl_loop06.fail kernel test robot
@ 2025-03-10  8:36 ` Li Wang
  2025-03-10 15:08   ` Luis Chamberlain via ltp
  0 siblings, 1 reply; 7+ messages in thread
From: Li Wang @ 2025-03-10  8:36 UTC (permalink / raw)
  To: kernel test robot, LTP List
  Cc: Christian Brauner, lkp, Matthew Wilcox (Oracle), linux-block,
	Luis Chamberlain, Hannes Reinecke, oe-lkp

Hi,

The ioctl_loop06 test expects PAGE_SIZE to be the upper limit, but the
kernel
now allows up to 64K (SZ_64K). If PAGE_SIZE < 64K (e.g., 4K on x86),
the test wrongly assumes anything above PAGE_SIZE should be rejected,
but the kernel now allows up to 64K.

I guess we probably need to adjust testcase to dynamically define an
EXPECTED_MAX_BLOCK_SIZE according to kernel versions.
I will send out a patch to LTP ML.



On Mon, Mar 10, 2025 at 3:41 PM kernel test robot <oliver.sang@intel.com>
wrote:

>
>
> Hello,
>
> kernel test robot noticed "ltp.ioctl_loop06.fail" on:
>
> commit: 47dd67532303803a87f43195e088b3b4bcf0454d ("block/bdev: lift block
> size restrictions to 64k")
> https://git.kernel.org/cgit/linux/kernel/git/next/linux-next.git master
>
> in testcase: ltp
> version: ltp-x86_64-0f9d817a3-1_20250222
> with following parameters:
>
>         disk: 1HDD
>         fs: xfs
>         test: syscalls-01/ioctl_loop06
>
>
>
> config: x86_64-rhel-9.4-ltp
> compiler: gcc-12
> test machine: 4 threads 1 sockets Intel(R) Core(TM) i3-3220 CPU @ 3.30GHz
> (Ivy Bridge) with 8G memory
>
> (please refer to attached dmesg/kmsg for entire log/backtrace)
>
>
>
>
> If you fix the issue in a separate patch/commit (i.e. not just a new
> version of
> the same patch/commit), kindly add following tags
> | Reported-by: kernel test robot <lkp@intel.com>
> | Closes:
> https://lore.kernel.org/oe-lkp/202503101538.84c33cd4-lkp@intel.com
>
>
> Running tests.......
> <<<test_start>>>
> tag=ioctl_loop06 stime=1741322388
> cmdline="ioctl_loop06"
> contacts=""
> analysis=exit
> <<<test_output>>>
> tst_tmpdir.c:316: TINFO: Using
> /fs/sda2/tmpdir/ltp-f5uEC1THVm/LTP_iocbBycpj as tmpdir (xfs filesystem)
> tst_test.c:1900: TINFO: LTP version: 20250130-118-g0f9d817a3
> tst_test.c:1904: TINFO: Tested kernel: 6.14.0-rc1-00007-g47dd67532303 #1
> SMP PREEMPT_DYNAMIC Fri Mar  7 11:25:50 CST 2025 x86_64
> tst_kconfig.c:88: TINFO: Parsing kernel config '/proc/config.gz'
> tst_kconfig.c:676: TINFO: CONFIG_KASAN kernel option detected which might
> slow the execution
> tst_test.c:1722: TINFO: Overall timeout per run is 0h 10m 00s
> tst_device.c:97: TINFO: Found free device 0 '/dev/loop0'
> ioctl_loop06.c:74: TINFO: Using LOOP_SET_BLOCK_SIZE with arg < 512
> ioctl_loop06.c:65: TPASS: Set block size failed as expected: EINVAL (22)
> ioctl_loop06.c:74: TINFO: Using LOOP_SET_BLOCK_SIZE with arg > PAGE_SIZE
> ioctl_loop06.c:57: TFAIL: Set block size succeed unexpectedly
> ioctl_loop06.c:74: TINFO: Using LOOP_SET_BLOCK_SIZE with arg != power_of_2
> ioctl_loop06.c:65: TPASS: Set block size failed as expected: EINVAL (22)
> ioctl_loop06.c:74: TINFO: Using LOOP_CONFIGURE with block_size < 512
> ioctl_loop06.c:65: TPASS: Set block size failed as expected: EINVAL (22)
> ioctl_loop06.c:74: TINFO: Using LOOP_CONFIGURE with block_size > PAGE_SIZE
> ioctl_loop06.c:57: TFAIL: Set block size succeed unexpectedly
> ioctl_loop06.c:74: TINFO: Using LOOP_CONFIGURE with block_size !=
> power_of_2
> ioctl_loop06.c:65: TPASS: Set block size failed as expected: EINVAL (22)
>
> Summary:
> passed   4
> failed   2
> broken   0
> skipped  0
> warnings 0
> incrementing stop
> <<<execution_status>>>
> initiation_status="ok"
> duration=1 termination_type=exited termination_id=1 corefile=no
> cutime=0 cstime=6
> <<<test_end>>>
> INFO: ltp-pan reported some tests FAIL
> LTP Version: 20250130-118-g0f9d817a3
>
>        ###############################################################
>
>             Done executing testcases.
>             LTP Version:  20250130-118-g0f9d817a3
>        ###############################################################
>
>
>
>
> The kernel config and materials to reproduce are available at:
>
> https://download.01.org/0day-ci/archive/20250310/202503101538.84c33cd4-lkp@intel.com
>
>
>
> --
> 0-DAY CI Kernel Test Service
> https://github.com/intel/lkp-tests/wiki
>
>
> --
> Mailing list info: https://lists.linux.it/listinfo/ltp
>
>

-- 
Regards,
Li Wang

-- 
Mailing list info: https://lists.linux.it/listinfo/ltp

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [LTP] [linux-next:master] [block/bdev] 47dd675323: ltp.ioctl_loop06.fail
  2025-03-10  8:36 ` Li Wang
@ 2025-03-10 15:08   ` Luis Chamberlain via ltp
  2025-03-11  1:43     ` Li Wang
  0 siblings, 1 reply; 7+ messages in thread
From: Luis Chamberlain via ltp @ 2025-03-10 15:08 UTC (permalink / raw)
  To: Li Wang
  Cc: Christian Brauner, 0day robot, Matthew Wilcox (Oracle),
	linux-block, kernel test robot, Hannes Reinecke, oe-lkp, LTP List

There's a fix for this already in next

On Mon, Mar 10, 2025, 1:36 AM Li Wang <liwang@redhat.com> wrote:

> Hi,
>
> The ioctl_loop06 test expects PAGE_SIZE to be the upper limit, but the
> kernel
> now allows up to 64K (SZ_64K). If PAGE_SIZE < 64K (e.g., 4K on x86),
> the test wrongly assumes anything above PAGE_SIZE should be rejected,
> but the kernel now allows up to 64K.
>
> I guess we probably need to adjust testcase to dynamically define an
> EXPECTED_MAX_BLOCK_SIZE according to kernel versions.
> I will send out a patch to LTP ML.
>
>
>
> On Mon, Mar 10, 2025 at 3:41 PM kernel test robot <oliver.sang@intel.com>
> wrote:
>
>>
>>
>> Hello,
>>
>> kernel test robot noticed "ltp.ioctl_loop06.fail" on:
>>
>> commit: 47dd67532303803a87f43195e088b3b4bcf0454d ("block/bdev: lift block
>> size restrictions to 64k")
>> https://git.kernel.org/cgit/linux/kernel/git/next/linux-next.git master
>>
>> in testcase: ltp
>> version: ltp-x86_64-0f9d817a3-1_20250222
>> with following parameters:
>>
>>         disk: 1HDD
>>         fs: xfs
>>         test: syscalls-01/ioctl_loop06
>>
>>
>>
>> config: x86_64-rhel-9.4-ltp
>> compiler: gcc-12
>> test machine: 4 threads 1 sockets Intel(R) Core(TM) i3-3220 CPU @ 3.30GHz
>> (Ivy Bridge) with 8G memory
>>
>> (please refer to attached dmesg/kmsg for entire log/backtrace)
>>
>>
>>
>>
>> If you fix the issue in a separate patch/commit (i.e. not just a new
>> version of
>> the same patch/commit), kindly add following tags
>> | Reported-by: kernel test robot <lkp@intel.com>
>> | Closes:
>> https://lore.kernel.org/oe-lkp/202503101538.84c33cd4-lkp@intel.com
>>
>>
>> Running tests.......
>> <<<test_start>>>
>> tag=ioctl_loop06 stime=1741322388
>> cmdline="ioctl_loop06"
>> contacts=""
>> analysis=exit
>> <<<test_output>>>
>> tst_tmpdir.c:316: TINFO: Using
>> /fs/sda2/tmpdir/ltp-f5uEC1THVm/LTP_iocbBycpj as tmpdir (xfs filesystem)
>> tst_test.c:1900: TINFO: LTP version: 20250130-118-g0f9d817a3
>> tst_test.c:1904: TINFO: Tested kernel: 6.14.0-rc1-00007-g47dd67532303 #1
>> SMP PREEMPT_DYNAMIC Fri Mar  7 11:25:50 CST 2025 x86_64
>> tst_kconfig.c:88: TINFO: Parsing kernel config '/proc/config.gz'
>> tst_kconfig.c:676: TINFO: CONFIG_KASAN kernel option detected which might
>> slow the execution
>> tst_test.c:1722: TINFO: Overall timeout per run is 0h 10m 00s
>> tst_device.c:97: TINFO: Found free device 0 '/dev/loop0'
>> ioctl_loop06.c:74: TINFO: Using LOOP_SET_BLOCK_SIZE with arg < 512
>> ioctl_loop06.c:65: TPASS: Set block size failed as expected: EINVAL (22)
>> ioctl_loop06.c:74: TINFO: Using LOOP_SET_BLOCK_SIZE with arg > PAGE_SIZE
>> ioctl_loop06.c:57: TFAIL: Set block size succeed unexpectedly
>> ioctl_loop06.c:74: TINFO: Using LOOP_SET_BLOCK_SIZE with arg != power_of_2
>> ioctl_loop06.c:65: TPASS: Set block size failed as expected: EINVAL (22)
>> ioctl_loop06.c:74: TINFO: Using LOOP_CONFIGURE with block_size < 512
>> ioctl_loop06.c:65: TPASS: Set block size failed as expected: EINVAL (22)
>> ioctl_loop06.c:74: TINFO: Using LOOP_CONFIGURE with block_size > PAGE_SIZE
>> ioctl_loop06.c:57: TFAIL: Set block size succeed unexpectedly
>> ioctl_loop06.c:74: TINFO: Using LOOP_CONFIGURE with block_size !=
>> power_of_2
>> ioctl_loop06.c:65: TPASS: Set block size failed as expected: EINVAL (22)
>>
>> Summary:
>> passed   4
>> failed   2
>> broken   0
>> skipped  0
>> warnings 0
>> incrementing stop
>> <<<execution_status>>>
>> initiation_status="ok"
>> duration=1 termination_type=exited termination_id=1 corefile=no
>> cutime=0 cstime=6
>> <<<test_end>>>
>> INFO: ltp-pan reported some tests FAIL
>> LTP Version: 20250130-118-g0f9d817a3
>>
>>        ###############################################################
>>
>>             Done executing testcases.
>>             LTP Version:  20250130-118-g0f9d817a3
>>        ###############################################################
>>
>>
>>
>>
>> The kernel config and materials to reproduce are available at:
>>
>> https://download.01.org/0day-ci/archive/20250310/202503101538.84c33cd4-lkp@intel.com
>>
>>
>>
>> --
>> 0-DAY CI Kernel Test Service
>> https://github.com/intel/lkp-tests/wiki
>>
>>
>> --
>> Mailing list info: https://lists.linux.it/listinfo/ltp
>>
>>
>
> --
> Regards,
> Li Wang
>

-- 
Mailing list info: https://lists.linux.it/listinfo/ltp

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [LTP] [linux-next:master] [block/bdev] 47dd675323: ltp.ioctl_loop06.fail
  2025-03-10 15:08   ` Luis Chamberlain via ltp
@ 2025-03-11  1:43     ` Li Wang
  2025-03-11  3:26       ` Luis Chamberlain via ltp
  0 siblings, 1 reply; 7+ messages in thread
From: Li Wang @ 2025-03-11  1:43 UTC (permalink / raw)
  To: Luis Chamberlain
  Cc: Christian Brauner, 0day robot, Matthew Wilcox (Oracle),
	linux-block, kernel test robot, Hannes Reinecke, oe-lkp, LTP List

On Mon, Mar 10, 2025 at 11:15 PM Luis Chamberlain <mcgrof@kernel.org> wrote:

> There's a fix for this already in next
>

Oh? Which commit?



> On Mon, Mar 10, 2025, 1:36 AM Li Wang <liwang@redhat.com> wrote:
>
>> Hi,
>>
>> The ioctl_loop06 test expects PAGE_SIZE to be the upper limit, but the
>> kernel
>> now allows up to 64K (SZ_64K). If PAGE_SIZE < 64K (e.g., 4K on x86),
>> the test wrongly assumes anything above PAGE_SIZE should be rejected,
>> but the kernel now allows up to 64K.
>>
>> I guess we probably need to adjust testcase to dynamically define an
>> EXPECTED_MAX_BLOCK_SIZE according to kernel versions.
>> I will send out a patch to LTP ML.
>>
>>
>>
>> On Mon, Mar 10, 2025 at 3:41 PM kernel test robot <oliver.sang@intel.com>
>> wrote:
>>
>>>
>>>
>>> Hello,
>>>
>>> kernel test robot noticed "ltp.ioctl_loop06.fail" on:
>>>
>>> commit: 47dd67532303803a87f43195e088b3b4bcf0454d ("block/bdev: lift
>>> block size restrictions to 64k")
>>> https://git.kernel.org/cgit/linux/kernel/git/next/linux-next.git master
>>>
>>> in testcase: ltp
>>> version: ltp-x86_64-0f9d817a3-1_20250222
>>> with following parameters:
>>>
>>>         disk: 1HDD
>>>         fs: xfs
>>>         test: syscalls-01/ioctl_loop06
>>>
>>>
>>>
>>> config: x86_64-rhel-9.4-ltp
>>> compiler: gcc-12
>>> test machine: 4 threads 1 sockets Intel(R) Core(TM) i3-3220 CPU @
>>> 3.30GHz (Ivy Bridge) with 8G memory
>>>
>>> (please refer to attached dmesg/kmsg for entire log/backtrace)
>>>
>>>
>>>
>>>
>>> If you fix the issue in a separate patch/commit (i.e. not just a new
>>> version of
>>> the same patch/commit), kindly add following tags
>>> | Reported-by: kernel test robot <lkp@intel.com>
>>> | Closes:
>>> https://lore.kernel.org/oe-lkp/202503101538.84c33cd4-lkp@intel.com
>>>
>>>
>>> Running tests.......
>>> <<<test_start>>>
>>> tag=ioctl_loop06 stime=1741322388
>>> cmdline="ioctl_loop06"
>>> contacts=""
>>> analysis=exit
>>> <<<test_output>>>
>>> tst_tmpdir.c:316: TINFO: Using
>>> /fs/sda2/tmpdir/ltp-f5uEC1THVm/LTP_iocbBycpj as tmpdir (xfs filesystem)
>>> tst_test.c:1900: TINFO: LTP version: 20250130-118-g0f9d817a3
>>> tst_test.c:1904: TINFO: Tested kernel: 6.14.0-rc1-00007-g47dd67532303 #1
>>> SMP PREEMPT_DYNAMIC Fri Mar  7 11:25:50 CST 2025 x86_64
>>> tst_kconfig.c:88: TINFO: Parsing kernel config '/proc/config.gz'
>>> tst_kconfig.c:676: TINFO: CONFIG_KASAN kernel option detected which
>>> might slow the execution
>>> tst_test.c:1722: TINFO: Overall timeout per run is 0h 10m 00s
>>> tst_device.c:97: TINFO: Found free device 0 '/dev/loop0'
>>> ioctl_loop06.c:74: TINFO: Using LOOP_SET_BLOCK_SIZE with arg < 512
>>> ioctl_loop06.c:65: TPASS: Set block size failed as expected: EINVAL (22)
>>> ioctl_loop06.c:74: TINFO: Using LOOP_SET_BLOCK_SIZE with arg > PAGE_SIZE
>>> ioctl_loop06.c:57: TFAIL: Set block size succeed unexpectedly
>>> ioctl_loop06.c:74: TINFO: Using LOOP_SET_BLOCK_SIZE with arg !=
>>> power_of_2
>>> ioctl_loop06.c:65: TPASS: Set block size failed as expected: EINVAL (22)
>>> ioctl_loop06.c:74: TINFO: Using LOOP_CONFIGURE with block_size < 512
>>> ioctl_loop06.c:65: TPASS: Set block size failed as expected: EINVAL (22)
>>> ioctl_loop06.c:74: TINFO: Using LOOP_CONFIGURE with block_size >
>>> PAGE_SIZE
>>> ioctl_loop06.c:57: TFAIL: Set block size succeed unexpectedly
>>> ioctl_loop06.c:74: TINFO: Using LOOP_CONFIGURE with block_size !=
>>> power_of_2
>>> ioctl_loop06.c:65: TPASS: Set block size failed as expected: EINVAL (22)
>>>
>>> Summary:
>>> passed   4
>>> failed   2
>>> broken   0
>>> skipped  0
>>> warnings 0
>>> incrementing stop
>>> <<<execution_status>>>
>>> initiation_status="ok"
>>> duration=1 termination_type=exited termination_id=1 corefile=no
>>> cutime=0 cstime=6
>>> <<<test_end>>>
>>> INFO: ltp-pan reported some tests FAIL
>>> LTP Version: 20250130-118-g0f9d817a3
>>>
>>>        ###############################################################
>>>
>>>             Done executing testcases.
>>>             LTP Version:  20250130-118-g0f9d817a3
>>>        ###############################################################
>>>
>>>
>>>
>>>
>>> The kernel config and materials to reproduce are available at:
>>>
>>> https://download.01.org/0day-ci/archive/20250310/202503101538.84c33cd4-lkp@intel.com
>>>
>>>
>>>
>>> --
>>> 0-DAY CI Kernel Test Service
>>> https://github.com/intel/lkp-tests/wiki
>>>
>>>
>>> --
>>> Mailing list info: https://lists.linux.it/listinfo/ltp
>>>
>>>
>>
>> --
>> Regards,
>> Li Wang
>>
>

-- 
Regards,
Li Wang

-- 
Mailing list info: https://lists.linux.it/listinfo/ltp

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [LTP] [linux-next:master] [block/bdev] 47dd675323: ltp.ioctl_loop06.fail
  2025-03-11  1:43     ` Li Wang
@ 2025-03-11  3:26       ` Luis Chamberlain via ltp
  2025-03-11 13:09         ` Li Wang
  0 siblings, 1 reply; 7+ messages in thread
From: Luis Chamberlain via ltp @ 2025-03-11  3:26 UTC (permalink / raw)
  To: Li Wang
  Cc: Christian Brauner, 0day robot, Matthew Wilcox (Oracle),
	linux-block, kernel test robot, Hannes Reinecke, oe-lkp, LTP List

On Tue, Mar 11, 2025 at 09:43:42AM +0800, Li Wang wrote:
> On Mon, Mar 10, 2025 at 11:15 PM Luis Chamberlain <mcgrof@kernel.org> wrote:
> 
> > There's a fix for this already in next
> >
> 
> Oh? Which commit?

Oh seems linux-next hasn't been updated in a few days, so you can try
this patch:

https://lore.kernel.org/all/20250307020403.3068567-1-mcgrof@kernel.org/

  Luis

-- 
Mailing list info: https://lists.linux.it/listinfo/ltp

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [LTP] [linux-next:master] [block/bdev] 47dd675323: ltp.ioctl_loop06.fail
  2025-03-11  3:26       ` Luis Chamberlain via ltp
@ 2025-03-11 13:09         ` Li Wang
  2025-03-12  5:00           ` Luis Chamberlain via ltp
  0 siblings, 1 reply; 7+ messages in thread
From: Li Wang @ 2025-03-11 13:09 UTC (permalink / raw)
  To: Luis Chamberlain
  Cc: Christian Brauner, 0day robot, Matthew Wilcox (Oracle),
	linux-block, kernel test robot, Hannes Reinecke, oe-lkp, LTP List

On Tue, Mar 11, 2025 at 11:33 AM Luis Chamberlain <mcgrof@kernel.org> wrote:

> On Tue, Mar 11, 2025 at 09:43:42AM +0800, Li Wang wrote:
> > On Mon, Mar 10, 2025 at 11:15 PM Luis Chamberlain <mcgrof@kernel.org>
> wrote:
> >
> > > There's a fix for this already in next
> > >
> >
> > Oh? Which commit?
>
> Oh seems linux-next hasn't been updated in a few days, so you can try
> this patch:
>
> https://lore.kernel.org/all/20250307020403.3068567-1-mcgrof@kernel.org/


--- a/block/bdev.c
+++ b/block/bdev.c
@@ -181,6 +181,8 @@ EXPORT_SYMBOL(set_blocksize);

 int sb_set_blocksize(struct super_block *sb, int size)
 {
+       if (!(sb->s_type->fs_flags & FS_LBS) && size > PAGE_SIZE)
+               return 0;
        if (set_blocksize(sb->s_bdev_file, size))
                return 0;
...


Thanks, but looking at the code change, seems filesystems with FS_LBS
(e.g., bcachefs, XFS) can still mount larger block sizes properly. IOW,
the test ioctl_loop06 still failed on RHEL9 (XFS) platform.

Is that expected? Or, should we adjust the testcase for FS with FS_LBS
as exception?



-- 
Regards,
Li Wang

-- 
Mailing list info: https://lists.linux.it/listinfo/ltp

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [LTP] [linux-next:master] [block/bdev] 47dd675323: ltp.ioctl_loop06.fail
  2025-03-11 13:09         ` Li Wang
@ 2025-03-12  5:00           ` Luis Chamberlain via ltp
  0 siblings, 0 replies; 7+ messages in thread
From: Luis Chamberlain via ltp @ 2025-03-12  5:00 UTC (permalink / raw)
  To: Li Wang
  Cc: Christian Brauner, 0day robot, Matthew Wilcox (Oracle),
	linux-block, kernel test robot, Hannes Reinecke, oe-lkp, LTP List

On Tue, Mar 11, 2025 at 09:09:08PM +0800, Li Wang wrote:
> On Tue, Mar 11, 2025 at 11:33 AM Luis Chamberlain <mcgrof@kernel.org> wrote:
> 
> > On Tue, Mar 11, 2025 at 09:43:42AM +0800, Li Wang wrote:
> > > On Mon, Mar 10, 2025 at 11:15 PM Luis Chamberlain <mcgrof@kernel.org>
> > wrote:
> > >
> > > > There's a fix for this already in next
> > > >
> > >
> > > Oh? Which commit?
> >
> > Oh seems linux-next hasn't been updated in a few days, so you can try
> > this patch:
> >
> > https://lore.kernel.org/all/20250307020403.3068567-1-mcgrof@kernel.org/
> 
> 
> --- a/block/bdev.c
> +++ b/block/bdev.c
> @@ -181,6 +181,8 @@ EXPORT_SYMBOL(set_blocksize);
> 
>  int sb_set_blocksize(struct super_block *sb, int size)
>  {
> +       if (!(sb->s_type->fs_flags & FS_LBS) && size > PAGE_SIZE)
> +               return 0;
>         if (set_blocksize(sb->s_bdev_file, size))
>                 return 0;
> ...
> 
> 
> Thanks, but looking at the code change, seems filesystems with FS_LBS
> (e.g., bcachefs, XFS) can still mount larger block sizes properly. IOW,
> the test ioctl_loop06 still failed on RHEL9 (XFS) platform.

The test does not fail because the filesystem being used, the test fails
because it expects setting the block size > PAGE_SIZE will fail for the
loop back device it is creating and then setting the block size for it.

There are two tests which fail:

  * set block size > PAGE_SIZE with LOOP_SET_BLOCK_SIZE
  * set block size > PAGE_SIZE with LOOP_CONFIGURE

It expects to fail. The new work enables the block layer to support
block sizes > PAGE_SIZE on block devices, essentially that the logical
or physical block size can be > PAGE_SIZE. That is supported now.

> Is that expected? Or, should we adjust the testcase for FS with FS_LBS
> as exception?

Contrary to filesystems, block drivers use now implicitly use
blk_validate_limits() through queue_limits_commit_update to validate
queue limits, but PAGE_SIZE is no longer an issue. In the loop back driver
case we have then:

ioctl LOOP_CONFIGURE --> loop_configure() 
	lim = queue_limits_start_update(lo->lo_queue);                           
	loop_update_limits(lo, &lim, config->block_size); 

ioctl LOOP_SET_BLOCK_SIZE --> loop_set_block_size()
	lim = queue_limits_start_update(lo->lo_queue);                           
	loop_update_limits(lo, &lim, arg); 

I don't see anything wrong with the loop driver supporting logical block
sizes > PAGE_SIZE, from a quick look, but it does not matter. If tests
exists which are verifying you *can't* do it, then we're bound to get
other similar reports. queue_limits_commit_update() calls
blk_validate_block_size. I just sent a fix.

Thanks for the report.

  Luis

-- 
Mailing list info: https://lists.linux.it/listinfo/ltp

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2025-03-12  5:01 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-03-10  7:40 [LTP] [linux-next:master] [block/bdev] 47dd675323: ltp.ioctl_loop06.fail kernel test robot
2025-03-10  8:36 ` Li Wang
2025-03-10 15:08   ` Luis Chamberlain via ltp
2025-03-11  1:43     ` Li Wang
2025-03-11  3:26       ` Luis Chamberlain via ltp
2025-03-11 13:09         ` Li Wang
2025-03-12  5:00           ` Luis Chamberlain via ltp

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox