mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Andrew Lunn <andrew@lunn.ch>
To: Chen Minqiang <ptpt52@gmail.com>
Cc: Rob Herring <robh@kernel.org>,
	Krzysztof Kozlowski <krzk+dt@kernel.org>,
	Conor Dooley <conor+dt@kernel.org>,
	Matthias Brugger <matthias.bgg@gmail.com>,
	AngeloGioacchino Del Regno
	<angelogioacchino.delregno@collabora.com>,
	"Chester A. Unal" <chester.a.unal@arinc9.com>,
	Daniel Golle <daniel@makrotopia.org>,
	DENG Qingfang <dqfext@gmail.com>,
	Sean Wang <sean.wang@mediatek.com>,
	linux-kernel@vger.kernel.org,
	linux-arm-kernel@lists.infradead.org,
	linux-mediatek@lists.infradead.org, netdev@vger.kernel.org
Subject: Re: [PATCH] ARM64: dts: mediatek: fix MT7531 reset polarity and reset sequence
Date: Thu, 20 Nov 2025 22:09:28 +0100	[thread overview]
Message-ID: <f8e9184a-2b29-461a-907b-9e17856b5d89@lunn.ch> (raw)
In-Reply-To: <20251120162225.13993-1-ptpt52@gmail.com>

On Fri, Nov 21, 2025 at 12:22:24AM +0800, Chen Minqiang wrote:
> The MT7531 reset pin is active-low, but multiple MediaTek boards describe
> the reset-gpios property without GPIO_ACTIVE_LOW or incorrectly mark it
> as active-high. With an active-low GPIO, gpiod_set_value(1) drives the
> line low (assert reset) and gpiod_set_value(0) drives it high (deassert).
> 
> Update all affected DTS files to explicitly use GPIO_ACTIVE_LOW so that
> the reset polarity matches the hardware design.
> 
> Additionally, adjust the mt7530 driver reset sequence to correctly assert
> reset by driving the GPIO low first, wait for the reset interval, and
> then deassert reset by driving the GPIO high.
> 
> Boards fixed:
>  - mt7622-bananapi-bpi-r64
>  - mt7622-rfb1
>  - mt7986a-bananapi-bpi-r3
>  - mt7986a-rfb
>  - mt7986b-rfb
> 
> This ensures the MT7531 receives a proper low-to-high active-low reset
> pulse and initializes reliably.

Please add a comment to the commit message about backwards/forwards
compatibility, how this is safe when booting an old DT blob on a new
kernel. Or a new DT blob on an old kernel. We don't expect regressions
in such cases, and it is good to indicate in the commit message you
have thought about this and don't expect problems.

    Andrew

---
pw-bot: cr

      parent reply	other threads:[~2025-11-20 21:09 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-11-20 16:22 Chen Minqiang
2025-11-20 16:45 ` Jakub Kicinski
2025-11-20 21:09 ` Andrew Lunn [this message]

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=f8e9184a-2b29-461a-907b-9e17856b5d89@lunn.ch \
    --to=andrew@lunn.ch \
    --cc=angelogioacchino.delregno@collabora.com \
    --cc=chester.a.unal@arinc9.com \
    --cc=conor+dt@kernel.org \
    --cc=daniel@makrotopia.org \
    --cc=dqfext@gmail.com \
    --cc=krzk+dt@kernel.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mediatek@lists.infradead.org \
    --cc=matthias.bgg@gmail.com \
    --cc=netdev@vger.kernel.org \
    --cc=ptpt52@gmail.com \
    --cc=robh@kernel.org \
    --cc=sean.wang@mediatek.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

all inboxes | Powered by JetHome®