Root/
1 | #ifndef _LINUX_BLKPG_H |
2 | #define _LINUX_BLKPG_H |
3 | |
4 | /* |
5 | * Partition table and disk geometry handling |
6 | * |
7 | * A single ioctl with lots of subfunctions: |
8 | * |
9 | * Device number stuff: |
10 | * get_whole_disk() (given the device number of a partition, |
11 | * find the device number of the encompassing disk) |
12 | * get_all_partitions() (given the device number of a disk, return the |
13 | * device numbers of all its known partitions) |
14 | * |
15 | * Partition stuff: |
16 | * add_partition() |
17 | * delete_partition() |
18 | * test_partition_in_use() (also for test_disk_in_use) |
19 | * |
20 | * Geometry stuff: |
21 | * get_geometry() |
22 | * set_geometry() |
23 | * get_bios_drivedata() |
24 | * |
25 | * For today, only the partition stuff - aeb, 990515 |
26 | */ |
27 | #include <linux/compiler.h> |
28 | #include <linux/ioctl.h> |
29 | |
30 | #define BLKPG _IO(0x12,105) |
31 | |
32 | /* The argument structure */ |
33 | struct blkpg_ioctl_arg { |
34 | int op; |
35 | int flags; |
36 | int datalen; |
37 | void __user *data; |
38 | }; |
39 | |
40 | /* The subfunctions (for the op field) */ |
41 | #define BLKPG_ADD_PARTITION 1 |
42 | #define BLKPG_DEL_PARTITION 2 |
43 | |
44 | /* Sizes of name fields. Unused at present. */ |
45 | #define BLKPG_DEVNAMELTH 64 |
46 | #define BLKPG_VOLNAMELTH 64 |
47 | |
48 | /* The data structure for ADD_PARTITION and DEL_PARTITION */ |
49 | struct blkpg_partition { |
50 | long long start; /* starting offset in bytes */ |
51 | long long length; /* length in bytes */ |
52 | int pno; /* partition number */ |
53 | char devname[BLKPG_DEVNAMELTH]; /* partition name, like sda5 or c0d1p2, |
54 | to be used in kernel messages */ |
55 | char volname[BLKPG_VOLNAMELTH]; /* volume label */ |
56 | }; |
57 | |
58 | #endif /* _LINUX_BLKPG_H */ |
59 |
Branches:
ben-wpan
ben-wpan-stefan
javiroman/ks7010
jz-2.6.34
jz-2.6.34-rc5
jz-2.6.34-rc6
jz-2.6.34-rc7
jz-2.6.35
jz-2.6.36
jz-2.6.37
jz-2.6.38
jz-2.6.39
jz-3.0
jz-3.1
jz-3.11
jz-3.12
jz-3.13
jz-3.15
jz-3.16
jz-3.18-dt
jz-3.2
jz-3.3
jz-3.4
jz-3.5
jz-3.6
jz-3.6-rc2-pwm
jz-3.9
jz-3.9-clk
jz-3.9-rc8
jz47xx
jz47xx-2.6.38
master
Tags:
od-2011-09-04
od-2011-09-18
v2.6.34-rc5
v2.6.34-rc6
v2.6.34-rc7
v3.9