Commit graph

35 commits

Author SHA1 Message Date
Frans Kaashoek 7894fcd217 Remove trailing white space with:
for f in *.{h,c}; do sed -i .sed 's/[[:blank:]]*$//' $f; done
(Thanks to Nicolás Wolovick)
2016-08-25 09:13:00 -04:00
Ayan Shafqat 4f2d38147f Fixed broken build on Arch Linux 2015-08-12 22:11:39 -04:00
Frans Kaashoek 8320d61be5 Pick up where i left off in april:
- move log into metadata part of disk, so that marking
that the log's blocks are in use falls out for free
- superblock describes the whole disk (sizes and offets)
- sizes and offsets are computed in one place (mkfs) and
the rest of the code refers to the superblock for these values,
instead of recomputing them.
2015-06-27 12:39:13 -04:00
Frans Kaashoek 895af77fe6 check blockno passed to idestart 2015-04-10 07:15:06 -04:00
Frans Kaashoek c24ac5d763 Disentangle block size from the disk's sector size. Set block size to 1024 to show
that they can be different.  Clean up mkfs, simplifying specifying fs parameters,
remove some redundancy between fs and mkfs, and fix disk layout bugs. Call blocks
in the file system blocks instead of sectors.  Passes usertests for different
block sizes.
2015-04-03 08:22:02 -04:00
Robert Morris 48aa917403 i think this is a working concurrent logging scheme 2014-08-28 05:57:47 -04:00
Frans Kaashoek c440b5cd97 Use static assert instead of _LP64 (thanks Eddie!) 2012-09-10 21:58:18 -04:00
Frans Kaashoek cf57e525c1 Remove -m32 flag from native gcc compiler
But check that mkfs.c is building with LP64
2012-09-07 17:39:04 -04:00
Frans Kaashoek 13a96baefc Dirt simple logging
Passes usertests and stressfs
Seems to recover correctly in a number of simple cases
2011-07-27 20:35:46 -04:00
Russ Cox c5f5387351 fixes from Peter Froehlich 2011-02-28 09:32:20 -05:00
Russ Cox 1a81e38b17 make new code like old code
Variable declarations at top of function,
separate from initialization.

Use == 0 instead of ! for checking pointers.

Consistent spacing around {, *, casts.

Declare 0-parameter functions as (void) not ().

Integer valued functions return -1 on failure, 0 on success.
2011-01-11 13:01:13 -05:00
Russ Cox 240679608c mkfs: avoid clash with system struct stat 2011-01-10 10:43:40 -05:00
Russ Cox e92fd6142d mkfs: avoid out of bounds access to sb in wsect 2011-01-02 17:59:57 -05:00
Austin Clements 1aee6a6c4f Hopefully get the printf size spec right, regardless of compiler. 2010-08-31 16:01:38 -04:00
Robert Morris 8d774afb2d no more pminit, or ELF header at 0x10000
kinit() knows about end and PHYSTOP
map all of kernel read/write (rather than r/o instructions)
thanks, austin
2010-08-31 15:39:25 -04:00
Austin Clements 880ee18ab1 mkfs must be compiled 32-bit. Fix mkfs warnings 2010-08-31 15:11:10 -04:00
rsc ba6cd8a685 drop NADDRS and INDIRECT; too many names 2009-05-31 00:59:37 +00:00
rsc 0c7f483838 move T_DIR etc into stat.h; move type up 2009-05-31 00:26:10 +00:00
rtm 2ce40d7088 be clear what the root i-number is 2008-10-08 18:57:13 +00:00
rtm 411ee74127 fix comments 2007-09-15 20:05:47 +00:00
rsc 558ab49f13 delete unnecessary #include lines 2007-08-27 23:26:33 +00:00
rtm 2036534834 add missing iput() at end of _namei() 2007-08-24 14:56:17 +00:00
rsc 72a590d9e5 quiet 2006-09-08 13:44:56 +00:00
rsc 94d7e25975 avoid system binary clashes 2006-09-07 13:07:39 +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 80f292f830 fix writing the indirect block 2006-08-25 01:25:22 +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 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
rtm 8a8be1b8c3 low-level keyboard input (not hooked up to /dev yet)
fix acquire() to cli() *before* incrementing nlock
make T_SYSCALL a trap gate, not an interrupt gate
sadly, various crashes if you hold down a keyboard key...
2006-08-10 02:07:10 +00:00
kaashoek 241113985f block bitmap
balloc
2006-08-09 01:09:36 +00:00
rtm 8455980b27 exec arguments 2006-07-28 22:33:07 +00:00
rtm c59361f143 primitive exec 2006-07-27 21:10:00 +00:00
rtm 9d3fb67141 namei 2006-07-21 22:10:40 +00:00
rtm 11a9947f1a bread
iget
mkfs makes a file system image
put this in your .bochsrc:
ata0-slave: type=disk, mode=flat, path="fs.img", cylinders=1024, heads=1, spt=1
2006-07-21 13:18:04 +00:00