From owner-freebsd-bugs Fri Oct 8 16: 0: 5 1999 Delivered-To: freebsd-bugs@freebsd.org Received: from freefall.freebsd.org (freefall.FreeBSD.ORG [204.216.27.21]) by hub.freebsd.org (Postfix) with ESMTP id 2CA0414D91 for ; Fri, 8 Oct 1999 16:00:01 -0700 (PDT) (envelope-from gnats@FreeBSD.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.9.3/8.9.2) id QAA35954; Fri, 8 Oct 1999 16:00:01 -0700 (PDT) (envelope-from gnats@FreeBSD.org) Received: from byzantine.student.umd.edu (byzantine.student.umd.edu [129.2.244.158]) by hub.freebsd.org (Postfix) with ESMTP id F08CB15956 for ; Fri, 8 Oct 1999 15:57:05 -0700 (PDT) (envelope-from howardjp@byzantine.student.umd.edu) Received: (from howardjp@localhost) by byzantine.student.umd.edu (8.9.3/8.9.3) id SAA03761; Fri, 8 Oct 1999 18:57:57 -0400 (EDT) (envelope-from howardjp) Message-Id: <199910082257.SAA03761@byzantine.student.umd.edu> Date: Fri, 8 Oct 1999 18:57:57 -0400 (EDT) From: howardjp@wam.umd.edu Reply-To: howardjp@wam.umd.edu To: FreeBSD-gnats-submit@freebsd.org X-Send-Pr-Version: 3.2 Subject: kern/14217: [PATCH] EXT2FS as a KLD Sender: owner-freebsd-bugs@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org >Number: 14217 >Category: kern >Synopsis: [PATCH] EXT2FS as a KLD >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: change-request >Submitter-Id: current-users >Arrival-Date: Fri Oct 8 16:00:00 PDT 1999 >Closed-Date: >Last-Modified: >Originator: James Howard >Release: FreeBSD 4.0-CURRENT i386 >Organization: University of Maryland >Environment: FreeBSD byzantine.student.umd.edu 4.0-CURRENT FreeBSD 4.0-CURRENT #40: Wed Oct 6 18:17:44 EDT 1999 howardjp@byzantine.student.umd.edu:/usr/src/sys/compile/BYZANTINE i386 >Description: I wanted to learn how KLDs work, and in the process, I KLD-ified EXT2FS support. Below is a patch to sys/modules. I am not entirely certain I have done this correctly, but with it loaded, I have been able to read and write to a file formatted using mke2fs from Linux. While I was at it, I "fixed" modules/Makefile so that each sub- directory lies on a seperate line, as in most of the other Makefiles. >How-To-Repeat: N/A >Fix: diff -Nur modules.old/Makefile modules/Makefile --- modules.old/Makefile Fri Oct 8 18:48:05 1999 +++ modules/Makefile Fri Oct 8 18:49:45 1999 @@ -2,15 +2,72 @@ # XXX present but broken: atapi ip_mroute_mod joy pcic -SUBDIR= aha al ax ccd cd9660 coda dm fdesc fxp if_disc if_ppp if_sl if_tun \ - ipfw kernfs md mfs mii msdos mx nfs ntfs nullfs pn portal procfs rl \ - sf sis sk ste ti tl umapfs union vn vr wb xl +SUBDIR= aha \ + al \ + ax \ + ccd \ + cd9660 \ + coda \ + dm \ + ext2fs \ + fdesc \ + fxp \ + if_disc \ + if_ppp \ + if_sl \ + if_tun \ + ipfw \ + kernfs \ + md \ + mfs \ + mii \ + msdos \ + mx \ + nfs \ + ntfs \ + nullfs \ + pn \ + portal \ + procfs \ + rl \ + sf \ + sis \ + sk \ + ste \ + ti \ + tl \ + umapfs \ + union \ + vn \ + vr \ + wb \ + xl # XXX some of these can move to the general case when de-i386'ed .if ${MACHINE_ARCH} == "i386" -SUBDIR+=amr bktr coff fpu gnufpu ibcs2 linux mlx ncp nwfs splash streams \ - svr4 syscons vesa vinum -SUBDIR+=ugen uhid ukbd ulpt ums umodem umass +SUBDIR+=amr \ + bktr \ + coff \ + fpu \ + gnufpu \ + ibcs2 \ + linux \ + mlx \ + ncp \ + nwfs \ + splash \ + streams \ + svr4 \ + syscons \ + vesa \ + vinum +SUBDIR+=ugen \ + uhid \ + ukbd \ + ulpt \ + ums \ + umodem \ + umass .endif .include diff -Nur modules.old/ext2fs/Makefile modules/ext2fs/Makefile --- modules.old/ext2fs/Makefile Wed Dec 31 19:00:00 1969 +++ modules/ext2fs/Makefile Fri Oct 8 18:48:40 1999 @@ -0,0 +1,23 @@ +# $FreeBSD: src/sys/modules/nfs/Makefile,v 1.12 1999/08/28 00:47:29 peter Exp $ + +.PATH: ${.CURDIR}/../../gnu/ext2fs +KMOD= ext2fs +SRCS= ext2_alloc.c ext2_balloc.c ext2_inode.c ext2_inode_cnv.c \ + ext2_linux_balloc.c ext2_linux_ialloc.c ext2_lookup.c \ + ext2_subr.c ext2_vfsops.c ext2_vnops.c \ + opt_ddb.h opt_suiddir.h opt_quota.h +NOMAN= +VFS_KLD= +CFLAGS+= -DEXT2FS +CLEANFILES= opt_ddb.h opt_suiddir.h opt_quota.h + +opt_ddb.h: + touch ${.TARGET} + +opt_suiddir.h: + touch ${.TARGET} + +opt_quota.h: + touch ${.TARGET} + +.include >Release-Note: >Audit-Trail: >Unformatted: To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-bugs" in the body of the message