From: David Miller <davem@davemloft.net>
To: weiyj.lk@gmail.com
Cc: grant.likely@linaro.org, rob.herring@calxeda.com,
jg1.han@samsung.com, jonas.jensen@gmail.com,
yongjun_wei@trendmicro.com.cn, netdev@vger.kernel.org
Subject: Re: [PATCH] moxa: drop free_irq of devm_request_irq allocated irq
Date: Mon, 30 Sep 2013 14:55:26 -0400 (EDT) [thread overview]
Message-ID: <20130930.145526.2002275544537353463.davem@davemloft.net> (raw)
In-Reply-To: <CAPgLHd8YRP7kL_jNHi3J9jFn86f=Fv-AWWUY_aRGZQOgVTNPgg@mail.gmail.com>
From: Wei Yongjun <weiyj.lk@gmail.com>
Date: Wed, 25 Sep 2013 15:33:29 +0800
> From: Wei Yongjun <yongjun_wei@trendmicro.com.cn>
>
> irq allocated with devm_request_irq should not be freed using
> free_irq, because doing so causes a dangling pointer, and a
> subsequent double free.
>
> Signed-off-by: Wei Yongjun <yongjun_wei@trendmicro.com.cn>
I think this is a dangerous change, if the IRQ fires after the point
of the existing free_irq() call it will try to dereference the net
device struct which will be free by the time the devm release code
runes.
I'm not applying this patch, sorry.
next prev parent reply other threads:[~2013-09-30 18:55 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-09-25 7:33 [PATCH] moxa: drop free_irq of devm_request_irq allocated irq Wei Yongjun
2013-09-26 0:47 ` Jingoo Han
2013-09-26 2:12 ` Wei Yongjun
2013-09-26 2:36 ` Jingoo Han
2013-09-26 14:02 ` Ben Hutchings
2013-09-30 18:55 ` David Miller [this message]
-- strict thread matches above, loose matches on Subject: below --
2013-09-26 3:23 Wei Yongjun
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=20130930.145526.2002275544537353463.davem@davemloft.net \
--to=davem@davemloft.net \
--cc=grant.likely@linaro.org \
--cc=jg1.han@samsung.com \
--cc=jonas.jensen@gmail.com \
--cc=netdev@vger.kernel.org \
--cc=rob.herring@calxeda.com \
--cc=weiyj.lk@gmail.com \
--cc=yongjun_wei@trendmicro.com.cn \
/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;
as well as URLs for NNTP newsgroup(s).