mirror of
https://xff.cz/git/u-boot/
synced 2025-09-01 00:32:04 +02:00
input: goodix: Fix address initialization
Pinetab2 has a different address than 0x14 configured by holding IRQ line high. Signed-off-by: Ondrej Jirman <megi@xff.cz>
This commit is contained in:
@@ -365,6 +365,7 @@ static int goodix_stop(struct udevice *dev)
|
|||||||
static int goodix_probe(struct udevice *dev)
|
static int goodix_probe(struct udevice *dev)
|
||||||
{
|
{
|
||||||
struct touchpanel_priv *uc_priv = dev_get_uclass_priv(dev);
|
struct touchpanel_priv *uc_priv = dev_get_uclass_priv(dev);
|
||||||
|
struct dm_i2c_chip *chip = dev_get_parent_plat(dev);
|
||||||
struct goodix_priv *ts = dev_get_priv(dev);
|
struct goodix_priv *ts = dev_get_priv(dev);
|
||||||
int ret;
|
int ret;
|
||||||
|
|
||||||
@@ -416,8 +417,8 @@ static int goodix_probe(struct udevice *dev)
|
|||||||
udelay(30 * 1000);
|
udelay(30 * 1000);
|
||||||
|
|
||||||
if (dm_gpio_is_valid(&ts->reset_gpio)) {
|
if (dm_gpio_is_valid(&ts->reset_gpio)) {
|
||||||
// select address 0x14
|
// select address
|
||||||
ret = dm_gpio_set_value(&ts->irq_gpio, 1);
|
ret = dm_gpio_set_value(&ts->irq_gpio, chip->chip_addr == 0x14 ? 1 : 0);
|
||||||
if (ret)
|
if (ret)
|
||||||
return ret;
|
return ret;
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user