linux-wireless.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: <Adham.Abozaeid@microchip.com>
To: <penguin-kernel@I-love.SAKURA.ne.jp>, <Ajay.Kathat@microchip.com>,
	<gregkh@linuxfoundation.org>
Cc: <linux-wireless@vger.kernel.org>
Subject: Re: [PATCH] staging: wilc1000: Avoid GFP_KERNEL allocation from atomic context.
Date: Mon, 8 Apr 2019 21:13:59 +0000	[thread overview]
Message-ID: <847e1f3c-f54f-ff4d-fa2e-74518597ef5f@microchip.com> (raw)
In-Reply-To: <1554641923-11503-1-git-send-email-penguin-kernel@I-love.SAKURA.ne.jp>


On 4/7/19 5:58 AM, Tetsuo Handa wrote:
> Since wilc_set_multicast_list() is called with dev->addr_list_lock
> spinlock held, we can't use GFP_KERNEL memory allocation.
>
> Signed-off-by: Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp>
> Fixes: e624c58cf8eb5116 ("staging: wilc1000: refactor code to avoid use of wilc_set_multicast_list global")
> Cc: Ajay Singh <ajay.kathat@microchip.com>
Reviewed-by: Adham Abozaeid <adham.abozaeid@microchip.com>

Thanks,
Adham

> ---
>  drivers/staging/wilc1000/wilc_netdev.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/staging/wilc1000/wilc_netdev.c b/drivers/staging/wilc1000/wilc_netdev.c
> index 1787154..ba78c08 100644
> --- a/drivers/staging/wilc1000/wilc_netdev.c
> +++ b/drivers/staging/wilc1000/wilc_netdev.c
> @@ -708,7 +708,7 @@ static void wilc_set_multicast_list(struct net_device *dev)
>  		return;
>  	}
>  
> -	mc_list = kmalloc_array(dev->mc.count, ETH_ALEN, GFP_KERNEL);
> +	mc_list = kmalloc_array(dev->mc.count, ETH_ALEN, GFP_ATOMIC);
>  	if (!mc_list)
>  		return;
>  

  reply	other threads:[~2019-04-08 21:14 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-04-07 12:58 [PATCH] staging: wilc1000: Avoid GFP_KERNEL allocation from atomic context Tetsuo Handa
2019-04-08 21:13 ` Adham.Abozaeid [this message]
2019-04-16 11:15 ` Greg Kroah-Hartman
2019-04-16 23:17 Adham.Abozaeid

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=847e1f3c-f54f-ff4d-fa2e-74518597ef5f@microchip.com \
    --to=adham.abozaeid@microchip.com \
    --cc=Ajay.Kathat@microchip.com \
    --cc=gregkh@linuxfoundation.org \
    --cc=linux-wireless@vger.kernel.org \
    --cc=penguin-kernel@I-love.SAKURA.ne.jp \
    /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).