From: linux@armlinux.org.uk (Russell King - ARM Linux)
To: linux-arm-kernel@lists.infradead.org
Subject: UBSAN: Undefined behaviour in ./arch/arm/include/asm/bitops.h
Date: Sat, 24 Sep 2016 10:15:15 +0100 [thread overview]
Message-ID: <20160924091515.GD1041@n2100.armlinux.org.uk> (raw)
In-Reply-To: <57E604ED.6000408@samsung.com>
On Sat, Sep 24, 2016 at 01:45:33PM +0900, Seung-Woo Kim wrote:
> With the patch "arm: ubsan: select ARCH_HAS_UBSAN_SANITIZE_ALL", I got
> following UBSAN warning on Exynos5422 SoC board.
Well, the simple solution is to have fls() and ffs() take unsigned int
arguments rather than ints - but the question that brings up is: why
do both of these take signed ints? It seems at least to me that it
would be more sensible for these to take unsigned int, or even
unsigned long like the other bitops do.
--
RMK's Patch system: http://www.armlinux.org.uk/developer/patches/
FTTC broadband for 0.8mile line: currently at 9.6Mbps down 400kbps up
according to speedtest.net.
prev parent reply other threads:[~2016-09-24 9:15 UTC|newest]
Thread overview: 2+ 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
[not found] ` <57E604ED.6000408@samsung.com>
2016-09-24 9:15 ` Russell King - ARM Linux [this message]
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=20160924091515.GD1041@n2100.armlinux.org.uk \
--to=linux@armlinux.org.uk \
--cc=linux-arm-kernel@lists.infradead.org \
/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 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).