linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Qiang Ma <maqianga@uniontech.com>
To: mpe@ellerman.id.au, benh@kernel.crashing.org, paulus@samba.org
Cc: linuxppc-dev@lists.ozlabs.org, linux-kernel@vger.kernel.org,
	Qiang Ma <maqianga@uniontech.com>
Subject: [PATCH] powerpc: fix coding style issues
Date: Thu,  4 Mar 2021 16:55:41 +0800	[thread overview]
Message-ID: <20210304085541.766-1-maqianga@uniontech.com> (raw)

There are several style issues in this function,
so fix them.

Signed-off-by: Qiang Ma <maqianga@uniontech.com>
---
 arch/powerpc/kernel/syscalls.c | 14 +++++++-------
 1 file changed, 7 insertions(+), 7 deletions(-)

diff --git a/arch/powerpc/kernel/syscalls.c b/arch/powerpc/kernel/syscalls.c
index 078608ec2e92..bcbb5fb2a0c1 100644
--- a/arch/powerpc/kernel/syscalls.c
+++ b/arch/powerpc/kernel/syscalls.c
@@ -81,15 +81,15 @@ SYSCALL_DEFINE6(mmap, unsigned long, addr, size_t, len,
 int
 ppc_select(int n, fd_set __user *inp, fd_set __user *outp, fd_set __user *exp, struct __kernel_old_timeval __user *tvp)
 {
-	if ( (unsigned long)n >= 4096 )
-	{
+	if ((unsigned long)n >= 4096) {
 		unsigned long __user *buffer = (unsigned long __user *)n;
-		if (!access_ok(buffer, 5*sizeof(unsigned long))
+		if (!access_ok(buffer, 5 * sizeof(unsigned long))
 		    || __get_user(n, buffer)
-		    || __get_user(inp, ((fd_set __user * __user *)(buffer+1)))
-		    || __get_user(outp, ((fd_set  __user * __user *)(buffer+2)))
-		    || __get_user(exp, ((fd_set  __user * __user *)(buffer+3)))
-		    || __get_user(tvp, ((struct __kernel_old_timeval  __user * __user *)(buffer+4))))
+		    || __get_user(inp, ((fd_set __user * __user *)(buffer + 1)))
+		    || __get_user(outp, ((fd_set  __user * __user *)(buffer + 2)))
+		    || __get_user(exp, ((fd_set  __user * __user *)(buffer + 3)))
+		    || __get_user(tvp,
+			    ((struct __kernel_old_timeval  __user * __user *)(buffer + 4))))
 			return -EFAULT;
 	}
 	return sys_select(n, inp, outp, exp, tvp);
-- 
2.20.1




                 reply	other threads:[~2021-03-04  8:59 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=20210304085541.766-1-maqianga@uniontech.com \
    --to=maqianga@uniontech.com \
    --cc=benh@kernel.crashing.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linuxppc-dev@lists.ozlabs.org \
    --cc=mpe@ellerman.id.au \
    --cc=paulus@samba.org \
    /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).