From: Daniel Almeida <daniel.almeida@collabora.com>
To: Nicolas Dufresne <nicolas.dufresne@collabora.com>
Cc: "Miguel Ojeda" <ojeda@kernel.org>,
"Boqun Feng" <boqun@kernel.org>, "Gary Guo" <gary@garyguo.net>,
"Björn Roy Baron" <bjorn3_gh@protonmail.com>,
"Benno Lossin" <lossin@kernel.org>,
"Andreas Hindborg" <a.hindborg@kernel.org>,
"Alice Ryhl" <aliceryhl@google.com>,
"Trevor Gross" <tmgross@umich.edu>,
"Danilo Krummrich" <dakr@kernel.org>,
"Tamir Duberstein" <tamird@kernel.org>,
"Alexandre Courbot" <acourbot@nvidia.com>,
"Onur Özkan" <work@onurozkan.dev>,
"Philipp Zabel" <p.zabel@pengutronix.de>,
linux-kernel@vger.kernel.org, rust-for-linux@vger.kernel.org,
dri-devel@lists.freedesktop.org,
"Detlev Casanova" <detlev.casanova@collabora.com>
Subject: Re: [PATCH 0/7] rust: reset: add reset control abstractions
Date: Thu, 26 Nov 2026 15:02:34 -0300 [thread overview]
Message-ID: <299B626E-DC60-4175-9D66-2DE58BA5070A@collabora.com> (raw)
In-Reply-To: <6300821339d6891983af704e2044fd1ed25285f6.camel@collabora.com>
Hi Nicolas,
> On 26 Nov 2026, at 13:33, Nicolas Dufresne <nicolas.dufresne@collabora.com> wrote:
>
> Hi Daniel,
>
> Le jeudi 26 novembre 2026 à 13:04 -0300, Daniel Almeida a écrit :
>> This series adds a Rust abstraction for the consumer side of the reset
>> controller API. A driver can get the reset lines of its device, as an
>> exclusive or a shared reset control, and assert and deassert them.
>>
>> This will be used by the upcoming rkvenc driver that my colleagues
>> Detlev Casanova, Nicolas Dufresne and I are working on, to recover a
>> hung core of the encoder without stopping the other one. More details on
>> this driver can be found by watching Nicolas Dufresne's talk at LPC 2026
>> [0]. Samsung's Rust UFS RFC [1] also uses reset lines, through an
>> abstraction that it has not posted.
>
> I don't mind being cited, but please give a heads-up, we haven't discussed any
> of this, so I can't really comment if its a good or bad idea. On the C side,
> shared reset don't really work today, so I'm left wondering.
>
> Nicolas
>
Fair, sorry for not giving you a heads-up. I have a branch a bit
further ahead where I have tested both encoder cores at once, including
this change. Due to the hierarchy of the power domains, to power down
core 0, you also need to power down core 1. In other words, if core 0
becomes stuck, there is no way to bring it back by means of a power
cycle without also stopping the jobs running on core 1.
This series mainly makes it possible to access the reset lines in an
established pattern (e.g. Regulator<T> already uses it, and so does the
Clk<T> series). For rkvenc, it allows pulsing only the lines of the
affected core.
Reset lines haven't come up so far because with only a single core
powered up, a power cycle is fine, since there is no other core to
affect anyway.
Also note that rkvenc does not use SharedResetControl, but I ended up
deciding to make it available as well. The same can be said of Clk<T>,
where we have devm_ and other conveniences like guards that are not
necessarily used at the moment, but that make sense when you look at
what a lot of C drivers tend to need and carry that over to Rust.
What does not work with shared resets on the C side?
— Daniel
next prev parent reply other threads:[~2026-11-26 18:04 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-11-26 16:04 Daniel Almeida
2026-11-26 16:04 ` [PATCH 1/7] rust: reset: add reset control helpers Daniel Almeida
2026-11-26 16:04 ` [PATCH 2/7] rust: reset: add ExclusiveResetControl Daniel Almeida
2026-11-26 16:04 ` [PATCH 3/7] rust: reset: add ExclusiveResetControl::get_array() and get_array_optional() Daniel Almeida
2026-11-26 16:04 ` [PATCH 4/7] rust: reset: add AssertedGuard Daniel Almeida
2026-11-26 16:04 ` [PATCH 5/7] rust: reset: add SharedResetControl Daniel Almeida
2026-11-26 19:14 ` Alice Ryhl
2026-11-26 16:04 ` [PATCH 6/7] rust: reset: add SharedResetControl::get_array() and get_array_optional() Daniel Almeida
2026-11-26 16:04 ` [PATCH 7/7] rust: reset: add devm_deassert() and devm_deassert_optional() Daniel Almeida
2026-11-26 16:33 ` [PATCH 0/7] rust: reset: add reset control abstractions Nicolas Dufresne
2026-11-26 18:02 ` Daniel Almeida [this message]
2026-11-26 18:11 ` Nicolas Dufresne
2026-11-26 18:36 ` Daniel Almeida
2026-11-26 18:46 ` Nicolas Dufresne
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=299B626E-DC60-4175-9D66-2DE58BA5070A@collabora.com \
--to=daniel.almeida@collabora.com \
--cc=a.hindborg@kernel.org \
--cc=acourbot@nvidia.com \
--cc=aliceryhl@google.com \
--cc=bjorn3_gh@protonmail.com \
--cc=boqun@kernel.org \
--cc=dakr@kernel.org \
--cc=detlev.casanova@collabora.com \
--cc=dri-devel@lists.freedesktop.org \
--cc=gary@garyguo.net \
--cc=linux-kernel@vger.kernel.org \
--cc=lossin@kernel.org \
--cc=nicolas.dufresne@collabora.com \
--cc=ojeda@kernel.org \
--cc=p.zabel@pengutronix.de \
--cc=rust-for-linux@vger.kernel.org \
--cc=tamird@kernel.org \
--cc=tmgross@umich.edu \
--cc=work@onurozkan.dev \
/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®