From: Seung-Woo Kim <sw0312.kim@samsung.com>
To: Seung-Woo Kim <sw0312.kim@samsung.com>
Cc: linux@armlinux.org.uk, linux-arm-kernel@lists.infradead.org,
linux-kernel@vger.kernel.org, aryabinin@virtuozzo.com,
arnd@arndb.de
Subject: UBSAN: Undefined behaviour in ./arch/arm/include/asm/bitops.h
Date: Sat, 24 Sep 2016 13:45:33 +0900 [thread overview]
Message-ID: <57E604ED.6000408@samsung.com> (raw)
In-Reply-To: <1474519757-10228-1-git-send-email-sw0312.kim@samsung.com>
With the patch "arm: ubsan: select ARCH_HAS_UBSAN_SANITIZE_ALL", I got
following UBSAN warning on Exynos5422 SoC board.
================================================================================
UBSAN: Undefined behaviour in ./arch/arm/include/asm/bitops.h:296:17
negation of -2147483648 cannot be represented in type 'int':
CPU: 2 PID: 5637 Comm: fsck.ext4 Tainted: G W
4.8.0-rc7-00173-g142932f #25
Hardware name: SAMSUNG EXYNOS (Flattened Device Tree)
[<c0119e28>] (unwind_backtrace) from [<c01123dc>] (show_stack+0x20/0x24)
[<c01123dc>] (show_stack) from [<c0617f70>] (dump_stack+0x84/0xa0)
[<c0617f70>] (dump_stack) from [<c0672ba0>] (ubsan_epilogue+0x14/0x50)
[<c0672ba0>] (ubsan_epilogue) from [<c067335c>]
(__ubsan_handle_negate_overflow+0x68/0x6c)
[<c067335c>] (__ubsan_handle_negate_overflow) from [<c0621044>]
(radix_tree_next_chunk+0x4e8/0x5ac)
[<c0621044>] (radix_tree_next_chunk) from [<c0286abc>]
(find_get_pages_tag+0x1b0/0x390)
[<c0286abc>] (find_get_pages_tag) from [<c02a6154>]
(pagevec_lookup_tag+0x38/0x68)
[<c02a6154>] (pagevec_lookup_tag) from [<c029e818>]
(write_cache_pages+0x134/0x85c)
[<c029e818>] (write_cache_pages) from [<c029ef9c>]
(generic_writepages+0x5c/0x9c)
[<c029ef9c>] (generic_writepages) from [<c038eae8>]
(blkdev_writepages+0x18/0x1c)
[<c038eae8>] (blkdev_writepages) from [<c02a2054>] (do_writepages+0x58/0xa4)
[<c02a2054>] (do_writepages) from [<c0289abc>]
(__filemap_fdatawrite_range+0xac/0x10c)
[<c0289abc>] (__filemap_fdatawrite_range) from [<c0289cc8>]
(filemap_write_and_wait_range+0x54/0xb8)
[<c0289cc8>] (filemap_write_and_wait_range) from [<c038f75c>]
(blkdev_fsync+0x40/0xa4)
[<c038f75c>] (blkdev_fsync) from [<c0381bf0>] (vfs_fsync_range+0x70/0x160)
[<c0381bf0>] (vfs_fsync_range) from [<c0381d68>] (do_fsync+0x4c/0x74)
[<c0381d68>] (do_fsync) from [<c038224c>] (SyS_fsync+0x1c/0x20)
[<c038224c>] (SyS_fsync) from [<c010bd20>] (ret_fast_syscall+0x0/0x3c)
================================================================================
================================================================================
UBSAN: Undefined behaviour in ./arch/arm/include/asm/bitops.h:296:17
negation of -2147483648 cannot be represented in type 'int':
CPU: 3 PID: 6313 Comm: enlightenment Tainted: G W
4.8.0-rc7-00173-g142932f #25
Hardware name: SAMSUNG EXYNOS (Flattened Device Tree)
[<c0119e28>] (unwind_backtrace) from [<c01123dc>] (show_stack+0x20/0x24)
[<c01123dc>] (show_stack) from [<c0617f10>] (dump_stack+0x84/0xa0)
[<c0617f10>] (dump_stack) from [<c0672b40>] (ubsan_epilogue+0x14/0x50)
[<c0672b40>] (ubsan_epilogue) from [<c06732fc>]
(__ubsan_handle_negate_overflow+0x68/0x6c)
[<c06732fc>] (__ubsan_handle_negate_overflow) from [<c0147f54>]
(next_signal+0x114/0x16c)
[<c0147f54>] (next_signal) from [<c0147fdc>] (dequeue_signal+0x30/0x30c)
[<c0147fdc>] (dequeue_signal) from [<c014cb58>] (get_signal+0x120/0xe84)
[<c014cb58>] (get_signal) from [<c01114fc>] (do_signal+0x37c/0x550)
[<c01114fc>] (do_signal) from [<c01119b8>] (do_work_pending+0xd0/0x134)
[<c01119b8>] (do_work_pending) from [<c010bd74>]
(slow_work_pending+0xc/0x20)
================================================================================
Regards,
- Seung-Woo Kim
--
Seung-Woo Kim
Samsung Software R&D Center
--
next prev parent reply other threads:[~2016-09-24 4:45 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <CGME20160922045043epcas1p2e275276a65b244a5a013842597fcc0f1@epcas1p2.samsung.com>
2016-09-22 4:49 ` [PATCH] arm: ubsan: select ARCH_HAS_UBSAN_SANITIZE_ALL Seung-Woo Kim
2016-09-22 4:49 ` Seung-Woo Kim
2016-09-24 4:45 ` Seung-Woo Kim [this message]
2016-09-24 9:15 ` UBSAN: Undefined behaviour in ./arch/arm/include/asm/bitops.h Russell King - ARM Linux
2016-09-24 9:15 ` Russell King - ARM Linux
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=57E604ED.6000408@samsung.com \
--to=sw0312.kim@samsung.com \
--cc=arnd@arndb.de \
--cc=aryabinin@virtuozzo.com \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux@armlinux.org.uk \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.