ReactOS 0.4.15-dev-5672-gf73ac17
diskmbr.h
Go to the documentation of this file.
1/* @(#)diskmbr.h 1.2 04/03/02 Copyright 1999-2004 J. Schilling */
2/*
3 * Header file diskmbr.h - assorted structure definitions and macros
4 * describing standard PC partition table
5 *
6 * Copyright (c) 1999-2004 J. Schilling
7 */
8/*
9 * This program is free software; you can redistribute it and/or modify
10 * it under the terms of the GNU General Public License version 2
11 * as published by the Free Software Foundation.
12 *
13 * This program is distributed in the hope that it will be useful,
14 * but WITHOUT ANY WARRANTY; without even the implied warranty of
15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16 * GNU General Public License for more details.
17 *
18 * You should have received a copy of the GNU General Public License along with
19 * this program; see the file COPYING. If not, write to the Free Software
20 * Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
21 */
22
23#ifndef _DISKMBR_H
24#define _DISKMBR_H
25
26#define MBR_MAGIC 0xAA55
27
28#define PARTITION_UNUSED 0x00
29#define PARTITION_ACTIVE 0x80
30
31#define PARTITION_COUNT 4
32
33#define MBR_SECTOR(x) ((x)&0x3F)
34#define MBR_CYLINDER(x) ((x)>>8|((x)<<2&0x300))
35
37 unsigned char status;
38 unsigned char s_head;
39 unsigned char s_cyl_sec[2];
40 unsigned char type;
41 unsigned char e_head;
42 unsigned char e_cyl_sec[2];
43 unsigned char boot_sec[4];
44 unsigned char size[4];
45};
46
48 char pad[0x1BE];
50 unsigned char magic[2];
51};
52
53#endif /* _DISKMBR_H */
#define PARTITION_COUNT
Definition: diskmbr.h:31
GLsizeiptr size
Definition: glext.h:5919
struct disk_partition partition[PARTITION_COUNT]
Definition: diskmbr.h:49
unsigned char magic[2]
Definition: diskmbr.h:50
char pad[0x1BE]
Definition: diskmbr.h:48
unsigned char e_cyl_sec[2]
Definition: diskmbr.h:42
unsigned char e_head
Definition: diskmbr.h:41
unsigned char s_cyl_sec[2]
Definition: diskmbr.h:39
unsigned char type
Definition: diskmbr.h:40
unsigned char status
Definition: diskmbr.h:37
unsigned char s_head
Definition: diskmbr.h:38
unsigned char boot_sec[4]
Definition: diskmbr.h:43