review fixes

This commit is contained in:
BVK Chaitanya 2010-06-02 14:45:07 +05:30
parent e508977630
commit 6d6f139349
6 changed files with 10 additions and 19 deletions

View file

@ -31,10 +31,6 @@
#include <grub/command.h> #include <grub/command.h>
#include <grub/i18n.h> #include <grub/i18n.h>
#if defined (GRUB_MACHINE_EMU)
#include <grub/emu/misc.h>
#endif
static struct grub_parttool *parts = 0; static struct grub_parttool *parts = 0;
static int curhandle = 0; static int curhandle = 0;
static grub_dl_t mymod; static grub_dl_t mymod;
@ -179,9 +175,7 @@ grub_cmd_parttool (grub_command_t cmd __attribute__ ((unused)),
} }
/* Load modules. */ /* Load modules. */
#if defined(GRUB_MACHINE_EMU)
if (! grub_no_autoload) if (! grub_no_autoload)
#endif
{ {
const char *prefix; const char *prefix;
prefix = grub_env_get ("prefix"); prefix = grub_env_get ("prefix");

View file

@ -95,13 +95,13 @@ int EXPORT_FUNC(grub_dl_ref) (grub_dl_t mod);
int EXPORT_FUNC(grub_dl_unref) (grub_dl_t mod); int EXPORT_FUNC(grub_dl_unref) (grub_dl_t mod);
void EXPORT_FUNC(grub_dl_iterate) (int (*hook) (grub_dl_t mod)); void EXPORT_FUNC(grub_dl_iterate) (int (*hook) (grub_dl_t mod));
grub_dl_t EXPORT_FUNC(grub_dl_get) (const char *name); grub_dl_t EXPORT_FUNC(grub_dl_get) (const char *name);
grub_err_t EXPORT_FUNC(grub_dl_register_symbol) (const char *name, void *addr, grub_err_t grub_dl_register_symbol (const char *name, void *addr,
grub_dl_t mod); grub_dl_t mod);
grub_err_t grub_arch_dl_check_header (void *ehdr); grub_err_t grub_arch_dl_check_header (void *ehdr);
grub_err_t grub_arch_dl_relocate_symbols (grub_dl_t mod, void *ehdr); grub_err_t grub_arch_dl_relocate_symbols (grub_dl_t mod, void *ehdr);
#if defined (_mips) && (! defined (GRUB_MACHINE_EMU) || ! GRUB_MACHINE_EMU) #if defined (_mips)
#define GRUB_LINKER_HAVE_INIT 1 #define GRUB_LINKER_HAVE_INIT 1
void grub_arch_dl_init_linker (void); void grub_arch_dl_init_linker (void);
#endif #endif

View file

@ -49,7 +49,4 @@ int EXPORT_FUNC(asprintf) (char **buf, const char *fmt, ...);
char * EXPORT_FUNC(xasprintf) (const char *fmt, ...); char * EXPORT_FUNC(xasprintf) (const char *fmt, ...);
extern char * canonicalize_file_name (const char *path); extern char * canonicalize_file_name (const char *path);
/* Flag to control module autoloading in normal mode. */
extern int EXPORT_VAR(grub_no_autoload);
#endif /* GRUB_EMU_MISC_H */ #endif /* GRUB_EMU_MISC_H */

View file

@ -308,4 +308,11 @@ void EXPORT_FUNC (grub_halt) (int no_apm);
void EXPORT_FUNC (grub_halt) (void); void EXPORT_FUNC (grub_halt) (void);
#endif #endif
#ifdef GRUB_MACHINE_EMU
/* Flag to control module autoloading in normal mode. */
extern int EXPORT_VAR(grub_no_autoload);
#else
#define grub_no_autoload 0
#endif
#endif /* ! GRUB_MISC_HEADER */ #endif /* ! GRUB_MISC_HEADER */

View file

@ -51,7 +51,6 @@ static jmp_buf main_env;
/* Store the prefix specified by an argument. */ /* Store the prefix specified by an argument. */
static char *prefix = NULL; static char *prefix = NULL;
/* Flag to control module autoloading in normal mode. */
int grub_no_autoload; int grub_no_autoload;
grub_addr_t grub_addr_t

View file

@ -32,10 +32,6 @@
#include <grub/i18n.h> #include <grub/i18n.h>
#include <grub/charset.h> #include <grub/charset.h>
#if defined (GRUB_MACHINE_EMU)
#include <grub/emu/misc.h>
#endif
#define GRUB_DEFAULT_HISTORY_SIZE 50 #define GRUB_DEFAULT_HISTORY_SIZE 50
static int nested_level = 0; static int nested_level = 0;
@ -480,9 +476,7 @@ grub_normal_init_page (struct grub_term_output *term)
static void static void
read_lists (const char *val) read_lists (const char *val)
{ {
#if defined(GRUB_MACHINE_EMU)
if (! grub_no_autoload) if (! grub_no_autoload)
#endif
{ {
read_command_list (val); read_command_list (val);
read_fs_list (val); read_fs_list (val);