Re: [PATCH v2 1/2] mfd: ls2kbmc: Fully convert to use managed resources

From: Lee Jones

Date: Wed Nov 19 2025 - 11:47:07 EST


On Thu, 13 Nov 2025, Andy Shevchenko wrote:

> The mixing of managed and non-managed resources may lead to possible
> use-after-free bugs. In this driver the problematic part is the device
> functionality that may just have gone behind the functions back, e.g.,
> when interrupt is being served. Fix this by switching to managed resources
> for PCI.
>
> Fixes: 91a3e1f5453a ("mfd: ls2kbmc: Check for devm_mfd_add_devices() failure")
> Fixes: d952bba3fbb5 ("mfd: ls2kbmc: Add Loongson-2K BMC reset function support")
> Reviewed-by: Binbin Zhou <zhoubinbin@xxxxxxxxxxx>
> Signed-off-by: Andy Shevchenko <andriy.shevchenko@xxxxxxxxxxxxxxx>
> ---
> drivers/mfd/ls2k-bmc-core.c | 28 +++++++---------------------
> 1 file changed, 7 insertions(+), 21 deletions(-)

Still doesn't apply. I'm getting lots of conflicts.

What base are you on?

% git --no-pager log --oneline drivers/mfd/ls2k-bmc-core.c
3696ac1d0db2 mfd: ls2kbmc: Remove unneeded semicolon from ls2k_bmc_recover_pci_data()
d952bba3fbb5 mfd: ls2kbmc: Add Loongson-2K BMC reset function support
0d64f6d1ffe9 mfd: ls2kbmc: Introduce Loongson-2K BMC core driver

--
Lee Jones [李琼斯]