Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Version Control Program and Rolling Backup Utility #88

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 5 additions & 3 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ $U/usys.o : $U/usys.S
$U/_forktest: $U/forktest.o $(ULIB)
# forktest has less library code linked in - needs to be small
# in order to be able to max out the proc table.
$(LD) $(LDFLAGS) -N -e main -Ttext 0 -o $U/_forktest $U/forktest.o $U/ulib.o $U/usys.o $U/umalloc.o $U/printf.o
$(LD) $(LDFLAGS) -N -e main -Ttext 0 -o $U/_forktest $U/forktest.o $U/ulib.o $U/usys.o $U/umalloc.o
$(OBJDUMP) -S $U/_forktest > $U/forktest.asm

mkfs/mkfs: mkfs/mkfs.c $K/fs.h $K/param.h
Expand All @@ -130,11 +130,13 @@ UPROGS=\
$U/_stressfs\
$U/_usertests\
$U/_grind\
$U/_vcp\
$U/_wc\
$U/_zombie\

fs.img: mkfs/mkfs README.md $(UPROGS)
mkfs/mkfs fs.img README.md $(UPROGS)
fs.img: mkfs/mkfs README.md getlinetest.txt $(UPROGS)
mkfs/mkfs fs.img README.md getlinetest.txt vcpTest.txt $(UPROGS)


-include kernel/*.d user/*.d

Expand Down
13 changes: 13 additions & 0 deletions getlinetest.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
# FogOS

Hello world!!

What's going on, class??

How about that fog out there?!

Let's create a REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY REALLY long line. IS THAT LONG ENOUGH?!?!?!

Okay all done.

Have a good one!
2 changes: 1 addition & 1 deletion kernel/fs.h
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ struct dinode {
#define BBLOCK(b, sb) ((b)/BPB + sb.bmapstart)

// Directory is a file containing a sequence of dirent structures.
#define DIRSIZ 14
#define DIRSIZ 30

struct dirent {
ushort inum;
Expand Down
20 changes: 18 additions & 2 deletions user/user.h
Original file line number Diff line number Diff line change
@@ -1,3 +1,16 @@
#define NULL ((void *) 0)

#define bool _Bool
#define true 1
#define false 0

#define SEEK_SET 0
#define STDIN_FILENO 0
#define SEEK_CUR 1
#define STDOUT_FILENO 1
#define SEEK_END 2
#define STDERR_FILENO 2

struct stat;

// system calls
Expand All @@ -22,6 +35,9 @@ int getpid(void);
char* sbrk(int);
int sleep(int);
int uptime(void);
int reboot(void);
int shutdown(void);
uint64 timestamp(void);

// ulib.c
int stat(const char*, struct stat*);
Expand All @@ -32,8 +48,8 @@ int strcmp(const char*, const char*);
void fprintf(int, const char*, ...);
void printf(const char*, ...);
char* gets(char*, int max);
int fgets(int fd, char*, int max);
int getline(char **lineptr, uint *n, int fd);
int fgets(int fd, char *buf, int max);
int getline(char **ptr, uint *size, int fd);
uint strlen(const char*);
void* memset(void*, int, uint);
void* malloc(uint);
Expand Down
Loading