Back to home page

OSCL-LXR

 
 

    


0001 /*
0002  * This file is subject to the terms and conditions of the GNU General Public
0003  * License.  See the file "COPYING" in the main directory of this archive
0004  * for more details.
0005  *
0006  * Copyright (C) 2012 MIPS Technologies, Inc.
0007  */
0008 #ifndef __ASM_FW_H_
0009 #define __ASM_FW_H_
0010 
0011 #include <asm/bootinfo.h>   /* For cleaner code... */
0012 
0013 extern int fw_argc;
0014 extern int *_fw_argv;
0015 extern int *_fw_envp;
0016 
0017 /*
0018  * Most firmware like YAMON, PMON, etc. pass arguments and environment
0019  * variables as 32-bit pointers. These take care of sign extension.
0020  */
0021 #define fw_argv(index)      ((char *)(long)_fw_argv[(index)])
0022 #define fw_envp(index)      ((char *)(long)_fw_envp[(index)])
0023 
0024 extern void fw_init_cmdline(void);
0025 extern char *fw_getcmdline(void);
0026 extern void fw_meminit(void);
0027 extern char *fw_getenv(char *name);
0028 extern unsigned long fw_getenvl(char *name);
0029 extern void fw_init_early_console(char port);
0030 
0031 #endif /* __ASM_FW_H_ */