rsc
d844f0f9d9
Change dev read/write functions
...
to take inode* instead of minor number.
Unlock console inode during console_read
and console_write. Otherwise background
processes cannot write to console while the
shell is reading it waiting for input.
2007-08-28 17:49:49 +00:00
rsc
3341e30f6e
nit
2007-08-28 04:13:24 +00:00
rsc
8970df0c1b
No one is going to find this inode.
...
There is only one ref to it -- the caller --
and no links to it.
2007-08-28 03:31:11 +00:00
rsc
558ab49f13
delete unnecessary #include lines
2007-08-27 23:26:33 +00:00
rsc
7895178df3
nits
2007-08-27 14:31:50 +00:00
rsc
6c34f97cb8
tell what an inode is
2007-08-27 14:23:48 +00:00
rsc
a505fd6651
FS cleanup.
...
Add utility routines bzero, readsb so that balloc, bfree fit on one page.
Make balloc loop clearer.
2007-08-27 14:20:24 +00:00
rsc
8d2e9a4867
shuffle for formatting
2007-08-24 22:17:54 +00:00
rsc
766ba5cc06
first ever correct use of strncpy
2007-08-24 21:00:02 +00:00
rsc
07090dd705
Remove struct uinode.
...
Remove type arg to mknod (assume T_DEV).
2007-08-24 20:54:23 +00:00
rsc
4d39b63388
nits
2007-08-24 19:46:19 +00:00
rtm
902b13f5d6
simplify ide queuing
...
nits in comments
2007-08-24 19:32:36 +00:00
rtm
2036534834
add missing iput() at end of _namei()
2007-08-24 14:56:17 +00:00
rsc
f0721f1be4
tweaks
2007-08-22 06:20:10 +00:00
rsc
eaea18cb9c
PDF at http://am.lcs.mit.edu/~rsc/xv6.pdf
...
Various changes made while offline.
+ bwrite sector argument is redundant; use b->sector.
+ reformatting of files for nicer PDF page breaks
+ distinguish between locked, unlocked inodes in type signatures
+ change FD_FILE to FD_INODE
+ move userinit (nee proc0init) to proc.c
+ move ROOTDEV to param.h
+ always parenthesize sizeof argument
2007-08-22 06:01:32 +00:00
rsc
fbf9103952
remove namelen parameter
2007-08-21 19:58:55 +00:00
rsc
f32f3638f4
Various cleanup:
...
- Got rid of dummy proc[0]. Now proc[0] is init.
- Added initcode.S to exec /init, so that /init is
just a regular binary.
- Moved exec out of sysfile to exec.c
- Moved code dealing with fs guts (like struct inode)
from sysfile.c to fs.c. Code dealing with system call
arguments stays in sysfile.c
- Refactored directory routines in fs.c; should be simpler.
- Changed iget to return *unlocked* inode structure.
This solves the lookup-then-use race in namei
without introducing deadlocks.
It also enabled getting rid of the dummy proc[0].
2007-08-21 19:22:08 +00:00
rsc
e2a620da49
checkpoint - simpler namei interface
2007-08-20 19:37:15 +00:00
rsc
bcca6c6bde
shuffle fs.c in bottom-up order
2007-08-20 18:23:52 +00:00
rsc
7d4aef6cfd
various cleanups
2007-08-10 16:52:31 +00:00
rsc
b6095304b7
Make cp a magic symbol.
2007-08-10 16:37:27 +00:00
rsc
bc01170334
The final curproc[cpu()] is now cp
2007-08-09 19:06:37 +00:00
rsc
ab5c2dbb59
Clearer namei
2007-08-09 19:05:00 +00:00
rsc
95c07f8267
move ialloc body up, avoiding double check for end of loop
2007-08-08 09:53:46 +00:00
rsc
32eea7665a
panic like bget
2007-08-08 09:50:46 +00:00
rsc
d80b06a1e0
iincref returns new ref
2007-08-08 09:30:42 +00:00
rsc
5f0c20ec14
fix . .. unlink bug
2007-08-08 09:08:29 +00:00
kaashoek
8e1d1ec934
some comment changes
2006-09-08 14:36:44 +00:00
rsc
be29b8e263
++
2006-09-08 14:26:16 +00:00
rsc
d911d83ca1
fix various comments
2006-09-08 13:55:43 +00:00
rsc
1542186378
allow long names again
2006-09-07 15:34:28 +00:00
rsc
0d6bbd3172
clean namei search loop
2006-09-07 15:15:32 +00:00
rsc
bb207a1d42
comments
2006-09-07 14:28:12 +00:00
rsc
1dca3afbbb
remove _ prefixes
2006-09-07 13:08:23 +00:00
rsc
0cfc7290e8
wrap long lines
2006-09-06 19:08:14 +00:00
rsc
db8fb62e4d
for vs while
2006-09-06 18:47:51 +00:00
rsc
48b824703b
break single-line if statements
2006-09-06 17:57:47 +00:00
rsc
f552738889
no /* */ comments
2006-09-06 17:50:20 +00:00
rsc
9e9bcaf143
standardize various * conventions
2006-09-06 17:27:19 +00:00
rsc
a650c606fe
spacing fixes: no tabs, 2-space indents (for rtm)
2006-09-06 17:04:06 +00:00
rtm
2aa4c3bc29
complain if no disk 1
...
lots of cleanup
2006-08-30 18:55:06 +00:00
rtm
7a37578e9e
clear killed flag in exit
...
idecref cwd in exit
2006-08-29 19:59:52 +00:00
rtm
03c70cc2e6
consistently ignore more than 14 chars in path component
...
forbid create or write of existing directory
mkdir("d1/d2/d3"), .. should refer to d2, not cwd
mkdir increase parent link count
2006-08-26 16:31:05 +00:00
rtm
5051da6de3
inode addrs[NDIRECT] -> NADDRS
...
fix race in mknod / creat
use last component in dirent in mknod, not path
2006-08-25 01:11:30 +00:00
rtm
bcfb84b6a9
big directory test
2006-08-24 19:21:19 +00:00
kaashoek
1be7668537
fix bugs in indirect-file code
...
clean up test program
2006-08-24 17:28:01 +00:00
kaashoek
ea2909b6b5
user-level malloc (untested)
...
nit in sbrk
indirect block
fix dup to share fd struct
2006-08-24 02:44:41 +00:00
kaashoek
8787cd01df
chdir
...
cd in shell
nits in mkdir, ls, etc.
2006-08-19 23:41:34 +00:00
kaashoek
e958c538fa
commented out code for cwd
2006-08-15 15:53:46 +00:00
kaashoek
bdb6643303
set size for directories correctly in wdir and mkfs
...
mkdir
ls shows stat info for each dir entry
2006-08-14 14:13:52 +00:00