Home | History | Annotate | Line # | Download | only in fsdb
fsdb.h revision 1.9.26.1
      1  1.9.26.1      mjf /*	$NetBSD: fsdb.h,v 1.9.26.1 2008/06/02 13:21:21 mjf Exp $	*/
      2       1.2  thorpej 
      3       1.3      jtc /*-
      4       1.3      jtc  * Copyright (c) 1996 The NetBSD Foundation, Inc.
      5       1.3      jtc  * All rights reserved.
      6       1.3      jtc  *
      7       1.3      jtc  * This code is derived from software contributed to The NetBSD Foundation
      8       1.3      jtc  * by John T. Kohl.
      9       1.3      jtc  *
     10       1.3      jtc  * Redistribution and use in source and binary forms, with or without
     11       1.3      jtc  * modification, are permitted provided that the following conditions
     12       1.3      jtc  * are met:
     13       1.3      jtc  * 1. Redistributions of source code must retain the above copyright
     14       1.3      jtc  *    notice, this list of conditions and the following disclaimer.
     15       1.3      jtc  * 2. Redistributions in binary form must reproduce the above copyright
     16       1.3      jtc  *    notice, this list of conditions and the following disclaimer in the
     17       1.3      jtc  *    documentation and/or other materials provided with the distribution.
     18       1.3      jtc  *
     19       1.3      jtc  * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS
     20       1.3      jtc  * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
     21       1.3      jtc  * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
     22       1.5      jtc  * PURPOSE ARE DISCLAIMED.  IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS
     23       1.5      jtc  * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
     24       1.3      jtc  * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
     25       1.3      jtc  * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
     26       1.3      jtc  * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
     27       1.3      jtc  * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
     28       1.3      jtc  * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
     29       1.1  thorpej  * POSSIBILITY OF SUCH DAMAGE.
     30       1.1  thorpej  */
     31       1.1  thorpej 
     32       1.9  xtraeme extern void rwerror(char *mesg, daddr_t blk);
     33       1.1  thorpej 
     34       1.1  thorpej extern long dev_bsize;
     35       1.1  thorpej extern long secsize;
     36       1.1  thorpej extern int fsmodified;
     37       1.1  thorpej extern int fsfd;
     38       1.6   bouyer extern int doswap;
     39       1.6   bouyer extern int needswap;
     40       1.6   bouyer extern int markclean;
     41       1.1  thorpej 
     42       1.1  thorpej struct cmdtable {
     43       1.1  thorpej 	const char *cmd;
     44       1.1  thorpej 	const char *helptxt;
     45       1.1  thorpej 	unsigned int minargc;
     46       1.1  thorpej 	unsigned int maxargc;
     47       1.9  xtraeme 	int (*handler)(int argc, char *argv[]);
     48       1.1  thorpej };
     49       1.8     fvdl extern union dinode *curinode;
     50       1.1  thorpej extern ino_t curinum;
     51       1.1  thorpej 
     52       1.9  xtraeme char **crack(char *, int *);
     53       1.9  xtraeme int argcount(struct cmdtable *, int, char *[]);
     54       1.9  xtraeme void printstat(const char *, ino_t, union dinode *);
     55       1.9  xtraeme int checkactive(void);
     56       1.9  xtraeme int checkactivedir(void);
     57       1.9  xtraeme int printactive(void);
     58