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:	Mon, 26 Mar 2012 09:31:24 -0700
From:	Joe Perches <joe@...ches.com>
To:	Kautuk Consul <consul.kautuk@...il.com>
Cc:	davem@...emloft.net, Paul Gortmaker <paul.gortmaker@...driver.com>,
	Ingo Molnar <mingo@...e.hu>,
	Peter Zijlstra <a.p.zijlstra@...llo.nl>,
	sparclinux@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH 20/20 v3] sparc/mm/fault_64.c: Port OOM changes to
 do_sparc64_fault

On Mon, 2012-03-26 at 11:33 -0400, Kautuk Consul wrote:
> diff --git a/arch/sparc/mm/fault_64.c b/arch/sparc/mm/fault_64.c
> index 504c062..8322962 100644
> --- a/arch/sparc/mm/fault_64.c
> +++ b/arch/sparc/mm/fault_64.c
> @@ -279,6 +279,7 @@ asmlinkage void __kprobes do_sparc64_fault(struct pt_regs *regs)
>  	unsigned int insn = 0;
>  	int si_code, fault_code, fault;
>  	unsigned long address, mm_rss;
> +	unsigned int flags = FAULT_FLAG_ALLOW_RETRY | FAULT_FLAG_KILLABLE;
>  
>  	fault_code = get_thread_fault_code();
>  
[]
> @@ -423,7 +426,13 @@ good_area:
>  			goto bad_area;
>  	}
>  
> -	fault = handle_mm_fault(mm, vma, address, (fault_code & FAULT_CODE_WRITE) ? FAULT_FLAG_WRITE : 0);
> +	fault = handle_mm_fault(mm, vma, address,
> +							flags | ((fault_code & FAULT_CODE_WRITE) ?
> +									 FAULT_FLAG_WRITE : 0);

A bit redundant and very poor style argument alignment
Make sure your tab indentation is set to 8.

	fault = handle_mm_fault(mm, vma, address,
				flags | (fault_code & FAULT_CODE_WRITE));

though perhaps fault_code could be unsigned and
perhaps you could use the same style initializer
for fault_code as patch 19/20.


--
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