From: Michael Ellerman <mpe@ellerman.id.au>
To: <linuxppc-dev@ozlabs.org>
Cc: <linux-kernel@vger.kernel.org>,
keescook@chromium.org, luto@amacapital.net, wad@chromium.org,
strosake@linux.vnet.ibm.com, bogdan.purcareata@freescale.com
Subject: [PATCH 03/11] powerpc: Drop unused syscall_get_error()
Date: Thu, 23 Jul 2015 20:21:03 +1000 [thread overview]
Message-ID: <1437646871-3195-3-git-send-email-mpe@ellerman.id.au> (raw)
In-Reply-To: <1437646871-3195-1-git-send-email-mpe@ellerman.id.au>
syscall_get_error() is unused, and never has been.
It's also probably wrong, as it negates r3 before returning it, but that
depends on what the caller is expecting.
It also doesn't deal with compat, and doesn't deal with TIF_NOERROR.
Although we could fix those, until it has a caller and it's clear what
semantics the caller wants it's just untested code. So drop it.
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
---
arch/powerpc/include/asm/syscall.h | 6 ------
1 file changed, 6 deletions(-)
diff --git a/arch/powerpc/include/asm/syscall.h b/arch/powerpc/include/asm/syscall.h
index ff21b7a2f0cc..c6239dabcfb1 100644
--- a/arch/powerpc/include/asm/syscall.h
+++ b/arch/powerpc/include/asm/syscall.h
@@ -34,12 +34,6 @@ static inline void syscall_rollback(struct task_struct *task,
regs->gpr[3] = regs->orig_gpr3;
}
-static inline long syscall_get_error(struct task_struct *task,
- struct pt_regs *regs)
-{
- return (regs->ccr & 0x10000000) ? -regs->gpr[3] : 0;
-}
-
static inline long syscall_get_return_value(struct task_struct *task,
struct pt_regs *regs)
{
--
2.1.0
next prev parent reply other threads:[~2015-07-23 10:21 UTC|newest]
Thread overview: 25+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-07-23 10:21 [PATCH 01/11] powerpc/kernel: Switch to using MAX_ERRNO Michael Ellerman
2015-07-23 10:21 ` [PATCH 02/11] powerpc/kernel: Change the do_syscall_trace_enter() API Michael Ellerman
2015-07-27 18:48 ` Kees Cook
2015-07-23 10:21 ` Michael Ellerman [this message]
2015-07-27 18:48 ` [PATCH 03/11] powerpc: Drop unused syscall_get_error() Kees Cook
2015-07-23 10:21 ` [PATCH 04/11] powerpc: Don't negate error in syscall_set_return_value() Michael Ellerman
2015-07-27 18:49 ` Kees Cook
2015-07-23 10:21 ` [PATCH 05/11] powerpc: Rework syscall_get_arguments() so there is only one loop Michael Ellerman
2015-07-27 18:50 ` Kees Cook
2015-07-23 10:21 ` [PATCH 06/11] powerpc: Use orig_gpr3 in syscall_get_arguments() Michael Ellerman
2015-07-27 18:52 ` Kees Cook
2015-07-23 10:21 ` [PATCH 07/11] powerpc: Change syscall_get_nr() to return int Michael Ellerman
2015-07-27 18:53 ` Kees Cook
2015-07-23 10:21 ` [PATCH 08/11] powerpc/kernel: Add SIG_SYS support for compat tasks Michael Ellerman
2015-07-27 18:54 ` Kees Cook
2015-07-23 10:21 ` [PATCH 09/11] powerpc/kernel: Enable seccomp filter Michael Ellerman
2015-07-27 18:56 ` Kees Cook
2015-07-30 5:56 ` [PATCH v2] " Michael Ellerman
2015-07-30 16:39 ` Kees Cook
2015-07-23 10:21 ` [PATCH 10/11] selftests/seccomp: Make seccomp tests work on big endian Michael Ellerman
2015-07-27 18:57 ` Kees Cook
2015-07-23 10:21 ` [PATCH 11/11] selftests/seccomp: Add powerpc support Michael Ellerman
2015-07-27 18:59 ` Kees Cook
2015-07-28 12:18 ` Michael Ellerman
2015-07-27 18:45 ` [PATCH 01/11] powerpc/kernel: Switch to using MAX_ERRNO Kees Cook
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=1437646871-3195-3-git-send-email-mpe@ellerman.id.au \
--to=mpe@ellerman.id.au \
--cc=bogdan.purcareata@freescale.com \
--cc=keescook@chromium.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linuxppc-dev@ozlabs.org \
--cc=luto@amacapital.net \
--cc=strosake@linux.vnet.ibm.com \
--cc=wad@chromium.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).