All of lore.kernel.org
 help / color / mirror / Atom feed
From: Kalle Valo <kvalo@qca.qualcomm.com>
To: Simon Wunderlich <sw@simonwunderlich.de>
Cc: ath10k@lists.infradead.org
Subject: Re: [PATCH] ath10k: unregister spectral before mac
Date: Thu, 14 Aug 2014 15:41:51 +0300	[thread overview]
Message-ID: <87y4urkzu8.fsf@kamboji.qca.qualcomm.com> (raw)
In-Reply-To: <9205567.prhmu1LLGe@prime> (Simon Wunderlich's message of "Thu, 14 Aug 2014 14:22:04 +0200")

Simon Wunderlich <sw@simonwunderlich.de> writes:

> On Thursday 14 August 2014 13:12:13 Kalle Valo wrote:
>> Simon Wunderlich <sw@simonwunderlich.de> writes:
>> > If spectral is unregistered after mac80211, the relayfs file has already
>> > been removed recursively by mac/cfg80211, and spectral tries to remove
>> > the file once more, thus leading to double free problems. Better clean
>> > up spectral before to avoid that problem.
>> > 
>> > Reported-by: Kalle Valo <kvalo@qca.qualcomm.com>
>> > Signed-off-by: Simon Wunderlich <sw@simonwunderlich.de>
>> 
>> Thanks for checking this. But I'm just wondering why even bother to call
>> relay_close() in the first place if mac80211 recursively removes
>> everything anyway? We don't remove any of the debugfs files anyway.
>
> We need to relay_close() in any case because this function also causes to 
> clean up internal buffers of relayfs.
>
> An alternative to this patch could be to instead having 
> remove_buf_file_handler() call debugfs_remove() just do nothing and relay on 
> the upper layers to (recursively) remove that file - then, the relayfs stuff 
> still can get cleaned up. But that's also not very elegant either. If you 
> prefer that I can prepare a patch though ....

Yeah, that's not really any better. I'll apply your original patch.

-- 
Kalle Valo

_______________________________________________
ath10k mailing list
ath10k@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/ath10k

  reply	other threads:[~2014-08-14 12:42 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-08-12 15:12 [PATCH] ath10k: unregister spectral before mac Simon Wunderlich
2014-08-14 10:12 ` Kalle Valo
2014-08-14 12:22   ` Simon Wunderlich
2014-08-14 12:41     ` Kalle Valo [this message]
2014-08-14 13:16 ` Kalle Valo

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87y4urkzu8.fsf@kamboji.qca.qualcomm.com \
    --to=kvalo@qca.qualcomm.com \
    --cc=ath10k@lists.infradead.org \
    --cc=sw@simonwunderlich.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.