All of lore.kernel.org
 help / color / mirror / Atom feed
From: Dmitry Torokhov <dmitry.torokhov@gmail.com>
To: linux-input@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] Input: joydev - replace ev_match boolean with goto for early exit
Date: Sat, 11 Jul 2026 15:47:48 -0700	[thread overview]
Message-ID: <alLH3-MqJwM_djak@google.com> (raw)
In-Reply-To: <ak8hKSa9HNYPoOZZ@thesun>

Hi Ashton,

On Thu, Jul 09, 2026 at 04:18:49PM +1200, Ashton Warner wrote:
> The joydev_dev_is_absolute_mouse runs unnecessary Event type checks to
> determine whether a joydev device is an absolute mouse. Change ev_match
> to a goto statement to exit early.
> 
> Signed-off-by: Ashton Warner <drflamemontgomery@gmail.com>

I think this is one of the cases where I'd avoid using goto. The extra
computation is not in hot path and will be unnoticeable. 

Thanks.

-- 
Dmitry

      reply	other threads:[~2026-07-11 22:47 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-07-09  4:18 [PATCH] Input: joydev - replace ev_match boolean with goto for early exit Ashton Warner
2026-07-11 22:47 ` Dmitry Torokhov [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=alLH3-MqJwM_djak@google.com \
    --to=dmitry.torokhov@gmail.com \
    --cc=linux-input@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.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 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.