- 14 Apr, 2023 1 commit
-
-
hrdl authored
Prior to this patch, the sensing configuration data was not parsed correctly, breaking detection of max_tch. The vendor driver includes this field. This change informs the driver about the correct maximum number of simultaneous touch inputs. Tested on a Pine64 PineNote with a modified touch screen controller firmware. Signed-off-by: hrdl <git@hrdl.eu> Reviewed-by: Alistair Francis <alistair@alistair23.me> Link: https://lore.kernel.org/r/20230411211651.3791304-1-git@hrdl.euSigned-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
- 10 Apr, 2023 1 commit
-
-
Soumya Negi authored
Fix WARNING in pegasus_open/usb_submit_urb Syzbot bug: https://syzkaller.appspot.com/bug?id=bbc107584dcf3262253ce93183e51f3612aaeb13 Warning raised because pegasus_driver submits transfer request for bogus URB (pipe type does not match endpoint type). Add sanity check at probe time for pipe value extracted from endpoint descriptor. Probe will fail if sanity check fails. Reported-and-tested-by: syzbot+04ee0cb4caccaed12d78@syzkaller.appspotmail.com Signed-off-by: Soumya Negi <soumya.negi97@gmail.com> Link: https://lore.kernel.org/r/20230404074145.11523-1-soumya.negi97@gmail.comSigned-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
- 24 Mar, 2023 1 commit
-
-
Werner Sembach authored
A lot of modern Clevo barebones have touchpad and/or keyboard issues after suspend fixable with nomux + reset + noloop + nopnp. Luckily, none of them have an external PS/2 port so this can safely be set for all of them. I'm not entirely sure if every device listed really needs all four quirks, but after testing and production use, no negative effects could be observed when setting all four. Setting SERIO_QUIRK_NOMUX or SERIO_QUIRK_RESET_ALWAYS on the Clevo N150CU and the Clevo NHxxRZQ makes the keyboard very laggy for ~5 seconds after boot and sometimes also after resume. However both are required for the keyboard to not fail completely sometimes after boot or resume. Signed-off-by: Werner Sembach <wse@tuxedocomputers.com> Cc: stable@vger.kernel.org Link: https://lore.kernel.org/r/20230321191619.647911-1-wse@tuxedocomputers.comSigned-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
- 20 Mar, 2023 3 commits
-
-
msizanoen authored
The AlpsPS/2 code previously relied on the assumption that `char` is a signed type, which was true on x86 platforms (the only place where this driver is used) before kernel 6.2. However, on 6.2 and later, this assumption is broken due to the introduction of -funsigned-char as a new global compiler flag. Fix this by explicitly specifying the signedness of `char` when sign extending the values received from the device. Fixes: f3f33c67 ("Input: alps - Rushmore and v7 resolution support") Signed-off-by: msizanoen <msizanoen@qtmlabs.xyz> Cc: stable@vger.kernel.org Link: https://lore.kernel.org/r/20230320045228.182259-1-msizanoen@qtmlabs.xyzSigned-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
Jason A. Donenfeld authored
The recent change of -funsigned-char causes additions of negative numbers to become additions of large positive numbers, leading to wrong calculations of mouse movement. Change these casts to be explicitly signed, to take into account negative offsets. Fixes: 3bc753c0 ("kbuild: treat char as always unsigned") Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com> Reviewed-by: Hans de Goede <hdegoede@redhat.com> Cc: stable@vger.kernel.org Link: https://bugzilla.kernel.org/show_bug.cgi?id=217211 Link: https://lore.kernel.org/r/20230318133010.1285202-1-Jason@zx2c4.comSigned-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
Matthias Benkmann authored
When commit commit fff1011a ("Input: xpad - add X-Box Adaptive Profile button") was applied, one hunk ended up in the wrong function; move it to where it belongs. Fixes: fff1011a ("Input: xpad - add X-Box Adaptive Profile button") Signed-off-by: Matthias Benkmann <matthias.benkmann@gmail.com> Link: https://lore.kernel.org/r/20230318162106.0aef4ba5@ninjaSigned-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
- 17 Mar, 2023 2 commits
-
-
Hans de Goede authored
The Android Lenovo Yoga Book X90F / X90L uses the same goodix touchscreen with 9 bytes touch reports for its touch keyboard as the already supported Windows Lenovo Yoga Book X91F/L, add a DMI match for this to the nine_bytes_report DMI table. When the quirk for the X91F/L was initially added it was written to also apply to the X90F/L but this does not work because the Android version of the Yoga Book uses completely different DMI strings. Also adjust the X91F/L quirk to reflect that it only applies to the X91F/L models. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Reviewed-by: Bastien Nocera <hadess@hadess.net> Link: https://lore.kernel.org/r/20230315134442.71787-1-hdegoede@redhat.comSigned-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
Jonathan Denose authored
Fujitsu Lifebook A574/H requires the nomux option to properly probe the touchpad, especially when waking from sleep. Signed-off-by: Jonathan Denose <jdenose@google.com> Reviewed-by: Hans de Goede <hdegoede@redhat.com> Link: https://lore.kernel.org/r/20230303152623.45859-1-jdenose@google.comSigned-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
- 21 Feb, 2023 1 commit
-
-
Dmitry Torokhov authored
Prepare input updates for 6.3 merge window.
-
- 04 Feb, 2023 8 commits
-
-
Jeff LaBundy authored
Following a recent refactor of the driver to properly drop unused device nodes, the driver expects trackpad channel touch thresholds and ATI base values to be specified under single trackpad channel child nodes. This enhancement moves both properties to scalar values as opposed to arrays, making their types consistent across bindings. Fixes: a8f1f0dc ("dt-bindings: input: Add bindings for Azoteq IQS626A") Signed-off-by: Jeff LaBundy <jeff@labundy.com> Reviewed-by: Rob Herring <robh@kernel.org> Link: https://lore.kernel.org/r/Y9RQcddToBr1rrnJ@nixie71Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
Jeff LaBundy authored
Each call to device/fwnode_get_named_child_node() must be matched with a call to fwnode_handle_put() once the corresponding node is no longer in use. This ensures a reference count remains balanced in the case of dynamic device tree support. Currently, the driver never calls fwnode_handle_put(); this patch adds the missing calls. Because fwnode_handle_put() does not take a const *fwnode_handle, the const qualifier is removed across all corresponding *fwnode_handle instances. As part of this change, trackpad channel touch thresholds and ATI base values are now specified under single trackpad channel child nodes. This enhancement moves both properties to scalar values as opposed to arrays, making their types consistent across bindings. Fixes: f1d2809d ("Input: Add support for Azoteq IQS626A") Signed-off-by: Jeff LaBundy <jeff@labundy.com> Link: https://lore.kernel.org/r/Y9RQVe/V1Hnw1oly@nixie71Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
Krzysztof Kozlowski authored
Convert the ST-Microelectronics FingerTip touchscreen controller bindings to DT schema. Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> Reviewed-by: Rob Herring <robh@kernel.org> Link: https://lore.kernel.org/r/20230127202040.196411-1-krzysztof.kozlowski@linaro.orgSigned-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
Richard Kjerstadius authored
Prior to this patch, the bitmask ends up being 0x3, as opposed to 0x1 which likely was the intention. The erroneous bit results in the driver reporting 2 different button activations in designs with 2 or more buttons. To detect which button has been pressed, cyttsp5_btn_attention() uses a for loop to iterate through the input buffer, while shifting and applying a bitmask to determine the state for each button. Unfortunately, when the bitmask is 0x3 and there are multiple buttons, this procedure falls apart. Consider a design with 3 buttons. Pressing the third button will result in a call to cyttsp5_btn_attention() with the input buffer containing 0x4 (binary 0100). In the first iteration of the for loop cur_btn_state will be: (0x4 >> 0 * 1) & 0x3 = 0x4 & 0x3 = 0x0 This is correct. However, in the next iteration this happens: (0x4 >> 1 * 1) & 0x3 = 0x2 & 0x3 = 0x2 Which means that a key event for key 1 is generated, even though it's not really active. In the third iteration, the loop detects the button that was actually pressed: (0x4 >> 2 * 1) & 0x3 = 0x1 & 0x3 = 0x1 This key event is the only one that should have been detected, but it is accompanied by the preceding key. Ensuring the applied mask is 0x1 solves this problem. Signed-off-by: Richard Kjerstadius <richard.kjerstadius@teledyne.com> Reviewed-by: Alistair Francis <alistair@alistair23.me> Link: https://lore.kernel.org/r/20230127102903.3317089-1-richard.kjerstadius@teledyne.comSigned-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
Dmitry Torokhov authored
We need to stop the timer on driver unbind or probe failures, otherwise we get UAF/Oops. Fixes: 7e577a17 ("Input: add I2C attached EETI EXC3000 multi touch driver") Reported-by: "Stahl, Michael" <mstahl@moba.de> Link: https://lore.kernel.org/r/Y9dK57BFqtlf8NmN@google.com Cc: stable@vger.kernel.org Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
Rayyan Ansari authored
Currently, the ID being set to "rmi4_spi" causes this warning: "SPI driver rmi4_spi has no spi_device_id for syna,rmi4-spi" Change the ID to rmi4-spi to stop this warning. Signed-off-by: Rayyan Ansari <rayyan@ansari.sh> Link: https://lore.kernel.org/r/20221219133717.1638496-1-rayyan@ansari.shSigned-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
Jiri Valek - 2N authored
Add basic support for more CAP1xxx sensors. All models from CAP1xxx family are register-compatible. Some advanced features are not used and disabled by default. Reported-by: kernel test robot <lkp@xxxxxxxxx> Signed-off-by: Jiri Valek - 2N <jiriv@axis.com> Reviewed-by: Mattijs Korpershoek <mkorpershoek@baylibre.com> Link: https://lore.kernel.org/r/20230111131111.475270-3-jiriv@axis.comSigned-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
Jiri Valek - 2N authored
Add support for cap1203, cap1293 and cap1298. Signed-off-by: Jiri Valek - 2N <jiriv@axis.com> Acked-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> Link: https://lore.kernel.org/r/20230111131111.475270-2-jiriv@axis.comSigned-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
- 30 Jan, 2023 12 commits
-
-
Randy Dunlap authored
Correct a spelling mistake (reported by codespell). Also hyphenate "matrix-based". Signed-off-by: Randy Dunlap <rdunlap@infradead.org> Link: https://lore.kernel.org/r/20230124233453.22893-1-rdunlap@infradead.orgSigned-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
Dario Binacchi authored
Replace 'firmares' with 'firmwares'. Signed-off-by: Dario Binacchi <dario.binacchi@amarulasolutions.com> Link: https://lore.kernel.org/r/20230128162325.64467-1-dario.binacchi@amarulasolutions.comSigned-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
ye xingchen authored
Convert platform_get_resource(), devm_ioremap_resource() to a single call to devm_platform_get_and_ioremap_resource(), as this is exactly what this function does. Signed-off-by: ye xingchen <ye.xingchen@zte.com.cn> Link: https://lore.kernel.org/r/202301281613032191431@zte.com.cnSigned-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
ye xingchen authored
Convert platform_get_resource(), devm_ioremap_resource() to a single call to devm_platform_get_and_ioremap_resource(), as this is exactly what this function does. Signed-off-by: ye xingchen <ye.xingchen@zte.com.cn> Link: https://lore.kernel.org/r/202301281611305841413@zte.com.cnSigned-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
ye xingchen authored
Convert platform_get_resource(), devm_ioremap_resource() to a single call to devm_platform_get_and_ioremap_resource(), as this is exactly what this function does. Signed-off-by: ye xingchen <ye.xingchen@zte.com.cn> Link: https://lore.kernel.org/r/202301281609576851394@zte.com.cnSigned-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
ye xingchen authored
Convert platform_get_resource(), devm_ioremap_resource() to a single call to devm_platform_get_and_ioremap_resource(), as this is exactly what this function does. Signed-off-by: ye xingchen <ye.xingchen@zte.com.cn> Link: https://lore.kernel.org/r/202301281608287301370@zte.com.cnSigned-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
ye xingchen authored
Convert platform_get_resource(), devm_ioremap_resource() to a single call to devm_platform_get_and_ioremap_resource(), as this is exactly what this function does. Signed-off-by: ye xingchen <ye.xingchen@zte.com.cn> Link: https://lore.kernel.org/r/202301281606309671328@zte.com.cnSigned-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
ye xingchen authored
Convert platform_get_resource(), devm_ioremap_resource() to a single call to devm_platform_get_and_ioremap_resource(), as this is exactly what this function does. Signed-off-by: ye xingchen <ye.xingchen@zte.com.cn> Link: https://lore.kernel.org/r/202301281604596831304@zte.com.cnSigned-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
ye xingchen authored
Convert platform_get_resource(), devm_ioremap_resource() to a single call to devm_platform_get_and_ioremap_resource(), as this is exactly what this function does. Signed-off-by: ye xingchen <ye.xingchen@zte.com.cn> Link: https://lore.kernel.org/r/202301281603290601283@zte.com.cnSigned-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
Luca Ellero authored
To discard false readings, one should use "ti,penirq-recheck-delay-usecs". Checking get_pendown_state() at the beginning, most of the time fails causing malfunctioning. Fixes: ffa458c1 ("spi: ads7846 driver") Signed-off-by: Luca Ellero <l.ellero@asem.it> Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Link: https://lore.kernel.org/r/20230126105227.47648-4-l.ellero@asem.itSigned-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
Luca Ellero authored
Controllers that report pressure (e.g. ADS7846) use 5 commands and the correct sequence is READ_X, READ_Y, READ_Z1, READ_Z2, PWRDOWN. Controllers that don't report pressure (e.g. ADS7845/ADS7843) use only 3 commands and the correct sequence should be READ_X, READ_Y, PWRDOWN. But the sequence sent was incorrect: READ_X, READ_Y, READ_Z1. Fix this by setting the third (and last) command to PWRDOWN. Fixes: ffa458c1 ("spi: ads7846 driver") Signed-off-by: Luca Ellero <l.ellero@asem.it> Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Link: https://lore.kernel.org/r/20230126105227.47648-3-l.ellero@asem.itSigned-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
Luca Ellero authored
ADS7845 doesn't support pressure. Avoid the following error reported by libinput-list-devices: "ADS7845 Touchscreen: kernel bug: device has min == max on ABS_PRESSURE". Fixes: ffa458c1 ("spi: ads7846 driver") Signed-off-by: Luca Ellero <l.ellero@asem.it> Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Link: https://lore.kernel.org/r/20230126105227.47648-2-l.ellero@asem.itSigned-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
- 27 Jan, 2023 11 commits
-
-
John Butler authored
Add VID and PID to the xpad_device table to allow driver to use the 8BitDo Pro 2 Wired Controller, which is XTYPE_XBOX360 compatible by default. Signed-off-by: John Butler <radon86dev@gmail.com> Reviewed-by: Mattijs Korpershoek <mkorpershoek@baylibre.com> Link: https://lore.kernel.org/r/20230124005206.80706-1-radon86dev@gmail.comSigned-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
Arnd Bergmann authored
The previous change was not properly build tested and needs a trivial spelling change: ipaq-micro-ts.c:146:8: error: type defaults to 'int' in declaration of 'DEFINE_SIMPLE_DEV_PM' [-Werror=implicit-int] Fixes: 144ff5e0 ("Input: ipaq-micro-ts - use DEFINE_SIMPLE_DEV_PM_OPS() and pm_sleep_ptr()") Signed-off-by: Arnd Bergmann <arnd@arndb.de> Reviewed-by: Jonathan Cameron <Jonathan.Cameron@huawei.com> Link: https://lore.kernel.org/r/20230117164539.1631336-1-arnd@kernel.orgSigned-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
Jonathan Cameron authored
As the guards only apply to suspend and resume, #ifdef CONFIG_PM_SLEEP would have been a tighter protection. As pm_sleep_ptr() lets the compiler see the protected ops structure and callbacks but also lets the compiler remove it as unused code if !CONFIG_PM_SLEEP this allows the #ifdef guards to be removed, slightly simplifying the resulting code. -- It seems likely that DEFINE_SIMPLE_DEV_PM_OPS() would work here but I'd prefer not to make that change unless someone can confirm that the extra callbacks registered will have no unwanted side effects in this driver. Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com> Link: https://lore.kernel.org/r/20230114171620.42891-17-jic23@kernel.orgSigned-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
Jonathan Cameron authored
As the guards only apply to suspend and resume, #ifdef CONFIG_PM_SLEEP would have been a tighter protection. As pm_sleep_ptr() lets the compiler see the protected ops structure and callbacks but also lets the compiler remove it as unused code if !CONFIG_PM_SLEEP this allows the #ifdef guards to be removed, slightly simplifying the resulting code. Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com> -- It seems likely that DEFINE_SIMPLE_DEV_PM_OPS() would work here but I'd prefer not to make that change unless someone can confirm that the extra callbacks registered will have no unwanted side effects in this driver. Link: https://lore.kernel.org/r/20230114171620.42891-16-jic23@kernel.orgSigned-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
Jonathan Cameron authored
As the new pm_sleep_ptr() macro lets the compiler see the code, but then remove it if !CONFIG_PM_SLEEP it can be used to avoid the need for #ifdef guards. Use that in the input core to simplify the code a little. Note pm_sleep_ptr() has not been applied to each callback in the ops structure because the pm_sleep_ptr() at the usage site is sufficient. Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com> Link: https://lore.kernel.org/r/20230114171620.42891-15-jic23@kernel.orgSigned-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
Jonathan Cameron authored
SET_RUNTIME_DEV_PM_OPS() is deprecated as it requires explicit protection against unused function warnings. The new combination of pm_ptr() and RUNTIME_DEV_PM_OPS() allows the compiler to see the functions, thus suppressing the warning, but still allowing the unused code to be removed. Thus also drop the __maybe_unused markings. Note that DEFINE_RUNTIME_DEV_PM_OPS() is not used because that adds additional callbacks for suspend and resume and would need testing. Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com> Link: https://lore.kernel.org/r/20230114171620.42891-14-jic23@kernel.orgSigned-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
Jonathan Cameron authored
SET_SYSTEM_SLEEP_PM_OPS() is deprecated as it requires explicit protection against unused function warnings. The new combination of pm_sleep_ptr() and SYSTEM_SLEEP_PM_OPS() allows the compiler to see the functions, thus suppressing the warning, but still allowing the unused code to be removed. Thus also drop the __maybe_unused markings. In this case we also have a .poweroff_late() callback. Whilst not strictly necessary, to future proof against relaxation of the protection of the main driver.pm = pm_sleep_ptr() protect this pointer with pm_sleep_ptr() as would be done if the LATE_SYSTEM_SLEEP_PM_OPS() macro were used to set it. Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com> Link: https://lore.kernel.org/r/20230114171620.42891-13-jic23@kernel.orgSigned-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
Jonathan Cameron authored
SIMPLE_DEV_PM_OPS() is deprecated as it requires explicit protection against unused function warnings. The new combination of pm_sleep_ptr() and EXPORT_GPL_SIMPLE_DEV_PMU_OPS() allows the compiler to see the functions, thus suppressing the warning, but still allowing the unused code to be removed. Thus also drop the __maybe_unused markings. It also rolls in the EXPORT_SYMBOL() so that we only export it if CONFIG_PM_SLEEP. Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com> Cc: Javier Martinez Canillas <javier@dowhile0.org> Cc: Linus Walleij <linus.walleij@linaro.org> Link: https://lore.kernel.org/r/20230114171620.42891-12-jic23@kernel.orgSigned-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
Jonathan Cameron authored
SET_SYSTEM_SLEEP_PM_OPS() and RUNTIME_PM_OPS() are deprecated as they requires explicit protection against unused function warnings. The new combination of pm_ptr() EXPORT_GPL_RUNTIME_DEV_PM_OPS() allows the compiler to see the functions, thus suppressing the warning, but still allowing the unused code to be removed. Thus also drop the #ifdef guards. Note that we are replacing an unconditional call to the suspend and resume functions for sleep use cases with one via pm_runtime_force_suspend() / pm_runtime_force_resume() that only do anything to the device if we are not already in the appropriate runtime suspended state. Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com> -- I 'think' this should be fine in that it can only reduce the number of unnecessary suspends. If anyone can test that would be great. Link: https://lore.kernel.org/r/20230114171620.42891-11-jic23@kernel.orgSigned-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
Jonathan Cameron authored
SIMPLE_DEV_PM_OPS() is deprecated as it requires explicit protection against unused function warnings. The new combination of pm_sleep_ptr() and EXPORT_GPL_SIMPLE_DEV_PM_OPS() allows the compiler to see the functions, thus suppressing the warning, but still allowing the unused code to be removed. Thus also drop the __maybe_unused markings. This function also removes the need for separate EXPORT_SYMBOL_GPL() Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com> Link: https://lore.kernel.org/r/20230114171620.42891-10-jic23@kernel.orgSigned-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
Jonathan Cameron authored
The I2C and SPI PM callbacks were identical (though wrapped in some bouncing out to the bus specific container of the struct device and then back again to get the drvdata). As such rather than just moving these to SIMPLE_DEV_PM_OPS() and pm_sleep_ptr() take the opportunity to unify the struct dev_pm_ops and use the new EXPORT_SIMPLE_DEV_PM_OPS() macro so that we can drop the unused suspend and resume callbacks as well as the structure if !CONFIG_PM_SLEEP without needing to mark the callbacks __maybe_unused. Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com> Cc: Michael Hennerich <michael.hennerich@analog.com> Link: https://lore.kernel.org/r/20230114171620.42891-9-jic23@kernel.orgSigned-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
-