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]
Date:	Wed, 07 May 2008 09:46:13 +0800
From:	Li Zefan <lizf@...fujitsu.com>
To:	Andrew Morton <akpm@...ux-foundation.org>
CC:	Paul Menage <menage@...gle.com>,
	Hidetoshi Seto <seto.hidetoshi@...fujitsu.com>,
	Paul Jackson <pj@....com>, Ingo Molnar <mingo@...e.hu>,
	linux-kernel@...r.kernel.org
Subject: Re: [PATCH] Fix cpuset sched_relax_domain_level control file

Andrew Morton wrote:
> On Tue, 06 May 2008 18:08:17 -0700 Paul Menage <menage@...gle.com> wrote:
> 
>> -static int update_relax_domain_level(struct cpuset *cs, char *buf)
>> +static int update_relax_domain_level(struct cpuset *cs, s64 val)
>>  {
>> -	int val = simple_strtol(buf, NULL, 10);
>> -
>> -	if (val < 0)
>> +	if ((int)val < 0)
>>  		val = -1;
>>  
> 
> Are you sure about the typecast here?  If `val' has a value of say
> 0x0000_ffff_ffff_ffff then I assume the casted value will be negative, only
> it wasn't?
> 

I saw this, but I think it's ok.

  -1  : no request. use system default or follow request of others.
   0  : no search.
  ...
 ( 5~ : search system wide [on NUMA system])

Or maybe we can restrict the value from -1 to 5 ?
--
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