summaryrefslogtreecommitdiffstats
path: root/sys/gnu/fs/ext2fs/ext2_readwrite.c
diff options
context:
space:
mode:
authorjulian <julian@FreeBSD.org>2001-09-12 08:38:13 +0000
committerjulian <julian@FreeBSD.org>2001-09-12 08:38:13 +0000
commit5596676e6c6c1e81e899cd0531f9b1c28a292669 (patch)
treeb1a19fcdf05759281fab0d89efb13f0fdf42102e /sys/gnu/fs/ext2fs/ext2_readwrite.c
parent83e00d4274950d2b531c24692cd123538ffbddb9 (diff)
downloadFreeBSD-src-5596676e6c6c1e81e899cd0531f9b1c28a292669.zip
FreeBSD-src-5596676e6c6c1e81e899cd0531f9b1c28a292669.tar.gz
KSE Milestone 2
Note ALL MODULES MUST BE RECOMPILED make the kernel aware that there are smaller units of scheduling than the process. (but only allow one thread per process at this time). This is functionally equivalent to teh previousl -current except that there is a thread associated with each process. Sorry john! (your next MFC will be a doosie!) Reviewed by: peter@freebsd.org, dillon@freebsd.org X-MFC after: ha ha ha ha
Diffstat (limited to 'sys/gnu/fs/ext2fs/ext2_readwrite.c')
-rw-r--r--sys/gnu/fs/ext2fs/ext2_readwrite.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/sys/gnu/fs/ext2fs/ext2_readwrite.c b/sys/gnu/fs/ext2fs/ext2_readwrite.c
index 62bc27a..2772f7b 100644
--- a/sys/gnu/fs/ext2fs/ext2_readwrite.c
+++ b/sys/gnu/fs/ext2fs/ext2_readwrite.c
@@ -172,7 +172,7 @@ WRITE(ap)
register struct inode *ip;
register FS *fs;
struct buf *bp;
- struct proc *p;
+ struct thread *td;
daddr_t lbn;
off_t osize;
int seqcount;
@@ -216,15 +216,15 @@ WRITE(ap)
* Maybe this should be above the vnode op call, but so long as
* file servers have no limits, I don't think it matters.
*/
- p = uio->uio_procp;
+ td = uio->uio_td;
/* For p_rlimit. */
mtx_assert(&Giant, MA_OWNED);
- if (vp->v_type == VREG && p &&
+ if (vp->v_type == VREG && td &&
uio->uio_offset + uio->uio_resid >
- p->p_rlimit[RLIMIT_FSIZE].rlim_cur) {
- PROC_LOCK(p);
- psignal(p, SIGXFSZ);
- PROC_UNLOCK(p);
+ td->td_proc->p_rlimit[RLIMIT_FSIZE].rlim_cur) {
+ PROC_LOCK(td->td_proc);
+ psignal(td->td_proc, SIGXFSZ);
+ PROC_UNLOCK(td->td_proc);
return (EFBIG);
}
@@ -302,7 +302,7 @@ WRITE(ap)
if (error) {
if (ioflag & IO_UNIT) {
(void)UFS_TRUNCATE(vp, osize,
- ioflag & IO_SYNC, ap->a_cred, uio->uio_procp);
+ ioflag & IO_SYNC, ap->a_cred, uio->uio_td);
uio->uio_offset -= resid - uio->uio_resid;
uio->uio_resid = resid;
}
OpenPOWER on IntegriCloud