summaryrefslogtreecommitdiff
path: root/sbin/pdisk
diff options
context:
space:
mode:
Diffstat (limited to 'sbin/pdisk')
-rw-r--r--sbin/pdisk/ATA_media.c98
-rw-r--r--sbin/pdisk/ATA_media.h34
-rw-r--r--sbin/pdisk/DoSCSICommand.c38
-rw-r--r--sbin/pdisk/DoSCSICommand.h34
-rw-r--r--sbin/pdisk/MacSCSICommand.h36
-rw-r--r--sbin/pdisk/README34
-rw-r--r--sbin/pdisk/SCSI_media.c84
-rw-r--r--sbin/pdisk/SCSI_media.h34
-rw-r--r--sbin/pdisk/bitfield.c34
-rw-r--r--sbin/pdisk/bitfield.h34
-rw-r--r--sbin/pdisk/convert.c34
-rw-r--r--sbin/pdisk/convert.h34
-rw-r--r--sbin/pdisk/deblock_media.c50
-rw-r--r--sbin/pdisk/deblock_media.h34
-rw-r--r--sbin/pdisk/dpme.h34
-rw-r--r--sbin/pdisk/dump.c50
-rw-r--r--sbin/pdisk/dump.h34
-rw-r--r--sbin/pdisk/errors.c34
-rw-r--r--sbin/pdisk/errors.h34
-rw-r--r--sbin/pdisk/file_media.c54
-rw-r--r--sbin/pdisk/file_media.h34
-rw-r--r--sbin/pdisk/io.c34
-rw-r--r--sbin/pdisk/io.h34
-rw-r--r--sbin/pdisk/layout_dump.c46
-rw-r--r--sbin/pdisk/layout_dump.h34
-rw-r--r--sbin/pdisk/media.c40
-rw-r--r--sbin/pdisk/media.h36
-rw-r--r--sbin/pdisk/partition_map.c44
-rw-r--r--sbin/pdisk/partition_map.h34
-rw-r--r--sbin/pdisk/pathname.c38
-rw-r--r--sbin/pdisk/pathname.h34
-rw-r--r--sbin/pdisk/pdisk.c36
-rw-r--r--sbin/pdisk/pdisk.h34
-rw-r--r--sbin/pdisk/pdisk.html120
-rw-r--r--sbin/pdisk/pdisk.r34
-rw-r--r--sbin/pdisk/util.c38
-rw-r--r--sbin/pdisk/util.h34
-rw-r--r--sbin/pdisk/validate.c60
-rw-r--r--sbin/pdisk/validate.h36
-rw-r--r--sbin/pdisk/version.h36
40 files changed, 844 insertions, 844 deletions
diff --git a/sbin/pdisk/ATA_media.c b/sbin/pdisk/ATA_media.c
index 533c6216e2e..5af7ef7ff92 100644
--- a/sbin/pdisk/ATA_media.c
+++ b/sbin/pdisk/ATA_media.c
@@ -6,23 +6,23 @@
/*
* Copyright 1997,1998 by Apple Computer, Inc.
- * All Rights Reserved
- *
- * Permission to use, copy, modify, and distribute this software and
- * its documentation for any purpose and without fee is hereby granted,
- * provided that the above copyright notice appears in all copies and
- * that both the copyright notice and this permission notice appear in
- * supporting documentation.
- *
- * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
- * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
- * FOR A PARTICULAR PURPOSE.
- *
- * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
- * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
- * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
- * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
- * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+ * All Rights Reserved
+ *
+ * Permission to use, copy, modify, and distribute this software and
+ * its documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appears in all copies and
+ * that both the copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
+ * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+ * FOR A PARTICULAR PURPOSE.
+ *
+ * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
+ * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
+ * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
+ * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
+ * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
@@ -237,7 +237,7 @@ ATAHardwarePresent(void)
// Hardware configuration flags
configFlags = LMGetHWCfgFlags();
-
+
return ((configFlags & 0x0080) != 0);
}
@@ -262,7 +262,7 @@ ata_init(void)
return;
}
ata_inited = 1;
-
+
if (ATAManagerPresent() == 0) {
ata_mgr.exists = 0;
return;
@@ -272,12 +272,12 @@ ata_init(void)
ata_mgr.kind = allocate_media_kind();
clear_memory((void *)&pb, sizeof(pb));
-
+
pb.ataPBFunctionCode = kATAMgrManagerInquiry;
pb.ataPBVers = kATAPBVers1;
status = ataManager((ataPB*) &pb );
-
+
if (status != noErr) {
ata_mgr.exists = 0;
return;
@@ -302,7 +302,7 @@ long
compute_id(long bus, long device)
{
long id;
-
+
id = -1;
if (ata_mgr.version.major < 3) {
if (device != 0) {
@@ -346,7 +346,7 @@ get_info(long id, struct ATA_identify_drive_info *ip)
pb.ataPBFlags = mATAFlagIORead | mATAFlagByteSwap;
pb.ataPBTimeOut = kATAtimeout;
pb.ataPBBuffer = (void*) ip;
-
+
status = ataManager((ataPB*) &pb );
if (status != noErr) {
@@ -397,11 +397,11 @@ open_ata_as_media(long bus, long device)
struct ATA_identify_drive_info info;
unsigned char *buf;
unsigned long total;
-
+
if (ata_inited == 0) {
ata_init();
}
-
+
if (ata_mgr.exists == 0) {
//printf("ATA manager does not exist\n");
return 0;
@@ -475,7 +475,7 @@ read_ata_media(MEDIA m, long long offset, unsigned long count, void *address)
long block_size;
unsigned char *buffer;
int i;
-
+
a = (ATA_MEDIA) m;
rtn_value = 0;
if (a == 0) {
@@ -518,7 +518,7 @@ write_ata_media(MEDIA m, long long offset, unsigned long count, void *address)
long block_size;
unsigned char *buffer;
int i;
-
+
a = (ATA_MEDIA) m;
rtn_value = 0;
if (a == 0) {
@@ -555,7 +555,7 @@ long
close_ata_media(MEDIA m)
{
ATA_MEDIA a;
-
+
a = (ATA_MEDIA) m;
if (a == 0) {
return 0;
@@ -590,7 +590,7 @@ ATA_ReadBlock(UInt32 deviceID, ATA_INFO info, UInt32 block_size, UInt32 block, U
pb.ataPBDeviceID = deviceID;
pb.ataPBFlags = mATAFlagTFRead | mATAFlagIORead ;
pb.ataPBTimeOut = kATAtimeout;
-
+
pb.ataPBLogicalBlockSize = block_size;
pb.ataPBBuffer = address;
pb.ataPBByteCount = block_size;
@@ -644,7 +644,7 @@ ATA_WriteBlock(UInt32 deviceID, ATA_INFO info, UInt32 block_size, UInt32 block,
pb.ataPBDeviceID = deviceID;
pb.ataPBFlags = mATAFlagTFRead | mATAFlagIOWrite ;
pb.ataPBTimeOut = kATAtimeout;
-
+
pb.ataPBLogicalBlockSize = block_size;
pb.ataPBBuffer = address;
pb.ataPBByteCount = block_size;
@@ -707,7 +707,7 @@ get_pi_info(long id, struct ATAPI_identify_drive_info *ip)
pb.ataPBFlags = mATAFlagIORead | mATAFlagByteSwap | mATAFlagProtocol1;
pb.ataPBTimeOut = kATAtimeout;
pb.ataPBBuffer = (void*) ip;
-
+
status = ataManager((ataPB*) &pb );
if (status != noErr) {
@@ -728,12 +728,12 @@ open_atapi_as_media(long bus, long device)
struct ATAPI_identify_drive_info info;
unsigned char *buf;
unsigned long block_size;
- unsigned long blocks;
-
+ unsigned long blocks;
+
if (ata_inited == 0) {
ata_init();
}
-
+
if (ata_mgr.exists == 0) {
return 0;
}
@@ -786,7 +786,7 @@ read_atapi_media(MEDIA m, long long offset, unsigned long count, void *address)
long block_size;
unsigned char *buffer;
int i;
-
+
a = (ATA_MEDIA) m;
rtn_value = 0;
if (a == 0) {
@@ -821,7 +821,7 @@ read_atapi_media(MEDIA m, long long offset, unsigned long count, void *address)
long
write_atapi_media(MEDIA m, long long offset, unsigned long count, void *address)
-{
+{
return 0;
}
@@ -842,7 +842,7 @@ ATAPI_ReadBlock(UInt32 deviceID, UInt32 block_size, UInt32 block, UInt8 *address
pb.ataPBDeviceID = deviceID;
pb.ataPBFlags = mATAFlagTFRead | mATAFlagIORead | mATAFlagProtocol1;
pb.ataPBTimeOut = kATAtimeout;
-
+
pb.ataPBBuffer = address;
pb.ataPBByteCount = block_size;
pb.ataPBTaskFile.ataTFCylinder = block_size;
@@ -855,7 +855,7 @@ ATAPI_ReadBlock(UInt32 deviceID, UInt32 block_size, UInt32 block, UInt8 *address
pb.ataPBTaskFile.ataTFSDH = 0xA0 | 0x40 | slave;
pb.ataPBTaskFile.ataTFCommand = kATAcmdATAPIPacket;
pb.ataPBPacketPtr = &cmdPacket;
-
+
cmdPacket.atapiPacketSize = 16;
clear_memory((void *)&cmdPacket.atapiCommandByte, 16);
gRead = (SCSI_10_Byte_Command *) &cmdPacket.atapiCommandByte[0];
@@ -898,7 +898,7 @@ ATAPI_TestUnitReady(UInt32 deviceID)
pb.ataPBDeviceID = deviceID;
pb.ataPBFlags = mATAFlagTFRead | mATAFlagIORead | mATAFlagProtocol1;
pb.ataPBTimeOut = kATAtimeout;
-
+
if (deviceID & 0x0FF00) {
slave = 0x10;
} else {
@@ -908,7 +908,7 @@ ATAPI_TestUnitReady(UInt32 deviceID)
pb.ataPBTaskFile.ataTFSDH = 0xA0 | 0x40 | slave;
pb.ataPBTaskFile.ataTFCommand = kATAcmdATAPIPacket;
pb.ataPBPacketPtr = &cmdPacket;
-
+
cmdPacket.atapiPacketSize = 16;
clear_memory((void *)&cmdPacket.atapiCommandByte, 16);
gTestUnit = (SCSI_10_Byte_Command *) &cmdPacket.atapiCommandByte[0];
@@ -946,7 +946,7 @@ ATAPI_ReadCapacity(UInt32 deviceID, unsigned long *block_size, unsigned long *bl
pb.ataPBDeviceID = deviceID;
pb.ataPBFlags = mATAFlagTFRead | mATAFlagIORead | mATAFlagProtocol1;
pb.ataPBTimeOut = kATAtimeout;
-
+
pb.ataPBBuffer = (unsigned char *)&rcd;
pb.ataPBByteCount = 8;
pb.ataPBTaskFile.ataTFCylinder = 8;
@@ -959,7 +959,7 @@ ATAPI_ReadCapacity(UInt32 deviceID, unsigned long *block_size, unsigned long *bl
pb.ataPBTaskFile.ataTFSDH = 0xA0 | 0x40 | slave;
pb.ataPBTaskFile.ataTFCommand = kATAcmdATAPIPacket;
pb.ataPBPacketPtr = &cmdPacket;
-
+
cmdPacket.atapiPacketSize = 16;
clear_memory((void *)&cmdPacket.atapiCommandByte, 16);
gReadCap = (SCSI_10_Byte_Command *) &cmdPacket.atapiCommandByte[0];
@@ -994,10 +994,10 @@ ATA_FindDevice(long dRefNum)
pb.ataPBDeviceID = 0xFFFF;
pb.ataPBTimeOut = kATAtimeout;
- pb.ataDeviceNextID = 1;
+ pb.ataDeviceNextID = 1;
do {
status = ataManager((ataPB*) &pb);
-
+
if (status != noErr) {
break;
} else if (pb.ataDrvrRefNum == dRefNum
@@ -1027,11 +1027,11 @@ MEDIA_ITERATOR
create_ata_iterator(void)
{
ATA_MEDIA_ITERATOR a;
-
+
if (ata_inited == 0) {
ata_init();
}
-
+
if (ata_mgr.exists == 0) {
return 0;
}
@@ -1055,7 +1055,7 @@ void
reset_ata_iterator(MEDIA_ITERATOR m)
{
ATA_MEDIA_ITERATOR a;
-
+
a = (ATA_MEDIA_ITERATOR) m;
if (a == 0) {
/* no media */
@@ -1072,7 +1072,7 @@ step_ata_iterator(MEDIA_ITERATOR m)
{
ATA_MEDIA_ITERATOR a;
char *result;
-
+
a = (ATA_MEDIA_ITERATOR) m;
if (a == 0) {
/* no media */
@@ -1134,7 +1134,7 @@ open_mklinux_ata_as_media(long index)
{
long bus;
long id;
-
+
bus = index / 2;
id = index % 2;
diff --git a/sbin/pdisk/ATA_media.h b/sbin/pdisk/ATA_media.h
index 96a83172233..39e0f7c2bdd 100644
--- a/sbin/pdisk/ATA_media.h
+++ b/sbin/pdisk/ATA_media.h
@@ -6,23 +6,23 @@
/*
* Copyright 1997,1998 by Apple Computer, Inc.
- * All Rights Reserved
- *
- * Permission to use, copy, modify, and distribute this software and
- * its documentation for any purpose and without fee is hereby granted,
- * provided that the above copyright notice appears in all copies and
- * that both the copyright notice and this permission notice appear in
- * supporting documentation.
- *
- * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
- * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
- * FOR A PARTICULAR PURPOSE.
- *
- * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
- * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
- * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
- * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
- * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+ * All Rights Reserved
+ *
+ * Permission to use, copy, modify, and distribute this software and
+ * its documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appears in all copies and
+ * that both the copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
+ * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+ * FOR A PARTICULAR PURPOSE.
+ *
+ * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
+ * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
+ * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
+ * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
+ * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
#ifndef __ATA_media__
diff --git a/sbin/pdisk/DoSCSICommand.c b/sbin/pdisk/DoSCSICommand.c
index ea9cd49a373..3e30a07a5bf 100644
--- a/sbin/pdisk/DoSCSICommand.c
+++ b/sbin/pdisk/DoSCSICommand.c
@@ -11,23 +11,23 @@
/*
* Copyright 1992, 1993, 1997, 1998 by Apple Computer, Inc.
- * All Rights Reserved
- *
- * Permission to use, copy, modify, and distribute this software and
- * its documentation for any purpose and without fee is hereby granted,
- * provided that the above copyright notice appears in all copies and
- * that both the copyright notice and this permission notice appear in
- * supporting documentation.
- *
- * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
- * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
- * FOR A PARTICULAR PURPOSE.
- *
- * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
- * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
- * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
- * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
- * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+ * All Rights Reserved
+ *
+ * Permission to use, copy, modify, and distribute this software and
+ * its documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appears in all copies and
+ * that both the copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
+ * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+ * FOR A PARTICULAR PURPOSE.
+ *
+ * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
+ * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
+ * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
+ * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
+ * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
#include "DoScsiCommand.h"
@@ -576,7 +576,7 @@ exit:
&& (scsiFlags & scsiDirectionMask) != scsiDirectionNone
&& myTransferCount != dataLength) {
status = scsiDataRunError;
- }
+ }
if (scsiStatusBytePtr != NULL) {
*scsiStatusBytePtr = scsiStatusByte;
}
@@ -612,7 +612,7 @@ IsVirtualMemoryRunning(void)
{
OSErr status;
long response;
-
+
status = Gestalt(gestaltVMAttr, &response);
/*
* VM is active iff Gestalt succeeded and the response is appropriate.
diff --git a/sbin/pdisk/DoSCSICommand.h b/sbin/pdisk/DoSCSICommand.h
index 34d7e6cd8dd..22aea57916d 100644
--- a/sbin/pdisk/DoSCSICommand.h
+++ b/sbin/pdisk/DoSCSICommand.h
@@ -7,23 +7,23 @@
/*
* Copyright 1993-1998 by Apple Computer, Inc.
- * All Rights Reserved
- *
- * Permission to use, copy, modify, and distribute this software and
- * its documentation for any purpose and without fee is hereby granted,
- * provided that the above copyright notice appears in all copies and
- * that both the copyright notice and this permission notice appear in
- * supporting documentation.
- *
- * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
- * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
- * FOR A PARTICULAR PURPOSE.
- *
- * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
- * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
- * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
- * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
- * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+ * All Rights Reserved
+ *
+ * Permission to use, copy, modify, and distribute this software and
+ * its documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appears in all copies and
+ * that both the copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
+ * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+ * FOR A PARTICULAR PURPOSE.
+ *
+ * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
+ * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
+ * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
+ * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
+ * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
#ifndef __DoScsiCommand__
diff --git a/sbin/pdisk/MacSCSICommand.h b/sbin/pdisk/MacSCSICommand.h
index b02b66f90ae..4cae2387eb3 100644
--- a/sbin/pdisk/MacSCSICommand.h
+++ b/sbin/pdisk/MacSCSICommand.h
@@ -9,23 +9,23 @@
/*
* Copyright 1995, 1997 by Apple Computer, Inc.
- * All Rights Reserved
- *
- * Permission to use, copy, modify, and distribute this software and
- * its documentation for any purpose and without fee is hereby granted,
- * provided that the above copyright notice appears in all copies and
- * that both the copyright notice and this permission notice appear in
- * supporting documentation.
- *
- * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
- * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
- * FOR A PARTICULAR PURPOSE.
- *
- * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
- * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
- * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
- * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
- * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+ * All Rights Reserved
+ *
+ * Permission to use, copy, modify, and distribute this software and
+ * its documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appears in all copies and
+ * that both the copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
+ * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+ * FOR A PARTICULAR PURPOSE.
+ *
+ * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
+ * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
+ * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
+ * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
+ * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/*
@@ -193,7 +193,7 @@ struct SCSI_Sense_Data { /* Request Sense result */
unsigned char additionalSenseLength;
unsigned char reservedForCopy[4];
unsigned char additionalSenseCode;
- unsigned char additionalSenseQualifier;
+ unsigned char additionalSenseQualifier;
unsigned char fruCode; /* Field replacable unit code */
unsigned char senseKeySpecific[2];
unsigned char additional[101];
diff --git a/sbin/pdisk/README b/sbin/pdisk/README
index aeda6d7405b..5c5a309f1e1 100644
--- a/sbin/pdisk/README
+++ b/sbin/pdisk/README
@@ -27,23 +27,23 @@ Price: Free
Legalese:
Copyright 1996,1997,1998 by Apple Computer, Inc.
- All Rights Reserved
-
- Permission to use, copy, modify, and distribute this software and
- its documentation for any purpose and without fee is hereby granted,
- provided that the above copyright notice appears in all copies and
- that both the copyright notice and this permission notice appear in
- supporting documentation.
-
- APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
- INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
- FOR A PARTICULAR PURPOSE.
-
- IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
- CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
- LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
- NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
- WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+ All Rights Reserved
+
+ Permission to use, copy, modify, and distribute this software and
+ its documentation for any purpose and without fee is hereby granted,
+ provided that the above copyright notice appears in all copies and
+ that both the copyright notice and this permission notice appear in
+ supporting documentation.
+
+ APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
+ INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+ FOR A PARTICULAR PURPOSE.
+
+ IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
+ CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
+ LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
+ NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
+ WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
Contact Info: Go to <http://www.mklinux.apple.com> to find out about MkLinux.
diff --git a/sbin/pdisk/SCSI_media.c b/sbin/pdisk/SCSI_media.c
index fb7bb587ecc..cbf7b54797d 100644
--- a/sbin/pdisk/SCSI_media.c
+++ b/sbin/pdisk/SCSI_media.c
@@ -6,23 +6,23 @@
/*
* Copyright 1997,1998 by Apple Computer, Inc.
- * All Rights Reserved
- *
- * Permission to use, copy, modify, and distribute this software and
- * its documentation for any purpose and without fee is hereby granted,
- * provided that the above copyright notice appears in all copies and
- * that both the copyright notice and this permission notice appear in
- * supporting documentation.
- *
- * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
- * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
- * FOR A PARTICULAR PURPOSE.
- *
- * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
- * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
- * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
- * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
- * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+ * All Rights Reserved
+ *
+ * Permission to use, copy, modify, and distribute this software and
+ * its documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appears in all copies and
+ * that both the copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
+ * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+ * FOR A PARTICULAR PURPOSE.
+ *
+ * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
+ * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
+ * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
+ * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
+ * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
@@ -162,12 +162,12 @@ scsi_init(void)
{
int i;
int old_scsi;
-
+
if (scsi_inited != 0) {
return;
}
scsi_inited = 1;
-
+
scsi_mgr.exists = 1;
scsi_mgr.kind = allocate_media_kind();
@@ -180,10 +180,10 @@ scsi_init(void)
scsi_mgr.bus_count = 1;
old_scsi = 1;
}
-
+
scsi_mgr.bus_list = (struct bus_entry *)
calloc(scsi_mgr.bus_count, sizeof(struct bus_entry));
-
+
if (scsi_mgr.bus_list == 0) {
scsi_mgr.bus_count = 0;
} else {
@@ -200,7 +200,7 @@ scsi_init(void)
sizeof(struct bus_entry), /* size of element */
bus_entry_compare); /* element comparison routine */
}
-
+
init_mklinux_cache();
}
@@ -257,10 +257,10 @@ int
bus_entry_compare(const void* a, const void* b)
{
long result;
-
+
const struct bus_entry *x = (const struct bus_entry *) a;
const struct bus_entry *y = (const struct bus_entry *) b;
-
+
result = x->sort_value - y->sort_value;
if (result == 0) {
result = x->bus - y->bus;
@@ -289,11 +289,11 @@ open_scsi_as_media(long bus, long device)
SCSI_MEDIA a;
UInt32 blockCount;
UInt32 blockSize;
-
+
if (scsi_inited == 0) {
scsi_init();
}
-
+
if (scsi_mgr.exists == 0) {
return 0;
}
@@ -329,7 +329,7 @@ read_scsi_media(MEDIA m, long long offset, unsigned long count, void *address)
long block_size;
unsigned char *buffer;
int i;
-
+
block = (long) offset;
//printf("scsi %d count %d\n", block, count);
a = (SCSI_MEDIA) m;
@@ -374,7 +374,7 @@ write_scsi_media(MEDIA m, long long offset, unsigned long count, void *address)
long block_size;
unsigned char *buffer;
int i;
-
+
a = (SCSI_MEDIA) m;
rtn_value = 0;
if (a == 0) {
@@ -411,7 +411,7 @@ long
close_scsi_media(MEDIA m)
{
SCSI_MEDIA a;
-
+
a = (SCSI_MEDIA) m;
if (a == 0) {
return 0;
@@ -675,7 +675,7 @@ SCSI_FindDevice(long dRefNum)
SCSIDriverPB pb;
OSErr status;
short targetID;
-
+
status = nsvErr;
if (AsyncSCSIPresent()) {
clear_memory((Ptr) &pb, sizeof pb);
@@ -688,7 +688,7 @@ SCSI_FindDevice(long dRefNum)
do {
status = SCSIAction((SCSI_PB *) &pb);
-
+
if (status != noErr) {
break;
} else if (pb.scsiDriver == dRefNum
@@ -728,11 +728,11 @@ MEDIA_ITERATOR
create_scsi_iterator(void)
{
SCSI_MEDIA_ITERATOR a;
-
+
if (scsi_inited == 0) {
scsi_init();
}
-
+
if (scsi_mgr.exists == 0) {
return 0;
}
@@ -757,7 +757,7 @@ void
reset_scsi_iterator(MEDIA_ITERATOR m)
{
SCSI_MEDIA_ITERATOR a;
-
+
a = (SCSI_MEDIA_ITERATOR) m;
if (a == 0) {
/* no media */
@@ -774,7 +774,7 @@ step_scsi_iterator(MEDIA_ITERATOR m)
{
SCSI_MEDIA_ITERATOR a;
char *result;
-
+
a = (SCSI_MEDIA_ITERATOR) m;
if (a == 0) {
/* no media */
@@ -852,13 +852,13 @@ open_mklinux_scsi_as_media(long index, int is_cdrom)
MEDIA m;
long bus;
long id;
-
+
if (lookup_scsi_index(index, is_cdrom, &bus, &id) > 0) {
m = open_scsi_as_media(bus, id);
} else {
m = 0;
}
-
+
return m;
}
@@ -930,7 +930,7 @@ void
probe_scsi_device(long bus, long id, int unsure)
{
UInt32 devType;
-
+
if (DoInquiry(id, bus, &devType)) {
if (devType == kScsiDevTypeDirect || devType == kScsiDevTypeWorm
|| devType == kScsiDevTypeOptical) {
@@ -954,7 +954,7 @@ lookup_scsi_device(long bus, long id, int *is_cdrom, int *unsure)
struct cache_item *next;
long result = -1;
int count = 0;
-
+
if (scsi_inited == 0) {
scsi_init();
}
@@ -991,7 +991,7 @@ lookup_scsi_index(long index, int is_cdrom, long *bus, long *id)
struct cache_item *next;
long result = 0;
int count = 0;
-
+
if (scsi_inited == 0) {
scsi_init();
}
@@ -1022,7 +1022,7 @@ void
add_to_cache(long bus, long id, int is_cdrom, int unsure)
{
struct cache_item *item;
-
+
item = malloc(sizeof(struct cache_item));
if (item == NULL) {
return;
@@ -1063,7 +1063,7 @@ clear_mklinux_cache(void)
{
struct cache_item *item;
struct cache_item *next;
-
+
for (item = mklinux_order.first; item != NULL; item = next) {
next = item->next;
free(item);
diff --git a/sbin/pdisk/SCSI_media.h b/sbin/pdisk/SCSI_media.h
index 481c0ff289a..e7b17776c3e 100644
--- a/sbin/pdisk/SCSI_media.h
+++ b/sbin/pdisk/SCSI_media.h
@@ -6,23 +6,23 @@
/*
* Copyright 1997,1998 by Apple Computer, Inc.
- * All Rights Reserved
- *
- * Permission to use, copy, modify, and distribute this software and
- * its documentation for any purpose and without fee is hereby granted,
- * provided that the above copyright notice appears in all copies and
- * that both the copyright notice and this permission notice appear in
- * supporting documentation.
- *
- * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
- * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
- * FOR A PARTICULAR PURPOSE.
- *
- * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
- * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
- * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
- * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
- * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+ * All Rights Reserved
+ *
+ * Permission to use, copy, modify, and distribute this software and
+ * its documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appears in all copies and
+ * that both the copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
+ * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+ * FOR A PARTICULAR PURPOSE.
+ *
+ * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
+ * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
+ * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
+ * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
+ * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
#ifndef __SCSI_media__
diff --git a/sbin/pdisk/bitfield.c b/sbin/pdisk/bitfield.c
index 795cffcae45..fbb23716505 100644
--- a/sbin/pdisk/bitfield.c
+++ b/sbin/pdisk/bitfield.c
@@ -8,23 +8,23 @@
/*
* Copyright 1996, 1997 by Apple Computer, Inc.
- * All Rights Reserved
- *
- * Permission to use, copy, modify, and distribute this software and
- * its documentation for any purpose and without fee is hereby granted,
- * provided that the above copyright notice appears in all copies and
- * that both the copyright notice and this permission notice appear in
- * supporting documentation.
- *
- * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
- * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
- * FOR A PARTICULAR PURPOSE.
- *
- * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
- * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
- * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
- * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
- * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+ * All Rights Reserved
+ *
+ * Permission to use, copy, modify, and distribute this software and
+ * its documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appears in all copies and
+ * that both the copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
+ * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+ * FOR A PARTICULAR PURPOSE.
+ *
+ * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
+ * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
+ * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
+ * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
+ * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
#include "bitfield.h"
diff --git a/sbin/pdisk/bitfield.h b/sbin/pdisk/bitfield.h
index 4114ec28f46..57e7f5c810e 100644
--- a/sbin/pdisk/bitfield.h
+++ b/sbin/pdisk/bitfield.h
@@ -20,23 +20,23 @@
/*
* Copyright 1996,1998 by Apple Computer, Inc.
- * All Rights Reserved
- *
- * Permission to use, copy, modify, and distribute this software and
- * its documentation for any purpose and without fee is hereby granted,
- * provided that the above copyright notice appears in all copies and
- * that both the copyright notice and this permission notice appear in
- * supporting documentation.
- *
- * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
- * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
- * FOR A PARTICULAR PURPOSE.
- *
- * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
- * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
- * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
- * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
- * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+ * All Rights Reserved
+ *
+ * Permission to use, copy, modify, and distribute this software and
+ * its documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appears in all copies and
+ * that both the copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
+ * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+ * FOR A PARTICULAR PURPOSE.
+ *
+ * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
+ * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
+ * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
+ * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
+ * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
#ifndef __bitfield__
diff --git a/sbin/pdisk/convert.c b/sbin/pdisk/convert.c
index e7f8016bc1a..023cefbffcb 100644
--- a/sbin/pdisk/convert.c
+++ b/sbin/pdisk/convert.c
@@ -8,23 +8,23 @@
/*
* Copyright 1996,1997,1998 by Apple Computer, Inc.
- * All Rights Reserved
- *
- * Permission to use, copy, modify, and distribute this software and
- * its documentation for any purpose and without fee is hereby granted,
- * provided that the above copyright notice appears in all copies and
- * that both the copyright notice and this permission notice appear in
- * supporting documentation.
- *
- * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
- * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
- * FOR A PARTICULAR PURPOSE.
- *
- * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
- * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
- * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
- * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
- * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+ * All Rights Reserved
+ *
+ * Permission to use, copy, modify, and distribute this software and
+ * its documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appears in all copies and
+ * that both the copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
+ * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+ * FOR A PARTICULAR PURPOSE.
+ *
+ * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
+ * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
+ * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
+ * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
+ * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
#ifdef __linux__
diff --git a/sbin/pdisk/convert.h b/sbin/pdisk/convert.h
index c905c6f5bf9..69da1878c48 100644
--- a/sbin/pdisk/convert.h
+++ b/sbin/pdisk/convert.h
@@ -10,23 +10,23 @@
/*
* Copyright 1996,1998 by Apple Computer, Inc.
- * All Rights Reserved
- *
- * Permission to use, copy, modify, and distribute this software and
- * its documentation for any purpose and without fee is hereby granted,
- * provided that the above copyright notice appears in all copies and
- * that both the copyright notice and this permission notice appear in
- * supporting documentation.
- *
- * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
- * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
- * FOR A PARTICULAR PURPOSE.
- *
- * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
- * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
- * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
- * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
- * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+ * All Rights Reserved
+ *
+ * Permission to use, copy, modify, and distribute this software and
+ * its documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appears in all copies and
+ * that both the copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
+ * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+ * FOR A PARTICULAR PURPOSE.
+ *
+ * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
+ * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
+ * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
+ * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
+ * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
#ifndef __convert__
diff --git a/sbin/pdisk/deblock_media.c b/sbin/pdisk/deblock_media.c
index cb752d70554..75531cd25d9 100644
--- a/sbin/pdisk/deblock_media.c
+++ b/sbin/pdisk/deblock_media.c
@@ -6,23 +6,23 @@
/*
* Copyright 1997,1998 by Apple Computer, Inc.
- * All Rights Reserved
- *
- * Permission to use, copy, modify, and distribute this software and
- * its documentation for any purpose and without fee is hereby granted,
- * provided that the above copyright notice appears in all copies and
- * that both the copyright notice and this permission notice appear in
- * supporting documentation.
- *
- * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
- * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
- * FOR A PARTICULAR PURPOSE.
- *
- * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
- * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
- * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
- * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
- * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+ * All Rights Reserved
+ *
+ * Permission to use, copy, modify, and distribute this software and
+ * its documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appears in all copies and
+ * that both the copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
+ * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+ * FOR A PARTICULAR PURPOSE.
+ *
+ * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
+ * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
+ * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
+ * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
+ * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
@@ -90,7 +90,7 @@ deblock_init(void)
return;
}
deblock_inited = 1;
-
+
deblock_info.kind = allocate_media_kind();
}
@@ -107,11 +107,11 @@ open_deblock_media(long new_block_size, MEDIA m)
{
DEBLOCK_MEDIA a;
unsigned long block_size;
-
+
if (deblock_inited == 0) {
deblock_init();
}
-
+
a = 0;
if (m != 0) {
block_size = media_granularity(m);
@@ -237,7 +237,7 @@ write_deblock_media(MEDIA m, long long offset, unsigned long count, void *addres
long long cur_offset;
unsigned long remainder;
unsigned char *addr;
-
+
a = (DEBLOCK_MEDIA) m;
rtn_value = 0;
if (a == 0) {
@@ -301,7 +301,7 @@ long
close_deblock_media(MEDIA m)
{
DEBLOCK_MEDIA a;
-
+
a = (DEBLOCK_MEDIA) m;
if (a == 0) {
return 0;
@@ -309,7 +309,7 @@ close_deblock_media(MEDIA m)
/* XXX need to error here - this is an internal problem */
return 0;
}
-
+
close_media(a->next_media);
free(a->buffer);
return 1;
@@ -320,7 +320,7 @@ long
os_reload_deblock_media(MEDIA m)
{
DEBLOCK_MEDIA a;
-
+
a = (DEBLOCK_MEDIA) m;
if (a == 0) {
return 0;
@@ -328,7 +328,7 @@ os_reload_deblock_media(MEDIA m)
/* XXX need to error here - this is an internal problem */
return 0;
}
-
+
os_reload_media(a->next_media);
return 1;
}
diff --git a/sbin/pdisk/deblock_media.h b/sbin/pdisk/deblock_media.h
index 04c5dfeba33..ffd27b44aac 100644
--- a/sbin/pdisk/deblock_media.h
+++ b/sbin/pdisk/deblock_media.h
@@ -6,23 +6,23 @@
/*
* Copyright 1997,1998 by Apple Computer, Inc.
- * All Rights Reserved
- *
- * Permission to use, copy, modify, and distribute this software and
- * its documentation for any purpose and without fee is hereby granted,
- * provided that the above copyright notice appears in all copies and
- * that both the copyright notice and this permission notice appear in
- * supporting documentation.
- *
- * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
- * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
- * FOR A PARTICULAR PURPOSE.
- *
- * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
- * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
- * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
- * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
- * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+ * All Rights Reserved
+ *
+ * Permission to use, copy, modify, and distribute this software and
+ * its documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appears in all copies and
+ * that both the copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
+ * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+ * FOR A PARTICULAR PURPOSE.
+ *
+ * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
+ * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
+ * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
+ * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
+ * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
#ifndef __deblock_media__
diff --git a/sbin/pdisk/dpme.h b/sbin/pdisk/dpme.h
index e3d7084dfe5..b50fa87ea7c 100644
--- a/sbin/pdisk/dpme.h
+++ b/sbin/pdisk/dpme.h
@@ -19,23 +19,23 @@
/*
* Copyright 1996 by Apple Computer, Inc.
- * All Rights Reserved
- *
- * Permission to use, copy, modify, and distribute this software and
- * its documentation for any purpose and without fee is hereby granted,
- * provided that the above copyright notice appears in all copies and
- * that both the copyright notice and this permission notice appear in
- * supporting documentation.
- *
- * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
- * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
- * FOR A PARTICULAR PURPOSE.
- *
- * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
- * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
- * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
- * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
- * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+ * All Rights Reserved
+ *
+ * Permission to use, copy, modify, and distribute this software and
+ * its documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appears in all copies and
+ * that both the copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
+ * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+ * FOR A PARTICULAR PURPOSE.
+ *
+ * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
+ * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
+ * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
+ * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
+ * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
#ifndef __dpme__
#define __dpme__
diff --git a/sbin/pdisk/dump.c b/sbin/pdisk/dump.c
index 7c326c824c0..01d47fcdb2d 100644
--- a/sbin/pdisk/dump.c
+++ b/sbin/pdisk/dump.c
@@ -6,23 +6,23 @@
/*
* Copyright 1996,1997,1998 by Apple Computer, Inc.
- * All Rights Reserved
- *
- * Permission to use, copy, modify, and distribute this software and
- * its documentation for any purpose and without fee is hereby granted,
- * provided that the above copyright notice appears in all copies and
- * that both the copyright notice and this permission notice appear in
- * supporting documentation.
- *
- * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
- * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
- * FOR A PARTICULAR PURPOSE.
- *
- * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
- * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
- * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
- * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
- * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+ * All Rights Reserved
+ *
+ * Permission to use, copy, modify, and distribute this software and
+ * its documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appears in all copies and
+ * that both the copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
+ * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+ * FOR A PARTICULAR PURPOSE.
+ *
+ * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
+ * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
+ * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
+ * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
+ * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
// for *printf()
@@ -124,7 +124,7 @@ dump(char *name)
dump_partition_map(map, 1);
close_partition_map(map);
-
+
return 1;
}
@@ -154,7 +154,7 @@ dump_block_zero(partition_map_header *map)
printf("Drivers-\n");
m = (DDMap *) p->sbMap;
for (i = 0; i < p->sbDrvrCount; i++) {
- printf("%u: @ %lu for %u, type=0x%x\n", i+1,
+ printf("%u: @ %lu for %u, type=0x%x\n", i+1,
get_align_long(&m[i].ddBlock),
m[i].ddSize, m[i].ddType);
}
@@ -272,7 +272,7 @@ dump_partition_entry(partition_map *entry, int type_length, int name_length, int
} else {
printf("@~%-*lu", digits, p->dpme_pblock_start + p->dpme_lblock_start);
}
-
+
bytes = ((double)size) * map->logical_block;
adjust_value_and_compute_prefix(&bytes, &j);
if (j != ' ' && j != 'K') {
@@ -346,7 +346,7 @@ list_all_disks()
error(errno, "can't allocate memory for try buffer");
return;
}
-
+
for (iter = first_media_kind(&mark); iter != 0; iter = next_media_kind(&mark)) {
while ((name = step_media_iterator(iter)) != 0) {
@@ -415,7 +415,7 @@ show_data_structures(partition_map_header *map)
(zp->sbDrvrCount>1)?"s":kStringEmpty);
m = (DDMap *) zp->sbMap;
for (i = 0; i < zp->sbDrvrCount; i++) {
- printf("%u: @ %lu for %u, type=0x%x\n", i+1,
+ printf("%u: @ %lu for %u, type=0x%x\n", i+1,
get_align_long(&m[i].ddBlock),
m[i].ddSize, m[i].ddType);
}
@@ -531,7 +531,7 @@ full_dump_partition_entry(partition_map_header *map, int index)
printf("No such partition\n");
return;
}
-
+
p = cur->data;
printf(" signature: 0x%x\n", p->dpme_signature);
printf(" reserved1: 0x%x\n", p->dpme_reserved_1);
@@ -564,7 +564,7 @@ full_dump_partition_entry(partition_map_header *map, int index)
printf("boot length (in bytes): %10lu\n", p->dpme_boot_bytes);
printf(" load address: 0x%08lx 0x%08lx\n",
(u32)p->dpme_load_addr, (u32)p->dpme_load_addr_2);
- printf(" start address: 0x%08lx 0x%08lx\n",
+ printf(" start address: 0x%08lx 0x%08lx\n",
(u32)p->dpme_goto_addr, (u32)p->dpme_goto_addr_2);
printf(" checksum: 0x%08lx\n", p->dpme_checksum);
printf(" processor: '%.32s'\n", p->dpme_process_id);
@@ -663,7 +663,7 @@ display_patches(partition_map *entry)
long long offset;
MEDIA m;
static unsigned char *patch_block;
-
+
offset = entry->data->dpme_pblock_start;
m = entry->the_map->m;
offset = ((long long) entry->data->dpme_pblock_start) * entry->the_map->logical_block;
diff --git a/sbin/pdisk/dump.h b/sbin/pdisk/dump.h
index f6dcd0ab600..3f84bcc0313 100644
--- a/sbin/pdisk/dump.h
+++ b/sbin/pdisk/dump.h
@@ -6,23 +6,23 @@
/*
* Copyright 1996,1997 by Apple Computer, Inc.
- * All Rights Reserved
- *
- * Permission to use, copy, modify, and distribute this software and
- * its documentation for any purpose and without fee is hereby granted,
- * provided that the above copyright notice appears in all copies and
- * that both the copyright notice and this permission notice appear in
- * supporting documentation.
- *
- * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
- * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
- * FOR A PARTICULAR PURPOSE.
- *
- * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
- * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
- * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
- * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
- * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+ * All Rights Reserved
+ *
+ * Permission to use, copy, modify, and distribute this software and
+ * its documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appears in all copies and
+ * that both the copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
+ * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+ * FOR A PARTICULAR PURPOSE.
+ *
+ * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
+ * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
+ * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
+ * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
+ * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
#ifndef __dump__
diff --git a/sbin/pdisk/errors.c b/sbin/pdisk/errors.c
index 4396fc2114d..9c19bee955a 100644
--- a/sbin/pdisk/errors.c
+++ b/sbin/pdisk/errors.c
@@ -6,23 +6,23 @@
/*
* Copyright 1996,1997,1998 by Apple Computer, Inc.
- * All Rights Reserved
- *
- * Permission to use, copy, modify, and distribute this software and
- * its documentation for any purpose and without fee is hereby granted,
- * provided that the above copyright notice appears in all copies and
- * that both the copyright notice and this permission notice appear in
- * supporting documentation.
- *
- * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
- * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
- * FOR A PARTICULAR PURPOSE.
- *
- * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
- * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
- * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
- * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
- * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+ * All Rights Reserved
+ *
+ * Permission to use, copy, modify, and distribute this software and
+ * its documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appears in all copies and
+ * that both the copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
+ * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+ * FOR A PARTICULAR PURPOSE.
+ *
+ * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
+ * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
+ * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
+ * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
+ * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
// for *printf()
diff --git a/sbin/pdisk/errors.h b/sbin/pdisk/errors.h
index bd2861d3006..c90319bef94 100644
--- a/sbin/pdisk/errors.h
+++ b/sbin/pdisk/errors.h
@@ -6,23 +6,23 @@
/*
* Copyright 1996 by Apple Computer, Inc.
- * All Rights Reserved
- *
- * Permission to use, copy, modify, and distribute this software and
- * its documentation for any purpose and without fee is hereby granted,
- * provided that the above copyright notice appears in all copies and
- * that both the copyright notice and this permission notice appear in
- * supporting documentation.
- *
- * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
- * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
- * FOR A PARTICULAR PURPOSE.
- *
- * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
- * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
- * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
- * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
- * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+ * All Rights Reserved
+ *
+ * Permission to use, copy, modify, and distribute this software and
+ * its documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appears in all copies and
+ * that both the copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
+ * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+ * FOR A PARTICULAR PURPOSE.
+ *
+ * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
+ * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
+ * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
+ * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
+ * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
#ifndef __errors__
diff --git a/sbin/pdisk/file_media.c b/sbin/pdisk/file_media.c
index 9e518958f3f..d5dd989b52e 100644
--- a/sbin/pdisk/file_media.c
+++ b/sbin/pdisk/file_media.c
@@ -6,23 +6,23 @@
/*
* Copyright 1997,1998 by Apple Computer, Inc.
- * All Rights Reserved
- *
- * Permission to use, copy, modify, and distribute this software and
- * its documentation for any purpose and without fee is hereby granted,
- * provided that the above copyright notice appears in all copies and
- * that both the copyright notice and this permission notice appear in
- * supporting documentation.
- *
- * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
- * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
- * FOR A PARTICULAR PURPOSE.
- *
- * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
- * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
- * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
- * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
- * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+ * All Rights Reserved
+ *
+ * Permission to use, copy, modify, and distribute this software and
+ * its documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appears in all copies and
+ * that both the copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
+ * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+ * FOR A PARTICULAR PURPOSE.
+ *
+ * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
+ * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
+ * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
+ * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
+ * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
// for printf()
@@ -139,7 +139,7 @@ file_init(void)
return;
}
file_inited = 1;
-
+
file_info.kind = allocate_media_kind();
}
@@ -160,7 +160,7 @@ compute_block_size(int fd)
long t;
int i;
char *buffer;
-
+
max_size = 0;
for (i = 0; ; i++) {
size = potential_block_sizes[i];
@@ -171,7 +171,7 @@ compute_block_size(int fd)
max_size = size;
}
}
-
+
buffer = malloc(max_size);
if (buffer != 0) {
for (i = 0; ; i++) {
@@ -206,7 +206,7 @@ open_file_as_media(char *file, int oflag)
if (file_inited == 0) {
file_init();
}
-
+
a = 0;
fd = open(file, oflag);
if (fd >= 0) {
@@ -328,7 +328,7 @@ long
close_file_media(MEDIA m)
{
FILE_MEDIA a;
-
+
a = (FILE_MEDIA) m;
if (a == 0) {
return 0;
@@ -336,7 +336,7 @@ close_file_media(MEDIA m)
/* XXX need to error here - this is an internal problem */
return 0;
}
-
+
close(a->fd);
return 1;
}
@@ -408,11 +408,11 @@ MEDIA_ITERATOR
create_file_iterator(void)
{
FILE_MEDIA_ITERATOR a;
-
+
if (file_inited == 0) {
file_init();
}
-
+
a = new_file_iterator();
if (a != 0) {
a->m.kind = file_info.kind;
@@ -432,7 +432,7 @@ void
reset_file_iterator(MEDIA_ITERATOR m)
{
FILE_MEDIA_ITERATOR a;
-
+
a = (FILE_MEDIA_ITERATOR) m;
if (a == 0) {
/* no media */
@@ -450,7 +450,7 @@ step_file_iterator(MEDIA_ITERATOR m)
FILE_MEDIA_ITERATOR a;
char *result;
struct stat info;
-
+
a = (FILE_MEDIA_ITERATOR) m;
if (a == 0) {
/* no media */
diff --git a/sbin/pdisk/file_media.h b/sbin/pdisk/file_media.h
index 27e477b2504..1360b93e994 100644
--- a/sbin/pdisk/file_media.h
+++ b/sbin/pdisk/file_media.h
@@ -6,23 +6,23 @@
/*
* Copyright 1997,1998 by Apple Computer, Inc.
- * All Rights Reserved
- *
- * Permission to use, copy, modify, and distribute this software and
- * its documentation for any purpose and without fee is hereby granted,
- * provided that the above copyright notice appears in all copies and
- * that both the copyright notice and this permission notice appear in
- * supporting documentation.
- *
- * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
- * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
- * FOR A PARTICULAR PURPOSE.
- *
- * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
- * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
- * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
- * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
- * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+ * All Rights Reserved
+ *
+ * Permission to use, copy, modify, and distribute this software and
+ * its documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appears in all copies and
+ * that both the copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
+ * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+ * FOR A PARTICULAR PURPOSE.
+ *
+ * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
+ * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
+ * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
+ * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
+ * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
#ifndef __file_media__
diff --git a/sbin/pdisk/io.c b/sbin/pdisk/io.c
index bec60465782..84584e3f710 100644
--- a/sbin/pdisk/io.c
+++ b/sbin/pdisk/io.c
@@ -6,23 +6,23 @@
/*
* Copyright 1996,1997,1998 by Apple Computer, Inc.
- * All Rights Reserved
- *
- * Permission to use, copy, modify, and distribute this software and
- * its documentation for any purpose and without fee is hereby granted,
- * provided that the above copyright notice appears in all copies and
- * that both the copyright notice and this permission notice appear in
- * supporting documentation.
- *
- * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
- * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
- * FOR A PARTICULAR PURPOSE.
- *
- * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
- * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
- * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
- * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
- * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+ * All Rights Reserved
+ *
+ * Permission to use, copy, modify, and distribute this software and
+ * its documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appears in all copies and
+ * that both the copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
+ * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+ * FOR A PARTICULAR PURPOSE.
+ *
+ * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
+ * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
+ * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
+ * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
+ * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
// for *printf()
diff --git a/sbin/pdisk/io.h b/sbin/pdisk/io.h
index dd5a2525187..197ca7ab884 100644
--- a/sbin/pdisk/io.h
+++ b/sbin/pdisk/io.h
@@ -6,23 +6,23 @@
/*
* Copyright 1996,1997,1998 by Apple Computer, Inc.
- * All Rights Reserved
- *
- * Permission to use, copy, modify, and distribute this software and
- * its documentation for any purpose and without fee is hereby granted,
- * provided that the above copyright notice appears in all copies and
- * that both the copyright notice and this permission notice appear in
- * supporting documentation.
- *
- * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
- * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
- * FOR A PARTICULAR PURPOSE.
- *
- * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
- * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
- * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
- * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
- * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+ * All Rights Reserved
+ *
+ * Permission to use, copy, modify, and distribute this software and
+ * its documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appears in all copies and
+ * that both the copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
+ * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+ * FOR A PARTICULAR PURPOSE.
+ *
+ * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
+ * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
+ * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
+ * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
+ * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
#ifndef __io__
diff --git a/sbin/pdisk/layout_dump.c b/sbin/pdisk/layout_dump.c
index 5f5140ef56b..c76ab2a398f 100644
--- a/sbin/pdisk/layout_dump.c
+++ b/sbin/pdisk/layout_dump.c
@@ -6,23 +6,23 @@
/*
* Copyright 1996,1997 by Apple Computer, Inc.
- * All Rights Reserved
- *
- * Permission to use, copy, modify, and distribute this software and
- * its documentation for any purpose and without fee is hereby granted,
- * provided that the above copyright notice appears in all copies and
- * that both the copyright notice and this permission notice appear in
- * supporting documentation.
- *
- * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
- * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
- * FOR A PARTICULAR PURPOSE.
- *
- * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
- * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
- * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
- * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
- * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+ * All Rights Reserved
+ *
+ * Permission to use, copy, modify, and distribute this software and
+ * its documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appears in all copies and
+ * that both the copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
+ * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+ * FOR A PARTICULAR PURPOSE.
+ *
+ * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
+ * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
+ * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
+ * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
+ * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
// for printf()
@@ -72,7 +72,7 @@ dump_using_layout(void *buffer, layout *desc)
long value;
int max_name;
int i;
-
+
max_name = 0;
for (entry = desc; entry->format != kEnd; entry++) {
value = strlen(entry->name);
@@ -80,20 +80,20 @@ dump_using_layout(void *buffer, layout *desc)
max_name = value;
}
}
-
-
+
+
for (entry = desc; entry->format != kEnd; entry++) {
if (entry->format != kBit) {
printf("%*s: ", max_name, entry->name);
byte_length = entry->bit_length / 8;
-
+
if (entry->bit_offset != 0 || (entry->bit_length % 8) != 0) {
printf("entry %d, can't handle bitfields yet.\n", entry - desc);
continue;
}
-
+
value = 0;
for (i = entry->byte_offset; byte_length > 0;i++) {
value = value << 8;
@@ -104,7 +104,7 @@ dump_using_layout(void *buffer, layout *desc)
if (entry->bit_offset < 0 || entry->bit_offset > 8) {
printf("entry %d, bad bit offset (%d).\n", entry - desc, entry->bit_offset);
continue;
- } else if (entry->bit_length <= 0
+ } else if (entry->bit_length <= 0
|| entry->bit_length > (entry->bit_offset + 1)) {
printf("entry %d, bad bit length (%d,%d).\n", entry - desc,
entry->bit_offset, entry->bit_length);
diff --git a/sbin/pdisk/layout_dump.h b/sbin/pdisk/layout_dump.h
index a7c352ff086..67a01472810 100644
--- a/sbin/pdisk/layout_dump.h
+++ b/sbin/pdisk/layout_dump.h
@@ -6,23 +6,23 @@
/*
* Copyright 1997,1998 by Apple Computer, Inc.
- * All Rights Reserved
- *
- * Permission to use, copy, modify, and distribute this software and
- * its documentation for any purpose and without fee is hereby granted,
- * provided that the above copyright notice appears in all copies and
- * that both the copyright notice and this permission notice appear in
- * supporting documentation.
- *
- * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
- * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
- * FOR A PARTICULAR PURPOSE.
- *
- * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
- * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
- * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
- * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
- * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+ * All Rights Reserved
+ *
+ * Permission to use, copy, modify, and distribute this software and
+ * its documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appears in all copies and
+ * that both the copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
+ * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+ * FOR A PARTICULAR PURPOSE.
+ *
+ * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
+ * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
+ * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
+ * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
+ * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
#ifndef __layout_dump__
diff --git a/sbin/pdisk/media.c b/sbin/pdisk/media.c
index 85fa899ce6c..a9330cb3a4b 100644
--- a/sbin/pdisk/media.c
+++ b/sbin/pdisk/media.c
@@ -6,23 +6,23 @@
/*
* Copyright 1997,1998 by Apple Computer, Inc.
- * All Rights Reserved
- *
- * Permission to use, copy, modify, and distribute this software and
- * its documentation for any purpose and without fee is hereby granted,
- * provided that the above copyright notice appears in all copies and
- * that both the copyright notice and this permission notice appear in
- * supporting documentation.
- *
- * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
- * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
- * FOR A PARTICULAR PURPOSE.
- *
- * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
- * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
- * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
- * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
- * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+ * All Rights Reserved
+ *
+ * Permission to use, copy, modify, and distribute this software and
+ * its documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appears in all copies and
+ * that both the copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
+ * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+ * FOR A PARTICULAR PURPOSE.
+ *
+ * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
+ * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
+ * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
+ * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
+ * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
@@ -113,7 +113,7 @@ long
read_media(MEDIA m, long long offset, unsigned long count, void *address)
{
long result;
-
+
if (m != 0 && m->do_read != 0) {
//printf("media: read type %d, offset %Ld, count %d\n\t", m->kind, offset, count);
result = (*m->do_read)(m, offset, count, address);
@@ -129,7 +129,7 @@ long
write_media(MEDIA m, long long offset, unsigned long count, void *address)
{
long result;
-
+
if (m != 0 && m->do_write != 0) {
//printf("media: write type %d, offset %Ld, count %d\n\t", m->kind, offset, count);
result = (*m->do_write)(m, offset, count, address);
@@ -200,7 +200,7 @@ char *
step_media_iterator(MEDIA_ITERATOR m)
{
char *result;
-
+
if (m != 0 && m->do_step != 0) {
result = (*m->do_step)(m);
} else {
diff --git a/sbin/pdisk/media.h b/sbin/pdisk/media.h
index f631e157a52..1b4209073be 100644
--- a/sbin/pdisk/media.h
+++ b/sbin/pdisk/media.h
@@ -6,23 +6,23 @@
/*
* Copyright 1997,1998 by Apple Computer, Inc.
- * All Rights Reserved
- *
- * Permission to use, copy, modify, and distribute this software and
- * its documentation for any purpose and without fee is hereby granted,
- * provided that the above copyright notice appears in all copies and
- * that both the copyright notice and this permission notice appear in
- * supporting documentation.
- *
- * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
- * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
- * FOR A PARTICULAR PURPOSE.
- *
- * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
- * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
- * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
- * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
- * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+ * All Rights Reserved
+ *
+ * Permission to use, copy, modify, and distribute this software and
+ * its documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appears in all copies and
+ * that both the copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
+ * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+ * FOR A PARTICULAR PURPOSE.
+ *
+ * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
+ * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
+ * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
+ * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
+ * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
#ifndef __media__
@@ -35,7 +35,7 @@
* A media object has the following visible attributes:
*
* a granularity (e.g. 512, 1024, 1, etc.)
- * a total size in bytes
+ * a total size in bytes
*
* And the following operations are available:
*
diff --git a/sbin/pdisk/partition_map.c b/sbin/pdisk/partition_map.c
index 48738221b84..f109d899ebc 100644
--- a/sbin/pdisk/partition_map.c
+++ b/sbin/pdisk/partition_map.c
@@ -6,23 +6,23 @@
/*
* Copyright 1996,1997,1998 by Apple Computer, Inc.
- * All Rights Reserved
- *
- * Permission to use, copy, modify, and distribute this software and
- * its documentation for any purpose and without fee is hereby granted,
- * provided that the above copyright notice appears in all copies and
- * that both the copyright notice and this permission notice appear in
- * supporting documentation.
- *
- * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
- * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
- * FOR A PARTICULAR PURPOSE.
- *
- * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
- * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
- * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
- * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
- * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+ * All Rights Reserved
+ *
+ * Permission to use, copy, modify, and distribute this software and
+ * its documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appears in all copies and
+ * that both the copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
+ * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+ * FOR A PARTICULAR PURPOSE.
+ *
+ * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
+ * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
+ * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
+ * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
+ * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
// for *printf()
@@ -501,7 +501,7 @@ create_partition_map(char *name, partition_map_header *oldmap)
default_number = number;
flush_to_newline(0);
do {
- if (get_number_argument("what should be the size? ",
+ if (get_number_argument("what should be the size? ",
(long *)&number, default_number) == 0) {
printf("Not a number\n");
flush_to_newline(1);
@@ -613,7 +613,7 @@ add_partition_to_map(const char *name, const char *dptype, u32 base, u32 length,
// find a block that starts includes base and length
cur = map->base_order;
while (cur != NULL) {
- if (cur->data->dpme_pblock_start <= base
+ if (cur->data->dpme_pblock_start <= base
&& (base + length) <=
(cur->data->dpme_pblock_start + cur->data->dpme_pblocks)) {
break;
@@ -769,7 +769,7 @@ compute_device_size(partition_map_header *map, partition_map_header *oldmap)
if (fstat(fd, &info) < 0) {
printf("stat of device failed\n");
} else {
- printf("stat: mode = 0%o, type=%s\n", info.st_mode,
+ printf("stat: mode = 0%o, type=%s\n", info.st_mode,
(S_ISREG(info.st_mode)? "Regular":
(S_ISBLK(info.st_mode)?"Block":"Other")));
printf("size = %d, blocks = %d\n",
@@ -809,9 +809,9 @@ compute_device_size(partition_map_header *map, partition_map_header *oldmap)
if (size != 0) {
return (long)(size / map->logical_block);
}
-
+
// else case
-
+
data = (char *) malloc(PBLOCK_SIZE);
if (data == NULL) {
error(errno, "can't allocate memory for try buffer");
diff --git a/sbin/pdisk/partition_map.h b/sbin/pdisk/partition_map.h
index 5390bfe543e..d53032bcfde 100644
--- a/sbin/pdisk/partition_map.h
+++ b/sbin/pdisk/partition_map.h
@@ -6,23 +6,23 @@
/*
* Copyright 1996,1998 by Apple Computer, Inc.
- * All Rights Reserved
- *
- * Permission to use, copy, modify, and distribute this software and
- * its documentation for any purpose and without fee is hereby granted,
- * provided that the above copyright notice appears in all copies and
- * that both the copyright notice and this permission notice appear in
- * supporting documentation.
- *
- * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
- * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
- * FOR A PARTICULAR PURPOSE.
- *
- * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
- * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
- * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
- * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
- * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+ * All Rights Reserved
+ *
+ * Permission to use, copy, modify, and distribute this software and
+ * its documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appears in all copies and
+ * that both the copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
+ * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+ * FOR A PARTICULAR PURPOSE.
+ *
+ * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
+ * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
+ * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
+ * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
+ * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
#ifndef __partition_map__
diff --git a/sbin/pdisk/pathname.c b/sbin/pdisk/pathname.c
index aba083a00bc..81198433f36 100644
--- a/sbin/pdisk/pathname.c
+++ b/sbin/pdisk/pathname.c
@@ -6,23 +6,23 @@
/*
* Copyright 1997,1998 by Apple Computer, Inc.
- * All Rights Reserved
- *
- * Permission to use, copy, modify, and distribute this software and
- * its documentation for any purpose and without fee is hereby granted,
- * provided that the above copyright notice appears in all copies and
- * that both the copyright notice and this permission notice appear in
- * supporting documentation.
- *
- * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
- * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
- * FOR A PARTICULAR PURPOSE.
- *
- * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
- * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
- * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
- * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
- * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+ * All Rights Reserved
+ *
+ * Permission to use, copy, modify, and distribute this software and
+ * its documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appears in all copies and
+ * that both the copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
+ * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+ * FOR A PARTICULAR PURPOSE.
+ *
+ * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
+ * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
+ * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
+ * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
+ * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
@@ -164,7 +164,7 @@ get_mklinux_name(char *path)
}
}
#endif
-
+
return result;
}
@@ -221,7 +221,7 @@ next_media_kind(long *state)
default:
break;
}
-
+
*state = index;
return result;
}
diff --git a/sbin/pdisk/pathname.h b/sbin/pdisk/pathname.h
index 598287ae873..eddf78a8c06 100644
--- a/sbin/pdisk/pathname.h
+++ b/sbin/pdisk/pathname.h
@@ -6,23 +6,23 @@
/*
* Copyright 1997,1998 by Apple Computer, Inc.
- * All Rights Reserved
- *
- * Permission to use, copy, modify, and distribute this software and
- * its documentation for any purpose and without fee is hereby granted,
- * provided that the above copyright notice appears in all copies and
- * that both the copyright notice and this permission notice appear in
- * supporting documentation.
- *
- * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
- * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
- * FOR A PARTICULAR PURPOSE.
- *
- * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
- * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
- * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
- * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
- * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+ * All Rights Reserved
+ *
+ * Permission to use, copy, modify, and distribute this software and
+ * its documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appears in all copies and
+ * that both the copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
+ * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+ * FOR A PARTICULAR PURPOSE.
+ *
+ * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
+ * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
+ * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
+ * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
+ * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
#ifndef __pathname__
diff --git a/sbin/pdisk/pdisk.c b/sbin/pdisk/pdisk.c
index e8623e22db3..a8e7800ba9d 100644
--- a/sbin/pdisk/pdisk.c
+++ b/sbin/pdisk/pdisk.c
@@ -8,23 +8,23 @@
/*
* Copyright 1996,1997,1998 by Apple Computer, Inc.
- * All Rights Reserved
- *
- * Permission to use, copy, modify, and distribute this software and
- * its documentation for any purpose and without fee is hereby granted,
- * provided that the above copyright notice appears in all copies and
- * that both the copyright notice and this permission notice appear in
- * supporting documentation.
- *
- * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
- * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
- * FOR A PARTICULAR PURPOSE.
- *
- * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
- * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
- * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
- * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
- * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+ * All Rights Reserved
+ *
+ * Permission to use, copy, modify, and distribute this software and
+ * its documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appears in all copies and
+ * that both the copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
+ * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+ * FOR A PARTICULAR PURPOSE.
+ *
+ * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
+ * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
+ * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
+ * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
+ * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
// for printf()
@@ -148,7 +148,7 @@ main(int argc, char **argv)
printf("This app uses the SIOUX console library\n");
printf("Choose 'Quit' from the file menu to quit.\n\n");
printf("Use fake disk names (/dev/scsi<bus>.<id>; i.e. /dev/scsi0.1, /dev/scsi1.3, etc.).\n\n");
-
+
SIOUXSettings.autocloseonquit = 0; /* Do we close the SIOUX window on program termination ... */
SIOUXSettings.asktosaveonclose = 0; /* Do we offer to save on a close ... */
#endif
diff --git a/sbin/pdisk/pdisk.h b/sbin/pdisk/pdisk.h
index 3f32c9c3841..29a745c0ce4 100644
--- a/sbin/pdisk/pdisk.h
+++ b/sbin/pdisk/pdisk.h
@@ -6,23 +6,23 @@
/*
* Copyright 1996,1997 by Apple Computer, Inc.
- * All Rights Reserved
- *
- * Permission to use, copy, modify, and distribute this software and
- * its documentation for any purpose and without fee is hereby granted,
- * provided that the above copyright notice appears in all copies and
- * that both the copyright notice and this permission notice appear in
- * supporting documentation.
- *
- * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
- * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
- * FOR A PARTICULAR PURPOSE.
- *
- * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
- * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
- * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
- * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
- * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+ * All Rights Reserved
+ *
+ * Permission to use, copy, modify, and distribute this software and
+ * its documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appears in all copies and
+ * that both the copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
+ * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+ * FOR A PARTICULAR PURPOSE.
+ *
+ * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
+ * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
+ * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
+ * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
+ * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
#ifndef __pdisk__
diff --git a/sbin/pdisk/pdisk.html b/sbin/pdisk/pdisk.html
index cb757faa8c7..0ea70428793 100644
--- a/sbin/pdisk/pdisk.html
+++ b/sbin/pdisk/pdisk.html
@@ -68,16 +68,16 @@ DriveSetup, etc) are:</P>
<UL>
<LI>unlike the Apple partitioners, it does not restrict the set of
drives it can operate on
-
+
<LI>it allows partitions to be reordered (helpful, as MkLinux
depends on the order)
-
+
<LI>it creates MkLinux partitions by default
-
+
<LI>it allows the size of the partition map to be changed
-
+
<LI>it allows the name of a partition to be changed
-
+
<LI>it allows you to edit the partition map of your boot disk
</UL>
@@ -85,9 +85,9 @@ DriveSetup, etc) are:</P>
<UL>
<LI>it doesn't automatically initialize HFS partitions
-
+
<LI>it can't install disk drivers
-
+
<LI>it allows you to edit the partition map of your boot disk
</UL>
@@ -140,40 +140,40 @@ when the upper case letter does a variant form of the operation.</P>
<DL>
<DT><B>h</B>
-
+
<DD>Prints just the command help. The difference between <B>h</B>
and <B>?</B> is the latter prints some helpful notes as well.
-
+
<DT><B>v</B>
-
+
<DD>Prints a version number and release date. Matches the
version in the GetInfo window for the application.
-
+
<DT><B>l</B>
-
+
<DD>Prompts for the name of the device and then lists the
partition map on that device.
-
+
<DT><B>L</B>
-
+
<DD>Lists all the devices.
-
+
<DT><B>e</B>
-
+
<DD>Prompts for the name of the device and then opens the partition
map for editing.
-
+
<DT><B>E</B>
-
+
<DD>Same as <B>e</B>, except also prompts for block size.
-
+
<DT><B>r</B>
-
+
<DD>Toggles read-only setting. When read-only is on pdisk will not
write a partition map.
-
+
<DT><B>q</B>
-
+
<DD>Quit pdisk.
</DL>
@@ -184,10 +184,10 @@ like.</P>
<PRE>Partition map (with 512 byte blocks) on '/dev/scsi0.2' (/dev/sda)
#: type name length base ( size )
- 1: Apple_partition_map Apple 63 @ 1
- 2: Apple_Driver43*Macintosh 54 @ 64
- 3: Apple_Driver43*Macintosh 74 @ 118
- 4: Apple_Patches Patch Partition 512 @ 192
+ 1: Apple_partition_map Apple 63 @ 1
+ 2: Apple_Driver43*Macintosh 54 @ 64
+ 3: Apple_Driver43*Macintosh 74 @ 118
+ 4: Apple_Patches Patch Partition 512 @ 192
5: Apple_HFS untitled 2117430 @ 704 ( 1.0G)
6: Apple_Free Extra 10 @ 2118134
&nbsp;
@@ -212,18 +212,18 @@ index. For each entry, the following information is displayed:</P>
<LI>index - where the partition entry is in the map. This does not
correspond the relative order of the partition contents and can
change when the partition map is edited.
-
+
<LI>type - the sort of data expected to be in the partition. pdisk
doesn't put data into the contents of any partition except the
partition map partition. The type is a case-insensitive string.
-
+
<LI>name - the name is for the user's information.
-
+
<LI>length - the number of partition blocks the partition takes.
-
+
<LI>base - the first block of the partition, measured in partition
blocks, starting from zero.
-
+
<LI>size - this is the length in bytes. Only shown if the size is
at least one megabyte.
</UL>
@@ -276,96 +276,96 @@ map.</P>
<DL>
<DT><B>h</B>
-
+
<DD>Prints just the command help. The difference between <B>h</B>
and <B>?</B> is the latter prints some helpful notes as well.
-
+
<DT><B>p</B>
-
+
<DD>Prints the partition table. The form is identical to the
listing described above.
-
+
<DT><B>P</B>
-
+
<DD>Identical to <B>p</B>, except the entries are listed in the
order of the partitions on the disk (i.e. by the increasing base
value) rather than in index order.
-
+
<DT><B>i</B>
-
+
<DD>Initializes the partition map (rarely used). This command
prompts for the size of the device. WARNING - if you write the map
after initializing it you will delete all the drivers on the device.
That makes the device invisible to the Mac OS. pdisk is not able
to install drivers.
-
+
<DT><B>s</B>
-
+
<DD>Change the size of the partition map partition. The partition
map's size must be less than or equal to the size of the partition
it is contained in. This is mostly useful when you want to do
tricky things like making a disk with multiple partitioning
schemes on it.
-
+
<DT><B>c</B>
-
+
<DD>Create a new partition takes three arguments.<BR>
-
+
The first argument is the base address (in partition blocks) of
the partition. Besides a raw number, you can also specify a
partition number followed by the letter 'p' to indicate that the
first block of the new partition should be the same as the first
block of that existing free space partition.<BR>
-
+
The second argument is the length of the partition in partition
blocks. This can be a raw number or can be a partition number
followed by the letter 'p' to use the size of that partition or
can be a number followed by 'k', 'm', or 'g' to indicate the size
in kilobytes, megabytes, or gigabytes respectively. (These are
powers of 1024, of course, not powers of 1000.)<BR>
-
+
The last argument is the name of the partition. This can be a
single word without quotes, or a string surrounded by single or
double quotes.<BR>
-
+
The type of the created partition is set to the correct type for
MkLinux ("Apple_UNIX_SVR2").
-
+
<DT><B>C</B>
-
+
<DD>Identical to the <B>c</B> command, with the addition of a
prompt for the partition type after the other arguments. The type
can be a single word without quotes, or a string surrounded by
single or double quotes.
-
+
<DT><B>n</B>
-
+
<DD>Rename a partition. Do not change the name of any partition
whose type starts with "Apple_Driver". The MacOS looks at the
names of those partitions. All other partitions should be okay
to change.
<DT><B>d</B>
-
+
<DD>Delete a partition. When a partition is deleted it's type is
changed to free ("Apple_Free") and then it is combined with any
adjacent free space.
-
+
<DT><B>r</B>
-
+
<DD>Reorder takes the current index and the desired new index. If
you give a new index which is greater than the last index the
entry will be moved to the last index.
-
+
<DT><B>w</B>
-
+
<DD>Write does write the partition map out, but pdisk does not yet
flush the appropriate caches and unmount volumes so the partition
map is not reinterpreted. In order to use the new partition map
you must reboot your machine. Sorry.
-
+
<DT><B>q</B>
-
+
<DD>Quit out of editing. Returns to the top level prompt. If you
have modified the partition map you are NOT asked if you want to
save the changes, instead the changes are quietly thrown away.
@@ -376,12 +376,12 @@ map.</P>
<DL>
<DD>This is an awful Mac OS application, it should be rewritten
to look the way a Mac OS app should look.
-
+
<DD>The code assumes a better understanding of the partitioning
scheme than most people care to acquire.
-
+
<DD>&nbsp;
-
+
<DD>Even more help should be available during user input.
</DL>
diff --git a/sbin/pdisk/pdisk.r b/sbin/pdisk/pdisk.r
index 090a678f11a..3ae7ab9a7ee 100644
--- a/sbin/pdisk/pdisk.r
+++ b/sbin/pdisk/pdisk.r
@@ -4,23 +4,23 @@
/*
* Copyright 1997 by Apple Computer, Inc.
- * All Rights Reserved
- *
- * Permission to use, copy, modify, and distribute this software and
- * its documentation for any purpose and without fee is hereby granted,
- * provided that the above copyright notice appears in all copies and
- * that both the copyright notice and this permission notice appear in
- * supporting documentation.
- *
- * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
- * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
- * FOR A PARTICULAR PURPOSE.
- *
- * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
- * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
- * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
- * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
- * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+ * All Rights Reserved
+ *
+ * Permission to use, copy, modify, and distribute this software and
+ * its documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appears in all copies and
+ * that both the copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
+ * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+ * FOR A PARTICULAR PURPOSE.
+ *
+ * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
+ * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
+ * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
+ * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
+ * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
#ifndef SystemSevenOrLater
diff --git a/sbin/pdisk/util.c b/sbin/pdisk/util.c
index 725c4cc7ba5..c555a510789 100644
--- a/sbin/pdisk/util.c
+++ b/sbin/pdisk/util.c
@@ -6,23 +6,23 @@
/*
* Copyright 1997,1998 by Apple Computer, Inc.
- * All Rights Reserved
- *
- * Permission to use, copy, modify, and distribute this software and
- * its documentation for any purpose and without fee is hereby granted,
- * provided that the above copyright notice appears in all copies and
- * that both the copyright notice and this permission notice appear in
- * supporting documentation.
- *
- * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
- * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
- * FOR A PARTICULAR PURPOSE.
- *
- * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
- * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
- * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
- * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
- * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+ * All Rights Reserved
+ *
+ * Permission to use, copy, modify, and distribute this software and
+ * its documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appears in all copies and
+ * that both the copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
+ * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+ * FOR A PARTICULAR PURPOSE.
+ *
+ * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
+ * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
+ * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
+ * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
+ * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
@@ -134,7 +134,7 @@ get_version_string(void)
int stage;
/* "copy" of stuff from SysTypes.r, since we can't include that*/
enum {development = 0x20, alpha = 0x40, beta = 0x60, final = 0x80, /* or */ release = 0x80};
-
+
switch (kVersionStage) {
case development: stage = 'd'; break;
case alpha: stage = 'a'; break;
@@ -142,7 +142,7 @@ get_version_string(void)
case final: stage = 'f'; break;
default: stage = '?'; break;
}
-
+
if (kVersionBugFix != 0) {
if (kVersionStage == final) {
sprintf(dynamic_version, "%d.%d.%d",
diff --git a/sbin/pdisk/util.h b/sbin/pdisk/util.h
index 77ce624a9c6..0a1ec52afb3 100644
--- a/sbin/pdisk/util.h
+++ b/sbin/pdisk/util.h
@@ -6,23 +6,23 @@
/*
* Copyright 1997,1998 by Apple Computer, Inc.
- * All Rights Reserved
- *
- * Permission to use, copy, modify, and distribute this software and
- * its documentation for any purpose and without fee is hereby granted,
- * provided that the above copyright notice appears in all copies and
- * that both the copyright notice and this permission notice appear in
- * supporting documentation.
- *
- * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
- * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
- * FOR A PARTICULAR PURPOSE.
- *
- * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
- * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
- * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
- * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
- * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+ * All Rights Reserved
+ *
+ * Permission to use, copy, modify, and distribute this software and
+ * its documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appears in all copies and
+ * that both the copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
+ * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+ * FOR A PARTICULAR PURPOSE.
+ *
+ * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
+ * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
+ * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
+ * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
+ * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
#ifndef __util__
diff --git a/sbin/pdisk/validate.c b/sbin/pdisk/validate.c
index 1c331383665..779d3296899 100644
--- a/sbin/pdisk/validate.c
+++ b/sbin/pdisk/validate.c
@@ -1,28 +1,28 @@
//
-// validate.c -
+// validate.c -
//
// Written by Eryk Vershen (eryk@apple.com)
//
/*
* Copyright 1997,1998 by Apple Computer, Inc.
- * All Rights Reserved
- *
- * Permission to use, copy, modify, and distribute this software and
- * its documentation for any purpose and without fee is hereby granted,
- * provided that the above copyright notice appears in all copies and
- * that both the copyright notice and this permission notice appear in
- * supporting documentation.
- *
- * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
- * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
- * FOR A PARTICULAR PURPOSE.
- *
- * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
- * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
- * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
- * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
- * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+ * All Rights Reserved
+ *
+ * Permission to use, copy, modify, and distribute this software and
+ * its documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appears in all copies and
+ * that both the copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
+ * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+ * FOR A PARTICULAR PURPOSE.
+ *
+ * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
+ * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
+ * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
+ * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
+ * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
@@ -108,7 +108,7 @@ int
get_block_zero(void)
{
int rtn_value;
-
+
if (the_map != NULL) {
b0 = the_map->misc;
rtn_value = 1;
@@ -130,7 +130,7 @@ get_block_n(int n)
{
partition_map * entry;
int rtn_value;
-
+
if (the_map != NULL) {
entry = find_entry_by_disk_address(n, the_map);
if (entry != 0) {
@@ -156,7 +156,7 @@ range_list *
new_range_list_item(enum range_state state, int valid, u32 low, u32 high)
{
range_list *item;
-
+
item = (range_list *) malloc(sizeof(struct range_list));
item->next = 0;
item->prev = 0;
@@ -172,7 +172,7 @@ void
initialize_list(range_list **list)
{
range_list *item;
-
+
item = new_range_list_item(kUnallocated, 0, 0, 0xFFFFFFFF);
*list = item;
}
@@ -183,7 +183,7 @@ delete_list(range_list *list)
{
range_list *item;
range_list *cur;
-
+
for (cur = list; cur != 0; ) {
item = cur;
cur = cur->next;
@@ -199,12 +199,12 @@ add_range(range_list **list, u32 base, u32 len, int allocate)
range_list *cur;
u32 low;
u32 high;
-
+
if (list == 0 || *list == 0) {
/* XXX initialized list will always have one element */
return;
}
-
+
low = base;
high = base + len - 1;
if (len == 0 || high < len - 1) {
@@ -301,7 +301,7 @@ print_range_list(range_list *list)
range_list *cur;
int printed;
char *s;
-
+
if (list == 0) {
printf("Empty range list\n");
return;
@@ -355,9 +355,9 @@ validate_map(partition_map_header *map)
int i;
u32 limit;
int printed;
-
+
//printf("Validation not implemented yet.\n");
-
+
if (map == NULL) {
the_map = 0;
if (get_string_argument("Name of device: ", &name, 1) == 0) {
@@ -480,13 +480,13 @@ check_map:
post_processing:
// properties of whole map
-
+
// every block on disk in one & only one partition
coalesce_list(list);
print_range_list(list);
// there is a partition for the map
// map fits within partition that contains it
-
+
// try to detect 512/2048 mixed partition map?
done:
diff --git a/sbin/pdisk/validate.h b/sbin/pdisk/validate.h
index 4ef6e737f7e..550bbc4dfd0 100644
--- a/sbin/pdisk/validate.h
+++ b/sbin/pdisk/validate.h
@@ -1,28 +1,28 @@
//
-// validate.h -
+// validate.h -
//
// Written by Eryk Vershen (eryk@apple.com)
//
/*
* Copyright 1997,1998 by Apple Computer, Inc.
- * All Rights Reserved
- *
- * Permission to use, copy, modify, and distribute this software and
- * its documentation for any purpose and without fee is hereby granted,
- * provided that the above copyright notice appears in all copies and
- * that both the copyright notice and this permission notice appear in
- * supporting documentation.
- *
- * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
- * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
- * FOR A PARTICULAR PURPOSE.
- *
- * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
- * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
- * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
- * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
- * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+ * All Rights Reserved
+ *
+ * Permission to use, copy, modify, and distribute this software and
+ * its documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appears in all copies and
+ * that both the copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
+ * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+ * FOR A PARTICULAR PURPOSE.
+ *
+ * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
+ * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
+ * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
+ * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
+ * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
#ifndef __validate__
diff --git a/sbin/pdisk/version.h b/sbin/pdisk/version.h
index 378fb6dabee..21181c6bb53 100644
--- a/sbin/pdisk/version.h
+++ b/sbin/pdisk/version.h
@@ -6,23 +6,23 @@
/*
* Copyright 1997 by Apple Computer, Inc.
- * All Rights Reserved
- *
- * Permission to use, copy, modify, and distribute this software and
- * its documentation for any purpose and without fee is hereby granted,
- * provided that the above copyright notice appears in all copies and
- * that both the copyright notice and this permission notice appear in
- * supporting documentation.
- *
- * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
- * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
- * FOR A PARTICULAR PURPOSE.
- *
- * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
- * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
- * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
- * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
- * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+ * All Rights Reserved
+ *
+ * Permission to use, copy, modify, and distribute this software and
+ * its documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appears in all copies and
+ * that both the copyright notice and this permission notice appear in
+ * supporting documentation.
+ *
+ * APPLE COMPUTER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
+ * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+ * FOR A PARTICULAR PURPOSE.
+ *
+ * IN NO EVENT SHALL APPLE COMPUTER BE LIABLE FOR ANY SPECIAL, INDIRECT, OR
+ * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
+ * LOSS OF USE, DATA OR PROFITS, WHETHER IN ACTION OF CONTRACT,
+ * NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
+ * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
#ifndef __version__
#define __version__
@@ -35,7 +35,7 @@
* TO ADJUST THE VERSION - change the following six macros.
*
* A version is of the form: N.M{.X}{yZ}
- *
+ *
* N is two digits indicating the major version
* M is a single digit indicating relative revision
* X is a single digit indicating a bug fix revision