~smartboyhw/wubi/bug-1080090-new

« back to all changes in this revision

Viewing changes to src/grub4dos/stage1/.svn/text-base/stage1.h.svn-base

  • Committer: Howard Chan
  • Date: 2012-11-20 10:16:05 UTC
  • Revision ID: smartboyhw@gmail.com-20121120101605-qfmjfsdynpzg9an9
Added images

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
/*
2
 
 *  GRUB  --  GRand Unified Bootloader
3
 
 *  Copyright (C) 1999,2000,2002,2004   Free Software Foundation, Inc.
4
 
 *
5
 
 *  This program is free software; you can redistribute it and/or modify
6
 
 *  it under the terms of the GNU General Public License as published by
7
 
 *  the Free Software Foundation; either version 2 of the License, or
8
 
 *  (at your option) any later version.
9
 
 *
10
 
 *  This program is distributed in the hope that it will be useful,
11
 
 *  but WITHOUT ANY WARRANTY; without even the implied warranty of
12
 
 *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
13
 
 *  GNU General Public License for more details.
14
 
 *
15
 
 *  You should have received a copy of the GNU General Public License
16
 
 *  along with this program; if not, write to the Free Software
17
 
 *  Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
18
 
 */
19
 
 
20
 
#ifndef STAGE1_HEADER
21
 
#define STAGE1_HEADER   1
22
 
 
23
 
 
24
 
/* Define the version numbers here, so that Stage 1 can know them.  */
25
 
#define COMPAT_VERSION_MAJOR    3
26
 
#define COMPAT_VERSION_MINOR    2
27
 
#define COMPAT_VERSION          ((COMPAT_VERSION_MINOR << 8) \
28
 
                                        | COMPAT_VERSION_MAJOR)
29
 
 
30
 
/* The signature for bootloader.  */
31
 
#define STAGE1_SIGNATURE        0xaa55
32
 
 
33
 
/* The offset of the end of BPB (BIOS Parameter Block).  */
34
 
#define STAGE1_BPBEND           0x3e
35
 
 
36
 
/* The offset of the major version.  */
37
 
#define STAGE1_VER_MAJ_OFFS     0x3e
38
 
 
39
 
/* The offset of BOOT_DRIVE.  */
40
 
#define STAGE1_BOOT_DRIVE       0x40
41
 
 
42
 
/* The offset of FORCE_LBA.  */
43
 
#define STAGE1_FORCE_LBA        0x41
44
 
 
45
 
/* The offset of STAGE2_ADDRESS.  */
46
 
#define STAGE1_STAGE2_ADDRESS   0x42
47
 
 
48
 
/* The offset of STAGE2_SECTOR.  */
49
 
#define STAGE1_STAGE2_SECTOR    0x44
50
 
 
51
 
/* The offset of STAGE2_SEGMENT.  */
52
 
#define STAGE1_STAGE2_SEGMENT   0x48
53
 
 
54
 
/* The offset of BOOT_DRIVE_CHECK.  */
55
 
#define STAGE1_BOOT_DRIVE_CHECK 0x4b
56
 
 
57
 
/* The offset of a magic number used by Windows NT.  */
58
 
#define STAGE1_WINDOWS_NT_MAGIC 0x1b8
59
 
 
60
 
/* The offset of the start of the partition table.  */
61
 
#define STAGE1_PARTSTART        0x1be
62
 
 
63
 
/* The offset of the end of the partition table.  */
64
 
#define STAGE1_PARTEND          0x1fe
65
 
 
66
 
/* The stack segment.  */
67
 
#define STAGE1_STACKSEG         0x2000
68
 
 
69
 
/* The segment of disk buffer. The disk buffer MUST be 32K long and
70
 
   cannot straddle a 64K boundary.  */
71
 
#define STAGE1_BUFFERSEG        0x7000
72
 
 
73
 
/* The address of drive parameters.  */
74
 
#define STAGE1_DRP_ADDR         0x7f00
75
 
 
76
 
/* The size of drive parameters.  */
77
 
#define STAGE1_DRP_SIZE         0x42
78
 
 
79
 
/* The flag for BIOS drive number to designate a hard disk vs. a
80
 
   floppy.  */
81
 
#define STAGE1_BIOS_HD_FLAG     0x80
82
 
 
83
 
/* The drive number of an invalid drive.  */
84
 
#define GRUB_INVALID_DRIVE      0xFFFFFFFF
85
 
 
86
 
#endif /* ! STAGE1_HEADER */