mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
To: bongsu.jeon@samsung.com, Nguyen Dinh Phi <phind.uet@gmail.com>
Cc: "netdev@vger.kernel.org" <netdev@vger.kernel.org>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	"syzbot+6eb09d75211863f15e3e@syzkaller.appspotmail.com" 
	<syzbot+6eb09d75211863f15e3e@syzkaller.appspotmail.com>
Subject: Re: [PATCH] nfc: virtual_ncidev: Add variable to check if ndev is running
Date: Tue, 21 Nov 2023 08:05:52 +0100	[thread overview]
Message-ID: <3009000a-c973-4894-83d6-ce2ddab5ccf0@linaro.org> (raw)
In-Reply-To: <20231121013146epcms2p1587bebc341f17406625e8b0490b6ab1a@epcms2p1>

On 21/11/2023 02:31, Bongsu Jeon wrote:
> On 20/11/2023 19:23, Phi Nguyen wrote:
> 
>> The issue arises when an skb is added to the send_buff after invoking 
>> ndev->ops->close() but before unregistering the device. In such cases, 
>> the virtual device will generate a copy of skb, but with no consumer 
>> thereafter. Consequently, this object persists indefinitely.
>>
>> This problem seems to stem from the existence of time gaps between 
>> ops->close() and the destruction of the workqueue. During this interval, 
>> incoming requests continue to trigger the send function.
> 
> Dear Krzysztof,
> 
> Even though i agree on this patch, i think that NFC subsystem could handle this scenario not to trigger the send function after close.
> Do you think it would be better that each nci driver has the responsibility to handle this scenario?

It's better if core does it, but so far each driver was taking care of
it. Send a patch if you have some better solution.

Best regards,
Krzysztof


      reply	other threads:[~2023-11-21  7:06 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-11-19 16:47 Nguyen Dinh Phi
     [not found] ` <CGME20231119164714epcas2p2c0480d014abc4f0f780c714a445881ca@epcms2p4>
2023-11-20  4:47   ` Bongsu Jeon
2023-11-20  9:06     ` Krzysztof Kozlowski
2023-11-20 10:39       ` Nguyen Dinh Phi
2023-11-20 10:45         ` Krzysztof Kozlowski
2023-11-20 18:23           ` Phi Nguyen
2023-11-20 18:29             ` Krzysztof Kozlowski
2023-11-20 18:32               ` Krzysztof Kozlowski
2023-11-20 18:44 ` Krzysztof Kozlowski
     [not found] ` <CGME20231120184433epcas2p23e9f5db776d46ad8dd77a16dd326c1bc@epcms2p1>
2023-11-21  1:31   ` Bongsu Jeon
2023-11-21  7:05     ` Krzysztof Kozlowski [this message]

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=3009000a-c973-4894-83d6-ce2ddab5ccf0@linaro.org \
    --to=krzysztof.kozlowski@linaro.org \
    --cc=bongsu.jeon@samsung.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=phind.uet@gmail.com \
    --cc=syzbot+6eb09d75211863f15e3e@syzkaller.appspotmail.com \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®