[PATCH 3/4] crypto: caam: Unembed net_dev structure from qi
Breno Leitao
leitao at debian.org
Tue Jul 2 23:32:37 AEST 2024
Hello Simon,
On Fri, Jun 28, 2024 at 05:32:26PM +0100, Simon Horman wrote:
> On Mon, Jun 24, 2024 at 09:21:21AM -0700, Breno Leitao wrote:
> > @@ -530,6 +530,7 @@ static void caam_qi_shutdown(void *data)
> >
> > if (kill_fq(qidev, per_cpu(pcpu_qipriv.rsp_fq, i)))
> > dev_err(qidev, "Rsp FQ kill failed, cpu: %d\n", i);
> > + free_netdev(pcpu_qipriv.net_dev);
> Hi Breno,
>
> I don't think you can access pcpu_qipriv.net_dev like this,
> as pcpu_qipriv is a per-cpu variable. Perhaps this?
>
> free_netdev(per_cpu(pcpu_qipriv.net_dev, i));
You are absolutely correct. Let me fix it.
> Flagged by Sparse.
Thanks. I've just added sparse to my development workflow, and I can see
it also:
drivers/crypto/caam/qi.c:533:29: warning: dereference of noderef expression
Thanks for the review. I will send an updated version.
--breno
More information about the Linuxppc-dev
mailing list