mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Hans de Goede <hdegoede@redhat.com>
To: Andy Shevchenko <andy.shevchenko@gmail.com>
Cc: MyungJoo Ham <myungjoo.ham@samsung.com>,
	Chanwoo Choi <cw00.choi@samsung.com>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Subject: Re: [PATCH 2/2] extcon: int3496: Explicitly set the id pin to direction-input
Date: Mon, 13 Mar 2017 08:27:45 +0100	[thread overview]
Message-ID: <d94e6318-da4c-755d-8e3d-04fa57d4f79f@redhat.com> (raw)
In-Reply-To: <CAHp75VeZ89jvW_xreFEaao2beafJUZTyfcrH6fa+rpp6ta4Dsw@mail.gmail.com>

Hi,

On 10-03-17 23:11, Andy Shevchenko wrote:
> On Fri, Mar 10, 2017 at 10:52 PM, Hans de Goede <hdegoede@redhat.com> wrote:
>> With the new more strict ACPI gpio code the dsdt's IoRestriction
>> flags are honored on gpiod_get, but in some dsdt's it is wrong,
>> so explicitly call gpiod_direction_input on the id gpio.
>>
>> This fixes the following errors when the int3496 code is used
>> together with the new more strict ACPI gpio code:
>>
>> [ 2382.484415] gpio gpiochip1: (INT33FF:01): gpiochip_lock_as_irq: tried to flag a GPIO set as output for IRQ
>> [ 2382.484425] gpio gpiochip1: (INT33FF:01): unable to lock HW IRQ 3 for IRQ
>> [ 2382.484429] genirq: Failed to request resources for INT3496:00 (irq 174) on irqchip chv-gpio
>> [ 2382.484518] intel-int3496 INT3496:00: can't request IRQ for USB ID GPIO: -22
>> [ 2382.500359] intel-int3496: probe of INT3496:00 failed with error -22
>
> Because my patches are not yet upstreamed I think this would be postponed.
> I can take it into my branch and send together with the rest. What do you think?

It does not hurt to get it upstream already and merging patch-sets generally
is a lot easier if they do not span multiple subsystems. So I think it would
be better to get it upstream already as preparation for your series.

>
>> --- a/drivers/extcon/extcon-intel-int3496.c
>> +++ b/drivers/extcon/extcon-intel-int3496.c
>> @@ -113,6 +113,7 @@ static int int3496_probe(struct platform_device *pdev)
>>                 dev_err(dev, "can't request USB ID GPIO: %d\n", ret);
>>                 return ret;
>>         }
>
> It would be nice to check the direction here and complain to the user
> loudly the firmware has a bug.

Ok, I will send a v2 doing this.


>
>> +       gpiod_direction_input(data->gpio_usb_id);
>

Regards,

Hans

  reply	other threads:[~2017-03-13  7:27 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <CGME20170310205217epcas2p43f76d99969d753701b9911e601ba6232@epcas2p4.samsung.com>
2017-03-10 20:52 ` [PATCH 1/2] extcon: int3496: Use gpiod_get instead of gpiod_get_index Hans de Goede
2017-03-10 20:52   ` [PATCH 2/2] extcon: int3496: Explicitly set the id pin to direction-input Hans de Goede
2017-03-10 22:11     ` Andy Shevchenko
2017-03-13  7:27       ` Hans de Goede [this message]
2017-03-10 22:09   ` [PATCH 1/2] extcon: int3496: Use gpiod_get instead of gpiod_get_index Andy Shevchenko
2017-03-13  5:03   ` Chanwoo Choi

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=d94e6318-da4c-755d-8e3d-04fa57d4f79f@redhat.com \
    --to=hdegoede@redhat.com \
    --cc=andriy.shevchenko@linux.intel.com \
    --cc=andy.shevchenko@gmail.com \
    --cc=cw00.choi@samsung.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=myungjoo.ham@samsung.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

Powered by JetHome