[PATCH] code cleanup
jschopp at austin.ibm.com
jschopp at austin.ibm.com
Sat Apr 10 05:18:20 EST 2004
I was looking at rtas serialization for reasons I won't go into here.
While wandering through the code I found that two functions were not
properly serialized. phys_call_rtas and phys_call_rtas_display_status are
the functions. After looking further they are redundant and not
used anywhere at all.
Does anybody know of a reason not to remove these functions? A patch
below removes them, unless I hear some objections I will push it
early next week.
-Joel Schopp
# This is a BitKeeper generated patch for the following project:
# Project Name: Linux kernel tree
# This patch format is intended for GNU patch command version 2.5 or higher.
# This patch includes the following deltas:
# ChangeSet 1.1562 -> 1.1563
# arch/ppc64/kernel/rtas.c 1.37 -> 1.38
# include/asm-ppc64/rtas.h 1.23 -> 1.24
#
# The following is the BitKeeper ChangeSet Log
# --------------------------------------------
# 04/04/09 jschopp at threadlp13.austin.ibm.com 1.1563
# Remove a couple of unused, unnecessary functions.
# --------------------------------------------
#
diff -Nru a/arch/ppc64/kernel/rtas.c b/arch/ppc64/kernel/rtas.c
--- a/arch/ppc64/kernel/rtas.c Fri Apr 9 14:04:10 2004
+++ b/arch/ppc64/kernel/rtas.c Fri Apr 9 14:04:10 2004
@@ -64,43 +64,6 @@
spinlock_t rtas_data_buf_lock = SPIN_LOCK_UNLOCKED;
char rtas_data_buf[RTAS_DATA_BUF_SIZE]__page_aligned;
-
-void
-phys_call_rtas(int token, int nargs, int nret, ...)
-{
- va_list list;
- unsigned long offset = reloc_offset();
- struct rtas_args *rtas = PTRRELOC(&(get_paca()->xRtas));
- int i;
-
- rtas->token = token;
- rtas->nargs = nargs;
- rtas->nret = nret;
- rtas->rets = (rtas_arg_t *)PTRRELOC(&(rtas->args[nargs]));
-
- va_start(list, nret);
- for (i = 0; i < nargs; i++)
- rtas->args[i] = (rtas_arg_t)LONG_LSW(va_arg(list, ulong));
- va_end(list);
-
- enter_rtas(rtas);
-}
-
-void
-phys_call_rtas_display_status(char c)
-{
- unsigned long offset = reloc_offset();
- struct rtas_args *rtas = PTRRELOC(&(get_paca()->xRtas));
-
- rtas->token = 10;
- rtas->nargs = 1;
- rtas->nret = 1;
- rtas->rets = (rtas_arg_t *)PTRRELOC(&(rtas->args[1]));
- rtas->args[0] = (int)c;
-
- enter_rtas(rtas);
-}
-
void
call_rtas_display_status(char c)
{
diff -Nru a/include/asm-ppc64/rtas.h b/include/asm-ppc64/rtas.h
--- a/include/asm-ppc64/rtas.h Fri Apr 9 14:04:10 2004
+++ b/include/asm-ppc64/rtas.h Fri Apr 9 14:04:10 2004
@@ -169,8 +169,6 @@
extern void enter_rtas(struct rtas_args *);
extern int rtas_token(const char *service);
extern long rtas_call(int token, int, int, unsigned long *, ...);
-extern void phys_call_rtas(int, int, int, ...);
-extern void phys_call_rtas_display_status(char);
extern void call_rtas_display_status(char);
extern void rtas_restart(char *cmd);
extern void rtas_power_off(void);
** Sent via the linuxppc64-dev mail list. See http://lists.linuxppc.org/
More information about the Linuxppc64-dev
mailing list