Commit Graph

40 Commits

Author SHA1 Message Date
atatat 10a7ba9ef6 Tweak sysctl setup functions (the macros, actually) for use in lkms,
and tweak lkminit_*.c (where applicable) to call them, and to call
sysctl_teardown() when being unloaded.

This consists of (1) making setup functions not be static when being
compiled as lkms (change to sys/sysctl.h), (2) making prototypes
visible for the various setup functions in header files (changes to
various header files), and (3) making simple "load" and "unload"
functions in the actual lkminit stuff.

linux_sysctl.c also needs its root exposed (ie, made not static) for
this (when built as an lkm).
2004-05-20 06:34:24 +00:00
jrf 5f626331c1 caddr_t -> void * and removal of some more casts. 2004-05-12 02:07:37 +00:00
jrf e3a43961ff Remove caddr_t inlines. Approved by christos@NetBSD.org. 2004-05-04 13:26:58 +00:00
jrf fc97fd571a First pass for some caddr_t removal and changes to get rid of it where we
no longer use and/or need it

	- removed casts from unionfs, deadfs and fdesc
	  (there are more to hunt down still)
	- changed vfs_quotactl args argumet from caddr_t to void *
	- changed vfs_quotactl structures/callers to reflect the api change

Compiled fine and ran for about a day. Approved/reviewed by
christos@netbsd.org and gimpy@netbsd.org.
2004-04-27 17:37:30 +00:00
christos 6bd1d6d4db Replace the statfs() family of system calls with statvfs().
Retain binary compatibility.
2004-04-21 01:05:31 +00:00
atatat 19af35fd0d Tango on sysctl_createv() and flags. The flags have all been renamed,
and sysctl_createv() now uses more arguments.
2004-03-24 15:34:46 +00:00
jdolecek d8d0d9d81f g/c redundant debug printf 2004-03-22 16:39:30 +00:00
jdolecek 4ba68533b9 use global prtactive setting instead of ntfs-specific variable;
this also changes default, to not print the active vnodes
2004-02-29 11:08:55 +00:00
jdolecek 209952cca8 make VOP_UPDATE() trivially succeed (without doing anything), instead
of returning error

this makes it possible to mount other filesystems on directory on NTFS
filesystem
2004-02-22 10:26:14 +00:00
jdolecek ff7bf7ee82 use 64bit local variable for free space computation 2004-02-22 08:18:11 +00:00
hannken d6170777cf Fix xxx_strategy() to use the vnode arg instead of bp->b_vp. 2004-01-26 10:39:29 +00:00
atatat 13f8d2ce5f Dynamic sysctl.
Gone are the old kern_sysctl(), cpu_sysctl(), hw_sysctl(),
vfs_sysctl(), etc, routines, along with sysctl_int() et al.  Now all
nodes are registered with the tree, and nodes can be added (or
removed) easily, and I/O to and from the tree is handled generically.

Since the nodes are registered with the tree, the mapping from name to
number (and back again) can now be discovered, instead of having to be
hard coded.  Adding new nodes to the tree is likewise much simpler --
the new infrastructure handles almost all the work for simple types,
and just about anything else can be done with a small helper function.

All existing nodes are where they were before (numerically speaking),
so all existing consumers of sysctl information should notice no
difference.

PS - I'm sorry, but there's a distinct lack of documentation at the
moment.  I'm working on sysctl(3/8/9) right now, and I promise to
watch out for buses.
2003-12-04 19:38:21 +00:00
christos 6dc8df292b KASSERT was not the right thing here. Instead only set the type if f_type
has been inititialized. Reported by pooka
2003-11-11 00:44:16 +00:00
christos 79b169b7aa Fix typo. 2003-10-25 19:10:34 +00:00
christos 2017bf9a94 Fix uninitialized variable warning 2003-10-25 18:31:59 +00:00
jdolecek 87f9bd7267 change accidentaly left debug printf to dprintf() 2003-10-06 16:47:10 +00:00
yamt 589e82f2ba terminate snprintb 'new' format strings correctly.
(fixes overrun in mount_*)
2003-10-03 16:34:31 +00:00
agc aad01611e7 Move UCB-licensed code from 4-clause to 3-clause licence.
Patches provided by Joel Baker in PR 22364, verified by myself.
2003-08-07 16:26:28 +00:00
jdolecek 28d75bbaf3 remove all traces of non-working quota support
add quota support to TODO - makes sense only once writing support
would be implemented, and only once NTFS would support notion of file 'owner'

adresses kern/21967 by Martin Husemann
2003-08-02 12:11:56 +00:00
fvdl d5aece61d6 Back out the lwp/ktrace changes. They contained a lot of colateral damage,
and need to be examined and discussed more.
2003-06-29 22:28:00 +00:00
thorpej a06b275edc Undo part of the ktrace/lwp changes. In particular:
* Remove the "lwp *" argument that was added to vget().  Turns out
  that nothing actually used it!
* Remove the "lwp *" arguments that were added to VFS_ROOT(), VFS_VGET(),
  and VFS_FHTOVP(); all they did was pass it to vget() (which, as noted
  above, didn't use it).
* Remove all of the "lwp *" arguments to internal functions that were added
  just to appease the above.
2003-06-29 18:43:21 +00:00
darrenr 960df3c8d1 Pass lwp pointers throughtout the kernel, as required, so that the lwpid can
be inserted into ktrace records.  The general change has been to replace
"struct proc *" with "struct lwp *" in various function prototypes, pass
the lwp through and use l_proc to get the process pointer when needed.

Bump the kernel rev up to 1.6V
2003-06-28 14:20:43 +00:00
martin 864f19482a #ifdef _KERNEL_OPT police 2003-06-23 14:59:21 +00:00
martin 79b00c490a Disable QUOTA for ntfs - it's broken. 2003-06-23 11:53:47 +00:00
martin d505b18964 Make sure to include opt_foo.h if a defflag option FOO is used. 2003-06-23 11:00:59 +00:00
christos 94f1b04361 fix a few missing malloc attach/detach. Now this works. 2003-04-24 07:50:19 +00:00
christos 77500fa37f forgot one malloc attach/detach 2003-04-22 17:23:47 +00:00
christos baf70d805d explicitly attach and detach malloc types like smbfs does; thanks jaromir. 2003-04-22 16:48:19 +00:00
christos 80ecd573c0 PR/1796: John Kohl: statfs misbehaves under chrooted environments.
- Under chroot it displays only the visible filesystems with appropriate paths.
- The statfs f_mntonname gets adjusted to contain the real path from root.
- While was there, fixed a bug in ext2fs, locking problems with vfs_getfsstat(),
  and factored out some of the vfsop statfs() code to copy_statfs_info(). This
  fixes the problem where some filesystems forgot to set fsid.
- Made coda look more like a normal fs.
2003-04-16 21:44:18 +00:00
jdolecek 39a063b681 back to genfs_eopnotsupp() for vop_remove, vop_link, vop_rename,
vop_mkdir, vop_rmdir - it does the right unlocking now
2003-04-10 21:57:26 +00:00
jdolecek b41f818f25 change some printf()s on easily-triggerable codepaths to dprintf() 2003-04-10 21:37:32 +00:00
jdolecek 1f29707d43 move ntfs_remove() to be together with the other dummies - easier to c&p
eventually
2003-04-09 18:46:47 +00:00
jdolecek 6810b56243 add dummy link, rename, mkdir, rmdir vnode ops, which release the
appropriate vnodes before failing with EOPNOTSUPP - this is necessary
to not deadlock later
2003-04-09 18:41:05 +00:00
jdolecek 011c1952fd #if 0 some no longer used macros; keep around for refence 2003-04-09 16:18:56 +00:00
jdolecek af5ced0d31 replace VOP__UNLOCK(), VN_LOCK(), VGET() macros with the real thing, to
imporove readability
g/c some non-NetBSD code for same reason
2003-04-09 16:18:17 +00:00
jdolecek 81d7a920df print some potentially useful stuff in ntfs_print()
replace the VOP__UNLOCK() macros with VOP_UNLOCK() directly - it just
  obfuscates the code
similarily for VN_LOCK()->vn_lock()
unlock dvp before ntvattrget call in ntfs_lookup() in '..' case, not after
fix problem in ntfs_lookup() where PDIRUNLOCK was not set in one code path
  after unlocking parent directory vnode
2003-04-09 16:12:18 +00:00
jdolecek a0e0f99677 add real ntfs remove vnode op, which releases vnode locks on parent directory
and the file vnode before returning EOPNOTSUPP
fixes PR kern/19595 by Erik Berls
2003-04-09 16:02:18 +00:00
thorpej b193480908 Add extensible malloc types, adapted from FreeBSD. This turns
malloc types into a structure, a pointer to which is passed around,
instead of an int constant.  Allow the limit to be adjusted when the
malloc type is defined, or with a function call, as suggested by
Jonathan Stone.
2003-02-01 06:23:35 +00:00
wiz 6621e1674f Typo and grammar fixes in comments and a printf string. 2003-01-06 12:27:42 +00:00
jdolecek 9accf4df15 move NTFS code from sys/ntfs to sys/fs/ntfs 2002-12-23 17:38:19 +00:00