Linux Input/HID development
 help / color / mirror / Atom feed
From: Jiri Kosina <jikos@kernel.org>
To: Hans de Goede <hdegoede@redhat.com>
Cc: Benjamin Tissoires <benjamin.tissoires@redhat.com>,
	linux-input@vger.kernel.org
Subject: Re: [PATCH 3/6] HID: asus: Add hid_is_using_ll_driver(usb_hid_driver) check
Date: Tue, 5 May 2020 16:32:30 +0200 (CEST)	[thread overview]
Message-ID: <nycvar.YFH.7.76.2005051631560.25812@cbobk.fhfr.pm> (raw)
In-Reply-To: <20200428142254.252063-3-hdegoede@redhat.com>

On Tue, 28 Apr 2020, Hans de Goede wrote:

> Add a hid_is_using_ll_driver(usb_hid_driver) check to ensure that the
> parent device is an usb_interface, before casting the parent device
> pointer to an usb_interface pointer with to_usb_interface().
> 
> Signed-off-by: Hans de Goede <hdegoede@redhat.com>
> ---
>  drivers/hid/hid-asus.c | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
> 
> diff --git a/drivers/hid/hid-asus.c b/drivers/hid/hid-asus.c
> index b3292ff3f61a..719eff589f92 100644
> --- a/drivers/hid/hid-asus.c
> +++ b/drivers/hid/hid-asus.c
> @@ -842,7 +842,8 @@ static int asus_probe(struct hid_device *hdev, const struct hid_device_id *id)
>  	if (drvdata->quirks & QUIRK_IS_MULTITOUCH)
>  		drvdata->tp = &asus_i2c_tp;
>  
> -	if (drvdata->quirks & QUIRK_T100_KEYBOARD) {
> +	if ((drvdata->quirks & QUIRK_T100_KEYBOARD) &&
> +	    hid_is_using_ll_driver(hdev, &usb_hid_driver)) {
>  		struct usb_interface *intf = to_usb_interface(hdev->dev.parent);
>  

I am going to push the whole patchset to for-5.8/asus branch later today, 
but I guess this one should better be taken as 5.7 fix still, right?

Thanks,

-- 
Jiri Kosina
SUSE Labs


  reply	other threads:[~2020-05-05 14:32 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-04-28 14:22 [PATCH 1/6] HID: asus: Only set EV_REP if we are adding a mapping Hans de Goede
2020-04-28 14:22 ` [PATCH 2/6] HID: asus: Simplify skipping of mappings for Asus T100CHI keyboard-dock Hans de Goede
2020-04-28 14:22 ` [PATCH 3/6] HID: asus: Add hid_is_using_ll_driver(usb_hid_driver) check Hans de Goede
2020-05-05 14:32   ` Jiri Kosina [this message]
2020-05-06  8:41     ` Hans de Goede
2020-05-06  9:42       ` Jiri Kosina
2020-04-28 14:22 ` [PATCH 4/6] HID: asus: Add report_size to struct asus_touchpad_info Hans de Goede
2020-04-28 14:22 ` [PATCH 5/6] HID: asus: Add support for multi-touch touchpad on Medion Akoya E1239T Hans de Goede
2020-04-28 14:22 ` [PATCH 6/6] HID: asus: Fix mute and touchpad-toggle keys " Hans de Goede

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=nycvar.YFH.7.76.2005051631560.25812@cbobk.fhfr.pm \
    --to=jikos@kernel.org \
    --cc=benjamin.tissoires@redhat.com \
    --cc=hdegoede@redhat.com \
    --cc=linux-input@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox