1 1.6 christos /* $NetBSD: conf.c,v 1.6 2012/01/16 18:46:20 christos Exp $ */ 2 1.1 dsl 3 1.1 dsl /* 4 1.1 dsl * Copyright (c) 1997 5 1.1 dsl * Matthias Drochner. All rights reserved. 6 1.1 dsl * 7 1.1 dsl * Redistribution and use in source and binary forms, with or without 8 1.1 dsl * modification, are permitted provided that the following conditions 9 1.1 dsl * are met: 10 1.1 dsl * 1. Redistributions of source code must retain the above copyright 11 1.1 dsl * notice, this list of conditions and the following disclaimer. 12 1.1 dsl * 2. Redistributions in binary form must reproduce the above copyright 13 1.1 dsl * notice, this list of conditions and the following disclaimer in the 14 1.1 dsl * documentation and/or other materials provided with the distribution. 15 1.1 dsl * 16 1.1 dsl * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR 17 1.1 dsl * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES 18 1.1 dsl * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. 19 1.1 dsl * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, 20 1.1 dsl * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT 21 1.1 dsl * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 22 1.1 dsl * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 23 1.1 dsl * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 24 1.1 dsl * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF 25 1.1 dsl * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 26 1.1 dsl */ 27 1.1 dsl 28 1.1 dsl 29 1.1 dsl #include <sys/cdefs.h> 30 1.1 dsl 31 1.1 dsl #include <sys/types.h> 32 1.1 dsl 33 1.1 dsl #include <lib/libsa/stand.h> 34 1.1 dsl #include <lib/libsa/ufs.h> 35 1.1 dsl #include <lib/libsa/lfs.h> 36 1.5 tsutsui #ifdef SUPPORT_EXT2FS 37 1.5 tsutsui #include <lib/libsa/ext2fs.h> 38 1.5 tsutsui #endif 39 1.6 christos #ifdef SUPPORT_MINIXFS3 40 1.6 christos #include <lib/libsa/minixfs3.h> 41 1.6 christos #endif 42 1.1 dsl #ifdef SUPPORT_USTARFS 43 1.1 dsl #include <lib/libsa/ustarfs.h> 44 1.1 dsl #endif 45 1.1 dsl #ifdef SUPPORT_DOSFS 46 1.1 dsl #include <lib/libsa/dosfs.h> 47 1.1 dsl #endif 48 1.3 junyoung #ifdef SUPPORT_CD9660 49 1.3 junyoung #include <lib/libsa/cd9660.h> 50 1.3 junyoung #endif 51 1.1 dsl 52 1.1 dsl #include <biosdisk.h> 53 1.1 dsl 54 1.1 dsl struct devsw devsw[] = { 55 1.3 junyoung {"disk", biosdisk_strategy, biosdisk_open, biosdisk_close, 56 1.3 junyoung biosdisk_ioctl}, 57 1.1 dsl }; 58 1.1 dsl int ndevs = sizeof(devsw) / sizeof(struct devsw); 59 1.1 dsl 60 1.1 dsl struct fs_ops file_system[] = { 61 1.3 junyoung #ifdef SUPPORT_CD9660 62 1.3 junyoung FS_OPS(cd9660), 63 1.3 junyoung #endif 64 1.1 dsl #ifdef SUPPORT_USTARFS 65 1.1 dsl FS_OPS(ustarfs), 66 1.1 dsl #endif 67 1.1 dsl FS_OPS(ffsv1), FS_OPS(ffsv2), 68 1.1 dsl FS_OPS(lfsv1), FS_OPS(lfsv2), 69 1.5 tsutsui #ifdef SUPPORT_EXT2FS 70 1.5 tsutsui FS_OPS(ext2fs), 71 1.5 tsutsui #endif 72 1.6 christos #ifdef SUPPORT_MINIXFS3 73 1.6 christos FS_OPS(minixfs3), 74 1.6 christos #endif 75 1.1 dsl #ifdef SUPPORT_DOSFS 76 1.1 dsl FS_OPS(dosfs), 77 1.1 dsl #endif 78 1.1 dsl }; 79 1.1 dsl int nfsys = sizeof(file_system) / sizeof(struct fs_ops); 80