[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <ZfnILSPBiqk8JdJ4@gmail.com>
Date: Tue, 19 Mar 2024 10:15:25 -0700
From: Breno Leitao <leitao@...ian.org>
To: Jeff Johnson <quic_jjohnson@...cinc.com>
Cc: Kalle Valo <kvalo@...nel.org>, Jeff Johnson <jjohnson@...nel.org>,
kuba@...nel.org, keescook@...omium.org,
"open list:NETWORKING DRIVERS (WIRELESS)" <linux-wireless@...r.kernel.org>,
"open list:QUALCOMM ATHEROS ATH10K WIRELESS DRIVER" <ath10k@...ts.infradead.org>,
open list <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH] ath10k: allocate dummy net_device dynamically
On Tue, Mar 19, 2024 at 09:05:24AM -0700, Jeff Johnson wrote:
> On 3/19/2024 3:47 AM, Breno Leitao wrote:
> > @@ -3687,6 +3690,8 @@ struct ath10k *ath10k_core_create(size_t priv_size, struct device *dev,
> >
> > err_free_coredump:
> > ath10k_coredump_destroy(ar);
> > +err_free_netdev:
> > + free_netdev(ar->napi_dev);
> > err_free_tx_complete:
> > destroy_workqueue(ar->workqueue_tx_complete);
> > err_free_aux_wq:
> > @@ -3708,6 +3713,7 @@ void ath10k_core_destroy(struct ath10k *ar)
> >
> > destroy_workqueue(ar->workqueue_tx_complete);
> >
> > + free_netdev(ar->napi_dev);
> > ath10k_debug_destroy(ar);
> > ath10k_coredump_destroy(ar);
> > ath10k_htt_tx_destroy(&ar->htt);
>
> looks like there is a pre-existing issue that the order of operations in
> _destroy() doesn't match the order of operations in the _create() error path.
Right. I found it weird as well. Basically "ath10k_coredump" and
"ath10k_debug" operations are swapped between ath10k_core_create() and
ath10k_core_destroy().
If you wish, I can submit a patch ordering it properly.
> but the placement of your changes looks ok to me
Right. It is done in-between the workqueues and the coredump/debug
creation/destroy.
Thanks for the review.
Powered by blists - more mailing lists