linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Marek Szyprowski <m.szyprowski@samsung.com>
To: Krzysztof Kozlowski <krzk@kernel.org>,
	Rob Herring <robh+dt@kernel.org>,
	Bartlomiej Zolnierkiewicz <b.zolnierkie@samsung.com>,
	Lee Jones <lee.jones@linaro.org>,
	Chanwoo Choi <cw00.choi@samsung.com>,
	devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org,
	linux-samsung-soc@vger.kernel.org, linux-kernel@vger.kernel.org
Cc: Sylwester Nawrocki <snawrocki@kernel.org>
Subject: Re: [PATCH 9/9] mfd: sec-irq: Do not enforce (incorrect) interrupt trigger type
Date: Fri, 18 Dec 2020 14:25:39 +0100	[thread overview]
Message-ID: <0f1509ef-9ae7-7a77-84b7-360b8f0071c7@samsung.com> (raw)
In-Reply-To: <20201210212903.216728-9-krzk@kernel.org>

On 10.12.2020 22:29, Krzysztof Kozlowski wrote:
> Interrupt line can be configured on different hardware in different way,
> even inverted.  Therefore driver should not enforce specific trigger
> type - edge falling - but instead rely on Devicetree to configure it.
>
> The Samsung PMIC drivers are used only on Devicetree boards.
>
> Additionally, the PMIC datasheets describe the interrupt line as active
> low with a requirement of acknowledge from the CPU therefore the edge
> falling is not correct.
>
> Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org>

Tested-by: Marek Szyprowski <m.szyprowski@samsung.com>

It looks that this together with DTS change fixes RTC alarm failure that 
I've observed from time to time on TM2e board!

> ---
>
> This patch should wait till DTS changes are merged, as it relies on
> proper Devicetree.
> ---
>   drivers/mfd/sec-irq.c | 3 +--
>   1 file changed, 1 insertion(+), 2 deletions(-)
>
> diff --git a/drivers/mfd/sec-irq.c b/drivers/mfd/sec-irq.c
> index a98c5d165039..760f88a865ab 100644
> --- a/drivers/mfd/sec-irq.c
> +++ b/drivers/mfd/sec-irq.c
> @@ -480,8 +480,7 @@ int sec_irq_init(struct sec_pmic_dev *sec_pmic)
>   	}
>   
>   	ret = devm_regmap_add_irq_chip(sec_pmic->dev, sec_pmic->regmap_pmic,
> -				       sec_pmic->irq,
> -				       IRQF_TRIGGER_FALLING | IRQF_ONESHOT,
> +				       sec_pmic->irq, IRQF_ONESHOT,
>   				       sec_pmic->irq_base, sec_irq_chip,
>   				       &sec_pmic->irq_data);
>   	if (ret != 0) {

Best regards
-- 
Marek Szyprowski, PhD
Samsung R&D Institute Poland


  reply	other threads:[~2020-12-18 13:26 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <CGME20201210212917eucas1p2d0bc9a3099abfc2d2c223facc86be03e@eucas1p2.samsung.com>
2020-12-10 21:28 ` [PATCH 1/9] ARM: dts: exynos: correct PMIC interrupt trigger level on Artik 5 Krzysztof Kozlowski
2020-12-10 21:28   ` [PATCH 2/9] ARM: dts: exynos: correct PMIC interrupt trigger level on Monk Krzysztof Kozlowski
2020-12-10 21:28   ` [PATCH 3/9] ARM: dts: exynos: correct PMIC interrupt trigger level on Rinato Krzysztof Kozlowski
2020-12-11 15:49     ` Marek Szyprowski
2020-12-10 21:28   ` [PATCH 4/9] ARM: dts: exynos: correct PMIC interrupt trigger level on Spring Krzysztof Kozlowski
2020-12-10 21:28   ` [PATCH 5/9] ARM: dts: exynos: correct PMIC interrupt trigger level on Arndale Octa Krzysztof Kozlowski
2020-12-11 15:51     ` Marek Szyprowski
2020-12-10 21:29   ` [PATCH 6/9] ARM: dts: exynos: correct PMIC interrupt trigger level on Odroid XU3 family Krzysztof Kozlowski
2020-12-11 15:49     ` Marek Szyprowski
2020-12-10 21:29   ` [PATCH 7/9] arm64: dts: exynos: correct PMIC interrupt trigger level on TM2 Krzysztof Kozlowski
2020-12-18 12:46     ` Marek Szyprowski
2020-12-10 21:29   ` [PATCH 8/9] arm64: dts: exynos: correct PMIC interrupt trigger level on Espresso Krzysztof Kozlowski
2020-12-10 21:29   ` [PATCH 9/9] mfd: sec-irq: Do not enforce (incorrect) interrupt trigger type Krzysztof Kozlowski
2020-12-18 13:25     ` Marek Szyprowski [this message]
2020-12-18 14:22       ` Krzysztof Kozlowski
2020-12-21  7:36         ` Marek Szyprowski
2020-12-21  7:55           ` Krzysztof Kozlowski
2020-12-21  8:25             ` Marek Szyprowski
2020-12-11 15:49   ` [PATCH 1/9] ARM: dts: exynos: correct PMIC interrupt trigger level on Artik 5 Marek Szyprowski
2020-12-29 15:59   ` Krzysztof Kozlowski

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=0f1509ef-9ae7-7a77-84b7-360b8f0071c7@samsung.com \
    --to=m.szyprowski@samsung.com \
    --cc=b.zolnierkie@samsung.com \
    --cc=cw00.choi@samsung.com \
    --cc=devicetree@vger.kernel.org \
    --cc=krzk@kernel.org \
    --cc=lee.jones@linaro.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-samsung-soc@vger.kernel.org \
    --cc=robh+dt@kernel.org \
    --cc=snawrocki@kernel.org \
    /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;
as well as URLs for NNTP newsgroup(s).