OpenBSD CVS

CVS log for src/sbin/pdisk/Attic/dpme.h


[BACK] Up to [local] / src / sbin / pdisk

Request diff between arbitrary revisions


Default branch: MAIN


Revision 1.27, Sat Jan 30 17:23:09 2016 UTC (8 years, 4 months ago) by krw
Branch: MAIN
CVS Tags: HEAD
Changes since 1.26: +1 -1 lines
FILE REMOVED

Another to the attic.

Revision 1.26 / (download) - annotate - [select for diffs], Sat Jan 30 17:09:11 2016 UTC (8 years, 4 months ago) by krw
Branch: MAIN
Changes since 1.25: +1 -35 lines
Diff to previous 1.25 (colored)

Fold struct dpme into struct entry. Same reasons as for folding
struct block0 into struct partition_map. Easier to read code.

Revision 1.25 / (download) - annotate - [select for diffs], Fri Jan 29 22:51:43 2016 UTC (8 years, 4 months ago) by krw
Branch: MAIN
Changes since 1.24: +1 -19 lines
Diff to previous 1.24 (colored)

Fold struct block0 into struct partition map. There can be only one
and read/write_block0() can move the data from/to disk to/from
appropriate fields anywhere. Removes a bunch of dereferencing,
malloc'ing and pointer checking.

Revision 1.24 / (download) - annotate - [select for diffs], Thu Jan 28 13:01:33 2016 UTC (8 years, 4 months ago) by krw
Branch: MAIN
Changes since 1.23: +2 -2 lines
Diff to previous 1.23 (colored)

Use consistent 'return' idiom -- no parenthesis since that was the style
of the existing code.

Revision 1.23 / (download) - annotate - [select for diffs], Wed Jan 27 16:38:37 2016 UTC (8 years, 4 months ago) by krw
Branch: MAIN
Changes since 1.22: +4 -4 lines
Diff to previous 1.22 (colored)

On-disk partition name/types/processorid may or may not be NUL
terminated after all. So add an extra byte for a NUL in the in-memory
struct's.

Revision 1.22 / (download) - annotate - [select for diffs], Wed Jan 27 14:19:59 2016 UTC (8 years, 4 months ago) by krw
Branch: MAIN
Changes since 1.21: +4 -4 lines
Diff to previous 1.21 (colored)

Check block 0 signature, physical block size and physical block count when
reading partition map.

Check for unmapped physical blocks and overlapping partitions when reading
partition map.

No need for duplicate checks in validate_map(), so remove validate.c from
build and 'v' command from code and docs.

Revision 1.21 / (download) - annotate - [select for diffs], Mon Jan 25 23:43:20 2016 UTC (8 years, 4 months ago) by krw
Branch: MAIN
Changes since 1.20: +12 -19 lines
Diff to previous 1.20 (colored)

Use new read/write_block0 and read/write_dpme which handle any
endian or alignment issues forcefully. Removes need for convert_*
functions so unhook convert.c from build. read/write_block become
static functions inside file_media.c.

Tweak struct block0 to stop trying to handle alignment issues by clever
declaration. Rely on the new functions to accurately translate between
on-disk and in-memory layouts.

Enables pdisk to work on amd64 and likely other architectures if
it's ever desirable. Does bring back DEV_BSIZE to pdisk.c since the
in-memory structure will *not* be 512 bytes on other archs.

Revision 1.20 / (download) - annotate - [select for diffs], Mon Jan 25 21:51:23 2016 UTC (8 years, 4 months ago) by krw
Branch: MAIN
Changes since 1.19: +27 -34 lines
Diff to previous 1.19 (colored)

Tweak fields in struct dpme to be more consistent with Apple's info.

Better comments, make all reserved fields uint8_t arrays, don't
claim uint32_t fields are actually pointers.

Revision 1.19 / (download) - annotate - [select for diffs], Sun Jan 24 01:38:32 2016 UTC (8 years, 4 months ago) by krw
Branch: MAIN
Changes since 1.18: +2 -2 lines
Diff to previous 1.18 (colored)

Whitespace fixes.

Revision 1.18 / (download) - annotate - [select for diffs], Sat Jan 23 14:10:05 2016 UTC (8 years, 4 months ago) by krw
Branch: MAIN
Changes since 1.17: +11 -2 lines
Diff to previous 1.17 (colored)

Add comments to ensure future spelunkers realize that struct block0
and struct dpme must be 512-bytes long at the moment.

Use this fact to avoid using DEV_BSIZE and thus replace #include
<param.h> with #include <types.h> in pdisk.c.

Constrain media size to UINT32_MAX, the actual limit, instead of
LONG_MAX, which could be way more on some theoretical future arch
running pdisk. And do the constraint inside open_partition_map().

Revision 1.17 / (download) - annotate - [select for diffs], Fri Jan 22 17:22:35 2016 UTC (8 years, 4 months ago) by krw
Branch: MAIN
Changes since 1.16: +21 -21 lines
Diff to previous 1.16 (colored)

Whitespace fixes.

Revision 1.16 / (download) - annotate - [select for diffs], Sun Jan 17 23:18:19 2016 UTC (8 years, 4 months ago) by krw
Branch: MAIN
Changes since 1.15: +24 -22 lines
Diff to previous 1.15 (colored)

Change "//" comments to "/**/". Nuke really stupid ones.

Revision 1.15 / (download) - annotate - [select for diffs], Sun Jan 17 19:15:55 2016 UTC (8 years, 4 months ago) by krw
Branch: MAIN
Changes since 1.14: +12 -12 lines
Diff to previous 1.14 (colored)

Kill leading, imbedded, trailing whitespace.

Revision 1.14 / (download) - annotate - [select for diffs], Sun Jan 17 18:57:52 2016 UTC (8 years, 4 months ago) by krw
Branch: MAIN
Changes since 1.13: +1 -25 lines
Diff to previous 1.13 (colored)

Remove a bunch of ridiculous and uninformative comments like "// Defines".

Revision 1.13 / (download) - annotate - [select for diffs], Sun Jan 17 18:44:59 2016 UTC (8 years, 4 months ago) by krw
Branch: MAIN
Changes since 1.12: +15 -16 lines
Diff to previous 1.12 (colored)

The great de-typedef'ification concludes with u32 -> uint32_t. And a
bunch of consequent printf() format corrections.

Revision 1.12 / (download) - annotate - [select for diffs], Sun Jan 17 18:26:51 2016 UTC (8 years, 4 months ago) by krw
Branch: MAIN
Changes since 1.11: +11 -12 lines
Diff to previous 1.11 (colored)

The great de-typedef'ification continues. u16 -> uint16_t.

Revision 1.11 / (download) - annotate - [select for diffs], Sun Jan 17 18:23:30 2016 UTC (8 years, 4 months ago) by krw
Branch: MAIN
Changes since 1.10: +5 -6 lines
Diff to previous 1.10 (colored)

The great de-typedef'ification continues. u8 -> uint8_t.

Revision 1.10 / (download) - annotate - [select for diffs], Sun Jan 17 16:26:26 2016 UTC (8 years, 4 months ago) by krw
Branch: MAIN
Changes since 1.9: +3 -4 lines
Diff to previous 1.9 (colored)

The great de-typedef'ification continues. DDMap -> struct ddmap.

Revision 1.9 / (download) - annotate - [select for diffs], Sun Jan 17 16:15:59 2016 UTC (8 years, 4 months ago) by krw
Branch: MAIN
Changes since 1.8: +2 -3 lines
Diff to previous 1.8 (colored)

The great de-typedef'ification continues. Block0 -> struct block0.

Revision 1.8 / (download) - annotate - [select for diffs], Sun Jan 17 16:07:06 2016 UTC (8 years, 4 months ago) by krw
Branch: MAIN
Changes since 1.7: +1 -2 lines
Diff to previous 1.7 (colored)

The great de-typedef'ification continues. DPME -> struct dpme.

Revision 1.7 / (download) - annotate - [select for diffs], Sun Jan 17 14:28:25 2016 UTC (8 years, 4 months ago) by krw
Branch: MAIN
Changes since 1.6: +1 -38 lines
Diff to previous 1.6 (colored)

A/UX is no more, was m68k only, and we have no sentimental reasons for
keeping support.

Revision 1.6 / (download) - annotate - [select for diffs], Fri Jan 15 16:39:20 2016 UTC (8 years, 4 months ago) by krw
Branch: MAIN
Changes since 1.5: +19 -38 lines
Diff to previous 1.5 (colored)

Replace bitfield_get() and bitfield_set() abstraction with simple masking
operations since all the uses but 1 are for 1 bit fields. No functional
change intended.

Unhook bitfield.c from build.

Revision 1.5 / (download) - annotate - [select for diffs], Mon Jan 11 17:55:45 2016 UTC (8 years, 5 months ago) by jasper
Branch: MAIN
Changes since 1.4: +1 -31 lines
Diff to previous 1.4 (colored)

- remove some unused data structures/fields
- unifdef notdef

ok krw@

Revision 1.4 / (download) - annotate - [select for diffs], Mon Jan 11 07:54:07 2016 UTC (8 years, 5 months ago) by jasper
Branch: MAIN
Changes since 1.3: +2 -0 lines
Diff to previous 1.3 (colored)

add rcs ids

Revision 1.3 / (download) - annotate - [select for diffs], Thu Apr 27 19:52:21 2006 UTC (18 years, 1 month ago) by martin
Branch: MAIN
CVS Tags: OPENBSD_5_8_BASE, OPENBSD_5_8, OPENBSD_5_7_BASE, OPENBSD_5_7, OPENBSD_5_6_BASE, OPENBSD_5_6, OPENBSD_5_5_BASE, OPENBSD_5_5, OPENBSD_5_4_BASE, OPENBSD_5_4, OPENBSD_5_3_BASE, OPENBSD_5_3, OPENBSD_5_2_BASE, OPENBSD_5_2, OPENBSD_5_1_BASE, OPENBSD_5_1, OPENBSD_5_0_BASE, OPENBSD_5_0, OPENBSD_4_9_BASE, OPENBSD_4_9, OPENBSD_4_8_BASE, OPENBSD_4_8, OPENBSD_4_7_BASE, OPENBSD_4_7, OPENBSD_4_6_BASE, OPENBSD_4_6, OPENBSD_4_5_BASE, OPENBSD_4_5, OPENBSD_4_4_BASE, OPENBSD_4_4, OPENBSD_4_3_BASE, OPENBSD_4_3, OPENBSD_4_2_BASE, OPENBSD_4_2, OPENBSD_4_1_BASE, OPENBSD_4_1, OPENBSD_4_0_BASE, OPENBSD_4_0
Changes since 1.2: +3 -3 lines
Diff to previous 1.2 (colored)

update for pdisk 0.8a2, from NetBSD, retaining our local changes;
summing it up:

- Clean up sources - fix naming, delete old email addresses
- Added support for display of Mac volume names
- Fix block 0 display to show logical offset of drivers
- Require confirmation of quit without write
- Fix iteration to not complain about missing devices
- Warn when creating/writing a map with more than 15 entries

and, most important, add do_update_dpme() which allows us to partition
OpenBSD slices without previous MacOS setup.

Tested with shared MacOS install on macppc, procedure there remains the
same.

grammer and spelling help and ok jmc@

ok miod@

Revision 1.2 / (download) - annotate - [select for diffs], Sun Jun 9 08:13:08 2002 UTC (22 years ago) by todd
Branch: MAIN
CVS Tags: OPENBSD_3_9_BASE, OPENBSD_3_9, OPENBSD_3_8_BASE, OPENBSD_3_8, OPENBSD_3_7_BASE, OPENBSD_3_7, OPENBSD_3_6_BASE, OPENBSD_3_6, OPENBSD_3_5_BASE, OPENBSD_3_5, OPENBSD_3_4_BASE, OPENBSD_3_4, OPENBSD_3_3_BASE, OPENBSD_3_3, OPENBSD_3_2_BASE, OPENBSD_3_2
Changes since 1.1: +17 -17 lines
Diff to previous 1.1 (colored)

rm trailing whitespace

Revision 1.1.1.1 / (download) - annotate - [select for diffs] (vendor branch), Sat Mar 24 00:13:59 2001 UTC (23 years, 2 months ago) by drahn
Branch: apple19980218
CVS Tags: ver1, OPENBSD_3_1_BASE, OPENBSD_3_1, OPENBSD_3_0_BASE, OPENBSD_3_0, OPENBSD_2_9_BASE, OPENBSD_2_9
Changes since 1.1: +0 -0 lines
Diff to previous 1.1 (colored)

Import of pdisk from apple, BSD licensed code. Archive dated Feb 18 1998 
This is a HFS partition editing tool.

Revision 1.1 / (download) - annotate - [select for diffs], Sat Mar 24 00:13:59 2001 UTC (23 years, 2 months ago) by drahn
Branch: MAIN

Initial revision

This form allows you to request diff's between any two revisions of a file. You may select a symbolic revision name using the selection box or you may type in a numeric name using the type-in text box.