Module Name: src Committed By: martin Date: Sun Dec 14 16:41:30 UTC 2014
Modified Files: src/usr.sbin/installboot/arch [netbsd-7]: vax.c Log Message: Pull up following revision(s) (requested by tsutsui in ticket #323): usr.sbin/installboot/arch/vax.c: revision 1.18 Use VAX_LABELOFFSET here; It needs to be the machine-specific one. Thanks to gcc-4.8 for discovering the bug and to Atari for having a LABELOFFSET of 516 > 512 :-) XXX: Perhaps we should put all those constants in <sys/bootblock.h> instead of spreading them around. To generate a diff of this commit: cvs rdiff -u -r1.17 -r1.17.6.1 src/usr.sbin/installboot/arch/vax.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
Modified files: Index: src/usr.sbin/installboot/arch/vax.c diff -u src/usr.sbin/installboot/arch/vax.c:1.17 src/usr.sbin/installboot/arch/vax.c:1.17.6.1 --- src/usr.sbin/installboot/arch/vax.c:1.17 Sun Jun 16 19:05:00 2013 +++ src/usr.sbin/installboot/arch/vax.c Sun Dec 14 16:41:30 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: vax.c,v 1.17 2013/06/16 19:05:00 martin Exp $ */ +/* $NetBSD: vax.c,v 1.17.6.1 2014/12/14 16:41:30 martin Exp $ */ /*- * Copyright (c) 1999, 2002 The NetBSD Foundation, Inc. @@ -68,7 +68,7 @@ #include <sys/cdefs.h> #if !defined(__lint) -__RCSID("$NetBSD: vax.c,v 1.17 2013/06/16 19:05:00 martin Exp $"); +__RCSID("$NetBSD: vax.c,v 1.17.6.1 2014/12/14 16:41:30 martin Exp $"); #endif /* !__lint */ #include <sys/param.h> @@ -88,6 +88,8 @@ __RCSID("$NetBSD: vax.c,v 1.17 2013/06/1 #include "installboot.h" +#define VAX_LABELOFFSET 64 + #ifndef __CTASSERT #define __CTASSERT(X) #endif @@ -210,12 +212,12 @@ vax_setboot(ib_params *params) /* * Copy disklabel from old boot block to new. - * Assume everything between LABELOFFSET and the start of + * Assume everything between VAX_LABELOFFSET and the start of * the param block is scratch area and can be copied over. */ - memcpy(bootstrapbuf+LABELOFFSET, - oldbb+LABELOFFSET, - offsetof(struct vax_boot_block,bb_magic1)-LABELOFFSET); + memcpy(bootstrapbuf + VAX_LABELOFFSET, + oldbb + VAX_LABELOFFSET, + offsetof(struct vax_boot_block,bb_magic1) - VAX_LABELOFFSET); /* point to bootblock at begining of bootstrap */ bb = (struct vax_boot_block*)bootstrapbuf;