lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Thu, 23 Jul 2020 19:56:32 -0700
From:   Randy Dunlap <rdunlap@...radead.org>
To:     Roy Im <roy.im.opensource@...semi.com>,
        Uwe Kleine-Koenig <u.kleine-koenig@...gutronix.de>,
        Bartosz Golaszewski <bgolaszewski@...libre.com>,
        Brian Masney <masneyb@...tation.org>,
        Dmitry Torokhov <dmitry.torokhov@...il.com>,
        Greg KH <gregkh@...uxfoundation.org>,
        Lee Jones <lee.jones@...aro.org>, Luca Weiss <luca@...tu.xyz>,
        Maximilian Luz <luzmaximilian@...il.com>,
        Pascal PAILLET-LME <p.paillet@...com>,
        Rob Herring <robh@...nel.org>,
        Samuel Ortiz <sameo@...ux.intel.com>,
        Thierry Reding <thierry.reding@...il.com>,
        Thomas Gleixner <tglx@...utronix.de>
Cc:     Support Opensource <Support.Opensource@...semi.com>,
        "linux-input@...r.kernel.org" <linux-input@...r.kernel.org>,
        "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
        "linux-pwm@...r.kernel.org" <linux-pwm@...r.kernel.org>
Subject: Re: [PATCH V17 3/3] Input: new da7280 haptic driver

On 7/23/20 6:54 PM, Roy Im wrote:
> On Fri, July 24, 2020 5:51 AM, Randy Dunlap wrote
>> On 7/23/20 8:01 AM, Roy Im wrote:
>>> diff --git a/drivers/input/misc/Kconfig b/drivers/input/misc/Kconfig
>>> index 362e8a0..06dc5a3 100644
>>> --- a/drivers/input/misc/Kconfig
>>> +++ b/drivers/input/misc/Kconfig
>>> @@ -869,4 +869,17 @@ config INPUT_STPMIC1_ONKEY
>>>  	  To compile this driver as a module, choose M here: the
>>>  	  module will be called stpmic1_onkey.
>>>
>>> +config INPUT_DA7280_HAPTICS
>>> +	tristate "Dialog Semiconductor DA7280 haptics support"
>>> +	depends on INPUT && I2C
>>> +	select INPUT_FF_MEMLESS
>>> +	select REGMAP_I2C
>>> +	help
>>> +	  Say Y to enable support for the Dialog DA7280 haptics driver.
>>> +	  The haptics can be controlled by I2C communication,
>>> +	  or by PWM input, or by GPI.
>>
>> 	  Is that                GPIO.
>> ?
> The Haptics can be working by GPI(if see from the haptic device), but from the Host it is GPO. Do you think the GPIO is correct?

To me it needs to represent what services/interfaces/facilities are used by this driver that are
provided by the Linux kernel.  If it uses Linux GPIO services, then it should say GPIO --
although I don't see it using any Linux GPIO services.

>>
>> Can the haptics be controlled only by PWM or only by GPI(O)?
>>
>> Just curious: why is I2C required to build the driver if a user is only controlling the device by PWM or GPI?
> 
> I2C is required to control registers and it can be triggered by I2C or PWM or GPI(controlled by host outside this driver), so PWM and GPI are optional.
> With your comments, I think it's better to remove below lines(//remove) to avoid confusion and add PWM as below if you agree.
>          // remove
> 	  The haptics can be controlled by I2C communication,
> 	  or by PWM input, or by GPI.
>          // update, adding || PWM
>          depends on (INPUT && I2C) || PWM

Since <linux/pwm.h> provides stubs for when CONFIG_PWM is not enabled,
it appears that "depends on  PWM" is not required.

I'll leave it up to you. I was just trying to understand better.
It may be that no changes are needed.


thanks.
-- 
~Randy

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ