1*94715d8eSBen Gras /* $NetBSD: extern.h,v 1.4 2009/10/21 01:07:46 snj Exp $ */ 2*94715d8eSBen Gras 3*94715d8eSBen Gras /* 4*94715d8eSBen Gras * Copyright (c) 1997 Christos Zoulas. All rights reserved. 5*94715d8eSBen Gras * 6*94715d8eSBen Gras * Redistribution and use in source and binary forms, with or without 7*94715d8eSBen Gras * modification, are permitted provided that the following conditions 8*94715d8eSBen Gras * are met: 9*94715d8eSBen Gras * 1. Redistributions of source code must retain the above copyright 10*94715d8eSBen Gras * notice, this list of conditions and the following disclaimer. 11*94715d8eSBen Gras * 2. Redistributions in binary form must reproduce the above copyright 12*94715d8eSBen Gras * notice, this list of conditions and the following disclaimer in the 13*94715d8eSBen Gras * documentation and/or other materials provided with the distribution. 14*94715d8eSBen Gras * 15*94715d8eSBen Gras * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR 16*94715d8eSBen Gras * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES 17*94715d8eSBen Gras * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. 18*94715d8eSBen Gras * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, 19*94715d8eSBen Gras * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT 20*94715d8eSBen Gras * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 21*94715d8eSBen Gras * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 22*94715d8eSBen Gras * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 23*94715d8eSBen Gras * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF 24*94715d8eSBen Gras * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 25*94715d8eSBen Gras */ 26*94715d8eSBen Gras 27*94715d8eSBen Gras /* XXX should be in <sys/ufs/ext2fs.h> */ 28*94715d8eSBen Gras #define EXT2_LOG_MAXBSIZE 12 29*94715d8eSBen Gras #define EXT2_MAXBSIZE (1 << EXT2_LOG_MAXBSIZE) 30*94715d8eSBen Gras 31*94715d8eSBen Gras /* prototypes */ 32*94715d8eSBen Gras void mke2fs(const char *, int, int); 33*94715d8eSBen Gras 34*94715d8eSBen Gras /* variables set up by front end. */ 35*94715d8eSBen Gras extern int Nflag; /* run mkfs without writing file system */ 36*94715d8eSBen Gras extern int Oflag; /* format as an 4.3BSD file system */ 37*94715d8eSBen Gras extern int verbosity; /* amount of printf() output */ 38*94715d8eSBen Gras extern int64_t fssize; /* file system size */ 39*94715d8eSBen Gras extern uint16_t inodesize; /* bytes per inode */ 40*94715d8eSBen Gras extern uint sectorsize; /* sector size */ 41*94715d8eSBen Gras extern uint fsize; /* fragment size */ 42*94715d8eSBen Gras extern uint bsize; /* block size */ 43*94715d8eSBen Gras extern uint minfree; /* free space threshold */ 44*94715d8eSBen Gras extern uint num_inodes; /* number of inodes (overrides density) */ 45*94715d8eSBen Gras extern char *volname; /* volume name */ 46