Greg Kroah-Hartman | b244131 | 2017-11-01 15:07:57 +0100 | [diff] [blame] | 1 | /* SPDX-License-Identifier: GPL-2.0 */ |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 2 | /* |
| 3 | * Definitions for using the procedures in btext.c. |
| 4 | * |
| 5 | * Benjamin Herrenschmidt <benh@kernel.crashing.org> |
| 6 | */ |
| 7 | #ifndef __PPC_BTEXT_H |
| 8 | #define __PPC_BTEXT_H |
| 9 | #ifdef __KERNEL__ |
| 10 | |
Benjamin Herrenschmidt | 51d3082 | 2005-11-23 17:57:25 +1100 | [diff] [blame] | 11 | extern int btext_find_display(int allow_nonstdout); |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 12 | extern void btext_update_display(unsigned long phys, int width, int height, |
| 13 | int depth, int pitch); |
Benjamin Herrenschmidt | 51d3082 | 2005-11-23 17:57:25 +1100 | [diff] [blame] | 14 | extern void btext_setup_display(int width, int height, int depth, int pitch, |
| 15 | unsigned long address); |
Christophe Leroy | c21f5a9 | 2019-06-03 13:00:51 +0000 | [diff] [blame] | 16 | #ifdef CONFIG_PPC32 |
Benjamin Herrenschmidt | 51d3082 | 2005-11-23 17:57:25 +1100 | [diff] [blame] | 17 | extern void btext_prepare_BAT(void); |
Christophe Leroy | c21f5a9 | 2019-06-03 13:00:51 +0000 | [diff] [blame] | 18 | #else |
| 19 | static inline void btext_prepare_BAT(void) { } |
| 20 | #endif |
Benjamin Herrenschmidt | 7191b61 | 2013-07-25 12:12:32 +1000 | [diff] [blame] | 21 | extern void btext_map(void); |
Benjamin Herrenschmidt | 51d3082 | 2005-11-23 17:57:25 +1100 | [diff] [blame] | 22 | extern void btext_unmap(void); |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 23 | |
| 24 | extern void btext_drawchar(char c); |
| 25 | extern void btext_drawstring(const char *str); |
Nick Child | d276960 | 2021-12-16 17:00:16 -0500 | [diff] [blame] | 26 | void __init btext_drawhex(unsigned long v); |
| 27 | void __init btext_drawtext(const char *c, unsigned int len); |
Benjamin Herrenschmidt | 51d3082 | 2005-11-23 17:57:25 +1100 | [diff] [blame] | 28 | |
Nick Child | d276960 | 2021-12-16 17:00:16 -0500 | [diff] [blame] | 29 | void __init btext_clearscreen(void); |
| 30 | void __init btext_flushscreen(void); |
| 31 | void __init btext_flushline(void); |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 32 | |
| 33 | #endif /* __KERNEL__ */ |
| 34 | #endif /* __PPC_BTEXT_H */ |