xref: /netbsd/sys/arch/sh3/include/disklabel.h (revision 0c8dbeeb)
1*0c8dbeebSchristos /*	$NetBSD: disklabel.h,v 1.9 2013/05/16 18:47:38 christos Exp $	*/
265363da2Sitojun 
365363da2Sitojun /*
465363da2Sitojun  * Copyright (c) 1994 Christopher G. Demetriou
565363da2Sitojun  * All rights reserved.
665363da2Sitojun  *
765363da2Sitojun  * Redistribution and use in source and binary forms, with or without
865363da2Sitojun  * modification, are permitted provided that the following conditions
965363da2Sitojun  * are met:
1065363da2Sitojun  * 1. Redistributions of source code must retain the above copyright
1165363da2Sitojun  *    notice, this list of conditions and the following disclaimer.
1265363da2Sitojun  * 2. Redistributions in binary form must reproduce the above copyright
1365363da2Sitojun  *    notice, this list of conditions and the following disclaimer in the
1465363da2Sitojun  *    documentation and/or other materials provided with the distribution.
1565363da2Sitojun  * 3. All advertising materials mentioning features or use of this software
1665363da2Sitojun  *    must display the following acknowledgement:
1765363da2Sitojun  *      This product includes software developed by Christopher G. Demetriou.
1865363da2Sitojun  * 4. The name of the author may not be used to endorse or promote products
1965363da2Sitojun  *    derived from this software without specific prior written permission
2065363da2Sitojun  *
2165363da2Sitojun  * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
2265363da2Sitojun  * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
2365363da2Sitojun  * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
2465363da2Sitojun  * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
2565363da2Sitojun  * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
2665363da2Sitojun  * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
2765363da2Sitojun  * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
2865363da2Sitojun  * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
2965363da2Sitojun  * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
3065363da2Sitojun  * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
3165363da2Sitojun  */
3265363da2Sitojun 
3365363da2Sitojun #ifndef _MACHINE_DISKLABEL_H_
3465363da2Sitojun #define	_MACHINE_DISKLABEL_H_
3565363da2Sitojun 
3665363da2Sitojun #define	LABELSECTOR	1		/* sector containing label */
3765363da2Sitojun #define	LABELOFFSET	0		/* offset of label in sector */
38ba28fa4dSuch #define	MAXPARTITIONS	16		/* number of partitions */
39ba28fa4dSuch #define	RAW_PART	2
4065363da2Sitojun 
4165363da2Sitojun /* Pull in MBR partition definitions. */
42a37289dbSdyoung #if HAVE_NBTOOL_CONFIG_H
43a37289dbSdyoung #include <nbinclude/sys/bootblock.h>
44a37289dbSdyoung #else
451c33b4e6Slukem #include <sys/bootblock.h>
46a37289dbSdyoung #endif /* HAVE_NBTOOL_CONFIG_H */
4765363da2Sitojun 
4865363da2Sitojun #ifndef __ASSEMBLER__
49a37289dbSdyoung #if HAVE_NBTOOL_CONFIG_H
50a37289dbSdyoung #include <nbinclude/sys/dkbad.h>
51a37289dbSdyoung #else
5265363da2Sitojun #include <sys/dkbad.h>
53a37289dbSdyoung #endif /* HAVE_NBTOOL_CONFIG_H */
5465363da2Sitojun struct cpu_disklabel {
55*0c8dbeebSchristos 	struct mbr_partition mbrparts[MBR_PART_COUNT];
5609dbb89bSpooka #define __HAVE_DISKLABEL_DKBAD
5765363da2Sitojun 	struct dkbad bad;
5865363da2Sitojun };
5965363da2Sitojun #endif
6065363da2Sitojun 
6165363da2Sitojun #endif /* _MACHINE_DISKLABEL_H_ */
62