Re: [PATCH 1/3] dt-bindings: input: Add DT bindings for Whiskers switch

2019-10-18 Thread Dmitry Torokhov
Hi Ikjoon, On Thu, Oct 17, 2019 at 8:10 PM Ikjoon Jang wrote: > > A gentle ping on adding DT binding for Hammer (1/2). DT bindings need to be sent to devicet...@vger.kernel.org and Rob Herring Thanks, Dmitry

[PATCH 07/22] Input: jornada680_kbd - switch to using polled mode of input devices

2019-10-17 Thread Dmitry Torokhov
We have added polled mode to the normal input devices with the intent of retiring input_polled_dev. This converts jornada680_kbd driver to use the polling mode of standard input devices and removes dependency on INPUT_POLLDEV. Signed-off-by: Dmitry Torokhov --- drivers/input/keyboard/Kconfig

[PATCH 05/22] Input: adc-keys - switch to using polled mode of input devices

2019-10-17 Thread Dmitry Torokhov
We have added polled mode to the normal input devices with the intent of retiring input_polled_dev. This converts adc-keys driver to use the polling mode of standard input devices and removes dependency on INPUT_POLLDEV. Signed-off-by: Dmitry Torokhov --- drivers/input/keyboard/Kconfig| 1

[PATCH 17/22] Input: gpio_decoder - switch to using polled mode of input devices

2019-10-17 Thread Dmitry Torokhov
We have added polled mode to the normal input devices with the intent of retiring input_polled_dev. This converts gpio_decoder driver to use the polling mode of standard input devices and removes dependency on INPUT_POLLDEV. Signed-off-by: Dmitry Torokhov --- drivers/input/misc/Kconfig

[PATCH 08/22] Input: gpio_keys_polled - switch to using polled mode of input devices

2019-10-17 Thread Dmitry Torokhov
separate, as they are different enough and mixing them up would make the code pretty confusing. Signed-off-by: Dmitry Torokhov --- drivers/input/keyboard/Kconfig| 1 - drivers/input/keyboard/gpio_keys_polled.c | 65 --- 2 files changed, 34 insertions(+), 32 deletions

[PATCH 14/22] Input: sgi_btns - switch to using polled mode of input devices

2019-10-17 Thread Dmitry Torokhov
We have added polled mode to the normal input devices with the intent of retiring input_polled_dev. This converts sgi_btns driver to use the polling mode of standard input devices and removes dependency on INPUT_POLLDEV. Signed-off-by: Dmitry Torokhov --- drivers/input/misc/Kconfig| 1

[PATCH 15/22] Input: rb532_button - switch to using managed resources

2019-10-17 Thread Dmitry Torokhov
Using devm API allows us to clean up error handling paths and drop the remove() method. Signed-off-by: Dmitry Torokhov --- drivers/input/misc/rb532_button.c | 20 ++-- 1 file changed, 2 insertions(+), 18 deletions(-) diff --git a/drivers/input/misc/rb532_button.c b/drivers

[PATCH 21/22] Input: kxtj9 - switch to using managed resources

2019-10-17 Thread Dmitry Torokhov
Using devm API allows to clean up error handling and drop the remove() method. Signed-off-by: Dmitry Torokhov --- drivers/input/misc/kxtj9.c | 86 +- 1 file changed, 28 insertions(+), 58 deletions(-) diff --git a/drivers/input/misc/kxtj9.c b/drivers/input

[PATCH 19/22] Input: bma150 - use managed resources helpers

2019-10-17 Thread Dmitry Torokhov
From: Jonathan Bakker The driver can be cleaned up by using managed resource helpers. Signed-off-by: Jonathan Bakker Signed-off-by: Paweł Chmiel Patchwork-Id: 10794333 [dtor: do not explicitly set parent of input device since we are using devm] Signed-off-by: Dmitry Torokhov --- drivers

[PATCH 11/22] Input: cobalt_btns - convert to use managed resources

2019-10-17 Thread Dmitry Torokhov
This simplifies error handling and allows to remove cobalt_buttons_remove() method. Signed-off-by: Dmitry Torokhov --- drivers/input/misc/cobalt_btns.c | 57 ++-- 1 file changed, 17 insertions(+), 40 deletions(-) diff --git a/drivers/input/misc/cobalt_btns.c b

[PATCH 22/22] Input: kxtj9 - switch to using polled mode of input devices

2019-10-17 Thread Dmitry Torokhov
benefit in having separate INPUT_KXTJ9_POLLED_MODE config option. Signed-off-by: Dmitry Torokhov --- drivers/input/misc/Kconfig | 7 -- drivers/input/misc/kxtj9.c | 152 + 2 files changed, 37 insertions(+), 122 deletions(-) diff --git a/drivers/input/misc

[PATCH 18/22] Input: mma8450 - switch to using polled mode of input devices

2019-10-17 Thread Dmitry Torokhov
We have added polled mode to the normal input devices with the intent of retiring input_polled_dev. This converts mma8450 driver to use the polling mode of standard input devices and removes dependency on INPUT_POLLDEV. Signed-off-by: Dmitry Torokhov --- drivers/input/misc/Kconfig | 1

[PATCH 16/22] Input: rb532_button - switch to using polled mode of input devices

2019-10-17 Thread Dmitry Torokhov
We have added polled mode to the normal input devices with the intent of retiring input_polled_dev. This converts rb532_button driver to use the polling mode of standard input devices and removes dependency on INPUT_POLLDEV. Signed-off-by: Dmitry Torokhov --- drivers/input/misc/Kconfig

[PATCH 20/22] Input: bma150 - switch to using polled mode of input devices

2019-10-17 Thread Dmitry Torokhov
We have added polled mode to the normal input devices with the intent of retiring input_polled_dev. This converts bma150 driver to use the polling mode of standard input devices and removes dependency on INPUT_POLLDEV. Signed-off-by: Dmitry Torokhov --- drivers/input/misc/Kconfig | 1

[PATCH 12/22] Input: cobalt_btns - switch to using polled mode of input devices

2019-10-17 Thread Dmitry Torokhov
We have added polled mode to the normal input devices with the intent of retiring input_polled_dev. This converts cobalt_btns driver to use the polling mode of standard input devices and removes dependency on INPUT_POLLDEV. Signed-off-by: Dmitry Torokhov --- drivers/input/misc/Kconfig

[PATCH 09/22] Input: apanel - switch to using polled mode of input devices

2019-10-17 Thread Dmitry Torokhov
We have added polled mode to the normal input devices with the intent of retiring input_polled_dev. This converts apanel driver to use the polling mode of standard input devices and removes dependency on INPUT_POLLDEV. While at it, let's convert the driver to use devm. Signed-off-by: D

[PATCH 10/22] Input: wistron_btns - switch to using polled mode of input devices

2019-10-17 Thread Dmitry Torokhov
We have added polled mode to the normal input devices with the intent of retiring input_polled_dev. This converts wistron_btns driver to use the polling mode of standard input devices and removes dependency on INPUT_POLLDEV. Signed-off-by: Dmitry Torokhov --- drivers/input/misc/Kconfig

[PATCH 13/22] Input: sgi_btns - switch to using managed resources

2019-10-17 Thread Dmitry Torokhov
Switching to devm API allows to clean up error handling paths and drop the remove() method. Signed-off-by: Dmitry Torokhov --- drivers/input/misc/sgi_btns.c | 37 --- 1 file changed, 8 insertions(+), 29 deletions(-) diff --git a/drivers/input/misc/sgi_btns.c b

[PATCH 06/22] Input: clps711x-keypad - switch to using polled mode of input devices

2019-10-17 Thread Dmitry Torokhov
remove clps711x_keypad_remove() method. Signed-off-by: Dmitry Torokhov --- drivers/input/keyboard/Kconfig | 1 - drivers/input/keyboard/clps711x-keypad.c | 70 ++-- 2 files changed, 29 insertions(+), 42 deletions(-) diff --git a/drivers/input/keyboard/Kconfig b

[PATCH 01/22] Input: raspberrypi-ts - switch to using polled mode of input devices

2019-10-17 Thread Dmitry Torokhov
We have added polled mode to the normal input devices with the intent of retiring input_polled_dev. This converts raspberrypi-ts driver to use the polling mode of standard input devices and removes dependency on INPUT_POLLDEV. Signed-off-by: Dmitry Torokhov --- drivers/input/touchscreen

[PATCH 03/22] Input: ts4800-ts - switch to using polled mode of input devices

2019-10-17 Thread Dmitry Torokhov
We have added polled mode to the normal input devices with the intent of retiring input_polled_dev. This converts ts4800-ts driver to use the polling mode of standard input devices and removes dependency on INPUT_POLLDEV. Signed-off-by: Dmitry Torokhov --- drivers/input/touchscreen/Kconfig

[PATCH 00/22] Stop using input_polled_dev in polling drivers

2019-10-17 Thread Dmitry Torokhov
Input devices now support polling mode natively (via input_setup_polling API), and input_polled_dev implementation is going away. This series switches drivers found in drivers/input to the new scheme. Dmitry Torokhov (21): Input: raspberrypi-ts - switch to using polled mode of input devices

[PATCH 04/22] Input: tsc6507x-ts - switch to using polled mode of input devices

2019-10-17 Thread Dmitry Torokhov
We have added polled mode to the normal input devices with the intent of retiring input_polled_dev. This converts tsc6507x-ts driver to use the polling mode of standard input devices and removes dependency on INPUT_POLLDEV. Signed-off-by: Dmitry Torokhov --- drivers/input/touchscreen/Kconfig

[PATCH 02/22] Input: sur40 - switch to using polled mode of input devices

2019-10-17 Thread Dmitry Torokhov
We have added polled mode to the normal input devices with the intent of retiring input_polled_dev. This converts sur40 driver to use the polling mode of standard input devices and removes dependency on INPUT_POLLDEV. Signed-off-by: Dmitry Torokhov --- drivers/input/touchscreen/Kconfig | 1

Re: [PATCH] Input: synaptics-rmi4 - Avoid processing unknown IRQs

2019-10-17 Thread Dmitry Torokhov
On Fri, Oct 11, 2019 at 09:46:56PM +, Andrew Duggan wrote: > Hi Evan, > > On 10/8/19 3:36 PM, Evan Green wrote: > > rmi_process_interrupt_requests() calls handle_nested_irq() for > > each interrupt status bit it finds. If the irq domain mapping for > > this bit had not yet been set up, then it

Re: [PATCH 1/2] input: edt-ft5x06 - add polled input support

2019-10-17 Thread Dmitry Torokhov
Hi Nicolas, On Wed, Jun 12, 2019 at 01:57:46PM +0200, Nicolas Saenz Julienne wrote: > On Tue, 2019-04-30 at 20:58 +0200, Nicolas Saenz Julienne wrote: > > Some hardware configurations might pass on providing an interrupt line. > > In that case there is always the option to use a polled input appro

[git pull] Input updates for v5.4-rc3

2019-10-17 Thread Dmitry Torokhov
Hi Linus, Please pull from: git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input.git for-linus to receive updates for the input subsystem. The main change is that we are reverting blanket enablement of SMBus mode for devices with Elan touchpads that report BIOS release date as 2018+

Re: [PATCH] input: Add privacy screen toggle keycode

2019-10-17 Thread Dmitry Torokhov
Hi Mathew, On Thu, Oct 17, 2019 at 10:32:08AM -0600, Mathew King wrote: > Add keycode for toggling electronic privacy screen to the keycodes > definition. Some new laptops have a privacy screen which can be toggled > with a key on the keyboard. Has it made into HID spec yet? > > Signed-off-by:

Re: [PATCH v5 11/14] software node: move small properties inline when copying

2019-10-17 Thread Dmitry Torokhov
On Fri, Oct 11, 2019 at 04:07:18PM -0700, Dmitry Torokhov wrote: > When copying/duplicating set of properties, move smaller properties that > were stored separately directly inside property entry structures. We can > move: > > - up to 8 bytes from U8 arrays > - up to 4 words

Re: [PATCH v5 10/14] software node: rename is_array to is_inline

2019-10-17 Thread Dmitry Torokhov
On Fri, Oct 11, 2019 at 04:07:17PM -0700, Dmitry Torokhov wrote: > We do not need a special flag to know if we are dealing with an array, > as we can get that data from ratio between element length and the data > size, however we do need a flag to know whether the data is stored > dir

Re: [PATCH v5 10/14] software node: rename is_array to is_inline

2019-10-17 Thread Dmitry Torokhov
On Thu, Oct 17, 2019 at 10:16:28AM +0300, Andy Shevchenko wrote: > On Wed, Oct 16, 2019 at 09:54:30AM -0700, Dmitry Torokhov wrote: > > On Wed, Oct 16, 2019 at 10:59:40AM +0300, Andy Shevchenko wrote: > > > On Tue, Oct 15, 2019 at 11:22:06AM -0700, Dmitry Torokhov wrote: >

Re: [PATCH v5 05/14] software node: clean up property_copy_string_array()

2019-10-16 Thread Dmitry Torokhov
On Wed, Oct 16, 2019 at 10:53:00AM +0300, Andy Shevchenko wrote: > On Tue, Oct 15, 2019 at 11:12:11AM -0700, Dmitry Torokhov wrote: > > On Tue, Oct 15, 2019 at 03:07:26PM +0300, Andy Shevchenko wrote: > > > On Fri, Oct 11, 2019 at 04:07:12PM -0700, Dmitry Torokhov wrot

Re: [PATCH v5 10/14] software node: rename is_array to is_inline

2019-10-16 Thread Dmitry Torokhov
On Wed, Oct 16, 2019 at 10:59:40AM +0300, Andy Shevchenko wrote: > On Tue, Oct 15, 2019 at 11:22:06AM -0700, Dmitry Torokhov wrote: > > On Mon, Oct 14, 2019 at 10:37:20AM +0300, Andy Shevchenko wrote: > > > On Fri, Oct 11, 2019 at 04:07:17PM -0700, Dmitry Torokhov wrote: > &

Re: [PATCH v5 11/14] software node: move small properties inline when copying

2019-10-16 Thread Dmitry Torokhov
On Wed, Oct 16, 2019 at 07:23:08PM +0300, Andy Shevchenko wrote: > On Wed, Oct 16, 2019 at 07:18:45PM +0300, Andy Shevchenko wrote: > > On Wed, Oct 16, 2019 at 09:01:26AM -0700, Dmitry Torokhov wrote: > > > On Wed, Oct 16, 2019 at 10:48:57AM +0300, Andy Shevchenko wrote: >

Re: [PATCH v5 11/14] software node: move small properties inline when copying

2019-10-16 Thread Dmitry Torokhov
On Wed, Oct 16, 2019 at 10:48:57AM +0300, Andy Shevchenko wrote: > On Tue, Oct 15, 2019 at 11:25:53AM -0700, Dmitry Torokhov wrote: > > On Tue, Oct 15, 2019 at 03:20:28PM +0300, Andy Shevchenko wrote: > > > On Fri, Oct 11, 2019 at 04:07:18PM -0700, Dmitry Torokhov wrote: &g

Re: [PATCH] Revert "Input: elantech - enable SMBus on new (2018+) systems"

2019-10-15 Thread Dmitry Torokhov
On Fri, Oct 11, 2019 at 05:26:05PM +0200, Benjamin Tissoires wrote: > Hi Kai-Heng, > > On Tue, Oct 1, 2019 at 9:09 AM Kai-Heng Feng > wrote: > > > > This reverts commit 883a2a80f79ca5c0c105605fafabd1f3df99b34c. > > > > Apparently use dmi_get_bios_year() as manufacturing date isn't accurate > > an

Re: [PATCH v5 11/14] software node: move small properties inline when copying

2019-10-15 Thread Dmitry Torokhov
On Tue, Oct 15, 2019 at 03:20:28PM +0300, Andy Shevchenko wrote: > On Fri, Oct 11, 2019 at 04:07:18PM -0700, Dmitry Torokhov wrote: > > When copying/duplicating set of properties, move smaller properties that > > were stored separately directly inside property entry structures.

Re: [PATCH v5 10/14] software node: rename is_array to is_inline

2019-10-15 Thread Dmitry Torokhov
On Mon, Oct 14, 2019 at 10:37:20AM +0300, Andy Shevchenko wrote: > On Fri, Oct 11, 2019 at 04:07:17PM -0700, Dmitry Torokhov wrote: > > We do not need a special flag to know if we are dealing with an array, > > as we can get that data from ratio between element length and th

Re: [PATCH v5 06/14] software node: get rid of property_set_pointer()

2019-10-15 Thread Dmitry Torokhov
On Tue, Oct 15, 2019 at 03:09:49PM +0300, Andy Shevchenko wrote: > On Fri, Oct 11, 2019 at 04:07:13PM -0700, Dmitry Torokhov wrote: > > Instead of explicitly setting values of integer types when copying > > property entries lets just copy entire value union when processing >

Re: [PATCH v5 05/14] software node: clean up property_copy_string_array()

2019-10-15 Thread Dmitry Torokhov
On Tue, Oct 15, 2019 at 03:07:26PM +0300, Andy Shevchenko wrote: > On Fri, Oct 11, 2019 at 04:07:12PM -0700, Dmitry Torokhov wrote: > > Because property_copy_string_array() stores the newly allocated pointer in > > the > > destination property, we have an awkward code in pro

Re: [PATCH v5 04/14] software node: mark internal macros with double underscores

2019-10-15 Thread Dmitry Torokhov
On Tue, Oct 15, 2019 at 03:03:50PM +0300, Andy Shevchenko wrote: > On Fri, Oct 11, 2019 at 04:07:11PM -0700, Dmitry Torokhov wrote: > > Let's mark PROPERTY_ENTRY_* macros that are internal with double leading > > underscores so users are not tempted to use them. > > We

Re: [PATCH v5 03/14] efi/apple-properties: use PROPERTY_ENTRY_U8_ARRAY_LEN

2019-10-15 Thread Dmitry Torokhov
On Tue, Oct 15, 2019 at 03:01:49PM +0300, Andy Shevchenko wrote: > On Fri, Oct 11, 2019 at 04:07:10PM -0700, Dmitry Torokhov wrote: > > Let's switch to using PROPERTY_ENTRY_U8_ARRAY_LEN() to initialize > > property entries. Also, when dumping data, rely on local variables &

Re: [PATCH v5 00/14] software node: add support for reference properties

2019-10-14 Thread Dmitry Torokhov
On Mon, Oct 14, 2019 at 10:38:37AM +0300, Andy Shevchenko wrote: > On Fri, Oct 11, 2019 at 04:07:07PM -0700, Dmitry Torokhov wrote: > > These series implement "references" properties for software nodes as true > > properties, instead of managing them completely separate

[PATCH v2 2/3] net: phy: fixed_phy: fix use-after-free when checking link GPIO

2019-10-14 Thread Dmitry Torokhov
If we fail to locate GPIO for any reason other than deferral or not-found-GPIO, we try to print device tree node info, however if might be freed already as we called of_node_put() on it. Acked-by: David S. Miller Signed-off-by: Dmitry Torokhov --- drivers/net/phy/fixed_phy.c | 7 ++- 1

[PATCH v2 1/3] net: phylink: switch to using fwnode_gpiod_get_index()

2019-10-14 Thread Dmitry Torokhov
Instead of fwnode_get_named_gpiod() that I plan to hide away, let's use the new fwnode_gpiod_get_index() that mimics gpiod_get_index(), but works with arbitrary firmware node. Reviewed-by: Andy Shevchenko Acked-by: David S. Miller Signed-off-by: Dmitry Torokhov --- drivers/net/phy/phyl

[PATCH v2 3/3] net: phy: fixed_phy: switch to using fwnode_gpiod_get_index

2019-10-14 Thread Dmitry Torokhov
iller Signed-off-by: Dmitry Torokhov --- drivers/net/phy/fixed_phy.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/net/phy/fixed_phy.c b/drivers/net/phy/fixed_phy.c index 4190f9ed5313..73a72ff0fb16 100644 --- a/drivers/net/phy/fixed_phy.c +++ b/drivers/ne

[PATCH v2 0/3] net: phy: switch to using fwnode_gpiod_get_index

2019-10-14 Thread Dmitry Torokhov
platform firmware. Linus, as David would prefer not to pull in the immutable branch but rather route the patches through the tree that has the new API, could you please take them with his ACKs? Thanks! v2: - rebased on top of Linus' W devel branch - added David's AC

Re: [PATCH 0/3] net: phy: switch to using fwnode_gpiod_get_index

2019-10-14 Thread Dmitry Torokhov
On Fri, Oct 11, 2019 at 02:05:40PM -0700, David Miller wrote: > From: Dmitry Torokhov > Date: Fri, 11 Oct 2019 13:42:42 -0700 > > > I see that the patches are marked as "Not applicable" in the netdev > > patchwork. Does this mean that you decided against pulling th

Re: [PATCH v4 00/14] software node: add support for reference properties

2019-10-11 Thread Dmitry Torokhov
On Thu, Oct 03, 2019 at 10:39:24AM +0200, Rafael J. Wysocki wrote: > On Thu, Oct 3, 2019 at 2:32 AM Dmitry Torokhov > wrote: > > > > Hi Rafael, > > > > On Tue, Sep 10, 2019 at 10:12:17PM -0700, Dmitry Torokhov wrote: > > > These series implement "refer

Re: [PATCH 1/3] HID: logitech-hidpp: use devres to manage FF private data

2019-10-11 Thread Dmitry Torokhov
On Sat, Oct 12, 2019 at 12:48:42AM +0200, Benjamin Tissoires wrote: > On Fri, Oct 11, 2019 at 11:34 PM Dmitry Torokhov > wrote: > > > > On Fri, Oct 11, 2019 at 01:35:09PM -0700, Dmitry Torokhov wrote: > > > On Fri, Oct 11, 2019 at 01:33:03PM -0700, Dmitry Torokhov wr

[PATCH v5 10/14] software node: rename is_array to is_inline

2019-10-11 Thread Dmitry Torokhov
We do not need a special flag to know if we are dealing with an array, as we can get that data from ratio between element length and the data size, however we do need a flag to know whether the data is stored directly inside property_entry or separately. Signed-off-by: Dmitry Torokhov

[PATCH v5 12/14] software node: implement reference properties

2019-10-11 Thread Dmitry Torokhov
nter_props[] = { PROPERTY_ENTRY_U32("linux,code", KEY_ENTER), PROPERTY_ENTRY_STRING("label", "enter"), PROPERTY_ENTRY_REF("gpios", &gpio_bank_b_node, 123, GPIO_ACTIVE_LOW), { } }; Signed-off-b

[PATCH v5 06/14] software node: get rid of property_set_pointer()

2019-10-11 Thread Dmitry Torokhov
e" of the property when interpret the data. We rely on users of property entries on using PROPERTY_ENTRY_XXX() macros to properly initialize entries instead of poking in the instances directly. Signed-off-by: Dmitry Torokhov --- drivers/base/swnode

[PATCH v5 14/14] software node: remove separate handling of references

2019-10-11 Thread Dmitry Torokhov
Now that all users of references have moved to reference properties, we can remove separate handling of references. Signed-off-by: Dmitry Torokhov --- drivers/base/swnode.c| 46 +++- include/linux/property.h | 14 2 files changed, 17

[PATCH v5 13/14] platform/x86: intel_cht_int33fe: use inline reference properties

2019-10-11 Thread Dmitry Torokhov
Now that static device properties allow defining reference properties together with all other types of properties, instead of managing them separately, let's adjust the driver. Signed-off-by: Dmitry Torokhov --- drivers/platform/x86/intel_cht_int33fe.c | 81 1

[PATCH v5 07/14] software node: remove property_entry_read_uNN_array functions

2019-10-11 Thread Dmitry Torokhov
There is absolutely no reason to have them as we can handle it all nicely in property_entry_read_int_array(). Signed-off-by: Dmitry Torokhov --- drivers/base/swnode.c | 85 +++ 1 file changed, 14 insertions(+), 71 deletions(-) diff --git a/drivers/base

[PATCH v5 11/14] software node: move small properties inline when copying

2019-10-11 Thread Dmitry Torokhov
When copying/duplicating set of properties, move smaller properties that were stored separately directly inside property entry structures. We can move: - up to 8 bytes from U8 arrays - up to 4 words - up to 2 double words - one U64 value - one or 2 strings. Signed-off-by: Dmitry Torokhov

[PATCH v5 08/14] software node: unify PROPERTY_ENTRY_XXX macros

2019-10-11 Thread Dmitry Torokhov
We can unify string properties initializer macros with integer initializers. Signed-off-by: Dmitry Torokhov --- include/linux/property.h | 64 +--- 1 file changed, 27 insertions(+), 37 deletions(-) diff --git a/include/linux/property.h b/include/linux

[PATCH v5 02/14] software node: introduce PROPERTY_ENTRY_ARRAY_XXX_LEN()

2019-10-11 Thread Dmitry Torokhov
Sometimes we want to initialize property entry array from a regular pointer, when we can't determine length automatically via ARRAY_SIZE. Let's introduce PROPERTY_ENTRY_ARRAY_XXX_LEN macros that take explicit "len" argument. Signed-off-by: Dmitry Torokhov --- include/l

[PATCH v5 00/14] software node: add support for reference properties

2019-10-11 Thread Dmitry Torokhov
are not part of property_entry structure) to avoid size increase. From user's POV nothing is changed, one can still use PROPERTY_ENTRY_REF macro to define reference "inline". - dropped unused DEV_PROP_MAX - rebased on linux-next Dmitry Torokhov (14): software node: remov

[PATCH v5 04/14] software node: mark internal macros with double underscores

2019-10-11 Thread Dmitry Torokhov
Let's mark PROPERTY_ENTRY_* macros that are internal with double leading underscores so users are not tempted to use them. Signed-off-by: Dmitry Torokhov --- include/linux/property.h | 20 ++-- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/include/

[PATCH v5 05/14] software node: clean up property_copy_string_array()

2019-10-11 Thread Dmitry Torokhov
th in property_entry_copy_data() to store it in destination structure. Signed-off-by: Dmitry Torokhov --- drivers/base/swnode.c | 19 --- 1 file changed, 8 insertions(+), 11 deletions(-) diff --git a/drivers/base/swnode.c b/drivers/base/swnode.c index a1f3f0994f9f..2f2248c9003c 100644

[PATCH v5 09/14] software node: simplify property_entry_read_string_array()

2019-10-11 Thread Dmitry Torokhov
There is no need to treat string arrays and single strings separately, we can go exclusively by the element length in relation to data type size. Signed-off-by: Dmitry Torokhov --- drivers/base/swnode.c | 21 +++-- 1 file changed, 7 insertions(+), 14 deletions(-) diff --git a

[PATCH v5 01/14] software node: remove DEV_PROP_MAX

2019-10-11 Thread Dmitry Torokhov
This definition is not used anywhere, let's remove it. Suggested-by: Andy Shevchenko Reviewed-by: Andy Shevchenko Signed-off-by: Dmitry Torokhov --- include/linux/property.h | 1 - 1 file changed, 1 deletion(-) diff --git a/include/linux/property.h b/include/linux/property.h

[PATCH v5 03/14] efi/apple-properties: use PROPERTY_ENTRY_U8_ARRAY_LEN

2019-10-11 Thread Dmitry Torokhov
Let's switch to using PROPERTY_ENTRY_U8_ARRAY_LEN() to initialize property entries. Also, when dumping data, rely on local variables instead of poking into the property entry structure directly. Signed-off-by: Dmitry Torokhov --- drivers/firmware/efi/apple-properties.c

Re: [PATCH 1/3] HID: logitech-hidpp: use devres to manage FF private data

2019-10-11 Thread Dmitry Torokhov
On Fri, Oct 11, 2019 at 01:35:09PM -0700, Dmitry Torokhov wrote: > On Fri, Oct 11, 2019 at 01:33:03PM -0700, Dmitry Torokhov wrote: > > On Fri, Oct 11, 2019 at 09:25:52PM +0200, Benjamin Tissoires wrote: > > > On Fri, Oct 11, 2019 at 8:26 PM Dmitry Torokhov > > > wr

Re: [PATCH 1/3] HID: logitech-hidpp: use devres to manage FF private data

2019-10-11 Thread Dmitry Torokhov
On Fri, Oct 11, 2019 at 02:02:30PM -0700, Andrey Smirnov wrote: > On Fri, Oct 11, 2019 at 1:33 PM Dmitry Torokhov > wrote: > > > > On Fri, Oct 11, 2019 at 09:25:52PM +0200, Benjamin Tissoires wrote: > > > On Fri, Oct 11, 2019 at 8:26 PM Dmitry Torokhov > > > w

Re: [PATCH 0/3] net: phy: switch to using fwnode_gpiod_get_index

2019-10-11 Thread Dmitry Torokhov
Hi David, On Fri, Oct 04, 2019 at 04:13:53PM -0700, Dmitry Torokhov wrote: > This series switches phy drivers form using fwnode_get_named_gpiod() and > gpiod_get_from_of_node() that are scheduled to be removed in favor > of fwnode_gpiod_get_index() that behaves more like

Re: [PATCH 1/3] HID: logitech-hidpp: use devres to manage FF private data

2019-10-11 Thread Dmitry Torokhov
On Fri, Oct 11, 2019 at 01:33:03PM -0700, Dmitry Torokhov wrote: > On Fri, Oct 11, 2019 at 09:25:52PM +0200, Benjamin Tissoires wrote: > > On Fri, Oct 11, 2019 at 8:26 PM Dmitry Torokhov > > wrote: > > > > > > On Fri, Oct 11, 2019 at 04:52:04PM +0200, Benjamin T

Re: [PATCH 1/3] HID: logitech-hidpp: use devres to manage FF private data

2019-10-11 Thread Dmitry Torokhov
On Fri, Oct 11, 2019 at 09:25:52PM +0200, Benjamin Tissoires wrote: > On Fri, Oct 11, 2019 at 8:26 PM Dmitry Torokhov > wrote: > > > > On Fri, Oct 11, 2019 at 04:52:04PM +0200, Benjamin Tissoires wrote: > > > Hi Andrey, > > > > > > On Mon, Oct 7,

Re: [PATCH 1/3] HID: logitech-hidpp: use devres to manage FF private data

2019-10-11 Thread Dmitry Torokhov
On Fri, Oct 11, 2019 at 04:52:04PM +0200, Benjamin Tissoires wrote: > Hi Andrey, > > On Mon, Oct 7, 2019 at 7:13 AM Andrey Smirnov > wrote: > > > > To simplify resource management in commit that follows as well as to > > save a couple of extra kfree()s and simplify hidpp_ff_deinit() switch > > d

Re: [PATCH 3/3] Input: mms114 - add support for mms345l

2019-10-09 Thread Dmitry Torokhov
On Wed, Oct 09, 2019 at 10:26:12AM +0300, Andi Shyti wrote: > Hi Dmitry, > > > > There was a related patch [2] that removes I2C_M_NOSTART for all models, > > > but it seems abandoned and I do not have any other model for testing. > > > Therefore, this patch implements the least instrusive solution

Re: [PATCH 5.4 regression fix] Input: soc_button_array - partial revert of support for newer surface devices

2019-10-08 Thread Dmitry Torokhov
On Sat, Oct 05, 2019 at 12:55:51PM +0200, Hans de Goede wrote: > Commit c394159310d0 ("Input: soc_button_array - add support for newer > surface devices") not only added support for the MSHW0040 ACPI HID, > but for some reason it also makes changes to the error handling of the > soc_button_lookup_g

Re: [PATCH 3/3] Input: mms114 - add support for mms345l

2019-10-08 Thread Dmitry Torokhov
On Mon, Oct 07, 2019 at 10:50:21PM +0200, Stephan Gerhold wrote: > MMS345L is another first generation touch screen from Melfas, > which uses the same registers as MMS152. > > However, using I2C_M_NOSTART for it causes errors when reading: > > i2c i2c-0: sendbytes: NAK bailout. > mms1

Re: [PATCH 1/3] Input: mms114 - use device_get_match_data

2019-10-08 Thread Dmitry Torokhov
On Tue, Oct 08, 2019 at 02:44:26PM +0300, Andi Shyti wrote: > Hi Stephan, > > > device_get_match_data is available now, so we can replace the call > > to of_device_get_match_data and remove the FIXME comment. > > > > Signed-off-by: Stephan Gerhold > > Reviewed-by: Andi Shyti Applied, thank yo

[PATCH 2/3] net: phy: fixed_phy: fix use-after-free when checking link GPIO

2019-10-04 Thread Dmitry Torokhov
If we fail to locate GPIO for any reason other than deferral or not-found-GPIO, we try to print device tree node info, however if might be freed already as we called of_node_put() on it. Signed-off-by: Dmitry Torokhov --- drivers/net/phy/fixed_phy.c | 7 ++- 1 file changed, 2 insertions

[PATCH 3/3] net: phy: fixed_phy: switch to using fwnode_gpiod_get_index

2019-10-04 Thread Dmitry Torokhov
gpiod_get_from_of_node() is being retired in favor of [devm_]fwnode_gpiod_get_index(), that behaves similar to [devm_]gpiod_get_index(), but can work with arbitrary firmware node. It will also be able to support secondary software nodes. Let's switch this driver over. Signed-off-by: D

[PATCH 0/3] net: phy: switch to using fwnode_gpiod_get_index

2019-10-04 Thread Dmitry Torokhov
ll in this immutable branch and not wait until after 5.5 merge window. Dmitry Torokhov (3): net: phylink: switch to using fwnode_gpiod_get_index() net: phy: fixed_phy: fix use-after-free when checking link GPIO net: phy: fixed_phy: switch to using fwnode_gpiod_get_index drivers/net/phy/fixed_

[PATCH 1/3] net: phylink: switch to using fwnode_gpiod_get_index()

2019-10-04 Thread Dmitry Torokhov
Instead of fwnode_get_named_gpiod() that I plan to hide away, let's use the new fwnode_gpiod_get_index() that mimics gpiod_get_index(), but works with arbitrary firmware node. Reviewed-by: Andy Shevchenko Signed-off-by: Dmitry Torokhov --- drivers/net/phy/phylink.c | 4 ++-- 1 file chang

[PATCH 5/7] regulator: da9211: switch to using devm_fwnode_gpiod_get

2019-10-04 Thread Dmitry Torokhov
devm_gpiod_get_from_of_node() is being retired in favor of devm_fwnode_gpiod_get_index(), that behaves similar to devm_gpiod_get_index(), but can work with arbitrary firmware node. It will also be able to support secondary software nodes. Let's switch this driver over. Signed-off-by: D

[PATCH 6/7] regulator: tps65132: switch to using devm_fwnode_gpiod_get()

2019-10-04 Thread Dmitry Torokhov
devm_fwnode_get_index_gpiod_from_child() is going away as the name is too unwieldy, let's switch to using the new devm_fwnode_gpiod_get(). Note that we no longer need to check for NULL as devm_fwnode_gpiod_get() will return -ENOENT if GPIO is missing. Signed-off-by: Dmitry Tor

[PATCH 4/7] regulator: s2mps11: switch to using devm_fwnode_gpiod_get

2019-10-04 Thread Dmitry Torokhov
devm_gpiod_get_from_of_node() is being retired in favor of devm_fwnode_gpiod_get_index(), that behaves similar to devm_gpiod_get_index(), but can work with arbitrary firmware node. It will also be able to support secondary software nodes. Let's switch this driver over. Signed-off-by: D

[PATCH 3/7] regulator: tps65090: switch to using devm_fwnode_gpiod_get

2019-10-04 Thread Dmitry Torokhov
devm_gpiod_get_from_of_node() is being retired in favor of devm_fwnode_gpiod_get_index(), that behaves similar to devm_gpiod_get_index(), but can work with arbitrary firmware node. It will also be able to support secondary software nodes. Let's switch this driver over. Signed-off-by: D

[PATCH 0/7] regulator: switch to using [devm_]fwnode_gpiod_get_index

2019-10-04 Thread Dmitry Torokhov
this immutable branch and not wait until after 5.5 merge window. Thanks! Dmitry Torokhov (7): regulator: s5m8767: switch to using devm_fwnode_gpiod_get regulator: slg51000: switch to using fwnode_gpiod_get_index regulator: tps65090: switch to using devm_fwnode_gpiod_get regulator: s2mps11: s

[PATCH 2/7] regulator: slg51000: switch to using fwnode_gpiod_get_index

2019-10-04 Thread Dmitry Torokhov
at we have a good non-devm API for getting GPIO from arbitrary firmware node, there is no reason to use devm API here as regulator core takes care of managing lifetime of "enable" GPIO and we were immediately detaching requested GPIO from devm anyway. Signed-off-by: Dmitry Torokhov --- dr

[PATCH 7/7] regulator: max77686: switch to using fwnode_gpiod_get_index

2019-10-04 Thread Dmitry Torokhov
gpiod_get_from_of_node() is being retired in favor of fwnode_gpiod_get_index(), that behaves similar to gpiod_get_index(), but can work with arbitrary firmware node. It will also be able to support secondary software nodes. Let's switch this driver over. Signed-off-by: Dmitry Tor

[PATCH 1/7] regulator: s5m8767: switch to using devm_fwnode_gpiod_get

2019-10-04 Thread Dmitry Torokhov
devm_gpiod_get_from_of_node() is being retired in favor of devm_fwnode_gpiod_get_index(), that behaves similar to devm_gpiod_get_index(), but can work with arbitrary firmware node. It will also be able to support secondary software nodes. Let's switch this driver over. Signed-off-by: D

Re: [PATCH] Input: add input_get_poll_interval()

2019-10-03 Thread Dmitry Torokhov
Hi Benjamin, On Thu, Oct 03, 2019 at 02:34:59PM -0400, Benjamin Tissoires wrote: > Hi Dmitry, > > On Wed, Oct 2, 2019 at 5:58 PM Dmitry Torokhov > wrote: > > > > Some drivers need to be able to know the current polling interval for > > devices working in polling m

Re: [PATCH v2 0/2] Add support for software nodes to gpiolib

2019-10-03 Thread Dmitry Torokhov
On Thu, Oct 03, 2019 at 12:07:47PM +0200, Linus Walleij wrote: > On Fri, Sep 13, 2019 at 5:22 AM Dmitry Torokhov > wrote: > > > This is a part of the larger series previously posted at > > > > https://lore.kernel.org/linux-gpio/20190911075215.78047-1-dmitry.torok...

Re: [PATCH v4 00/14] software node: add support for reference properties

2019-10-02 Thread Dmitry Torokhov
Hi Rafael, On Tue, Sep 10, 2019 at 10:12:17PM -0700, Dmitry Torokhov wrote: > These series implement "references" properties for software nodes as true > properties, instead of managing them completely separately. > > The first 10 patches are generic cleanups and consoli

[PATCH] mfd: arizona: switch to using devm_gpiod_get()

2019-10-02 Thread Dmitry Torokhov
t set such custom label when using the modern binding, I opted to not having it here either. Signed-off-by: Dmitry Torokhov --- drivers/mfd/arizona-core.c | 6 +- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/drivers/mfd/arizona-core.c b/drivers/mfd/arizona-core.c index 4a

Re: [PATCH] lis3lv02d: switch to using input device polling mode

2019-10-02 Thread Dmitry Torokhov
On Wed, Oct 02, 2019 at 04:59:43PM -0700, Dmitry Torokhov wrote: > On Thu, Oct 03, 2019 at 07:30:23AM +0800, kbuild test robot wrote: > > Hi Dmitry, > > > > I love your patch! Yet something to improve: > > > > [auto build test ERROR on char-misc/char-misc-testi

Re: [PATCH] lis3lv02d: switch to using input device polling mode

2019-10-02 Thread Dmitry Torokhov
e in git format-patch, please see > https://stackoverflow.com/a/37406982] > > url: > https://github.com/0day-ci/linux/commits/Dmitry-Torokhov/lis3lv02d-switch-to-using-input-device-polling-mode/20191003-062746 > config: parisc-allyesconfig (attached as .config) > compiler: hpp

[PATCH] Input: gpio_mouse - switch to using input device polling mode

2019-10-02 Thread Dmitry Torokhov
Now that instances of input_dev support polling mode natively, we no longer need to create input_polled_dev instance. Signed-off-by: Dmitry Torokhov --- drivers/input/mouse/Kconfig | 1 - drivers/input/mouse/gpio_mouse.c | 45 ++-- 2 files changed, 20

[PATCH] Input: add input_get_poll_interval()

2019-10-02 Thread Dmitry Torokhov
Some drivers need to be able to know the current polling interval for devices working in polling mode, let's allow them fetching it. Signed-off-by: Dmitry Torokhov --- drivers/input/input-poller.c | 9 + include/linux/input.h| 1 + 2 files changed, 10 insertions(+) diff --

[PATCH] lis3lv02d: switch to using input device polling mode

2019-10-02 Thread Dmitry Torokhov
Now that instances of input_dev support polling mode natively, we no longer need to create input_polled_dev instance. Signed-off-by: Dmitry Torokhov --- drivers/misc/Kconfig | 1 - drivers/misc/lis3lv02d/lis3lv02d.c | 80 -- drivers/misc/lis3lv02d

[PATCH] rt2x00: remove input-polldev.h header

2019-10-02 Thread Dmitry Torokhov
The driver does not use input subsystem so we do not need this header, and it is being removed, so stop pulling it in. Signed-off-by: Dmitry Torokhov --- drivers/net/wireless/ralink/rt2x00/rt2x00.h | 1 - 1 file changed, 1 deletion(-) diff --git a/drivers/net/wireless/ralink/rt2x00/rt2x00.h b

[PATCH] macintosh/ams-input: switch to using input device polling mode

2019-10-02 Thread Dmitry Torokhov
Now that instances of input_dev support polling mode natively, we no longer need to create input_polled_dev instance. Signed-off-by: Dmitry Torokhov --- drivers/macintosh/Kconfig | 1 - drivers/macintosh/ams/ams-input.c | 37 +++ drivers/macintosh/ams/ams.h

Re: [PATCH v3] Input: atmel_mxt_ts - Disable IRQ across suspend

2019-10-02 Thread Dmitry Torokhov
On Tue, Oct 01, 2019 at 11:15:03AM -0700, Evan Green wrote: > Across suspend and resume, we are seeing error messages like the following: > > atmel_mxt_ts i2c-PRP0001:00: __mxt_read_reg: i2c transfer failed (-121) > atmel_mxt_ts i2c-PRP0001:00: Failed to read T44 and T5 (-121) > > This occurs bec

[PATCH] platform/x86: toshiba_acpi: do not select INPUT_POLLDEV

2019-10-02 Thread Dmitry Torokhov
The driver does not use polling mode of input devices, and this config option is going away, so let's not reference it. Signed-off-by: Dmitry Torokhov --- drivers/platform/x86/Kconfig | 1 - 1 file changed, 1 deletion(-) diff --git a/drivers/platform/x86/Kconfig b/drivers/platform/x86/Kc

<    1   2   3   4   5   6   7   8   9   10   >