From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.7 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id BB5A2C433FE for ; Wed, 9 Dec 2020 15:39:17 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 7F12022B39 for ; Wed, 9 Dec 2020 15:39:17 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728209AbgLIPjF (ORCPT ); Wed, 9 Dec 2020 10:39:05 -0500 Received: from mail-40137.protonmail.ch ([185.70.40.137]:11015 "EHLO mail-40137.protonmail.ch" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726278AbgLIPjE (ORCPT ); Wed, 9 Dec 2020 10:39:04 -0500 X-Greylist: delayed 63525 seconds by postgrey-1.27 at vger.kernel.org; Wed, 09 Dec 2020 10:39:03 EST Date: Wed, 09 Dec 2020 15:38:11 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=protonmail.com; s=protonmail; t=1607528297; bh=wdJCyYk1f38GX5JvsezuTqDeFPgJXHx/BdZltjPklBA=; h=Date:To:From:Cc:Reply-To:Subject:In-Reply-To:References:From; b=ZzIQYxx70gKFm2N/jzgQd3dZxYzeo+dyYLsbsRTILwu3UiKgA9juRLSpncZiWsDMB P2ul/Csk1luCpRbSfHaXglKka7qPcm5NY72u5vCNJFxw+g5PJxPCgwYGZ+72l41m00 4UNU+Brvu31D/+9aO4IyT/TlSjMDdmbHXTrCAenQ= To: Greg KH From: =?utf-8?Q?Barnab=C3=A1s_P=C5=91cze?= Cc: Coiby Xu , "linux-input@vger.kernel.org" , Helmut Stult , Baq Domalaq , Pedro Ribeiro , "stable@vger.kernel.org" , Jiri Kosina , Benjamin Tissoires , open list Reply-To: =?utf-8?Q?Barnab=C3=A1s_P=C5=91cze?= Subject: Re: [PATCH v4] HID: i2c-hid: add polling mode based on connected GPIO chip's pin status Message-ID: In-Reply-To: References: <20201125141022.321643-1-coiby.xu@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-input@vger.kernel.org 2020. december 9., szerda 8:00 keltez=C3=A9ssel, Greg KH =C3=ADrta: > On Tue, Dec 08, 2020 at 09:59:20PM +0000, Barnab=C3=A1s P=C5=91cze wrote: > > > 2020. november 25., szerda 16:07 keltez=C3=A9ssel, Greg KH =C3=ADrta: > > > > > [...] > > > > > > > +static u8 polling_mode; > > > > +module_param(polling_mode, byte, 0444); > > > > +MODULE_PARM_DESC(polling_mode, "How to poll (default=3D0) - 0 disa= bled; 1 based on GPIO pin's status"); > > > > > > Module parameters are for the 1990's, they are global and horrible to > > > try to work with. You should provide something on a per-device basis, > > > as what happens if your system requires different things here for > > > different devices? You set this for all devices :( > > > [...] > > > > Hi > > do you think something like what the usbcore has would be better? > > A module parameter like "quirks=3D::[,::]*"? > > Not really, that's just for debugging, and asking users to test > something, not for a final solution to anything. My understanding is that this polling mode option is by no means intended as a final solution, it's purely for debugging/fallback: "Polling mode could be a fallback solution for enthusiastic Linux users when they have a new laptop. It also acts like a debugging feature. If polling mode works for a broken touchpad, we can almost be certain the root cause is related to the interrupt or power setting." What would you suggest instead of the module parameter? Regards, Barnab=C3=A1s P=C5=91cze