From: b.zolnierkie@samsung.com (Bartlomiej Zolnierkiewicz)
Subject: [Linux-kernel-mentees] [PATCH v3] video: atmel_lcdc: Fix Shifting signed 32 bit value by 31 bits problem
Date: Mon, 19 Aug 2019 16:29:12 +0200 [thread overview]
Message-ID: <75a65eae-2fb3-6326-abe6-03dcfa04bd37@samsung.com> (raw)
Message-ID: <20190819142912.TGoKAdOMt8WTP79SLSueMP697LVp80HyWZfekJLTiU8@z> (raw)
In-Reply-To: <1563756160-29702-1-git-send-email-shobhitkukreti@gmail.com>
Hi,
On 7/22/19 2:42 AM, Shobhit Kukreti wrote:
> Fix ATMEL_LCDC_MEMOR and ATMEL_LCDC_MEMOR_LITTLE defines to use "U"
> cast to avoid shifting signed 32 bit values by 31 bit problem. This
> problem. This is not a problem for gcc built kernel.
>
> However, this may be a problem since the header is part of pbulic API
> which could be included for builds using compilers which do not handle
> this condition safely resulting in undefined behavior
>
> Signed-off-by: Shobhit Kukreti <shobhitkukreti at gmail.com>
> ---
> Changes in v3:
> Replace Bit Shift Operations with BIT() macros
1. Please update the patch summary & description to reflect that,
please see commit 13990cf8a180 for the reference:
commit 13990cf8a180cc070f0b1266140e799db8754289
Author: Amol Surati <suratiamol at gmail.com>
Date: Sun Jul 7 14:27:29 2019 +0530
ide: use BIT() macro for defining bit-flags
The BIT() macro is available for defining the required bit-flags.
Since it operates on an unsigned value and expands to an unsigned result,
using it, instead of an expression like (1 << x), also fixes the problem
of shifting a signed 32-bit value by 31 bits (e.g. 1 << 31).
Signed-off-by: Amol Surati <suratiamol at gmail.com>
Signed-off-by: David S. Miller <davem at davemloft.net>
2. Please update Cc: list of your mail by all mailing lists returned by
./scripts/get_maintainer.pl:
$ ./scripts/get_maintainer.pl -f include/video/atmel_lcdc.h
Nicolas Ferre <nicolas.ferre at microchip.com> (maintainer:MICROCHIP LCDFB DRIVER)
Bartlomiej Zolnierkiewicz <b.zolnierkie at samsung.com> (maintainer:FRAMEBUFFER LAYER)
Alexandre Belloni <alexandre.belloni at bootlin.com> (supporter:ARM/Microchip (AT91) SoC support)
Ludovic Desroches <ludovic.desroches at microchip.com> (supporter:ARM/Microchip (AT91) SoC support)
linux-fbdev at vger.kernel.org (open list:MICROCHIP LCDFB DRIVER)
dri-devel at lists.freedesktop.org (open list:FRAMEBUFFER LAYER)
linux-arm-kernel at lists.infradead.org (moderated list:ARM/Microchip (AT91) SoC support)
linux-kernel at vger.kernel.org (open list)
> Changes in v2:
> Fixed spelling typo
>
> include/video/atmel_lcdc.h | 28 ++++++++++++++--------------
> 1 file changed, 14 insertions(+), 14 deletions(-)
Best regards,
--
Bartlomiej Zolnierkiewicz
Samsung R&D Institute Poland
Samsung Electronics
next prev parent reply other threads:[~2019-08-19 14:29 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-07-06 17:41 [Linux-kernel-mentees] [PATCH] video: atmel_lcdc: Fix Shifting signed 32 bit value by 31 bits problem shobhitkukreti
2019-07-06 17:41 ` Shobhit Kukreti
2019-07-06 18:28 ` [Linux-kernel-mentees] [PATCH v2] " shobhitkukreti
2019-07-06 18:28 ` shobhitkukreti
2019-07-15 11:33 ` b.zolnierkie
2019-07-15 11:33 ` Bartlomiej Zolnierkiewicz
2019-07-22 0:42 ` [Linux-kernel-mentees] [PATCH v3] " shobhitkukreti
2019-07-22 0:42 ` Shobhit Kukreti
2019-08-19 14:29 ` b.zolnierkie [this message]
2019-08-19 14:29 ` Bartlomiej Zolnierkiewicz
2020-01-08 13:08 ` Nicolas.Ferre
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=75a65eae-2fb3-6326-abe6-03dcfa04bd37@samsung.com \
--to=b.zolnierkie@samsung.com \
/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).