1 --- a/purgatory/arch/ppc64/console-ppc64.c 2011-10-03 00:56:38.000000000 +0200
2 +++ b/purgatory/arch/ppc64/console-ppc64.c 2013-02-16 11:09:31.600289142 +0100
9 +#define CONS_LENGTH 0xff0
14 - unsigned long *lbuf = (unsigned long *)buff;
15 + static int initialized = 0;
16 + unsigned long data, written;
19 - if (!debug) /* running on non pseries */
22 + ret = lv1_undocumented_function_105(CONS_ID, 0, 0,
23 + CONS_LENGTH, CONS_LENGTH, 0, 0);
24 + if ((ret != 0) && (ret != -7))
35 + lv1_undocumented_function_107(CONS_ID, 1, data, 0, 0, 0,
38 + /* flush to console buffer in LV1 */
39 + lv1_undocumented_function_109(CONS_ID);
42 - plpar_hcall_norets(H_PUT_TERM_CHAR, 0, 1, lbuf[0], lbuf[1]);
45 --- a/purgatory/arch/ppc64/hvCall.S 2011-10-03 00:56:38.000000000 +0200
46 +++ b/purgatory/arch/ppc64/hvCall.S 2013-02-16 11:11:41.006963337 +0100
48 #define HVSC .long 0x44000022
51 -.globl .plpar_hcall_norets
53 - or 6,6,6 # medium low priority
56 +.globl .lv1_undocumented_function_105
57 +.lv1_undocumented_function_105:
66 - HVSC /* invoke the hypervisor */
67 +.globl .lv1_undocumented_function_107
68 +.lv1_undocumented_function_107:
83 - blr /* return r3 = status */
84 +.globl .lv1_undocumented_function_109
85 +.lv1_undocumented_function_109:
93 --- a/purgatory/arch/ppc64/hvCall.h 2011-10-03 00:56:38.000000000 +0200
94 +++ b/purgatory/arch/ppc64/hvCall.h 2013-02-16 11:12:31.713632953 +0100
99 -#define H_PUT_TERM_CHAR 0x58
100 +int lv1_undocumented_function_105(unsigned long arg1,
101 + unsigned long arg2, unsigned long arg3, unsigned long arg4,
102 + unsigned long arg5, unsigned long arg6, unsigned long arg7);
104 -long plpar_hcall_norets(unsigned long opcode, ...);
105 +int lv1_undocumented_function_107(unsigned long arg1,
106 + unsigned long arg2, unsigned long arg3, unsigned long arg4,
107 + unsigned long arg5, unsigned long arg6, unsigned long *arg7);
109 +int lv1_undocumented_function_109(unsigned long arg1);