From: "Tomasz Pakuła" <tomasz.pakula.oficjalny@gmail.com>
To: Markus Elfring <Markus.Elfring@web.de>,
linux-input@vger.kernel.org,
Benjamin Tissoires <bentiss@kernel.org>,
Jiri Kosina <jikos@kernel.org>
Cc: LKML <linux-kernel@vger.kernel.org>, Oleg Makarenko <oleg@makarenk.ooo>
Subject: Re: [PATCH] HID: pidff: Fix integer overflow in pidff_rescale
Date: Sun, 26 Apr 2026 21:57:31 +0200 [thread overview]
Message-ID: <25715cc23884f74a7417ba53ba144cbb7f675293.camel@gmail.com> (raw)
In-Reply-To: <dd6e5b2c-700e-444d-a9e5-8794c0ff8e34@web.de>
On Sun, 2026-04-26 at 12:48 +0200, Markus Elfring wrote:
> > Rescaling values close to the max (U16_MAX) temporairly creates values
> …
> temporarily?
>
>
> See also:
> https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/Documentation/process/submitting-patches.rst?h=v7.0#n145
>
> Regards,
> Markus
I don't quite understand the point. I'm aware of the error but didn't
have time to look onto it yet. I probably just need to switch to the
division functions exposed by the kernel.
As far as the other stuff you mentioned, I don't get it. I don't think
it would make sense to mention the 20 yo commit that added this driver.
As far as the temporary status of the value. It only exceeds the s32
range after the multiplication, and is reduced right after, during
division. I think "temporarily" applies here perfectly?
Maybe I'm not seeing something here, please elaborate so I can fix it :D
Tomasz
next prev parent reply other threads:[~2026-04-26 19:57 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-04-21 19:49 [PATCH] HID: pidff: Fix integer overflow in pidff_rescale Tomasz Pakuła
2026-04-26 5:31 ` kernel test robot
2026-04-26 10:48 ` Markus Elfring
2026-04-26 19:57 ` Tomasz Pakuła [this message]
2026-04-27 7:03 ` Markus Elfring
2026-04-26 12:35 ` [PATCH] " kernel test robot
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=25715cc23884f74a7417ba53ba144cbb7f675293.camel@gmail.com \
--to=tomasz.pakula.oficjalny@gmail.com \
--cc=Markus.Elfring@web.de \
--cc=bentiss@kernel.org \
--cc=jikos@kernel.org \
--cc=linux-input@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=oleg@makarenk.ooo \
/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