disk: convert CONFIG_ISO_PARTITION to Kconfig
[platform/kernel/u-boot.git] / include / console.h
index 06ec32a..3d37f6a 100644 (file)
@@ -1,38 +1,52 @@
 /*
- * (C) Copyright 2000
- * Paolo Scaffardi, AIRVENT SAM s.p.a - RIMINI(ITALY), arsenio@tin.it
+ * (C) Copyright 2000-2009
+ * Wolfgang Denk, DENX Software Engineering, wd@denx.de.
  *
- * See file CREDITS for list of people who contributed to this
- * project.
- *
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of the GNU General Public License as
- * published by the Free Software Foundation; either version 2 of
- * the License, or (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
- * MA 02111-1307 USA
+ * SPDX-License-Identifier:    GPL-2.0+
  */
 
-#ifndef _CONSOLE_H_
-#define _CONSOLE_H_
+#ifndef __CONSOLE_H
+#define __CONSOLE_H
 
-#include <devices.h>
+extern char console_buffer[];
 
-/*
-** VARIABLES
-*/
+/* common/console.c */
+int console_init_f(void);      /* Before relocation; uses the serial  stuff */
+int console_init_r(void);      /* After  relocation; uses the console stuff */
+int console_assign(int file, const char *devname);     /* Assign the console */
+int ctrlc(void);
+int had_ctrlc(void);   /* have we had a Control-C since last clear? */
+void clear_ctrlc(void);        /* clear the Control-C condition */
+int disable_ctrlc(int);        /* 1 to disable, 0 to enable Control-C detect */
+int confirm_yesno(void);        /*  1 if input is "y", "Y", "yes" or "YES" */
 
-extern device_t        *stdio_devices[] ;
-extern char *stdio_names[MAX_FILES] ;
+/**
+ * console_record_init() - set up the console recording buffers
+ *
+ * This should be called as soon as malloc() is available so that the maximum
+ * amount of console output can be recorded.
+ */
+int console_record_init(void);
 
-int console_realloc(int top);
+/**
+ * console_record_reset() - reset the console recording buffers
+ *
+ * Removes any data in the buffers
+ */
+void console_record_reset(void);
+
+/**
+ * console_record_reset_enable() - reset and enable the console buffers
+ *
+ * This should be called to enable the console buffer.
+ */
+void console_record_reset_enable(void);
+
+/*
+ * CONSOLE multiplexing.
+ */
+#ifdef CONFIG_CONSOLE_MUX
+#include <iomux.h>
+#endif
 
 #endif