Permalink
Browse files

. 消除 UUID 改动对 RUN 的影响.

  • Loading branch information...
yaya
yaya committed May 23, 2017
1 parent 515e8f7 commit 8a774d45ca0d534936e9f897e794ad5420fcca46
Showing with 12 additions and 13 deletions.
  1. +6 −6 stage2/builtins.c
  2. +1 −1 stage2/cmdline.c
  3. +4 −4 stage2/console.c
  4. +0 −1 stage2/disk_io.c
  5. +1 −1 stage2/fsys_iso9660.c
View
@@ -3281,9 +3281,9 @@ color_func (char *arg, int flags)
if (! *arg)
{
if (new_normal_color >> 8)
- new_color[COLOR_STATE_HIGHLIGHT] = ((new_normal_color >> 32) | (new_normal_color << 32));
+ new_color[COLOR_STATE_HIGHLIGHT] = 0xffffff;
else
- new_color[COLOR_STATE_HIGHLIGHT] = (((new_normal_color >> 4) & 0xf) | ((new_normal_color & 0xf) << 4));
+ new_color[COLOR_STATE_HIGHLIGHT] = 0xf;
}
else
{
@@ -3327,7 +3327,7 @@ static struct builtin builtin_color =
"Change the menu colors. The color NORMAL is used for most"
" lines in the menu, and the color HIGHLIGHT is used to highlight the"
" line where the cursor points. If you omit HIGHLIGHT, then the"
- " inverted color of NORMAL is used for the highlighted line. If you"
+ " 0xf(4 bit) or 0xffffff(32 bit) is used for the highlighted line. If you"
" omit HELPTEXT and/or HEADING, then NORMAL is used."
" The format of a color is \"FG/BG\". FG and BG are symbolic color names."
" A symbolic color name must be one of these: black, blue, green,"
@@ -6635,7 +6635,8 @@ uuid_func (char *argument, int flags)
if (debug > 0)
{
print_root_device (NULL,1);
- grub_printf (": %s is \"%s\".", p, ((*uuid_found) ? uuid_found : "(unsupported)"));
+ grub_printf (": %s is \"%s\".\n\t", p, ((*uuid_found) ? uuid_found : "(unsupported)"));
+ print_fsys_type();
}
saved_drive = tmp_drive;
saved_partition = tmp_partition;
@@ -6754,7 +6755,7 @@ uuid_func (char *argument, int flags)
{
grub_printf ("(%s%x%c%c%c%c):", ((drive<10)?"fd":(drive>=0x9f)?"0x":"hd"),((drive<10 || drive>=0x9f)?drive:(drive-0x80)), ((pc_slice==0xff)?'\0':','),((pc_slice==0xff)?'\0' :(pc_slice + '0')), ((bsd_part == 0xFF) ? '\0' : ','), ((bsd_part == 0xFF) ? '\0' : (bsd_part + 'a')));
if (*uuid_found || debug)
- grub_printf(" %s is \"%s\".\n", p, ((*uuid_found) ? uuid_found : "(unsupported)"));
+ grub_printf("%s%s is \"%s\".\n\t", ((drive<10)?" ":(drive>=0x9f)?" ":" "), p, ((*uuid_found) ? uuid_found : "(unsupported)"));
print_fsys_type();
}
else if (substring((char*)uuid_found,arg,1) == 0)
@@ -6929,7 +6930,6 @@ static struct builtin builtin_vol =
" DEVICE (if VOLUME is not specified)."
};
-unsigned int iso_type;
int read_mft(char* buf,unsigned long mftno);
static void
get_vol (char* vol_found, int flags)
View
@@ -228,7 +228,7 @@ static char *skip_to_next_cmd (char *cmd,int *status,int flags)
#define PRINTF_BUFFER ((unsigned char *)SYSTEM_RESERVED_MEMORY + 0x20000)
//char *pre_cmdline = (char *)0x4CB08;
-static char *cmd_buffer = ((char *)SYSTEM_RESERVED_MEMORY - 0x10000);
+static char *cmd_buffer = ((char *)0x3A9000);
int expand_var(const char *str,char *out,const unsigned int len_max)
{
View
@@ -97,13 +97,13 @@ color_32_to_4 (unsigned long color32)
col32 = b;
}
- if (col32 >= 0xaa)
+ if (col32 > 0xaa)
col4 |= 8;
- if (r && r >= col32/2)
+ if (r > col32/2)
col4 |= 4;
- if (g && g >= col32/2)
+ if (g > col32/2)
col4 |= 2;
- if (b && b >= col32/2)
+ if (b > col32/2)
col4 |= 1;
return col4;
View
@@ -644,7 +644,6 @@ set_bootdev (int hdbias)
/*
* This prints the filesystem type or gives relevant information.
*/
-unsigned int iso_type;
void
print_fsys_type (void)
{
View
@@ -62,7 +62,7 @@ struct iso_inode_info {
#define DIRREC ((struct iso_directory_record *)(FSYS_BUF + 10240))
#define UDF_DIRREC ((struct udf_descriptor *)(FSYS_BUF + 10240))
-extern unsigned int iso_type; //0/1/2/3=ISO_TYPE_9660/ISO_TYPE_udf/ISO_TYPE_Joliet/ISO_TYPE_RockRidge
+unsigned int iso_type; //0/1/2/3=ISO_TYPE_9660/ISO_TYPE_udf/ISO_TYPE_Joliet/ISO_TYPE_RockRidge
unsigned long udf_partition_start;
#if 0

0 comments on commit 8a774d4

Please sign in to comment.