Re: [RFC PATCH v7 6/9] media: tegra: Add Tegra210 Video input driver

From: Dmitry Osipenko
Date: Wed Apr 15 2020 - 10:23:27 EST


15.04.2020 05:57, Sowjanya Komatineni ÐÐÑÐÑ:
> +static int tegra_csi_remove(struct platform_device *pdev)
> +{
> + struct tegra_csi *csi = platform_get_drvdata(pdev);
> + int err;
> +
> + err = host1x_client_unregister(&csi->client);
> + if (err < 0) {
> + dev_err(csi->dev,
> + "failed to unregister host1x client: %d\n", err);
> + return err;
> + }
> +
> + pm_runtime_disable(csi->dev);
> + kfree(csi);

IIRC, the driver removal is invoked on the unbinding. Hence, I'm not
sure how moving away from the resource-managed API helps here. Could you
please explain in a more details?

Have you tried to test this driver under KASAN? I suspect that you just
masked the problem, instead of fixing it.