summaryrefslogtreecommitdiffstats
path: root/lib/libdisk/write_disk.c
diff options
context:
space:
mode:
authorjkh <jkh@FreeBSD.org>1999-01-08 00:32:19 +0000
committerjkh <jkh@FreeBSD.org>1999-01-08 00:32:19 +0000
commitce49697787054f99e7d79d569abc5518051fd1e5 (patch)
treed9df43706aadb4066758871be13eda424119079f /lib/libdisk/write_disk.c
parent2bd023c3bcc58af13caf3dfc72e45544f76e02d0 (diff)
downloadFreeBSD-src-ce49697787054f99e7d79d569abc5518051fd1e5.zip
FreeBSD-src-ce49697787054f99e7d79d569abc5518051fd1e5.tar.gz
Changes for alpha support.
Submitted by: dfr
Diffstat (limited to 'lib/libdisk/write_disk.c')
-rw-r--r--lib/libdisk/write_disk.c12
1 files changed, 11 insertions, 1 deletions
diff --git a/lib/libdisk/write_disk.c b/lib/libdisk/write_disk.c
index 799e5a1..b27d17b 100644
--- a/lib/libdisk/write_disk.c
+++ b/lib/libdisk/write_disk.c
@@ -6,7 +6,7 @@
* this stuff is worth it, you can buy me a beer in return. Poul-Henning Kamp
* ----------------------------------------------------------------------------
*
- * $Id: write_disk.c,v 1.23 1998/10/06 11:57:08 dfr Exp $
+ * $Id: write_disk.c,v 1.24 1998/10/27 21:14:03 msmith Exp $
*
*/
@@ -110,6 +110,14 @@ Write_FreeBSD(int fd, struct disk *new, struct disk *old, struct chunk *c1)
#ifdef __alpha__
/*
+ * Tell SRM where the bootstrap is.
+ */
+ lp = (u_long *)buf;
+ lp[60] = 15;
+ lp[61] = 1;
+ lp[62] = 0;
+
+ /*
* Generate the bootblock checksum for the SRM console.
*/
for (lp = (u_long *)buf, i = 0, sum = 0; i < 63; i++)
@@ -242,6 +250,7 @@ Write_Disk(struct disk *d1)
if (dp[i].dp_typ == 0xa5)
dp[i].dp_flag = 0x80;
+#ifndef __alpha__
mbr = read_block(fd,WHERE(0,d1));
if (d1->bootmgr)
memcpy(mbr,d1->bootmgr,DOSPARTOFF);
@@ -249,6 +258,7 @@ Write_Disk(struct disk *d1)
mbr[512-2] = 0x55;
mbr[512-1] = 0xaa;
write_block(fd,WHERE(0,d1),mbr);
+#endif
i = 1;
i = ioctl(fd,DIOCSYNCSLICEINFO,&i);
OpenPOWER on IntegriCloud