linux-kselftest.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Re: ext4: add kunit test for decoding extended timestamps
       [not found] <git-mailbomb-linux-master-1cbeab1b242d16fdb22dc3dab6a7d6afe746ae6d@kernel.org>
@ 2019-11-26 13:15 ` Geert Uytterhoeven
  2019-11-27  0:10   ` Iurii Zaikin
  0 siblings, 1 reply; 2+ messages in thread
From: Geert Uytterhoeven @ 2019-11-26 13:15 UTC (permalink / raw)
  To: Iurii Zaikin
  Cc: Shuah Khan, Brendan Higgins, Theodore Tso, Ext4 Developers List,
	Linux Kernel Mailing List, open list:KERNEL SELFTEST FRAMEWORK

Hi Lurii,

On Tue, Nov 26, 2019 at 3:12 AM Linux Kernel Mailing List
<linux-kernel@vger.kernel.org> wrote:
> Commit:     1cbeab1b242d16fdb22dc3dab6a7d6afe746ae6d
> Parent:     d460623c5fa126dc51bb2571dd7714ca75b0116c
> Refname:    refs/heads/master
> Web:        https://git.kernel.org/torvalds/c/1cbeab1b242d16fdb22dc3dab6a7d6afe746ae6d
> Author:     Iurii Zaikin <yzaikin@google.com>
> AuthorDate: Thu Oct 17 15:12:33 2019 -0700
> Committer:  Shuah Khan <skhan@linuxfoundation.org>
> CommitDate: Wed Oct 23 10:28:23 2019 -0600
>
>     ext4: add kunit test for decoding extended timestamps
>
>     KUnit tests for decoding extended 64 bit timestamps that verify the
>     seconds part of [a/c/m] timestamps in ext4 inode structs are decoded
>     correctly.
>
>     Test data is derived from the table in the Inode Timestamps section of
>     Documentation/filesystems/ext4/inodes.rst.
>
>     KUnit tests run during boot and output the results to the debug log
>     in TAP format (http://testanything.org/). Only useful for kernel devs
>     running KUnit test harness and are not for inclusion into a production
>     build.
>
>     Signed-off-by: Iurii Zaikin <yzaikin@google.com>
>     Reviewed-by: Theodore Ts'o <tytso@mit.edu>
>     Reviewed-by: Brendan Higgins <brendanhiggins@google.com>
>     Tested-by: Brendan Higgins <brendanhiggins@google.com>
>     Reviewed-by: Shuah Khan <skhan@linuxfoundation.org>
>     Signed-off-by: Shuah Khan <skhan@linuxfoundation.org>

While this test succeeds on arm64, it fails on m68k and arm32 (presumably
all 32-bit platforms?):

# Subtest: ext4_inode_test
1..1
# inode_test_xtimestamp_decoding: EXPECTATION FAILED at fs/ext4/inode-test.c:250
Expected test_data[i].expected.tv_sec == timestamp.tv_sec, but
test_data[i].expected.tv_sec == -2147483648
timestamp.tv_sec == 2147483648
1901-12-13 Lower bound of 32bit < 0 timestamp, no extra bits: msb:1
lower_bound:1 extra_bits: 0
# inode_test_xtimestamp_decoding: EXPECTATION FAILED at fs/ext4/inode-test.c:250
Expected test_data[i].expected.tv_sec == timestamp.tv_sec, but
test_data[i].expected.tv_sec == 2147483648
timestamp.tv_sec == 6442450944
2038-01-19 Lower bound of 32bit <0 timestamp, lo extra sec bit on:
msb:1 lower_bound:1 extra_bits: 1
# inode_test_xtimestamp_decoding: EXPECTATION FAILED at fs/ext4/inode-test.c:250
Expected test_data[i].expected.tv_sec == timestamp.tv_sec, but
test_data[i].expected.tv_sec == 6442450944
timestamp.tv_sec == 10737418240
2174-02-25 Lower bound of 32bit <0 timestamp, hi extra sec bit on:
msb:1 lower_bound:1 extra_bits: 2
not ok 1 - inode_test_xtimestamp_decoding
not ok 1 - ext4_inode_test

Gr{oetje,eeting}s,

                        Geert

-- 
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org

In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
                                -- Linus Torvalds

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

* Re: ext4: add kunit test for decoding extended timestamps
  2019-11-26 13:15 ` ext4: add kunit test for decoding extended timestamps Geert Uytterhoeven
@ 2019-11-27  0:10   ` Iurii Zaikin
  0 siblings, 0 replies; 2+ messages in thread
From: Iurii Zaikin @ 2019-11-27  0:10 UTC (permalink / raw)
  To: Geert Uytterhoeven
  Cc: Shuah Khan, Brendan Higgins, Theodore Tso, Ext4 Developers List,
	Linux Kernel Mailing List, open list:KERNEL SELFTEST FRAMEWORK

On Tue, Nov 26, 2019 at 5:15 AM Geert Uytterhoeven <geert@linux-m68k.org> wrote:

> While this test succeeds on arm64, it fails on m68k and arm32 (presumably
> all 32-bit platforms?):
:(
Reproducible on i386 too.
Sending the patch to fix it.

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

end of thread, other threads:[~2019-11-27  0:11 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <git-mailbomb-linux-master-1cbeab1b242d16fdb22dc3dab6a7d6afe746ae6d@kernel.org>
2019-11-26 13:15 ` ext4: add kunit test for decoding extended timestamps Geert Uytterhoeven
2019-11-27  0:10   ` Iurii Zaikin

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).