From: Alice Ryhl <aliceryhl@google.com>
To: "Uwe Kleine-König" <ukleinek@kernel.org>
Cc: Stephen Rothwell <sfr@canb.auug.org.au>,
Michal Wilczynski <m.wilczynski@samsung.com>,
Danilo Krummrich <dakr@kernel.org>,
Boqun Feng <boqun.feng@gmail.com>,
Daniel Almeida <daniel.almeida@collabora.com>,
Peter Colberg <pcolberg@redhat.com>,
Lyude Paul <lyude@redhat.com>, Miguel Ojeda <ojeda@kernel.org>,
Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
Linux Next Mailing List <linux-next@vger.kernel.org>,
Viresh Kumar <viresh.kumar@linaro.org>,
Alexandre Courbot <acourbot@nvidia.com>,
Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Subject: Re: linux-next: build failure after merge of the pwm tree'
Date: Tue, 28 Oct 2025 09:52:11 +0000 [thread overview]
Message-ID: <aQCSS_h47zUVilno@google.com> (raw)
In-Reply-To: <22fl35khmbf6ufyjzbfvxor7b6nohqakqovjoya3v4mmlenz5c@6wbdednrd2pb>
On Mon, Oct 27, 2025 at 09:11:31AM +0100, Uwe Kleine-König wrote:
> Hello Stephen,
>
> thanks for your report (and creating next each day!)
>
> On Mon, Oct 27, 2025 at 12:51:48PM +1100, Stephen Rothwell wrote:
> > After merging the pwm tree, today's linux-next build (x86_64 allmodconfig)
> > failed like this:
> >
> > error[E0277]: the trait bound `core::result::Result<core::pin::Pin<Box<Th1520PwmPlatformDriver, Kmalloc>>, kernel::error::Error>: PinInit<Th1520PwmPlatformDriver, kernel::error::Error>` is not satisfied
> > --> drivers/pwm/pwm_th1520.rs:331:10
> > |
> > 331 | ) -> Result<Pin<KBox<Self>>> {
> > | ^^^^^^^^^^^^^^^^^^^^^^^ unsatisfied trait bound
> > |
> > = help: the trait `PinInit<Th1520PwmPlatformDriver, kernel::error::Error>` is not implemented for `Result<Pin<Box<Th1520PwmPlatformDriver, Kmalloc>>, Error>`
> > but trait `PinInit<core::pin::Pin<Box<Th1520PwmPlatformDriver, Kmalloc>>, kernel::error::Error>` is implemented for it
> > = help: for that trait implementation, expected `core::pin::Pin<Box<Th1520PwmPlatformDriver, Kmalloc>>`, found `Th1520PwmPlatformDriver`
> > note: required by a bound in `kernel::platform::Driver::{synthetic#0}`
> > --> rust/kernel/platform.rs:196:15
> > |
> > 196 | ) -> impl PinInit<Self, Error>;
> > | ^^^^^^^^^^^^^^^^^^^^ required by this bound in `Driver::{synthetic#0}`
> >
> > error: aborting due to 1 previous error
> >
> > For more information about this error, try `rustc --explain E0277`.
> >
> > Caused by commit
> >
> > fb3957af9ec6 ("pwm: Add Rust driver for T-HEAD TH1520 SoC")
> >
> > presumably interacting with something merged earlier in my tree.
> > If someone could provide me with an appropriate merge resolution, I will
> > apply it.
>
> Having no relevant clue about Rust, I bisected that. The bisection points to
> 0242623384c7 ("rust: driver: let probe() return impl PinInit<Self, Error>").
>
> Translating the changes that commit does to
> drivers/gpu/drm/nova/driver.rs for drivers/pwm/pwm_th1520.rs results in:
>
> diff --git a/drivers/pwm/pwm_th1520.rs b/drivers/pwm/pwm_th1520.rs
> index 0ad38b78be85..dd554574adc8 100644
> --- a/drivers/pwm/pwm_th1520.rs
> +++ b/drivers/pwm/pwm_th1520.rs
> @@ -328,7 +328,7 @@ impl platform::Driver for Th1520PwmPlatformDriver {
> fn probe(
> pdev: &platform::Device<Core>,
> _id_info: Option<&Self::IdInfo>,
> - ) -> Result<Pin<KBox<Self>>> {
> + ) -> impl PinInit<Self, Error> {
> let dev = pdev.as_ref();
> let request = pdev.io_request_by_index(0).ok_or(ENODEV)?;
>
> @@ -365,7 +365,7 @@ fn probe(
>
> pwm::Registration::register(dev, chip)?;
>
> - Ok(KBox::new(Th1520PwmPlatformDriver, GFP_KERNEL)?.into())
> + Ok(Th1520PwmPlatformDriver)
> }
> }
>
> which builds again.
This merge resolution looks correct.
Alice
next prev parent reply other threads:[~2025-10-28 9:52 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <CGME20251027015241eucas1p1784b974d0c150e8c3513f32401205669@eucas1p1.samsung.com>
2025-10-27 1:51 ` linux-next: build failure after merge of the pwm tree Stephen Rothwell
2025-10-27 8:11 ` Uwe Kleine-König
2025-10-27 9:38 ` Danilo Krummrich
2025-10-28 1:51 ` Stephen Rothwell
2025-12-05 3:33 ` Stephen Rothwell
2025-10-27 13:40 ` Uwe Kleine-König
2025-10-27 13:49 ` Danilo Krummrich
2025-10-28 9:52 ` Alice Ryhl [this message]
2025-10-27 8:36 ` Michal Wilczynski
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=aQCSS_h47zUVilno@google.com \
--to=aliceryhl@google.com \
--cc=acourbot@nvidia.com \
--cc=boqun.feng@gmail.com \
--cc=dakr@kernel.org \
--cc=daniel.almeida@collabora.com \
--cc=gregkh@linuxfoundation.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-next@vger.kernel.org \
--cc=lyude@redhat.com \
--cc=m.wilczynski@samsung.com \
--cc=ojeda@kernel.org \
--cc=pcolberg@redhat.com \
--cc=sfr@canb.auug.org.au \
--cc=ukleinek@kernel.org \
--cc=viresh.kumar@linaro.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