Re: [PATCH v4] rust_binder: unregister shrinker if binderfs initialization fails
From: Greg Kroah-Hartman
Date: Thu Dec 03 2026 - 07:10:44 EST
On Thu, Dec 03, 2026 at 11:22:06AM +0800, Poil Zero wrote:
> BinderModule::init() registers the Binder shrinker before initializing
> binderfs. If init_rust_binderfs() fails, the driver returns an error
> but leaves the shrinker registered and its list_lru allocated.
>
> Unregister the shrinker on this error path before destroying its
> list_lru so that active reclaim callbacks finish before teardown.
> Return the original binderfs error.
>
> Fixes: eafedbc7c050 ("rust_binder: add Rust Binder driver")
> Signed-off-by: Poil Zero <poilandgginchi@xxxxxxxxx>
> ---
> Changes in v4:
> - Resend with git send-email to preserve the diff headers.
>
> Changes in v3:
> - Match the From and Signed-off-by names.
You might have matched it, but that's not the correct one to use, please
fix and use your real name for both, I can't take this as-is.
thanks,
greg k-h