Commit Graph

643 Commits

Author SHA1 Message Date
nyan
d75f204b28 Supported non-512 bytes/sector format.
PR:		misc/12992
Submitted by:	chi@bd.mbn.or.jp (Chiharu Shibata) and
		Dmitrij Tejblum <tejblum@arc.hq.cti.ru>
Reviewed by:	Dmitrij Tejblum <tejblum@arc.hq.cti.ru>
2000-01-27 14:43:07 +00:00
rwatson
f2d8638a5c Fix bde'isms in acl/extattr syscall interface, renaming syscalls to
prettier (?) names, adding some const's around here, et al.

Reviewed by:	bde
2000-01-19 06:07:34 +00:00
bp
b7c9ebac80 Check if module was compiled without SMP support and running on
an SMP system.
2000-01-15 08:35:48 +00:00
bp
50108d2796 Add VT_NWFS tag. 2000-01-15 08:28:03 +00:00
bde
762f2e59e4 Forward declare some structs so that this header is more self-suifficent. 2000-01-14 19:54:42 +00:00
bde
7c59c0cbac Use MALLOC_DECLARE when it is #defined, not when a (wrong) test of
__FreeBSD_version succeeds.
2000-01-14 19:47:07 +00:00
phk
0c41ecfa99 remove check now done in vn_isdisk(). 2000-01-10 12:24:36 +00:00
phk
ae0c1ec8f7 Give vn_isdisk() a second argument where it can return a suitable errno.
Suggested by:	bde
2000-01-10 12:04:27 +00:00
bp
21379a643b Treat negative uio_offset value as eof (idea by: bde).
Prevent overflows by casting uio_offset to uoff_t.
Return correct error number if directory entry is broken.

Reviewed by:	bde
2000-01-08 10:45:54 +00:00
phk
0a3cb76ffd Return ENXIO if there is no device. 2000-01-02 15:16:17 +00:00
bp
11b5b4872e Fix the mess with signed/unsigned longs and ints (inspired by bde).
Fix potential bug with directory reading.
Explicitly limit file size to 4GB (msdos can't handle larger files).
Slightly reorganize msdosfs_read() to reduce number of 'if's.
2000-01-02 03:30:42 +00:00
peter
d53e4c1d80 Change #ifdef KERNEL to #ifdef _KERNEL in the public headers. "KERNEL"
is an application space macro and the applications are supposed to be free
to use it as they please (but cannot).  This is consistant with the other
BSD's who made this change quite some time ago.  More commits to come.
1999-12-29 05:07:58 +00:00
bp
4e45fd3449 Avoid to write garbage if uiomove fails. 1999-12-28 16:14:54 +00:00
bp
5f346bab48 Fix an overflow in the msdosfs_read() function which exposed on the files
with size > 2GB.

PR:		15639
Submitted by:	Tim Kientzle <kientzle@acm.org>
Reviewed by:	phk
1999-12-28 15:34:23 +00:00
bp
7b78445d14 It is possible that number of sectors specified in the BPB
will exceed FAT capacity. This will lead to kernel panic while other
systems just limit number of clusters.

PR:		4381, 15136
Reviewed by:	phk
1999-12-28 15:27:39 +00:00
peter
a6b139a8de Fix typo "," vs ";"
PR:		15696
Submitted by:	Takashi Okumura <taka@cs.pitt.edu>
1999-12-27 16:03:38 +00:00
chris
220d3c3bf1 Fix a typo that was doing something kind of silly, and that is initializing
the creation time for files to the uninitialized value:

	vap->va_ctime = vap->va_ctime;

Changed to what was intended, assigning it to the modification time (thus
making all three values of access time, modification time and creation time
the same thing).

Reviewed by:	grog
1999-12-21 06:29:00 +00:00
eivind
46fa0fc35e Include vm/vm_extern.h to get at prototypes 1999-12-20 18:26:58 +00:00
rwatson
4b6baecfc7 Second pass commit to introduce new ACL and Extended Attribute system
calls, vnops, vfsops, both in /kern, and to individual file systems that
require a vfsop_ array entry.

Reviewed by:	eivind
1999-12-19 06:08:07 +00:00
eivind
87724eb673 Introduce NDFREE (and remove VOP_ABORTOP) 1999-12-15 23:02:35 +00:00
peter
10d963c9b0 Fix pointer problem for the Alpha 1999-12-12 21:10:53 +00:00
bp
af2fc77e5c Bump local version number to 1.3.4. 1999-12-12 05:53:02 +00:00
eivind
287836faea Lock reporting and assertion changes.
* lockstatus() and VOP_ISLOCKED() gets a new process argument and a new
  return value: LK_EXCLOTHER, when the lock is held exclusively by another
  process.
* The ASSERT_VOP_(UN)LOCKED family is extended to use what this gives them
* Extend the vnode_if.src format to allow more exact specification than
  locked/unlocked.

This commit should not do any semantic changes unless you are using
DEBUG_VFS_LOCKS.

Discussed with:	grog, mch, peter, phk
Reviewed by:	peter
1999-12-11 16:13:02 +00:00
peter
a9e62f9902 Don't simulate a pseudo address-space beyond VM_MAXUSER_ADDRESS that
maps onto the upages.  We used to use this extensively, particularly
for ps and gdb.  Both of these have been "fixed".  ps gets the p_stats
via eproc along with all the other stats, and gdb uses the regs, fpregs
etc files.

Once apon a time the UPAGES were mapped here, but that changed back
in January '96.  This essentially kills my revisions 1.16 and 1.17.
The 2-page "hole" above the stack can be reclaimed now.
1999-12-11 10:21:34 +00:00
semenu
d230d55c6a First version of HPFS stuff. 1999-12-09 19:10:13 +00:00
phk
989c4095ed Remove unused #includes.
Obtained from:	http://bogon.freebsd.dk/include
1999-12-08 08:59:40 +00:00
sos
1f5f1ce072 Commit the kernel part of our DVD support. Nothing much to say really,
its just a number of new ioctl's, the rest is done in userland.
1999-12-07 22:25:28 +00:00
semenu
39d5a6d9a1 Merged NetBSD version, as they have done improvements:
1. ntfs_read*attr*() functions now accept
	uio structure to eliminate one data copying.
	2. found and removed deadlock caused
	by 6 concurent ls -lR.
	3. started implementation of nromal
	Unicode<->unix recodeing.

Obtained from:	NetBSD
1999-12-03 20:37:40 +00:00
mckusick
a7a8ed1423 Collect read and write counts for filesystems. This new code
drops the counting in bwrite and puts it all in spec_strategy.
I did some tests and verified that the counts collected for writes
in spec_strategy is identical to the counts that we previously
collected in bwrite. We now also get read counts (async reads
come from requests for read-ahead blocks). Note that you need
to compile a new version of mount to get the read counts printed
out. The old mount binary is completely compatible, the only
reason to install a new mount is to get the read counts printed.

Submitted by:	Craig A Soules <soules+@andrew.cmu.edu>
Reviewed by:	Kirk McKusick <mckusick@mckusick.com>
1999-12-01 02:09:30 +00:00
bp
dc2c10cce6 Remove abuse of struct nameidata.
Pointed by:	Eivind Eklund
1999-11-27 17:46:04 +00:00
phk
5dbe9d95ba Add a sysctl to control if argv is disclosed to the world:
kern.ps_argsopen
It defaults to 1 which means that all users can see all argvs in ps(1).

Reviewed by:	Warner
1999-11-26 08:27:16 +00:00
phk
fd22d5412a Introduce the new function
p_trespass(struct proc *p1, struct proc *p2)
which returns zero or an errno depending on the legality of p1 trespassing
on p2.

Replace kern_sig.c:CANSIGNAL() with call to p_trespass() and one
extra signal related check.

Replace procfs.h:CHECKIO() macros with calls to p_trespass().

Only show command lines to process which can trespass on the target
process.
1999-11-21 19:03:20 +00:00
bp
daddfe794d Remove race condition under SMP.
Noted by:	Denis Kalinin <denis@mail.rbc.ru>
1999-11-21 16:35:29 +00:00
phk
d19d6e6b45 s/p_cred->pc_ucred/p_ucred/g 1999-11-21 12:38:21 +00:00
sef
b5a0bd9494 A process should be able to examine itself. 1999-11-20 18:22:14 +00:00
phk
1adcecffd9 struct mountlist and struct mount.mnt_list have no business being
a CIRCLEQ.  Change them to TAILQ_HEAD and TAILQ_ENTRY respectively.

This removes ugly  mp != (void*)&mountlist  comparisons.

Requested by:   phk
Submitted by:   Jake Burkholder jake@checker.org
PR:             14967
1999-11-20 10:00:46 +00:00
peter
82f748df7a Fix an unused variable warning. 1999-11-18 09:07:30 +00:00
peter
7931c8be96 Fix a warning. 1999-11-18 08:47:10 +00:00
phk
1c13fa8c14 Make proc/*/cmdline use the cached argv if available.
Submitted by:   Paul Saab <paul@mu.org>
Reviewed by:    phk
1999-11-17 21:35:07 +00:00
phk
33d16c3322 The function `procfs_getattr()' in procfs doesn't set the value of
vap->va_fsid, so we cannot get valid information about procfs.

Submitted by:   SAWADA Mizuki miz@pa.aix.or.jp
Reviewed by:    phk
PR:     1654
1999-11-17 21:33:25 +00:00
eivind
4ce73d7096 Remove WILLRELE from VOP_SYMLINK
Note: Previous commit to these files (except coda_vnops and devfs_vnops)
that claimed to remove WILLRELE from VOP_RENAME actually removed it from
VOP_MKNOD.
1999-11-13 20:58:17 +00:00
eivind
21fff7b1c2 Remove WILLRELE from VOP_RENAME 1999-11-12 03:34:28 +00:00
phk
8c9bc6b146 Next step in the device cleanup process.
Correctly lock vnodes when calling VOP_OPEN() from filesystem mount code.

Unify spec_open() for bdev and cdev cases.

Remove the disabled bdev specific read/write code.
1999-11-09 14:15:33 +00:00
alc
49c5eada3d Passing "0" or "FALSE" as the fourth argument to vm_fault is wrong. It
should be "VM_FAULT_NORMAL".
1999-11-09 01:44:28 +00:00
phk
ab35df5a74 remove a confusing and stale comment. 1999-11-08 13:52:57 +00:00
phk
3e649437d2 Oops, a bit too hasty there. 1999-11-08 13:08:02 +00:00
phk
e6b1d22771 Various cleanups. 1999-11-08 09:59:34 +00:00
sef
8074856056 Explain why Warner is right, and I am wrong, in the removing of the
file object.  Also explain some possible directions to re-implement it --
I'm not sure it should be, given the minimal application use.  (Other
than having the debugger automatically access the symbols for a process,
the main use I'd found was with some minor accounting ability, but _that_
depends on it being in the filesystem space; an ioctl access method would
be useless in that case.)

This is a code-less change; only a comment has been added.
1999-11-08 05:13:54 +00:00
peter
4cd2b5b992 Update for fileops.fo_stat() addition. Note, this would panic if
it saw a DTYPE_PIPE.  This isn't quite right but should stop a crash.
1999-11-08 03:36:29 +00:00
phk
63959e2797 Use vop_panic() instead of spec_badop(). 1999-11-07 15:09:59 +00:00