#
1354ceb1 |
| 20-Sep-2021 |
Hans de Goede <hdegoede@redhat.com> |
Input: goodix - change goodix_i2c_write() len parameter type to int
[ Upstream commit 31ae0102a34ed863c7d32b10e768036324991679 ]
Change the type of the goodix_i2c_write() len parameter to from 'uns
Input: goodix - change goodix_i2c_write() len parameter type to int
[ Upstream commit 31ae0102a34ed863c7d32b10e768036324991679 ]
Change the type of the goodix_i2c_write() len parameter to from 'unsigned' to 'int' to avoid bare use of 'unsigned', changing it to 'int' makes goodix_i2c_write()' prototype consistent with goodix_i2c_read().
Reviewed-by: Bastien Nocera <hadess@hadess.net> Signed-off-by: Hans de Goede <hdegoede@redhat.com> Link: https://lore.kernel.org/r/20210920150643.155872-2-hdegoede@redhat.com Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> Signed-off-by: Sasha Levin <sashal@kernel.org>
show more ...
|
#
14039521 |
| 07-Dec-2021 |
Hans de Goede <hdegoede@redhat.com> |
Input: goodix - try not to touch the reset-pin on x86/ACPI devices
[ Upstream commit a2fd46cd3dbb83b373ba74f4043f8dae869c65f1 ]
Unless the controller is not responding at boot or after suspend/resu
Input: goodix - try not to touch the reset-pin on x86/ACPI devices
[ Upstream commit a2fd46cd3dbb83b373ba74f4043f8dae869c65f1 ]
Unless the controller is not responding at boot or after suspend/resume, the driver never resets the controller on x86/ACPI platforms. The driver still requesting the reset pin at probe() though in case it needs it.
Until now the driver has always requested the reset pin with GPIOD_IN as type. The idea being to put the pin in high-impedance mode to save power until the driver actually wants to issue a reset.
But this means that just requesting the pin can cause issues, since requesting it in another mode then GPIOD_ASIS may cause the pinctrl driver to touch the pin settings. We have already had issues before due to a bug in the pinctrl-cherryview.c driver which has been fixed in commit 921daeeca91b ("pinctrl: cherryview: Preserve CHV_PADCTRL1_INVRXTX_TXDATA flag on GPIOs").
And now it turns out that requesting the reset-pin as GPIOD_IN also stops the touchscreen from working on the GPD P2 max mini-laptop. The behavior of putting the pin in high-impedance mode relies on there being some external pull-up to keep it high and there seems to be no pull-up on the GPD P2 max, causing things to break.
This commit fixes this by requesting the reset pin as is when using the x86/ACPI code paths to lookup the GPIOs; and by not dropping it back into input-mode in case the driver does end up issuing a reset for error-recovery.
BugLink: https://bugzilla.kernel.org/show_bug.cgi?id=209061 Fixes: a7d4b171660c ("Input: goodix - add support for getting IRQ + reset GPIOs on Cherry Trail devices") Cc: stable@vger.kernel.org Signed-off-by: Hans de Goede <hdegoede@redhat.com> Link: https://lore.kernel.org/r/20211206091116.44466-2-hdegoede@redhat.com Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> Signed-off-by: Sasha Levin <sashal@kernel.org>
show more ...
|
#
8422a9b3 |
| 20-Sep-2021 |
Hans de Goede <hdegoede@redhat.com> |
Input: goodix - refactor reset handling
[ Upstream commit 209bda4741f68f102cf2f272227bfc938e387b51 ]
Refactor reset handling a bit, change the main reset handler into a new goodix_reset_no_int_sync
Input: goodix - refactor reset handling
[ Upstream commit 209bda4741f68f102cf2f272227bfc938e387b51 ]
Refactor reset handling a bit, change the main reset handler into a new goodix_reset_no_int_sync() helper and add a goodix_reset() wrapper which calls goodix_int_sync() separately.
Also push the dev_err() call on reset failure into the goodix_reset_no_int_sync() and goodix_int_sync() functions, so that we don't need to have separate dev_err() calls in all their callers.
This is a preparation patch for adding support for controllers without flash, which need to have their firmware uploaded and need some other special handling too.
Reviewed-by: Bastien Nocera <hadess@hadess.net> Signed-off-by: Hans de Goede <hdegoede@redhat.com> Link: https://lore.kernel.org/r/20210920150643.155872-4-hdegoede@redhat.com Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> Signed-off-by: Sasha Levin <sashal@kernel.org>
show more ...
|
#
f5b1c6d5 |
| 20-Sep-2021 |
Hans de Goede <hdegoede@redhat.com> |
Input: goodix - add a goodix.h header file
[ Upstream commit a2233cb7b65a017067e2f2703375ecc930a0ab30 ]
Add a goodix.h header file, and move the register definitions, and struct declarations there
Input: goodix - add a goodix.h header file
[ Upstream commit a2233cb7b65a017067e2f2703375ecc930a0ab30 ]
Add a goodix.h header file, and move the register definitions, and struct declarations there and add prototypes for various helper functions.
This is a preparation patch for adding support for controllers without flash, which need to have their firmware uploaded and need some other special handling too.
Since MAINTAINERS needs updating because of this change anyways, also add myself as co-maintainer.
Reviewed-by: Bastien Nocera <hadess@hadess.net> Signed-off-by: Hans de Goede <hdegoede@redhat.com> Link: https://lore.kernel.org/r/20210920150643.155872-3-hdegoede@redhat.com Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> Signed-off-by: Sasha Levin <sashal@kernel.org>
show more ...
|
#
1354ceb1 |
| 20-Sep-2021 |
Hans de Goede <hdegoede@redhat.com> |
Input: goodix - change goodix_i2c_write() len parameter type to int
[ Upstream commit 31ae0102a34ed863c7d32b10e768036324991679 ]
Change the type of the goodix_i2c_write() len parameter to from 'uns
Input: goodix - change goodix_i2c_write() len parameter type to int
[ Upstream commit 31ae0102a34ed863c7d32b10e768036324991679 ]
Change the type of the goodix_i2c_write() len parameter to from 'unsigned' to 'int' to avoid bare use of 'unsigned', changing it to 'int' makes goodix_i2c_write()' prototype consistent with goodix_i2c_read().
Reviewed-by: Bastien Nocera <hadess@hadess.net> Signed-off-by: Hans de Goede <hdegoede@redhat.com> Link: https://lore.kernel.org/r/20210920150643.155872-2-hdegoede@redhat.com Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> Signed-off-by: Sasha Levin <sashal@kernel.org>
show more ...
|
#
14039521 |
| 07-Dec-2021 |
Hans de Goede <hdegoede@redhat.com> |
Input: goodix - try not to touch the reset-pin on x86/ACPI devices
[ Upstream commit a2fd46cd3dbb83b373ba74f4043f8dae869c65f1 ]
Unless the controller is not responding at boot or after suspend/resu
Input: goodix - try not to touch the reset-pin on x86/ACPI devices
[ Upstream commit a2fd46cd3dbb83b373ba74f4043f8dae869c65f1 ]
Unless the controller is not responding at boot or after suspend/resume, the driver never resets the controller on x86/ACPI platforms. The driver still requesting the reset pin at probe() though in case it needs it.
Until now the driver has always requested the reset pin with GPIOD_IN as type. The idea being to put the pin in high-impedance mode to save power until the driver actually wants to issue a reset.
But this means that just requesting the pin can cause issues, since requesting it in another mode then GPIOD_ASIS may cause the pinctrl driver to touch the pin settings. We have already had issues before due to a bug in the pinctrl-cherryview.c driver which has been fixed in commit 921daeeca91b ("pinctrl: cherryview: Preserve CHV_PADCTRL1_INVRXTX_TXDATA flag on GPIOs").
And now it turns out that requesting the reset-pin as GPIOD_IN also stops the touchscreen from working on the GPD P2 max mini-laptop. The behavior of putting the pin in high-impedance mode relies on there being some external pull-up to keep it high and there seems to be no pull-up on the GPD P2 max, causing things to break.
This commit fixes this by requesting the reset pin as is when using the x86/ACPI code paths to lookup the GPIOs; and by not dropping it back into input-mode in case the driver does end up issuing a reset for error-recovery.
BugLink: https://bugzilla.kernel.org/show_bug.cgi?id=209061 Fixes: a7d4b171660c ("Input: goodix - add support for getting IRQ + reset GPIOs on Cherry Trail devices") Cc: stable@vger.kernel.org Signed-off-by: Hans de Goede <hdegoede@redhat.com> Link: https://lore.kernel.org/r/20211206091116.44466-2-hdegoede@redhat.com Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> Signed-off-by: Sasha Levin <sashal@kernel.org>
show more ...
|
#
8422a9b3 |
| 20-Sep-2021 |
Hans de Goede <hdegoede@redhat.com> |
Input: goodix - refactor reset handling
[ Upstream commit 209bda4741f68f102cf2f272227bfc938e387b51 ]
Refactor reset handling a bit, change the main reset handler into a new goodix_reset_no_int_sync
Input: goodix - refactor reset handling
[ Upstream commit 209bda4741f68f102cf2f272227bfc938e387b51 ]
Refactor reset handling a bit, change the main reset handler into a new goodix_reset_no_int_sync() helper and add a goodix_reset() wrapper which calls goodix_int_sync() separately.
Also push the dev_err() call on reset failure into the goodix_reset_no_int_sync() and goodix_int_sync() functions, so that we don't need to have separate dev_err() calls in all their callers.
This is a preparation patch for adding support for controllers without flash, which need to have their firmware uploaded and need some other special handling too.
Reviewed-by: Bastien Nocera <hadess@hadess.net> Signed-off-by: Hans de Goede <hdegoede@redhat.com> Link: https://lore.kernel.org/r/20210920150643.155872-4-hdegoede@redhat.com Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> Signed-off-by: Sasha Levin <sashal@kernel.org>
show more ...
|
#
f5b1c6d5 |
| 20-Sep-2021 |
Hans de Goede <hdegoede@redhat.com> |
Input: goodix - add a goodix.h header file
[ Upstream commit a2233cb7b65a017067e2f2703375ecc930a0ab30 ]
Add a goodix.h header file, and move the register definitions, and struct declarations there
Input: goodix - add a goodix.h header file
[ Upstream commit a2233cb7b65a017067e2f2703375ecc930a0ab30 ]
Add a goodix.h header file, and move the register definitions, and struct declarations there and add prototypes for various helper functions.
This is a preparation patch for adding support for controllers without flash, which need to have their firmware uploaded and need some other special handling too.
Since MAINTAINERS needs updating because of this change anyways, also add myself as co-maintainer.
Reviewed-by: Bastien Nocera <hadess@hadess.net> Signed-off-by: Hans de Goede <hdegoede@redhat.com> Link: https://lore.kernel.org/r/20210920150643.155872-3-hdegoede@redhat.com Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> Signed-off-by: Sasha Levin <sashal@kernel.org>
show more ...
|
#
1354ceb1 |
| 20-Sep-2021 |
Hans de Goede <hdegoede@redhat.com> |
Input: goodix - change goodix_i2c_write() len parameter type to int
[ Upstream commit 31ae0102a34ed863c7d32b10e768036324991679 ]
Change the type of the goodix_i2c_write() len parameter to from 'uns
Input: goodix - change goodix_i2c_write() len parameter type to int
[ Upstream commit 31ae0102a34ed863c7d32b10e768036324991679 ]
Change the type of the goodix_i2c_write() len parameter to from 'unsigned' to 'int' to avoid bare use of 'unsigned', changing it to 'int' makes goodix_i2c_write()' prototype consistent with goodix_i2c_read().
Reviewed-by: Bastien Nocera <hadess@hadess.net> Signed-off-by: Hans de Goede <hdegoede@redhat.com> Link: https://lore.kernel.org/r/20210920150643.155872-2-hdegoede@redhat.com Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> Signed-off-by: Sasha Levin <sashal@kernel.org>
show more ...
|
#
14039521 |
| 07-Dec-2021 |
Hans de Goede <hdegoede@redhat.com> |
Input: goodix - try not to touch the reset-pin on x86/ACPI devices
[ Upstream commit a2fd46cd3dbb83b373ba74f4043f8dae869c65f1 ]
Unless the controller is not responding at boot or after suspend/resu
Input: goodix - try not to touch the reset-pin on x86/ACPI devices
[ Upstream commit a2fd46cd3dbb83b373ba74f4043f8dae869c65f1 ]
Unless the controller is not responding at boot or after suspend/resume, the driver never resets the controller on x86/ACPI platforms. The driver still requesting the reset pin at probe() though in case it needs it.
Until now the driver has always requested the reset pin with GPIOD_IN as type. The idea being to put the pin in high-impedance mode to save power until the driver actually wants to issue a reset.
But this means that just requesting the pin can cause issues, since requesting it in another mode then GPIOD_ASIS may cause the pinctrl driver to touch the pin settings. We have already had issues before due to a bug in the pinctrl-cherryview.c driver which has been fixed in commit 921daeeca91b ("pinctrl: cherryview: Preserve CHV_PADCTRL1_INVRXTX_TXDATA flag on GPIOs").
And now it turns out that requesting the reset-pin as GPIOD_IN also stops the touchscreen from working on the GPD P2 max mini-laptop. The behavior of putting the pin in high-impedance mode relies on there being some external pull-up to keep it high and there seems to be no pull-up on the GPD P2 max, causing things to break.
This commit fixes this by requesting the reset pin as is when using the x86/ACPI code paths to lookup the GPIOs; and by not dropping it back into input-mode in case the driver does end up issuing a reset for error-recovery.
BugLink: https://bugzilla.kernel.org/show_bug.cgi?id=209061 Fixes: a7d4b171660c ("Input: goodix - add support for getting IRQ + reset GPIOs on Cherry Trail devices") Cc: stable@vger.kernel.org Signed-off-by: Hans de Goede <hdegoede@redhat.com> Link: https://lore.kernel.org/r/20211206091116.44466-2-hdegoede@redhat.com Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> Signed-off-by: Sasha Levin <sashal@kernel.org>
show more ...
|
#
8422a9b3 |
| 20-Sep-2021 |
Hans de Goede <hdegoede@redhat.com> |
Input: goodix - refactor reset handling
[ Upstream commit 209bda4741f68f102cf2f272227bfc938e387b51 ]
Refactor reset handling a bit, change the main reset handler into a new goodix_reset_no_int_sync
Input: goodix - refactor reset handling
[ Upstream commit 209bda4741f68f102cf2f272227bfc938e387b51 ]
Refactor reset handling a bit, change the main reset handler into a new goodix_reset_no_int_sync() helper and add a goodix_reset() wrapper which calls goodix_int_sync() separately.
Also push the dev_err() call on reset failure into the goodix_reset_no_int_sync() and goodix_int_sync() functions, so that we don't need to have separate dev_err() calls in all their callers.
This is a preparation patch for adding support for controllers without flash, which need to have their firmware uploaded and need some other special handling too.
Reviewed-by: Bastien Nocera <hadess@hadess.net> Signed-off-by: Hans de Goede <hdegoede@redhat.com> Link: https://lore.kernel.org/r/20210920150643.155872-4-hdegoede@redhat.com Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> Signed-off-by: Sasha Levin <sashal@kernel.org>
show more ...
|
#
f5b1c6d5 |
| 20-Sep-2021 |
Hans de Goede <hdegoede@redhat.com> |
Input: goodix - add a goodix.h header file
[ Upstream commit a2233cb7b65a017067e2f2703375ecc930a0ab30 ]
Add a goodix.h header file, and move the register definitions, and struct declarations there
Input: goodix - add a goodix.h header file
[ Upstream commit a2233cb7b65a017067e2f2703375ecc930a0ab30 ]
Add a goodix.h header file, and move the register definitions, and struct declarations there and add prototypes for various helper functions.
This is a preparation patch for adding support for controllers without flash, which need to have their firmware uploaded and need some other special handling too.
Since MAINTAINERS needs updating because of this change anyways, also add myself as co-maintainer.
Reviewed-by: Bastien Nocera <hadess@hadess.net> Signed-off-by: Hans de Goede <hdegoede@redhat.com> Link: https://lore.kernel.org/r/20210920150643.155872-3-hdegoede@redhat.com Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> Signed-off-by: Sasha Levin <sashal@kernel.org>
show more ...
|
#
1354ceb1 |
| 20-Sep-2021 |
Hans de Goede <hdegoede@redhat.com> |
Input: goodix - change goodix_i2c_write() len parameter type to int
[ Upstream commit 31ae0102a34ed863c7d32b10e768036324991679 ]
Change the type of the goodix_i2c_write() len parameter to from 'uns
Input: goodix - change goodix_i2c_write() len parameter type to int
[ Upstream commit 31ae0102a34ed863c7d32b10e768036324991679 ]
Change the type of the goodix_i2c_write() len parameter to from 'unsigned' to 'int' to avoid bare use of 'unsigned', changing it to 'int' makes goodix_i2c_write()' prototype consistent with goodix_i2c_read().
Reviewed-by: Bastien Nocera <hadess@hadess.net> Signed-off-by: Hans de Goede <hdegoede@redhat.com> Link: https://lore.kernel.org/r/20210920150643.155872-2-hdegoede@redhat.com Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> Signed-off-by: Sasha Levin <sashal@kernel.org>
show more ...
|
#
14039521 |
| 07-Dec-2021 |
Hans de Goede <hdegoede@redhat.com> |
Input: goodix - try not to touch the reset-pin on x86/ACPI devices
[ Upstream commit a2fd46cd3dbb83b373ba74f4043f8dae869c65f1 ]
Unless the controller is not responding at boot or after suspend/resu
Input: goodix - try not to touch the reset-pin on x86/ACPI devices
[ Upstream commit a2fd46cd3dbb83b373ba74f4043f8dae869c65f1 ]
Unless the controller is not responding at boot or after suspend/resume, the driver never resets the controller on x86/ACPI platforms. The driver still requesting the reset pin at probe() though in case it needs it.
Until now the driver has always requested the reset pin with GPIOD_IN as type. The idea being to put the pin in high-impedance mode to save power until the driver actually wants to issue a reset.
But this means that just requesting the pin can cause issues, since requesting it in another mode then GPIOD_ASIS may cause the pinctrl driver to touch the pin settings. We have already had issues before due to a bug in the pinctrl-cherryview.c driver which has been fixed in commit 921daeeca91b ("pinctrl: cherryview: Preserve CHV_PADCTRL1_INVRXTX_TXDATA flag on GPIOs").
And now it turns out that requesting the reset-pin as GPIOD_IN also stops the touchscreen from working on the GPD P2 max mini-laptop. The behavior of putting the pin in high-impedance mode relies on there being some external pull-up to keep it high and there seems to be no pull-up on the GPD P2 max, causing things to break.
This commit fixes this by requesting the reset pin as is when using the x86/ACPI code paths to lookup the GPIOs; and by not dropping it back into input-mode in case the driver does end up issuing a reset for error-recovery.
BugLink: https://bugzilla.kernel.org/show_bug.cgi?id=209061 Fixes: a7d4b171660c ("Input: goodix - add support for getting IRQ + reset GPIOs on Cherry Trail devices") Cc: stable@vger.kernel.org Signed-off-by: Hans de Goede <hdegoede@redhat.com> Link: https://lore.kernel.org/r/20211206091116.44466-2-hdegoede@redhat.com Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> Signed-off-by: Sasha Levin <sashal@kernel.org>
show more ...
|
#
8422a9b3 |
| 20-Sep-2021 |
Hans de Goede <hdegoede@redhat.com> |
Input: goodix - refactor reset handling
[ Upstream commit 209bda4741f68f102cf2f272227bfc938e387b51 ]
Refactor reset handling a bit, change the main reset handler into a new goodix_reset_no_int_sync
Input: goodix - refactor reset handling
[ Upstream commit 209bda4741f68f102cf2f272227bfc938e387b51 ]
Refactor reset handling a bit, change the main reset handler into a new goodix_reset_no_int_sync() helper and add a goodix_reset() wrapper which calls goodix_int_sync() separately.
Also push the dev_err() call on reset failure into the goodix_reset_no_int_sync() and goodix_int_sync() functions, so that we don't need to have separate dev_err() calls in all their callers.
This is a preparation patch for adding support for controllers without flash, which need to have their firmware uploaded and need some other special handling too.
Reviewed-by: Bastien Nocera <hadess@hadess.net> Signed-off-by: Hans de Goede <hdegoede@redhat.com> Link: https://lore.kernel.org/r/20210920150643.155872-4-hdegoede@redhat.com Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> Signed-off-by: Sasha Levin <sashal@kernel.org>
show more ...
|
#
f5b1c6d5 |
| 20-Sep-2021 |
Hans de Goede <hdegoede@redhat.com> |
Input: goodix - add a goodix.h header file
[ Upstream commit a2233cb7b65a017067e2f2703375ecc930a0ab30 ]
Add a goodix.h header file, and move the register definitions, and struct declarations there
Input: goodix - add a goodix.h header file
[ Upstream commit a2233cb7b65a017067e2f2703375ecc930a0ab30 ]
Add a goodix.h header file, and move the register definitions, and struct declarations there and add prototypes for various helper functions.
This is a preparation patch for adding support for controllers without flash, which need to have their firmware uploaded and need some other special handling too.
Since MAINTAINERS needs updating because of this change anyways, also add myself as co-maintainer.
Reviewed-by: Bastien Nocera <hadess@hadess.net> Signed-off-by: Hans de Goede <hdegoede@redhat.com> Link: https://lore.kernel.org/r/20210920150643.155872-3-hdegoede@redhat.com Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> Signed-off-by: Sasha Levin <sashal@kernel.org>
show more ...
|
#
1354ceb1 |
| 20-Sep-2021 |
Hans de Goede <hdegoede@redhat.com> |
Input: goodix - change goodix_i2c_write() len parameter type to int
[ Upstream commit 31ae0102a34ed863c7d32b10e768036324991679 ]
Change the type of the goodix_i2c_write() len parameter to from 'uns
Input: goodix - change goodix_i2c_write() len parameter type to int
[ Upstream commit 31ae0102a34ed863c7d32b10e768036324991679 ]
Change the type of the goodix_i2c_write() len parameter to from 'unsigned' to 'int' to avoid bare use of 'unsigned', changing it to 'int' makes goodix_i2c_write()' prototype consistent with goodix_i2c_read().
Reviewed-by: Bastien Nocera <hadess@hadess.net> Signed-off-by: Hans de Goede <hdegoede@redhat.com> Link: https://lore.kernel.org/r/20210920150643.155872-2-hdegoede@redhat.com Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> Signed-off-by: Sasha Levin <sashal@kernel.org>
show more ...
|
#
14039521 |
| 07-Dec-2021 |
Hans de Goede <hdegoede@redhat.com> |
Input: goodix - try not to touch the reset-pin on x86/ACPI devices
[ Upstream commit a2fd46cd3dbb83b373ba74f4043f8dae869c65f1 ]
Unless the controller is not responding at boot or after suspend/resu
Input: goodix - try not to touch the reset-pin on x86/ACPI devices
[ Upstream commit a2fd46cd3dbb83b373ba74f4043f8dae869c65f1 ]
Unless the controller is not responding at boot or after suspend/resume, the driver never resets the controller on x86/ACPI platforms. The driver still requesting the reset pin at probe() though in case it needs it.
Until now the driver has always requested the reset pin with GPIOD_IN as type. The idea being to put the pin in high-impedance mode to save power until the driver actually wants to issue a reset.
But this means that just requesting the pin can cause issues, since requesting it in another mode then GPIOD_ASIS may cause the pinctrl driver to touch the pin settings. We have already had issues before due to a bug in the pinctrl-cherryview.c driver which has been fixed in commit 921daeeca91b ("pinctrl: cherryview: Preserve CHV_PADCTRL1_INVRXTX_TXDATA flag on GPIOs").
And now it turns out that requesting the reset-pin as GPIOD_IN also stops the touchscreen from working on the GPD P2 max mini-laptop. The behavior of putting the pin in high-impedance mode relies on there being some external pull-up to keep it high and there seems to be no pull-up on the GPD P2 max, causing things to break.
This commit fixes this by requesting the reset pin as is when using the x86/ACPI code paths to lookup the GPIOs; and by not dropping it back into input-mode in case the driver does end up issuing a reset for error-recovery.
BugLink: https://bugzilla.kernel.org/show_bug.cgi?id=209061 Fixes: a7d4b171660c ("Input: goodix - add support for getting IRQ + reset GPIOs on Cherry Trail devices") Cc: stable@vger.kernel.org Signed-off-by: Hans de Goede <hdegoede@redhat.com> Link: https://lore.kernel.org/r/20211206091116.44466-2-hdegoede@redhat.com Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> Signed-off-by: Sasha Levin <sashal@kernel.org>
show more ...
|
#
8422a9b3 |
| 20-Sep-2021 |
Hans de Goede <hdegoede@redhat.com> |
Input: goodix - refactor reset handling
[ Upstream commit 209bda4741f68f102cf2f272227bfc938e387b51 ]
Refactor reset handling a bit, change the main reset handler into a new goodix_reset_no_int_sync
Input: goodix - refactor reset handling
[ Upstream commit 209bda4741f68f102cf2f272227bfc938e387b51 ]
Refactor reset handling a bit, change the main reset handler into a new goodix_reset_no_int_sync() helper and add a goodix_reset() wrapper which calls goodix_int_sync() separately.
Also push the dev_err() call on reset failure into the goodix_reset_no_int_sync() and goodix_int_sync() functions, so that we don't need to have separate dev_err() calls in all their callers.
This is a preparation patch for adding support for controllers without flash, which need to have their firmware uploaded and need some other special handling too.
Reviewed-by: Bastien Nocera <hadess@hadess.net> Signed-off-by: Hans de Goede <hdegoede@redhat.com> Link: https://lore.kernel.org/r/20210920150643.155872-4-hdegoede@redhat.com Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> Signed-off-by: Sasha Levin <sashal@kernel.org>
show more ...
|
#
f5b1c6d5 |
| 20-Sep-2021 |
Hans de Goede <hdegoede@redhat.com> |
Input: goodix - add a goodix.h header file
[ Upstream commit a2233cb7b65a017067e2f2703375ecc930a0ab30 ]
Add a goodix.h header file, and move the register definitions, and struct declarations there
Input: goodix - add a goodix.h header file
[ Upstream commit a2233cb7b65a017067e2f2703375ecc930a0ab30 ]
Add a goodix.h header file, and move the register definitions, and struct declarations there and add prototypes for various helper functions.
This is a preparation patch for adding support for controllers without flash, which need to have their firmware uploaded and need some other special handling too.
Since MAINTAINERS needs updating because of this change anyways, also add myself as co-maintainer.
Reviewed-by: Bastien Nocera <hadess@hadess.net> Signed-off-by: Hans de Goede <hdegoede@redhat.com> Link: https://lore.kernel.org/r/20210920150643.155872-3-hdegoede@redhat.com Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> Signed-off-by: Sasha Levin <sashal@kernel.org>
show more ...
|
#
1354ceb1 |
| 20-Sep-2021 |
Hans de Goede <hdegoede@redhat.com> |
Input: goodix - change goodix_i2c_write() len parameter type to int
[ Upstream commit 31ae0102a34ed863c7d32b10e768036324991679 ]
Change the type of the goodix_i2c_write() len parameter to from 'uns
Input: goodix - change goodix_i2c_write() len parameter type to int
[ Upstream commit 31ae0102a34ed863c7d32b10e768036324991679 ]
Change the type of the goodix_i2c_write() len parameter to from 'unsigned' to 'int' to avoid bare use of 'unsigned', changing it to 'int' makes goodix_i2c_write()' prototype consistent with goodix_i2c_read().
Reviewed-by: Bastien Nocera <hadess@hadess.net> Signed-off-by: Hans de Goede <hdegoede@redhat.com> Link: https://lore.kernel.org/r/20210920150643.155872-2-hdegoede@redhat.com Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> Signed-off-by: Sasha Levin <sashal@kernel.org>
show more ...
|
#
14039521 |
| 07-Dec-2021 |
Hans de Goede <hdegoede@redhat.com> |
Input: goodix - try not to touch the reset-pin on x86/ACPI devices
[ Upstream commit a2fd46cd3dbb83b373ba74f4043f8dae869c65f1 ]
Unless the controller is not responding at boot or after suspend/resu
Input: goodix - try not to touch the reset-pin on x86/ACPI devices
[ Upstream commit a2fd46cd3dbb83b373ba74f4043f8dae869c65f1 ]
Unless the controller is not responding at boot or after suspend/resume, the driver never resets the controller on x86/ACPI platforms. The driver still requesting the reset pin at probe() though in case it needs it.
Until now the driver has always requested the reset pin with GPIOD_IN as type. The idea being to put the pin in high-impedance mode to save power until the driver actually wants to issue a reset.
But this means that just requesting the pin can cause issues, since requesting it in another mode then GPIOD_ASIS may cause the pinctrl driver to touch the pin settings. We have already had issues before due to a bug in the pinctrl-cherryview.c driver which has been fixed in commit 921daeeca91b ("pinctrl: cherryview: Preserve CHV_PADCTRL1_INVRXTX_TXDATA flag on GPIOs").
And now it turns out that requesting the reset-pin as GPIOD_IN also stops the touchscreen from working on the GPD P2 max mini-laptop. The behavior of putting the pin in high-impedance mode relies on there being some external pull-up to keep it high and there seems to be no pull-up on the GPD P2 max, causing things to break.
This commit fixes this by requesting the reset pin as is when using the x86/ACPI code paths to lookup the GPIOs; and by not dropping it back into input-mode in case the driver does end up issuing a reset for error-recovery.
BugLink: https://bugzilla.kernel.org/show_bug.cgi?id=209061 Fixes: a7d4b171660c ("Input: goodix - add support for getting IRQ + reset GPIOs on Cherry Trail devices") Cc: stable@vger.kernel.org Signed-off-by: Hans de Goede <hdegoede@redhat.com> Link: https://lore.kernel.org/r/20211206091116.44466-2-hdegoede@redhat.com Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> Signed-off-by: Sasha Levin <sashal@kernel.org>
show more ...
|
#
8422a9b3 |
| 20-Sep-2021 |
Hans de Goede <hdegoede@redhat.com> |
Input: goodix - refactor reset handling
[ Upstream commit 209bda4741f68f102cf2f272227bfc938e387b51 ]
Refactor reset handling a bit, change the main reset handler into a new goodix_reset_no_int_sync
Input: goodix - refactor reset handling
[ Upstream commit 209bda4741f68f102cf2f272227bfc938e387b51 ]
Refactor reset handling a bit, change the main reset handler into a new goodix_reset_no_int_sync() helper and add a goodix_reset() wrapper which calls goodix_int_sync() separately.
Also push the dev_err() call on reset failure into the goodix_reset_no_int_sync() and goodix_int_sync() functions, so that we don't need to have separate dev_err() calls in all their callers.
This is a preparation patch for adding support for controllers without flash, which need to have their firmware uploaded and need some other special handling too.
Reviewed-by: Bastien Nocera <hadess@hadess.net> Signed-off-by: Hans de Goede <hdegoede@redhat.com> Link: https://lore.kernel.org/r/20210920150643.155872-4-hdegoede@redhat.com Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> Signed-off-by: Sasha Levin <sashal@kernel.org>
show more ...
|
#
f5b1c6d5 |
| 20-Sep-2021 |
Hans de Goede <hdegoede@redhat.com> |
Input: goodix - add a goodix.h header file
[ Upstream commit a2233cb7b65a017067e2f2703375ecc930a0ab30 ]
Add a goodix.h header file, and move the register definitions, and struct declarations there
Input: goodix - add a goodix.h header file
[ Upstream commit a2233cb7b65a017067e2f2703375ecc930a0ab30 ]
Add a goodix.h header file, and move the register definitions, and struct declarations there and add prototypes for various helper functions.
This is a preparation patch for adding support for controllers without flash, which need to have their firmware uploaded and need some other special handling too.
Since MAINTAINERS needs updating because of this change anyways, also add myself as co-maintainer.
Reviewed-by: Bastien Nocera <hadess@hadess.net> Signed-off-by: Hans de Goede <hdegoede@redhat.com> Link: https://lore.kernel.org/r/20210920150643.155872-3-hdegoede@redhat.com Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> Signed-off-by: Sasha Levin <sashal@kernel.org>
show more ...
|
#
1354ceb1 |
| 20-Sep-2021 |
Hans de Goede <hdegoede@redhat.com> |
Input: goodix - change goodix_i2c_write() len parameter type to int
[ Upstream commit 31ae0102a34ed863c7d32b10e768036324991679 ]
Change the type of the goodix_i2c_write() len parameter to from 'uns
Input: goodix - change goodix_i2c_write() len parameter type to int
[ Upstream commit 31ae0102a34ed863c7d32b10e768036324991679 ]
Change the type of the goodix_i2c_write() len parameter to from 'unsigned' to 'int' to avoid bare use of 'unsigned', changing it to 'int' makes goodix_i2c_write()' prototype consistent with goodix_i2c_read().
Reviewed-by: Bastien Nocera <hadess@hadess.net> Signed-off-by: Hans de Goede <hdegoede@redhat.com> Link: https://lore.kernel.org/r/20210920150643.155872-2-hdegoede@redhat.com Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> Signed-off-by: Sasha Levin <sashal@kernel.org>
show more ...
|