disklabel.h revision 1.6
11.6Schristos/* $NetBSD: disklabel.h,v 1.6 2013/05/16 19:06:45 christos Exp $ */ 21.1Smatt 31.1Smatt/* 41.1Smatt * Copyright (c) 1994 Christopher G. Demetriou 51.1Smatt * All rights reserved. 61.1Smatt * 71.1Smatt * Redistribution and use in source and binary forms, with or without 81.1Smatt * modification, are permitted provided that the following conditions 91.1Smatt * are met: 101.1Smatt * 1. Redistributions of source code must retain the above copyright 111.1Smatt * notice, this list of conditions and the following disclaimer. 121.1Smatt * 2. Redistributions in binary form must reproduce the above copyright 131.1Smatt * notice, this list of conditions and the following disclaimer in the 141.1Smatt * documentation and/or other materials provided with the distribution. 151.1Smatt * 3. All advertising materials mentioning features or use of this software 161.1Smatt * must display the following acknowledgement: 171.1Smatt * This product includes software developed by Christopher G. Demetriou. 181.1Smatt * 4. The name of the author may not be used to endorse or promote products 191.1Smatt * derived from this software without specific prior written permission 201.1Smatt * 211.1Smatt * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR 221.1Smatt * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES 231.1Smatt * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. 241.1Smatt * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, 251.1Smatt * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT 261.1Smatt * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 271.1Smatt * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 281.1Smatt * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 291.1Smatt * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF 301.1Smatt * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 311.1Smatt */ 321.1Smatt 331.1Smatt#ifndef _IBMNWS_DISKLABEL_H_ 341.1Smatt#define _IBMNWS_DISKLABEL_H_ 351.1Smatt 361.5Sbouyer#define LABELUSESMBR 0 /* no MBR partitionning */ 371.1Smatt#define LABELSECTOR 1 /* sector containing label */ 381.1Smatt#define LABELOFFSET 0 /* offset of label in sector */ 391.1Smatt#define MAXPARTITIONS 16 /* number of partitions */ 401.1Smatt#define RAW_PART 2 /* raw partition: xx?c */ 411.1Smatt 421.1Smatt/* Pull in MBR partition definitions. */ 431.2Sdyoung#if HAVE_NBTOOL_CONFIG_H 441.2Sdyoung#include <nbinclude/sys/bootblock.h> 451.2Sdyoung#include <nbinclude/sys/dkbad.h> 461.2Sdyoung#else 471.1Smatt#include <sys/bootblock.h> 481.1Smatt#include <sys/dkbad.h> 491.2Sdyoung#endif /* HAVE_NBTOOL_CONFIG_H */ 501.1Smatt 511.1Smattstruct cpu_disklabel { 521.6Schristos struct mbr_partition mbrparts[MBR_PART_COUNT]; 531.4Spooka#define __HAVE_DISKLABEL_DKBAD 541.1Smatt struct dkbad bad; 551.1Smatt}; 561.1Smatt 571.1Smatt#endif /* _IBMNWS_DISKLABEL_H_ */ 58