lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <4822AA6F.5040703@cn.fujitsu.com>
Date:	Thu, 08 May 2008 15:23:27 +0800
From:	Li Zefan <lizf@...fujitsu.com>
To:	KOSAKI Motohiro <kosaki.motohiro@...fujitsu.com>
CC:	Paul Menage <menage@...gle.com>,
	Jeremy Fitzhardinge <jeremy@...source.com>,
	Andi Kleen <ak@...e.de>, LKML <linux-kernel@...r.kernel.org>,
	Rusty Russell <rusty@...tcorp.com.au>
Subject: Re: [PATCH] call_usermodehelper_setup() should use GFP_KERNEL

KOSAKI Motohiro wrote:
> Now, call_usermodehelper_setup() use GFP_ATOMIC.
> but it is slighly odd.
> because call_usermodehelper() is always called process context.
> 

Are you sure? I found the following call chain:

  static irqreturn_t power_handler(int irq, void *dev_id)
  ->orderly_poweroff(true);
    ->call_usermodehelper_setup()

> GFP_KERNEL is robust and better.
> 
> 
> Signed-off-by: KOSAKI Motohiro <kosaki.motohiro@...fujitsu.com>
> CC: "Paul Menage" <menage@...gle.com>
> CC: Li Zefan <lizf@...fujitsu.com>
> CC: Jeremy Fitzhardinge <jeremy@...source.com>
> CC: Andi Kleen <ak@...e.de>
> CC: Rusty Russell <rusty@...tcorp.com.au> 
> 
> ---
>  kernel/kmod.c |    2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> Index: b/kernel/kmod.c
> ===================================================================
> --- a/kernel/kmod.c	2008-04-29 17:37:41.000000000 +0900
> +++ b/kernel/kmod.c	2008-05-06 20:20:02.000000000 +0900
> @@ -360,7 +360,7 @@ struct subprocess_info *call_usermodehel
>  						  char **argv, char **envp)
>  {
>  	struct subprocess_info *sub_info;
> -	sub_info = kzalloc(sizeof(struct subprocess_info),  GFP_ATOMIC);
> +	sub_info = kzalloc(sizeof(struct subprocess_info),  GFP_KERNEL);
>  	if (!sub_info)
>  		goto out;
>  
> 
> 
> 
> 
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ