summaryrefslogtreecommitdiff
path: root/payloads/libpayload/curses
diff options
context:
space:
mode:
Diffstat (limited to 'payloads/libpayload/curses')
-rw-r--r--payloads/libpayload/curses/Makefile.inc254
-rw-r--r--payloads/libpayload/curses/keyboard.c14
-rw-r--r--payloads/libpayload/curses/local.h4
-rw-r--r--payloads/libpayload/curses/pdcurses-backend/pdcdisp.c16
-rw-r--r--payloads/libpayload/curses/pdcurses-backend/pdckbd.c14
-rw-r--r--payloads/libpayload/curses/pdcurses-backend/pdcscrn.c2
-rw-r--r--payloads/libpayload/curses/pdcurses-backend/pdcsetsc.c4
-rw-r--r--payloads/libpayload/curses/pdcurses-backend/pdcutil.c2
-rw-r--r--payloads/libpayload/curses/tinycurses.c30
9 files changed, 170 insertions, 170 deletions
diff --git a/payloads/libpayload/curses/Makefile.inc b/payloads/libpayload/curses/Makefile.inc
index 5d14431cda..025a0511d3 100644
--- a/payloads/libpayload/curses/Makefile.inc
+++ b/payloads/libpayload/curses/Makefile.inc
@@ -27,142 +27,142 @@
## SUCH DAMAGE.
##
-ifeq ($(CONFIG_TINYCURSES),y)
+ifeq ($(CONFIG_LP_TINYCURSES),y)
INCLUDES += -Icurses
endif
-libcurses-$(CONFIG_TINYCURSES) += keyboard.c
-libcurses-$(CONFIG_TINYCURSES) += tinycurses.c
-libcurses-$(CONFIG_TINYCURSES) += colors.c
+libcurses-$(CONFIG_LP_TINYCURSES) += keyboard.c
+libcurses-$(CONFIG_LP_TINYCURSES) += tinycurses.c
+libcurses-$(CONFIG_LP_TINYCURSES) += colors.c
-includes-$(CONFIG_TINYCURSES) += curses.h
+includes-$(CONFIG_LP_TINYCURSES) += curses.h
-ifeq ($(CONFIG_PDCURSES),y)
+ifeq ($(CONFIG_LP_PDCURSES),y)
INCLUDES += -D_LP64=0 -Icurses/PDCurses-3.4 -Icurses/pdcurses-backend -Icurses/menu -Icurses/form
endif
-libcurses-$(CONFIG_PDCURSES) += pdcurses-backend/pdcdisp.c
-libcurses-$(CONFIG_PDCURSES) += pdcurses-backend/pdcgetsc.c
-libcurses-$(CONFIG_PDCURSES) += pdcurses-backend/pdckbd.c
-libcurses-$(CONFIG_PDCURSES) += pdcurses-backend/pdcscrn.c
-libcurses-$(CONFIG_PDCURSES) += pdcurses-backend/pdcsetsc.c
-libcurses-$(CONFIG_PDCURSES) += pdcurses-backend/pdcutil.c
-libcurses-$(CONFIG_PDCURSES) += PDCurses-3.4/pdcurses/addch.c
-libcurses-$(CONFIG_PDCURSES) += PDCurses-3.4/pdcurses/move.c
-libcurses-$(CONFIG_PDCURSES) += PDCurses-3.4/pdcurses/overlay.c
-libcurses-$(CONFIG_PDCURSES) += PDCurses-3.4/pdcurses/refresh.c
-libcurses-$(CONFIG_PDCURSES) += PDCurses-3.4/pdcurses/terminfo.c
-libcurses-$(CONFIG_PDCURSES) += PDCurses-3.4/pdcurses/window.c
-libcurses-$(CONFIG_PDCURSES) += PDCurses-3.4/pdcurses/util.c
-libcurses-$(CONFIG_PDCURSES) += PDCurses-3.4/pdcurses/inopts.c
-libcurses-$(CONFIG_PDCURSES) += PDCurses-3.4/pdcurses/addstr.c
-libcurses-$(CONFIG_PDCURSES) += PDCurses-3.4/pdcurses/keyname.c
-libcurses-$(CONFIG_PDCURSES) += PDCurses-3.4/pdcurses/instr.c
-libcurses-$(CONFIG_PDCURSES) += PDCurses-3.4/pdcurses/clear.c
-libcurses-$(CONFIG_PDCURSES) += PDCurses-3.4/pdcurses/addchstr.c
-libcurses-$(CONFIG_PDCURSES) += PDCurses-3.4/pdcurses/kernel.c
-libcurses-$(CONFIG_PDCURSES) += PDCurses-3.4/pdcurses/pad.c
-libcurses-$(CONFIG_PDCURSES) += PDCurses-3.4/pdcurses/insstr.c
-libcurses-$(CONFIG_PDCURSES) += PDCurses-3.4/pdcurses/border.c
-libcurses-$(CONFIG_PDCURSES) += PDCurses-3.4/pdcurses/getyx.c
-libcurses-$(CONFIG_PDCURSES) += PDCurses-3.4/pdcurses/getstr.c
-libcurses-$(CONFIG_PDCURSES) += PDCurses-3.4/pdcurses/getch.c
-libcurses-$(CONFIG_PDCURSES) += PDCurses-3.4/pdcurses/termattr.c
-libcurses-$(CONFIG_PDCURSES) += PDCurses-3.4/pdcurses/outopts.c
-libcurses-$(CONFIG_PDCURSES) += PDCurses-3.4/pdcurses/color.c
-libcurses-$(CONFIG_PDCURSES) += PDCurses-3.4/pdcurses/deleteln.c
-libcurses-$(CONFIG_PDCURSES) += PDCurses-3.4/pdcurses/initscr.c
-libcurses-$(CONFIG_PDCURSES) += PDCurses-3.4/pdcurses/slk.c
-libcurses-$(CONFIG_PDCURSES) += PDCurses-3.4/pdcurses/delch.c
-libcurses-$(CONFIG_PDCURSES) += PDCurses-3.4/pdcurses/touch.c
-libcurses-$(CONFIG_PDCURSES) += PDCurses-3.4/pdcurses/mouse.c
-libcurses-$(CONFIG_PDCURSES) += PDCurses-3.4/pdcurses/scanw.c
-libcurses-$(CONFIG_PDCURSES) += PDCurses-3.4/pdcurses/scroll.c
-libcurses-$(CONFIG_PDCURSES) += PDCurses-3.4/pdcurses/printw.c
-libcurses-$(CONFIG_PDCURSES) += PDCurses-3.4/pdcurses/bkgd.c
-libcurses-$(CONFIG_PDCURSES) += PDCurses-3.4/pdcurses/inch.c
-libcurses-$(CONFIG_PDCURSES) += PDCurses-3.4/pdcurses/attr.c
-libcurses-$(CONFIG_PDCURSES) += PDCurses-3.4/pdcurses/insch.c
-libcurses-$(CONFIG_PDCURSES) += PDCurses-3.4/pdcurses/inchstr.c
-libcurses-$(CONFIG_PDCURSES) += PDCurses-3.4/pdcurses/beep.c
+libcurses-$(CONFIG_LP_PDCURSES) += pdcurses-backend/pdcdisp.c
+libcurses-$(CONFIG_LP_PDCURSES) += pdcurses-backend/pdcgetsc.c
+libcurses-$(CONFIG_LP_PDCURSES) += pdcurses-backend/pdckbd.c
+libcurses-$(CONFIG_LP_PDCURSES) += pdcurses-backend/pdcscrn.c
+libcurses-$(CONFIG_LP_PDCURSES) += pdcurses-backend/pdcsetsc.c
+libcurses-$(CONFIG_LP_PDCURSES) += pdcurses-backend/pdcutil.c
+libcurses-$(CONFIG_LP_PDCURSES) += PDCurses-3.4/pdcurses/addch.c
+libcurses-$(CONFIG_LP_PDCURSES) += PDCurses-3.4/pdcurses/move.c
+libcurses-$(CONFIG_LP_PDCURSES) += PDCurses-3.4/pdcurses/overlay.c
+libcurses-$(CONFIG_LP_PDCURSES) += PDCurses-3.4/pdcurses/refresh.c
+libcurses-$(CONFIG_LP_PDCURSES) += PDCurses-3.4/pdcurses/terminfo.c
+libcurses-$(CONFIG_LP_PDCURSES) += PDCurses-3.4/pdcurses/window.c
+libcurses-$(CONFIG_LP_PDCURSES) += PDCurses-3.4/pdcurses/util.c
+libcurses-$(CONFIG_LP_PDCURSES) += PDCurses-3.4/pdcurses/inopts.c
+libcurses-$(CONFIG_LP_PDCURSES) += PDCurses-3.4/pdcurses/addstr.c
+libcurses-$(CONFIG_LP_PDCURSES) += PDCurses-3.4/pdcurses/keyname.c
+libcurses-$(CONFIG_LP_PDCURSES) += PDCurses-3.4/pdcurses/instr.c
+libcurses-$(CONFIG_LP_PDCURSES) += PDCurses-3.4/pdcurses/clear.c
+libcurses-$(CONFIG_LP_PDCURSES) += PDCurses-3.4/pdcurses/addchstr.c
+libcurses-$(CONFIG_LP_PDCURSES) += PDCurses-3.4/pdcurses/kernel.c
+libcurses-$(CONFIG_LP_PDCURSES) += PDCurses-3.4/pdcurses/pad.c
+libcurses-$(CONFIG_LP_PDCURSES) += PDCurses-3.4/pdcurses/insstr.c
+libcurses-$(CONFIG_LP_PDCURSES) += PDCurses-3.4/pdcurses/border.c
+libcurses-$(CONFIG_LP_PDCURSES) += PDCurses-3.4/pdcurses/getyx.c
+libcurses-$(CONFIG_LP_PDCURSES) += PDCurses-3.4/pdcurses/getstr.c
+libcurses-$(CONFIG_LP_PDCURSES) += PDCurses-3.4/pdcurses/getch.c
+libcurses-$(CONFIG_LP_PDCURSES) += PDCurses-3.4/pdcurses/termattr.c
+libcurses-$(CONFIG_LP_PDCURSES) += PDCurses-3.4/pdcurses/outopts.c
+libcurses-$(CONFIG_LP_PDCURSES) += PDCurses-3.4/pdcurses/color.c
+libcurses-$(CONFIG_LP_PDCURSES) += PDCurses-3.4/pdcurses/deleteln.c
+libcurses-$(CONFIG_LP_PDCURSES) += PDCurses-3.4/pdcurses/initscr.c
+libcurses-$(CONFIG_LP_PDCURSES) += PDCurses-3.4/pdcurses/slk.c
+libcurses-$(CONFIG_LP_PDCURSES) += PDCurses-3.4/pdcurses/delch.c
+libcurses-$(CONFIG_LP_PDCURSES) += PDCurses-3.4/pdcurses/touch.c
+libcurses-$(CONFIG_LP_PDCURSES) += PDCurses-3.4/pdcurses/mouse.c
+libcurses-$(CONFIG_LP_PDCURSES) += PDCurses-3.4/pdcurses/scanw.c
+libcurses-$(CONFIG_LP_PDCURSES) += PDCurses-3.4/pdcurses/scroll.c
+libcurses-$(CONFIG_LP_PDCURSES) += PDCurses-3.4/pdcurses/printw.c
+libcurses-$(CONFIG_LP_PDCURSES) += PDCurses-3.4/pdcurses/bkgd.c
+libcurses-$(CONFIG_LP_PDCURSES) += PDCurses-3.4/pdcurses/inch.c
+libcurses-$(CONFIG_LP_PDCURSES) += PDCurses-3.4/pdcurses/attr.c
+libcurses-$(CONFIG_LP_PDCURSES) += PDCurses-3.4/pdcurses/insch.c
+libcurses-$(CONFIG_LP_PDCURSES) += PDCurses-3.4/pdcurses/inchstr.c
+libcurses-$(CONFIG_LP_PDCURSES) += PDCurses-3.4/pdcurses/beep.c
-includes-$(CONFIG_PDCURSES) += pdcurses-backend/nc_alloc.h
-includes-$(CONFIG_PDCURSES) += pdcurses-backend/ncurses_cfg.h
-includes-$(CONFIG_PDCURSES) += PDCurses-3.4/curses.h
-includes-$(CONFIG_PDCURSES) += PDCurses-3.4/term.h
-includes-$(CONFIG_PDCURSES) += PDCurses-3.4/panel.h
-includes-$(CONFIG_PDCURSES) += menu/eti.h
-includes-$(CONFIG_PDCURSES) += menu/menu.h
-includes-$(CONFIG_PDCURSES) += menu/mf_common.h
-includes-$(CONFIG_PDCURSES) += form/form.h
+includes-$(CONFIG_LP_PDCURSES) += pdcurses-backend/nc_alloc.h
+includes-$(CONFIG_LP_PDCURSES) += pdcurses-backend/ncurses_cfg.h
+includes-$(CONFIG_LP_PDCURSES) += PDCurses-3.4/curses.h
+includes-$(CONFIG_LP_PDCURSES) += PDCurses-3.4/term.h
+includes-$(CONFIG_LP_PDCURSES) += PDCurses-3.4/panel.h
+includes-$(CONFIG_LP_PDCURSES) += menu/eti.h
+includes-$(CONFIG_LP_PDCURSES) += menu/menu.h
+includes-$(CONFIG_LP_PDCURSES) += menu/mf_common.h
+includes-$(CONFIG_LP_PDCURSES) += form/form.h
-libpanel-$(CONFIG_PDCURSES) += PDCurses-3.4/pdcurses/panel.c
+libpanel-$(CONFIG_LP_PDCURSES) += PDCurses-3.4/pdcurses/panel.c
-libmenu-$(CONFIG_PDCURSES) += menu/m_req_name.c
-libmenu-$(CONFIG_PDCURSES) += menu/m_item_nam.c
-libmenu-$(CONFIG_PDCURSES) += menu/m_pad.c
-libmenu-$(CONFIG_PDCURSES) += menu/m_cursor.c
-libmenu-$(CONFIG_PDCURSES) += menu/m_item_new.c
-libmenu-$(CONFIG_PDCURSES) += menu/m_attribs.c
-libmenu-$(CONFIG_PDCURSES) += menu/m_item_opt.c
-libmenu-$(CONFIG_PDCURSES) += menu/m_format.c
-libmenu-$(CONFIG_PDCURSES) += menu/m_post.c
-libmenu-$(CONFIG_PDCURSES) += menu/m_userptr.c
-libmenu-$(CONFIG_PDCURSES) += menu/m_item_cur.c
-libmenu-$(CONFIG_PDCURSES) += menu/m_driver.c
-libmenu-$(CONFIG_PDCURSES) += menu/m_sub.c
-libmenu-$(CONFIG_PDCURSES) += menu/m_win.c
-libmenu-$(CONFIG_PDCURSES) += menu/m_global.c
-libmenu-$(CONFIG_PDCURSES) += menu/m_item_vis.c
-libmenu-$(CONFIG_PDCURSES) += menu/m_new.c
-libmenu-$(CONFIG_PDCURSES) += menu/m_scale.c
-libmenu-$(CONFIG_PDCURSES) += menu/m_spacing.c
-libmenu-$(CONFIG_PDCURSES) += menu/m_opts.c
-libmenu-$(CONFIG_PDCURSES) += menu/m_pattern.c
-libmenu-$(CONFIG_PDCURSES) += menu/m_item_val.c
-libmenu-$(CONFIG_PDCURSES) += menu/m_hook.c
-libmenu-$(CONFIG_PDCURSES) += menu/m_item_use.c
-libmenu-$(CONFIG_PDCURSES) += menu/m_items.c
-libmenu-$(CONFIG_PDCURSES) += menu/m_item_top.c
-libform-$(CONFIG_PDCURSES) += form/frm_page.c
-libform-$(CONFIG_PDCURSES) += form/frm_opts.c
-libform-$(CONFIG_PDCURSES) += form/frm_def.c
-libform-$(CONFIG_PDCURSES) += form/frm_req_name.c
-libform-$(CONFIG_PDCURSES) += form/fty_alpha.c
-libform-$(CONFIG_PDCURSES) += form/frm_driver.c
-libform-$(CONFIG_PDCURSES) += form/fld_user.c
-libform-$(CONFIG_PDCURSES) += form/frm_win.c
-libform-$(CONFIG_PDCURSES) += form/fld_newftyp.c
-#libform-$(CONFIG_PDCURSES) += form/fty_regex.c
-libform-$(CONFIG_PDCURSES) += form/fld_stat.c
-libform-$(CONFIG_PDCURSES) += form/fld_pad.c
-libform-$(CONFIG_PDCURSES) += form/fld_current.c
-libform-$(CONFIG_PDCURSES) += form/frm_post.c
-#libform-$(CONFIG_PDCURSES) += form/f_trace.c
-libform-$(CONFIG_PDCURSES) += form/fty_generic.c
-libform-$(CONFIG_PDCURSES) += form/fld_page.c
-libform-$(CONFIG_PDCURSES) += form/frm_hook.c
-libform-$(CONFIG_PDCURSES) += form/frm_scale.c
-libform-$(CONFIG_PDCURSES) += form/fty_int.c
-libform-$(CONFIG_PDCURSES) += form/fty_alnum.c
-libform-$(CONFIG_PDCURSES) += form/frm_cursor.c
-#libform-$(CONFIG_PDCURSES) += form/fty_ipv4.c
-libform-$(CONFIG_PDCURSES) += form/fld_link.c
-libform-$(CONFIG_PDCURSES) += form/fld_arg.c
-libform-$(CONFIG_PDCURSES) += form/fld_move.c
-libform-$(CONFIG_PDCURSES) += form/fld_def.c
-libform-$(CONFIG_PDCURSES) += form/fld_type.c
-libform-$(CONFIG_PDCURSES) += form/fld_max.c
-libform-$(CONFIG_PDCURSES) += form/fld_ftlink.c
-libform-$(CONFIG_PDCURSES) += form/fld_ftchoice.c
-libform-$(CONFIG_PDCURSES) += form/fld_info.c
-libform-$(CONFIG_PDCURSES) += form/frm_user.c
-#libform-$(CONFIG_PDCURSES) += form/fty_num.c
-libform-$(CONFIG_PDCURSES) += form/frm_sub.c
-libform-$(CONFIG_PDCURSES) += form/fty_enum.c
-libform-$(CONFIG_PDCURSES) += form/frm_data.c
-libform-$(CONFIG_PDCURSES) += form/fld_opts.c
-libform-$(CONFIG_PDCURSES) += form/fld_attr.c
-libform-$(CONFIG_PDCURSES) += form/fld_dup.c
-libform-$(CONFIG_PDCURSES) += form/fld_just.c
+libmenu-$(CONFIG_LP_PDCURSES) += menu/m_req_name.c
+libmenu-$(CONFIG_LP_PDCURSES) += menu/m_item_nam.c
+libmenu-$(CONFIG_LP_PDCURSES) += menu/m_pad.c
+libmenu-$(CONFIG_LP_PDCURSES) += menu/m_cursor.c
+libmenu-$(CONFIG_LP_PDCURSES) += menu/m_item_new.c
+libmenu-$(CONFIG_LP_PDCURSES) += menu/m_attribs.c
+libmenu-$(CONFIG_LP_PDCURSES) += menu/m_item_opt.c
+libmenu-$(CONFIG_LP_PDCURSES) += menu/m_format.c
+libmenu-$(CONFIG_LP_PDCURSES) += menu/m_post.c
+libmenu-$(CONFIG_LP_PDCURSES) += menu/m_userptr.c
+libmenu-$(CONFIG_LP_PDCURSES) += menu/m_item_cur.c
+libmenu-$(CONFIG_LP_PDCURSES) += menu/m_driver.c
+libmenu-$(CONFIG_LP_PDCURSES) += menu/m_sub.c
+libmenu-$(CONFIG_LP_PDCURSES) += menu/m_win.c
+libmenu-$(CONFIG_LP_PDCURSES) += menu/m_global.c
+libmenu-$(CONFIG_LP_PDCURSES) += menu/m_item_vis.c
+libmenu-$(CONFIG_LP_PDCURSES) += menu/m_new.c
+libmenu-$(CONFIG_LP_PDCURSES) += menu/m_scale.c
+libmenu-$(CONFIG_LP_PDCURSES) += menu/m_spacing.c
+libmenu-$(CONFIG_LP_PDCURSES) += menu/m_opts.c
+libmenu-$(CONFIG_LP_PDCURSES) += menu/m_pattern.c
+libmenu-$(CONFIG_LP_PDCURSES) += menu/m_item_val.c
+libmenu-$(CONFIG_LP_PDCURSES) += menu/m_hook.c
+libmenu-$(CONFIG_LP_PDCURSES) += menu/m_item_use.c
+libmenu-$(CONFIG_LP_PDCURSES) += menu/m_items.c
+libmenu-$(CONFIG_LP_PDCURSES) += menu/m_item_top.c
+libform-$(CONFIG_LP_PDCURSES) += form/frm_page.c
+libform-$(CONFIG_LP_PDCURSES) += form/frm_opts.c
+libform-$(CONFIG_LP_PDCURSES) += form/frm_def.c
+libform-$(CONFIG_LP_PDCURSES) += form/frm_req_name.c
+libform-$(CONFIG_LP_PDCURSES) += form/fty_alpha.c
+libform-$(CONFIG_LP_PDCURSES) += form/frm_driver.c
+libform-$(CONFIG_LP_PDCURSES) += form/fld_user.c
+libform-$(CONFIG_LP_PDCURSES) += form/frm_win.c
+libform-$(CONFIG_LP_PDCURSES) += form/fld_newftyp.c
+#libform-$(CONFIG_LP_PDCURSES) += form/fty_regex.c
+libform-$(CONFIG_LP_PDCURSES) += form/fld_stat.c
+libform-$(CONFIG_LP_PDCURSES) += form/fld_pad.c
+libform-$(CONFIG_LP_PDCURSES) += form/fld_current.c
+libform-$(CONFIG_LP_PDCURSES) += form/frm_post.c
+#libform-$(CONFIG_LP_PDCURSES) += form/f_trace.c
+libform-$(CONFIG_LP_PDCURSES) += form/fty_generic.c
+libform-$(CONFIG_LP_PDCURSES) += form/fld_page.c
+libform-$(CONFIG_LP_PDCURSES) += form/frm_hook.c
+libform-$(CONFIG_LP_PDCURSES) += form/frm_scale.c
+libform-$(CONFIG_LP_PDCURSES) += form/fty_int.c
+libform-$(CONFIG_LP_PDCURSES) += form/fty_alnum.c
+libform-$(CONFIG_LP_PDCURSES) += form/frm_cursor.c
+#libform-$(CONFIG_LP_PDCURSES) += form/fty_ipv4.c
+libform-$(CONFIG_LP_PDCURSES) += form/fld_link.c
+libform-$(CONFIG_LP_PDCURSES) += form/fld_arg.c
+libform-$(CONFIG_LP_PDCURSES) += form/fld_move.c
+libform-$(CONFIG_LP_PDCURSES) += form/fld_def.c
+libform-$(CONFIG_LP_PDCURSES) += form/fld_type.c
+libform-$(CONFIG_LP_PDCURSES) += form/fld_max.c
+libform-$(CONFIG_LP_PDCURSES) += form/fld_ftlink.c
+libform-$(CONFIG_LP_PDCURSES) += form/fld_ftchoice.c
+libform-$(CONFIG_LP_PDCURSES) += form/fld_info.c
+libform-$(CONFIG_LP_PDCURSES) += form/frm_user.c
+#libform-$(CONFIG_LP_PDCURSES) += form/fty_num.c
+libform-$(CONFIG_LP_PDCURSES) += form/frm_sub.c
+libform-$(CONFIG_LP_PDCURSES) += form/fty_enum.c
+libform-$(CONFIG_LP_PDCURSES) += form/frm_data.c
+libform-$(CONFIG_LP_PDCURSES) += form/fld_opts.c
+libform-$(CONFIG_LP_PDCURSES) += form/fld_attr.c
+libform-$(CONFIG_LP_PDCURSES) += form/fld_dup.c
+libform-$(CONFIG_LP_PDCURSES) += form/fld_just.c
diff --git a/payloads/libpayload/curses/keyboard.c b/payloads/libpayload/curses/keyboard.c
index 9648dde573..927e06f17f 100644
--- a/payloads/libpayload/curses/keyboard.c
+++ b/payloads/libpayload/curses/keyboard.c
@@ -45,7 +45,7 @@ static int _halfdelay = 0;
/* ============== Serial ==================== */
-#ifdef CONFIG_SERIAL_CONSOLE
+#ifdef CONFIG_LP_SERIAL_CONSOLE
/* We treat serial like a vt100 terminal. For now we
do the cooking in here, but we should probably eventually
pass it to dedicated vt100 code */
@@ -146,12 +146,12 @@ static int cook_serial(unsigned char ch)
static int curses_getchar(int _delay)
{
-#if defined(CONFIG_USB_HID) || defined(CONFIG_PC_KEYBOARD) || defined(CONFIG_SERIAL_CONSOLE)
+#if defined(CONFIG_LP_USB_HID) || defined(CONFIG_LP_PC_KEYBOARD) || defined(CONFIG_LP_SERIAL_CONSOLE)
unsigned short c;
#endif
do {
-#ifdef CONFIG_USB_HID
+#ifdef CONFIG_LP_USB_HID
usb_poll();
if ((curses_flags & F_ENABLE_CONSOLE) &&
usbhid_havechar()) {
@@ -159,7 +159,7 @@ static int curses_getchar(int _delay)
if (c != 0) return c;
}
#endif
-#ifdef CONFIG_PC_KEYBOARD
+#ifdef CONFIG_LP_PC_KEYBOARD
if ((curses_flags & F_ENABLE_CONSOLE) &&
keyboard_havechar()) {
c = keyboard_getchar();
@@ -167,7 +167,7 @@ static int curses_getchar(int _delay)
}
#endif
-#ifdef CONFIG_SERIAL_CONSOLE
+#ifdef CONFIG_LP_SERIAL_CONSOLE
if ((curses_flags & F_ENABLE_SERIAL) &&
serial_havechar()) {
c = serial_getchar();
@@ -225,7 +225,7 @@ int nocbreak(void)
return 0;
}
-#ifdef CONFIG_VGA_VIDEO_CONSOLE
+#ifdef CONFIG_LP_VGA_VIDEO_CONSOLE
void curses_enable_vga(int state)
{
if (state)
@@ -243,7 +243,7 @@ void curses_enable_vga(int state) { }
int curses_vga_enabled(void) { return 0; }
#endif
-#ifdef CONFIG_SERIAL_CONSOLE
+#ifdef CONFIG_LP_SERIAL_CONSOLE
void curses_enable_serial(int state)
{
if (state)
diff --git a/payloads/libpayload/curses/local.h b/payloads/libpayload/curses/local.h
index b7c459d2a0..73fb005c5a 100644
--- a/payloads/libpayload/curses/local.h
+++ b/payloads/libpayload/curses/local.h
@@ -70,13 +70,13 @@
/* Flags used to determine what output methods are available */
-#ifdef CONFIG_VIDEO_CONSOLE
+#ifdef CONFIG_LP_VIDEO_CONSOLE
#define F_ENABLE_CONSOLE 0x01
#else
#define F_ENABLE_CONSOLE 0x00
#endif
-#ifdef CONFIG_SERIAL_CONSOLE
+#ifdef CONFIG_LP_SERIAL_CONSOLE
#define F_ENABLE_SERIAL 0x02
#else
#define F_ENABLE_SERIAL 0x00
diff --git a/payloads/libpayload/curses/pdcurses-backend/pdcdisp.c b/payloads/libpayload/curses/pdcurses-backend/pdcdisp.c
index ab73831aa6..308370e5bf 100644
--- a/payloads/libpayload/curses/pdcurses-backend/pdcdisp.c
+++ b/payloads/libpayload/curses/pdcurses-backend/pdcdisp.c
@@ -66,8 +66,8 @@ chtype fallback_acs_map[128] =
'|', '<', '>', '*', '!', 'f', 'o', ' ',
};
-#ifdef CONFIG_SERIAL_CONSOLE
-#ifdef CONFIG_SERIAL_ACS_FALLBACK
+#ifdef CONFIG_LP_SERIAL_CONSOLE
+#ifdef CONFIG_LP_SERIAL_ACS_FALLBACK
chtype serial_acs_map[128];
#else
/* See acsc of vt100. */
@@ -93,7 +93,7 @@ chtype serial_acs_map[128] =
#endif
#endif
-#ifdef CONFIG_VIDEO_CONSOLE
+#ifdef CONFIG_LP_VIDEO_CONSOLE
/* See acsc of linux. */
chtype console_acs_map[128] =
{
@@ -122,10 +122,10 @@ void PDC_gotoyx(int row, int col)
{
PDC_LOG(("PDC_gotoyx() - called: row %d col %d\n", row, col));
-#ifdef CONFIG_SERIAL_CONSOLE
+#ifdef CONFIG_LP_SERIAL_CONSOLE
serial_set_cursor(col, row);
#endif
-#ifdef CONFIG_VIDEO_CONSOLE
+#ifdef CONFIG_LP_VIDEO_CONSOLE
video_console_set_cursor(col, row);
#endif
}
@@ -139,7 +139,7 @@ void PDC_transform_line(int lineno, int x, int len, const chtype *srcp)
PDC_LOG(("PDC_transform_line() - called: line %d, len %d, curses_flags %d\n", lineno, len, curses_flags));
-#ifdef CONFIG_SERIAL_CONSOLE
+#ifdef CONFIG_LP_SERIAL_CONSOLE
int serial_is_bold = 0;
int serial_is_reverse = 0;
int serial_is_altcharset = 0;
@@ -157,7 +157,7 @@ void PDC_transform_line(int lineno, int x, int len, const chtype *srcp)
{
ch = srcp[j];
attr = ch;
-#ifdef CONFIG_SERIAL_CONSOLE
+#ifdef CONFIG_LP_SERIAL_CONSOLE
if (curses_flags & F_ENABLE_SERIAL) {
if (attr & A_BOLD) {
if (!serial_is_bold) {
@@ -222,7 +222,7 @@ void PDC_transform_line(int lineno, int x, int len, const chtype *srcp)
}
#endif
-#ifdef CONFIG_VIDEO_CONSOLE
+#ifdef CONFIG_LP_VIDEO_CONSOLE
unsigned char c = pdc_atrtab[srcp[j] >> PDC_ATTR_SHIFT];
if (curses_flags & F_ENABLE_CONSOLE) {
diff --git a/payloads/libpayload/curses/pdcurses-backend/pdckbd.c b/payloads/libpayload/curses/pdcurses-backend/pdckbd.c
index 49b80c74fc..d1061b2499 100644
--- a/payloads/libpayload/curses/pdcurses-backend/pdckbd.c
+++ b/payloads/libpayload/curses/pdcurses-backend/pdckbd.c
@@ -5,7 +5,7 @@
unsigned long pdc_key_modifiers = 0L;
-#ifdef CONFIG_SERIAL_CONSOLE
+#ifdef CONFIG_LP_SERIAL_CONSOLE
/* We treat serial like a vt100 terminal. For now we
do the cooking in here, but we should probably eventually
pass it to dedicated vt100 code */
@@ -108,7 +108,7 @@ void PDC_set_keyboard_binary(bool on)
bool PDC_check_key(void)
{
-#ifdef CONFIG_USB_HID
+#ifdef CONFIG_LP_USB_HID
usb_poll();
if ((curses_flags & F_ENABLE_CONSOLE) &&
usbhid_havechar()) {
@@ -116,14 +116,14 @@ bool PDC_check_key(void)
}
#endif
-#ifdef CONFIG_PC_KEYBOARD
+#ifdef CONFIG_LP_PC_KEYBOARD
if ((curses_flags & F_ENABLE_CONSOLE) &&
keyboard_havechar()) {
return TRUE;
}
#endif
-#ifdef CONFIG_SERIAL_CONSOLE
+#ifdef CONFIG_LP_SERIAL_CONSOLE
if ((curses_flags & F_ENABLE_SERIAL) &&
serial_havechar()) {
return TRUE;
@@ -139,7 +139,7 @@ int PDC_get_key(void)
{
int c = 0;
-#ifdef CONFIG_USB_HID
+#ifdef CONFIG_LP_USB_HID
usb_poll();
if ((curses_flags & F_ENABLE_CONSOLE) &&
usbhid_havechar()) {
@@ -147,14 +147,14 @@ int PDC_get_key(void)
}
#endif
-#ifdef CONFIG_PC_KEYBOARD
+#ifdef CONFIG_LP_PC_KEYBOARD
if ((curses_flags & F_ENABLE_CONSOLE) &&
keyboard_havechar() && (c==0)) {
c = keyboard_getchar();
}
#endif
-#ifdef CONFIG_SERIAL_CONSOLE
+#ifdef CONFIG_LP_SERIAL_CONSOLE
if ((curses_flags & F_ENABLE_SERIAL) &&
serial_havechar() && (c==0)) {
c = cook_serial(serial_getchar());
diff --git a/payloads/libpayload/curses/pdcurses-backend/pdcscrn.c b/payloads/libpayload/curses/pdcurses-backend/pdcscrn.c
index e741b15d09..c4922ec409 100644
--- a/payloads/libpayload/curses/pdcurses-backend/pdcscrn.c
+++ b/payloads/libpayload/curses/pdcurses-backend/pdcscrn.c
@@ -72,7 +72,7 @@ int PDC_scr_open(int argc, char **argv)
SP->lines = PDC_get_rows();
SP->cols = PDC_get_columns();
-#ifdef CONFIG_SPEAKER
+#ifdef CONFIG_LP_SPEAKER
SP->audible = TRUE;
#endif
diff --git a/payloads/libpayload/curses/pdcurses-backend/pdcsetsc.c b/payloads/libpayload/curses/pdcurses-backend/pdcsetsc.c
index d016063ff0..b2997a16f9 100644
--- a/payloads/libpayload/curses/pdcurses-backend/pdcsetsc.c
+++ b/payloads/libpayload/curses/pdcurses-backend/pdcsetsc.c
@@ -13,12 +13,12 @@ int PDC_curs_set(int visibility)
ret_vis = SP->visibility;
SP->visibility = visibility;
-#ifdef CONFIG_SERIAL_CONSOLE
+#ifdef CONFIG_LP_SERIAL_CONSOLE
if (curses_flags & F_ENABLE_SERIAL) {
serial_cursor_enable(visibility);
}
#endif
-#ifdef CONFIG_VIDEO_CONSOLE
+#ifdef CONFIG_LP_VIDEO_CONSOLE
if (curses_flags & F_ENABLE_CONSOLE) {
video_console_cursor_enable(visibility);
}
diff --git a/payloads/libpayload/curses/pdcurses-backend/pdcutil.c b/payloads/libpayload/curses/pdcurses-backend/pdcutil.c
index 030f4622e2..c40e2ed1eb 100644
--- a/payloads/libpayload/curses/pdcurses-backend/pdcutil.c
+++ b/payloads/libpayload/curses/pdcurses-backend/pdcutil.c
@@ -11,7 +11,7 @@ void PDC_beep(void)
{
PDC_LOG(("PDC_beep() - called\n"));
-#ifdef CONFIG_SPEAKER
+#ifdef CONFIG_LP_SPEAKER
speaker_tone(1760, 500); /* 1760 == note A6 */
#endif
}
diff --git a/payloads/libpayload/curses/tinycurses.c b/payloads/libpayload/curses/tinycurses.c
index fe6e7dee41..d5bf23f1af 100644
--- a/payloads/libpayload/curses/tinycurses.c
+++ b/payloads/libpayload/curses/tinycurses.c
@@ -111,8 +111,8 @@ chtype fallback_acs_map[128] =
'|', '<', '>', '*', '!', 'f', 'o', ' ',
};
-#ifdef CONFIG_SERIAL_CONSOLE
-#ifdef CONFIG_SERIAL_ACS_FALLBACK
+#ifdef CONFIG_LP_SERIAL_CONSOLE
+#ifdef CONFIG_LP_SERIAL_ACS_FALLBACK
chtype serial_acs_map[128];
#else
/* See acsc of vt100. */
@@ -138,7 +138,7 @@ chtype serial_acs_map[128] =
#endif
#endif
-#ifdef CONFIG_VIDEO_CONSOLE
+#ifdef CONFIG_LP_VIDEO_CONSOLE
/* See acsc of linux. */
chtype console_acs_map[128] =
{
@@ -191,7 +191,7 @@ NCURSES_CH_T _nc_render(WINDOW *win, NCURSES_CH_T ch)
int beep(void)
{
/* TODO: Flash the screen if beeping fails? */
-#ifdef CONFIG_SPEAKER
+#ifdef CONFIG_LP_SPEAKER
speaker_tone(1760, 500); /* 1760 == note A6 */
#endif
return OK;
@@ -202,12 +202,12 @@ int cbreak(void) { /* TODO */ return 0; }
// int color_content(short color, short *r, short *g, short *b) {}
int curs_set(int on)
{
-#ifdef CONFIG_SERIAL_CONSOLE
+#ifdef CONFIG_LP_SERIAL_CONSOLE
if (curses_flags & F_ENABLE_SERIAL) {
serial_cursor_enable(on);
}
#endif
-#ifdef CONFIG_VIDEO_CONSOLE
+#ifdef CONFIG_LP_VIDEO_CONSOLE
if (curses_flags & F_ENABLE_CONSOLE) {
video_console_cursor_enable(on);
}
@@ -315,12 +315,12 @@ WINDOW *initscr(void)
for (i = 0; i < 128; i++)
acs_map[i] = (chtype) i | A_ALTCHARSET;
-#ifdef CONFIG_SERIAL_CONSOLE
+#ifdef CONFIG_LP_SERIAL_CONSOLE
if (curses_flags & F_ENABLE_SERIAL) {
serial_clear();
}
#endif
-#ifdef CONFIG_VIDEO_CONSOLE
+#ifdef CONFIG_LP_VIDEO_CONSOLE
if (curses_flags & F_ENABLE_CONSOLE) {
/* Clear the screen and kill the cursor */
@@ -719,7 +719,7 @@ int whline(WINDOW *win, chtype ch, int n)
(((c) & 0x4400) >> 2) | ((c) & 0xAA00) | (((c) & 0x1100) << 2)
int wnoutrefresh(WINDOW *win)
{
-#ifdef CONFIG_SERIAL_CONSOLE
+#ifdef CONFIG_LP_SERIAL_CONSOLE
// FIXME.
int serial_is_bold = 0;
int serial_is_reverse = 0;
@@ -732,7 +732,7 @@ int wnoutrefresh(WINDOW *win)
int x, y;
chtype ch;
-#ifdef CONFIG_SERIAL_CONSOLE
+#ifdef CONFIG_LP_SERIAL_CONSOLE
serial_end_bold();
serial_end_altcharset();
#endif
@@ -744,7 +744,7 @@ int wnoutrefresh(WINDOW *win)
/* Position the serial cursor */
-#ifdef CONFIG_SERIAL_CONSOLE
+#ifdef CONFIG_LP_SERIAL_CONSOLE
if (curses_flags & F_ENABLE_SERIAL)
serial_set_cursor(win->_begy + y, win->_begx +
win->_line[y].firstchar);
@@ -753,7 +753,7 @@ int wnoutrefresh(WINDOW *win)
for (x = win->_line[y].firstchar; x <= win->_line[y].lastchar; x++) {
attr_t attr = win->_line[y].text[x].attr;
-#ifdef CONFIG_SERIAL_CONSOLE
+#ifdef CONFIG_LP_SERIAL_CONSOLE
if (curses_flags & F_ENABLE_SERIAL) {
ch = win->_line[y].text[x].chars[0];
@@ -819,7 +819,7 @@ int wnoutrefresh(WINDOW *win)
}
#endif
-#ifdef CONFIG_VIDEO_CONSOLE
+#ifdef CONFIG_LP_VIDEO_CONSOLE
unsigned int c =
((int)color_pairs[PAIR_NUMBER(attr)]) << 8;
@@ -860,12 +860,12 @@ int wnoutrefresh(WINDOW *win)
win->_line[y].lastchar = _NOCHANGE;
}
-#ifdef CONFIG_SERIAL_CONSOLE
+#ifdef CONFIG_LP_SERIAL_CONSOLE
if (curses_flags & F_ENABLE_SERIAL)
serial_set_cursor(win->_begy + win->_cury, win->_begx + win->_curx);
#endif
-#ifdef CONFIG_VIDEO_CONSOLE
+#ifdef CONFIG_LP_VIDEO_CONSOLE
if (curses_flags & F_ENABLE_CONSOLE)
video_console_set_cursor(win->_begx + win->_curx, win->_begy + win->_cury);
#endif