Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1681689 > unrolled thread
| Started by | Brian Norris <briannorris@chromium.org> |
|---|---|
| First post | 2017-07-05 20:10 +0200 |
| Last post | 2017-07-06 10:50 +0200 |
| Articles | 2 — 2 participants |
Back to article view | Back to linux.kernel
This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by
below is the oldest one visible, not the original post.
Re: [PATCH] mwifiex: uninit wakeup info when failed to add card Brian Norris <briannorris@chromium.org> - 2017-07-05 20:10 +0200
Re: [PATCH] mwifiex: uninit wakeup info when failed to add card jeffy <jeffy.chen@rock-chips.com> - 2017-07-06 10:50 +0200
| From | Brian Norris <briannorris@chromium.org> |
|---|---|
| Date | 2017-07-05 20:10 +0200 |
| Subject | Re: [PATCH] mwifiex: uninit wakeup info when failed to add card |
| Message-ID | <tZWUp-1gP-7@gated-at.bofh.it> |
On Mon, Jul 03, 2017 at 03:54:30PM +0800, Jeffy Chen wrote: > We inited wakeup info at the beginning of mwifiex_add_card, so we need > to uninit it in the error handling. > > It's much the same as what we did in: > 36908c4 mwifiex: uninit wakeup info when removing device Yeah, I noticed I hadn't covered all the error cases, so your change is part of the fix. But you're not covering the error paths when the firmware doesn't load correctly -- this happens asynchronously to mwifiex_add_card(). i.e., you need to fixup the error paths in _mwifiex_fw_dpc() too. Brian > Signed-off-by: Jeffy Chen <jeffy.chen@rock-chips.com> > > --- > > drivers/net/wireless/marvell/mwifiex/main.c | 2 ++ > 1 file changed, 2 insertions(+) > > diff --git a/drivers/net/wireless/marvell/mwifiex/main.c b/drivers/net/wireless/marvell/mwifiex/main.c > index f2600b8..17d2cbe 100644 > --- a/drivers/net/wireless/marvell/mwifiex/main.c > +++ b/drivers/net/wireless/marvell/mwifiex/main.c > @@ -1655,6 +1655,8 @@ mwifiex_add_card(void *card, struct completion *fw_done, > mwifiex_shutdown_drv(adapter); > } > err_kmalloc: > + if (adapter->irq_wakeup >= 0) > + device_init_wakeup(adapter->dev, false); > mwifiex_free_adapter(adapter); > > err_init_sw: > -- > 2.1.4 > >
[toc] | [next] | [standalone]
| From | jeffy <jeffy.chen@rock-chips.com> |
|---|---|
| Date | 2017-07-06 10:50 +0200 |
| Message-ID | <u0aE2-1W0-19@gated-at.bofh.it> |
| In reply to | #1681689 |
Hi brian, On 07/06/2017 02:08 AM, Brian Norris wrote: > On Mon, Jul 03, 2017 at 03:54:30PM +0800, Jeffy Chen wrote: >> We inited wakeup info at the beginning of mwifiex_add_card, so we need >> to uninit it in the error handling. >> >> It's much the same as what we did in: >> 36908c4 mwifiex: uninit wakeup info when removing device > > Yeah, I noticed I hadn't covered all the error cases, so your change is > part of the fix. But you're not covering the error paths when the > firmware doesn't load correctly -- this happens asynchronously to > mwifiex_add_card(). i.e., you need to fixup the error paths in > _mwifiex_fw_dpc() too. right, so we need to uninit it before every mwifiex_free_adapter :) > > Brian > >> Signed-off-by: Jeffy Chen <jeffy.chen@rock-chips.com> >> >> --- >> >> drivers/net/wireless/marvell/mwifiex/main.c | 2 ++ >> 1 file changed, 2 insertions(+) >> >> diff --git a/drivers/net/wireless/marvell/mwifiex/main.c b/drivers/net/wireless/marvell/mwifiex/main.c >> index f2600b8..17d2cbe 100644 >> --- a/drivers/net/wireless/marvell/mwifiex/main.c >> +++ b/drivers/net/wireless/marvell/mwifiex/main.c >> @@ -1655,6 +1655,8 @@ mwifiex_add_card(void *card, struct completion *fw_done, >> mwifiex_shutdown_drv(adapter); >> } >> err_kmalloc: >> + if (adapter->irq_wakeup >= 0) >> + device_init_wakeup(adapter->dev, false); >> mwifiex_free_adapter(adapter); >> >> err_init_sw: >> -- >> 2.1.4 >> >> > > >
[toc] | [prev] | [standalone]
Back to top | Article view | linux.kernel
csiph-web