projects
/
pintos-anon
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
859a5d6
)
Fix up header guards.
author
Ben Pfaff
<blp@cs.stanford.edu>
Mon, 6 Sep 2004 05:38:45 +0000
(
05:38
+0000)
committer
Ben Pfaff
<blp@cs.stanford.edu>
Mon, 6 Sep 2004 05:38:45 +0000
(
05:38
+0000)
49 files changed:
src/devices/16550a.h
patch
|
blob
|
history
src/devices/disk.h
patch
|
blob
|
history
src/devices/kbd.h
patch
|
blob
|
history
src/devices/serial.h
patch
|
blob
|
history
src/devices/timer.h
patch
|
blob
|
history
src/devices/vga.h
patch
|
blob
|
history
src/filesys/directory.h
patch
|
blob
|
history
src/filesys/file.h
patch
|
blob
|
history
src/filesys/filehdr.h
patch
|
blob
|
history
src/filesys/filesys.h
patch
|
blob
|
history
src/filesys/fsutil.h
patch
|
blob
|
history
src/filesys/off_t.h
patch
|
blob
|
history
src/lib/ctype.h
patch
|
blob
|
history
src/lib/debug.h
patch
|
blob
|
history
src/lib/inttypes.h
patch
|
blob
|
history
src/lib/kernel/bitmap.h
patch
|
blob
|
history
src/lib/kernel/hash.h
patch
|
blob
|
history
src/lib/kernel/list.h
patch
|
blob
|
history
src/lib/limits.h
patch
|
blob
|
history
src/lib/random.h
patch
|
blob
|
history
src/lib/round.h
patch
|
blob
|
history
src/lib/stdarg.h
patch
|
blob
|
history
src/lib/stdbool.h
patch
|
blob
|
history
src/lib/stddef.h
patch
|
blob
|
history
src/lib/stdint.h
patch
|
blob
|
history
src/lib/stdio.h
patch
|
blob
|
history
src/lib/stdlib.h
patch
|
blob
|
history
src/lib/string.h
patch
|
blob
|
history
src/lib/syscall-nr.h
patch
|
blob
|
history
src/lib/user/syscall-stub.h
patch
|
blob
|
history
src/lib/user/syscall.h
patch
|
blob
|
history
src/lib/user/user.h
patch
|
blob
|
history
src/threads/init.h
patch
|
blob
|
history
src/threads/interrupt.h
patch
|
blob
|
history
src/threads/intr-stubs.h
patch
|
blob
|
history
src/threads/io.h
patch
|
blob
|
history
src/threads/loader.h
patch
|
blob
|
history
src/threads/malloc.h
patch
|
blob
|
history
src/threads/mmu.h
patch
|
blob
|
history
src/threads/paging.h
patch
|
blob
|
history
src/threads/palloc.h
patch
|
blob
|
history
src/threads/switch.h
patch
|
blob
|
history
src/threads/synch.h
patch
|
blob
|
history
src/threads/thread.h
patch
|
blob
|
history
src/userprog/addrspace.h
patch
|
blob
|
history
src/userprog/exception.h
patch
|
blob
|
history
src/userprog/gdt.h
patch
|
blob
|
history
src/userprog/syscall.h
patch
|
blob
|
history
src/userprog/tss.h
patch
|
blob
|
history
diff --git
a/src/devices/16550a.h
b/src/devices/16550a.h
index b3cb37a6a804c5e29614f058c240ea35a6844720..99b7e578ad23478e13e06ed96c443c35cf9aabae 100644
(file)
--- a/
src/devices/16550a.h
+++ b/
src/devices/16550a.h
@@
-1,5
+1,5
@@
-#ifndef
HEADER
_16550A_H
-#define
HEADER_16550A_H 1
+#ifndef
DEVICES
_16550A_H
+#define
DEVICES_16550A_H
#include <debug.h>
#include <stdbool.h>
#include <debug.h>
#include <stdbool.h>
@@
-120,4
+120,4
@@
make_lcr (int bits, enum parity_type parity, int stop, bool send_break,
#define MSR_RI 0x40 /* Ring Indicator. */
#define MSR_DCD 0x80 /* Data Carrier Detect. */
#define MSR_RI 0x40 /* Ring Indicator. */
#define MSR_DCD 0x80 /* Data Carrier Detect. */
-#endif /* 16550a.h */
+#endif /*
devices/
16550a.h */
diff --git
a/src/devices/disk.h
b/src/devices/disk.h
index 9e785e549937079554d063658550bc7372cc8ee0..539c4b0bafdd8c589125e30d05266c4ded065210 100644
(file)
--- a/
src/devices/disk.h
+++ b/
src/devices/disk.h
@@
-1,5
+1,5
@@
-#ifndef
HEADER
_DISK_H
-#define
HEADER_DISK_H 1
+#ifndef
DEVICES
_DISK_H
+#define
DEVICES_DISK_H
#include <inttypes.h>
#include <stdint.h>
#include <inttypes.h>
#include <stdint.h>
@@
-21,4
+21,4
@@
disk_sector_t disk_size (struct disk *);
void disk_read (struct disk *, disk_sector_t, void *);
void disk_write (struct disk *, disk_sector_t, const void *);
void disk_read (struct disk *, disk_sector_t, void *);
void disk_write (struct disk *, disk_sector_t, const void *);
-#endif /* disk.h */
+#endif /* d
evices/d
isk.h */
diff --git
a/src/devices/kbd.h
b/src/devices/kbd.h
index f08ef74a58d97d6b23e3a552242a0adcd5604094..b32b63117cd5264ea2d797da0c5b0ce5d039111d 100644
(file)
--- a/
src/devices/kbd.h
+++ b/
src/devices/kbd.h
@@
-1,6
+1,6
@@
-#ifndef
HEADER
_KBD_H
-#define
HEADER_KBD_H 1
+#ifndef
DEVICES
_KBD_H
+#define
DEVICES_KBD_H
void kbd_init (void);
void kbd_init (void);
-#endif /* kbd.h */
+#endif /*
devices/
kbd.h */
diff --git
a/src/devices/serial.h
b/src/devices/serial.h
index 2b638005dc1ef6bd1be97e4385d71a62d1ce2432..672f8deb0ff88b4cd2c49f3de1d7bd08c4468756 100644
(file)
--- a/
src/devices/serial.h
+++ b/
src/devices/serial.h
@@
-1,9
+1,9
@@
-#ifndef
HEADER
_SERIAL_H
-#define
HEADER_SERIAL_H 1
+#ifndef
DEVICES
_SERIAL_H
+#define
DEVICES_SERIAL_H
#include <stdint.h>
void serial_init (void);
void serial_outb (uint8_t);
#include <stdint.h>
void serial_init (void);
void serial_outb (uint8_t);
-#endif /* serial.h */
+#endif /*
devices/
serial.h */
diff --git
a/src/devices/timer.h
b/src/devices/timer.h
index 33fdaec3ce90e45ff6d83a90831201ddfa170dcf..ba736d2a28d6d7e23c9ce41d4da06006f2877554 100644
(file)
--- a/
src/devices/timer.h
+++ b/
src/devices/timer.h
@@
-1,5
+1,5
@@
-#ifndef
HEADER
_TIMER_H
-#define
HEADER_TIMER_H 1
+#ifndef
DEVICES
_TIMER_H
+#define
DEVICES_TIMER_H
#include <stdint.h>
#include <stdint.h>
@@
-13,4
+13,4
@@
void timer_msleep (int64_t ms);
void timer_usleep (int64_t us);
void timer_nsleep (int64_t ns);
void timer_usleep (int64_t us);
void timer_nsleep (int64_t ns);
-#endif /* timer.h */
+#endif /*
devices/
timer.h */
diff --git
a/src/devices/vga.h
b/src/devices/vga.h
index 2221034883af29f1c6566c95abc4ba5977a21f42..190cf2158952123f27a55397b4c8ea6650eab024 100644
(file)
--- a/
src/devices/vga.h
+++ b/
src/devices/vga.h
@@
-1,7
+1,7
@@
-#ifndef
HEADER
_VGA_H
-#define
HEADER_VGA_H 1
+#ifndef
DEVICES
_VGA_H
+#define
DEVICES_VGA_H
void vga_init (void);
void vga_putc (int);
void vga_init (void);
void vga_putc (int);
-#endif /* vga.h */
+#endif /*
devices/
vga.h */
diff --git
a/src/filesys/directory.h
b/src/filesys/directory.h
index a3364aeb75e1d076002842fcd47ded7886ea2920..4464d466baffa0b04fca022e8f9d72939f7b6884 100644
(file)
--- a/
src/filesys/directory.h
+++ b/
src/filesys/directory.h
@@
-1,5
+1,5
@@
-#ifndef
HEADER
_DIRECTORY_H
-#define
HEADER_DIRECTORY_H 1
+#ifndef
FILESYS
_DIRECTORY_H
+#define
FILESYS_DIRECTORY_H
#include <stdbool.h>
#include <stddef.h>
#include <stdbool.h>
#include <stddef.h>
@@
-36,4
+36,4
@@
bool dir_remove (struct dir *, const char *name);
void dir_list (const struct dir *);
void dir_dump (const struct dir *);
void dir_list (const struct dir *);
void dir_dump (const struct dir *);
-#endif /* directory.h */
+#endif /*
filesys/
directory.h */
diff --git
a/src/filesys/file.h
b/src/filesys/file.h
index 28495c23c307c85a39279512318806191dd465c7..ea716aae032ffb78353c37c7dfc67f4ca620b1ee 100644
(file)
--- a/
src/filesys/file.h
+++ b/
src/filesys/file.h
@@
-1,5
+1,5
@@
-#ifndef
HEADER
_FILE_H
-#define
HEADER_FILE_H 1
+#ifndef
FILESYS
_FILE_H
+#define
FILESYS_FILE_H
#include <stdbool.h>
#include <stdint.h>
#include <stdbool.h>
#include <stdint.h>
@@
-24,4
+24,4
@@
off_t file_length (struct file *);
void file_seek (struct file *, off_t);
off_t file_tell (struct file *);
void file_seek (struct file *, off_t);
off_t file_tell (struct file *);
-#endif /* file.h */
+#endif /* file
sys/file
.h */
diff --git
a/src/filesys/filehdr.h
b/src/filesys/filehdr.h
index 7c9f37f27ba1e510e282f4945cdd4fe5fcf5ddba..60bca9619d452a26f08800cc089733b89e738491 100644
(file)
--- a/
src/filesys/filehdr.h
+++ b/
src/filesys/filehdr.h
@@
-1,5
+1,5
@@
-#ifndef
HEADER
_FILEHDR_H
-#define
HEADER_FILEHDR_H 1
+#ifndef
FILESYS
_FILEHDR_H
+#define
FILESYS_FILEHDR_H
#include <stdbool.h>
#include <stddef.h>
#include <stdbool.h>
#include <stddef.h>
@@
-29,4
+29,4
@@
disk_sector_t filehdr_byte_to_sector (const struct filehdr *, off_t);
off_t filehdr_length (const struct filehdr *);
void filehdr_print (const struct filehdr *);
off_t filehdr_length (const struct filehdr *);
void filehdr_print (const struct filehdr *);
-#endif /* filehdr.h */
+#endif /* file
sys/file
hdr.h */
diff --git
a/src/filesys/filesys.h
b/src/filesys/filesys.h
index 6e6c13610ab6522732804dad68d3fe2e1437a535..44c89f48b4eb25b06155ee101be36404c3bbc7ec 100644
(file)
--- a/
src/filesys/filesys.h
+++ b/
src/filesys/filesys.h
@@
-1,5
+1,5
@@
-#ifndef
HEADER
_FILESYS_H
-#define
HEADER_FILESYS_H 1
+#ifndef
FILESYS
_FILESYS_H
+#define
FILESYS_FILESYS_H
#include <stdbool.h>
#include <stdint.h>
#include <stdbool.h>
#include <stdint.h>
@@
-18,4
+18,4
@@
bool filesys_dump (void);
void filesys_self_test (void);
void filesys_self_test (void);
-#endif /* filesys.h */
+#endif /* filesys
/filesys
.h */
diff --git
a/src/filesys/fsutil.h
b/src/filesys/fsutil.h
index b37c5b6217c9c00d98662b17742d0a7468df4204..8962a8a7bfa4856fcf43bd8850197ff2edcbada1 100644
(file)
--- a/
src/filesys/fsutil.h
+++ b/
src/filesys/fsutil.h
@@
-1,5
+1,5
@@
-#ifndef
HEADER
_FSUTIL_H
-#define
HEADER_FSUTIL_H 1
+#ifndef
FILESYS
_FSUTIL_H
+#define
FILESYS_FSUTIL_H
#include <stdbool.h>
#include <stdbool.h>
@@
-12,4
+12,4
@@
extern bool fsutil_dump_filesys;
void fsutil_run (void);
void fsutil_print (const char *filename);
void fsutil_run (void);
void fsutil_print (const char *filename);
-#endif /* fsutil.h */
+#endif /* f
ilesys/f
sutil.h */
diff --git
a/src/filesys/off_t.h
b/src/filesys/off_t.h
index 84475e11dd3c7ad1b56dfa4886aa851e9f1605ef..55ff174cd0ae5cb52583b847785007b43412ffa2 100644
(file)
--- a/
src/filesys/off_t.h
+++ b/
src/filesys/off_t.h
@@
-1,5
+1,5
@@
-#ifndef
HEADER
_OFF_T_H
-#define
HEADER_OFF_T_H 1
+#ifndef
FILESYS
_OFF_T_H
+#define
FILESYS_OFF_T_H
#include <stdint.h>
#include <stdint.h>
@@
-8,4
+8,4
@@
definition but not any others. */
typedef int32_t off_t;
definition but not any others. */
typedef int32_t off_t;
-#endif /* off_t.h */
+#endif /*
filesys/
off_t.h */
diff --git
a/src/lib/ctype.h
b/src/lib/ctype.h
index fafa51fdba6cb8b6084a7a25cf27879d2e9fc75c..d0baf4fef9673526ba8a5b79be73af8f58b9d099 100644
(file)
--- a/
src/lib/ctype.h
+++ b/
src/lib/ctype.h
@@
-1,5
+1,5
@@
-#ifndef LIB_CTYPE_H
-#define
LIB_CTYPE_H 1
+#ifndef
__
LIB_CTYPE_H
+#define
__LIB_CTYPE_H
static inline int islower (int c) { return c >= 'a' && c <= 'z'; }
static inline int isupper (int c) { return c >= 'A' && c <= 'Z'; }
static inline int islower (int c) { return c >= 'a' && c <= 'z'; }
static inline int isupper (int c) { return c >= 'A' && c <= 'Z'; }
diff --git
a/src/lib/debug.h
b/src/lib/debug.h
index 2af8ba421ebe248b07c3a03d5e80fe09dbba3acc..947dff204f17fab746107a8def7b097d23a3db52 100644
(file)
--- a/
src/lib/debug.h
+++ b/
src/lib/debug.h
@@
-1,5
+1,5
@@
-#ifndef
HEADER
_DEBUG_H
-#define
HEADER_DEBUG_H 1
+#ifndef
__LIB
_DEBUG_H
+#define
__LIB_DEBUG_H
/* GCC lets us add "attributes" to functions, function
parameters, etc. to indicate their properties.
/* GCC lets us add "attributes" to functions, function
parameters, etc. to indicate their properties.
@@
-45,4
+45,4
@@
void debug_backtrace (void);
#else
#define ASSERT(CONDITION) ((void) 0)
#define NOT_REACHED() for (;;)
#else
#define ASSERT(CONDITION) ((void) 0)
#define NOT_REACHED() for (;;)
-#endif
+#endif
/* lib/debug.h */
diff --git
a/src/lib/inttypes.h
b/src/lib/inttypes.h
index 70bb8980b722c1bc7cf16ddc40125a76a1a3a449..08ee8fe0ffc6b0e054871063e813a7740214ee42 100644
(file)
--- a/
src/lib/inttypes.h
+++ b/
src/lib/inttypes.h
@@
-1,5
+1,5
@@
-#ifndef LIB_INTTYPES_H
-#define LIB_INTTYPES_H
+#ifndef
__
LIB_INTTYPES_H
+#define
__
LIB_INTTYPES_H
#define PRId8 "hhd"
#define PRId16 "hd"
#define PRId8 "hhd"
#define PRId16 "hd"
diff --git
a/src/lib/kernel/bitmap.h
b/src/lib/kernel/bitmap.h
index ada1354d26944ab8d1bb1a8f1b26f0526f296fcd..f70688b28662e70233cef635a2c1dcece495808b 100644
(file)
--- a/
src/lib/kernel/bitmap.h
+++ b/
src/lib/kernel/bitmap.h
@@
-1,5
+1,5
@@
-#ifndef
HEADER
_BITMAP_H
-#define
HEADER_BITMAP_H 1
+#ifndef
__LIB_KERNEL
_BITMAP_H
+#define
__LIB_KERNEL_BITMAP_H
#include <stdbool.h>
#include <stddef.h>
#include <stdbool.h>
#include <stddef.h>
@@
-60,4
+60,4
@@
void bitmap_write (const struct bitmap *, struct file *);
void bitmap_dump (const struct bitmap *);
void bitmap_dump (const struct bitmap *);
-#endif /* bitmap.h */
+#endif /*
lib/kernel/
bitmap.h */
diff --git
a/src/lib/kernel/hash.h
b/src/lib/kernel/hash.h
index e37592bfbeae5d32ac2928dcecb8b6470b1f0ad2..b7eadd31a57a147b7590efb142383bf2ab612e43 100644
(file)
--- a/
src/lib/kernel/hash.h
+++ b/
src/lib/kernel/hash.h
@@
-1,5
+1,5
@@
-#ifndef
HEADER
_HASH_H
-#define
HEADER_HASH_H 1
+#ifndef
__LIB_KERNEL
_HASH_H
+#define
__LIB_KERNEL_HASH_H
/* Hash table.
/* Hash table.
@@
-88,4
+88,4
@@
unsigned hash_bytes (const void *, size_t);
unsigned hash_string (const char *);
unsigned hash_int (int);
unsigned hash_string (const char *);
unsigned hash_int (int);
-#endif /* hash.h */
+#endif /*
lib/kernel/
hash.h */
diff --git
a/src/lib/kernel/list.h
b/src/lib/kernel/list.h
index 1bf66312553cc4ec271840f6fb39c287dd7a2735..88ed5952650a033de6d36a84e171eb79dc502f3b 100644
(file)
--- a/
src/lib/kernel/list.h
+++ b/
src/lib/kernel/list.h
@@
-1,5
+1,5
@@
-#ifndef
HEADER
_LIST_H
-#define
HEADER_LIST_H 1
+#ifndef
__LIB_KERNEL
_LIST_H
+#define
__LIB_KERNEL_LIST_H
/* Doubly linked list.
/* Doubly linked list.
@@
-162,4
+162,4
@@
void list_insert_ordered (struct list *, list_elem *,
void list_unique (struct list *, struct list *duplicates,
list_less_func *, void *aux);
void list_unique (struct list *, struct list *duplicates,
list_less_func *, void *aux);
-#endif /* list.h */
+#endif /* li
b/kernel/li
st.h */
diff --git
a/src/lib/limits.h
b/src/lib/limits.h
index 930a97b64deb1d22ac3ec6ebe5be16261f40a0b7..c957ec43e5075bcdc26230e20a93ef6f013bfa58 100644
(file)
--- a/
src/lib/limits.h
+++ b/
src/lib/limits.h
@@
-1,5
+1,5
@@
-#ifndef LIB_LIMITS_H
-#define LIB_LIMITS_H
+#ifndef
__
LIB_LIMITS_H
+#define
__
LIB_LIMITS_H
#define CHAR_BIT 8
#define CHAR_BIT 8
diff --git
a/src/lib/random.h
b/src/lib/random.h
index cc6eed41bf28f0788c0be709bae1d21754c59130..0950ae2e0e76f54f6f018c457d14d6a3e2daf5e0 100644
(file)
--- a/
src/lib/random.h
+++ b/
src/lib/random.h
@@
-1,5
+1,5
@@
-#ifndef
HEADER
_RANDOM_H
-#define
HEADER_RANDOM_H 1
+#ifndef
__LIB
_RANDOM_H
+#define
__LIB_RANDOM_H
#include <stddef.h>
#include <stddef.h>
@@
-7,4
+7,4
@@
void random_init (unsigned seed);
void random_bytes (void *, size_t);
unsigned long random_ulong (void);
void random_bytes (void *, size_t);
unsigned long random_ulong (void);
-#endif /* random.h */
+#endif /*
lib/
random.h */
diff --git
a/src/lib/round.h
b/src/lib/round.h
index df0fb4af0f2e016bc6f8a0d2af2d134a7f06880b..3aa66427409c4e3be1e061a8d910cba38b4766f3 100644
(file)
--- a/
src/lib/round.h
+++ b/
src/lib/round.h
@@
-1,5
+1,5
@@
-#ifndef LIB_ROUND_H
-#define LIB_ROUND_H
+#ifndef
__
LIB_ROUND_H
+#define
__
LIB_ROUND_H
/* Yields X rounded up to the nearest multiple of STEP.
For X >= 0, STEP >= 1 only. */
/* Yields X rounded up to the nearest multiple of STEP.
For X >= 0, STEP >= 1 only. */
diff --git
a/src/lib/stdarg.h
b/src/lib/stdarg.h
index 690bb284906c40f9c9113199115cb6c2b5df0435..32622b5ab70a6065b091eaf0d14542f09eae1882 100644
(file)
--- a/
src/lib/stdarg.h
+++ b/
src/lib/stdarg.h
@@
-1,5
+1,5
@@
-#ifndef LIB_STDARG_H
-#define LIB_STDARG_H
+#ifndef
__
LIB_STDARG_H
+#define
__
LIB_STDARG_H
/* GCC has <stdarg.h> functionality as built-ins,
so all we need is to use it. */
/* GCC has <stdarg.h> functionality as built-ins,
so all we need is to use it. */
diff --git
a/src/lib/stdbool.h
b/src/lib/stdbool.h
index 45fc51560e69ca8bd4ba19c9a17c1ff8fdb7d758..f173a912ad086ac0189191240fc728f5c8d81ece 100644
(file)
--- a/
src/lib/stdbool.h
+++ b/
src/lib/stdbool.h
@@
-1,5
+1,5
@@
-#ifndef LIB_STDBOOL_H
-#define LIB_STDBOOL_H
+#ifndef
__
LIB_STDBOOL_H
+#define
__
LIB_STDBOOL_H
#define bool _Bool
#define true 1
#define bool _Bool
#define true 1
diff --git
a/src/lib/stddef.h
b/src/lib/stddef.h
index 836b8f21c1dfc8dab191894c4572fb97d7e7a45f..2a05bc9c980d845af6ed562377fc9401d0639d56 100644
(file)
--- a/
src/lib/stddef.h
+++ b/
src/lib/stddef.h
@@
-1,5
+1,5
@@
-#ifndef LIB_STDDEF_H
-#define LIB_STDDEF_H
+#ifndef
__
LIB_STDDEF_H
+#define
__
LIB_STDDEF_H
#define NULL ((void *) 0)
#define offsetof(TYPE, MEMBER) ((size_t) &((TYPE *) 0)->MEMBER)
#define NULL ((void *) 0)
#define offsetof(TYPE, MEMBER) ((size_t) &((TYPE *) 0)->MEMBER)
diff --git
a/src/lib/stdint.h
b/src/lib/stdint.h
index 2f0218fab4667a04535f7909515b73680d4c75e3..c7b78395801ef83e683b106da507f715c65b4351 100644
(file)
--- a/
src/lib/stdint.h
+++ b/
src/lib/stdint.h
@@
-1,5
+1,5
@@
-#ifndef LIB_STDINT_H
-#define LIB_STDINT_H
+#ifndef
__
LIB_STDINT_H
+#define
__
LIB_STDINT_H
typedef signed char int8_t;
#define INT8_MAX 127
typedef signed char int8_t;
#define INT8_MAX 127
diff --git
a/src/lib/stdio.h
b/src/lib/stdio.h
index 71413870d47129d3129944ab09411463734a0edb..4609fb3be1e1cca30ebb13498c5c62cc78ae428e 100644
(file)
--- a/
src/lib/stdio.h
+++ b/
src/lib/stdio.h
@@
-1,5
+1,5
@@
-#ifndef LIB_STDIO_H
-#define LIB_STDIO_H
+#ifndef
__
LIB_STDIO_H
+#define
__
LIB_STDIO_H
#include <debug.h>
#include <stdbool.h>
#include <debug.h>
#include <stdbool.h>
diff --git
a/src/lib/stdlib.h
b/src/lib/stdlib.h
index 0a8abcb166edf576c493ff0889caffef37ab55df..d2f9bba721a83ea69abd635685b304200dfdd61f 100644
(file)
--- a/
src/lib/stdlib.h
+++ b/
src/lib/stdlib.h
@@
-1,5
+1,5
@@
-#ifndef LIB_STDLIB_H
-#define LIB_STDLIB_H
+#ifndef
__
LIB_STDLIB_H
+#define
__
LIB_STDLIB_H
#include "stddef.h"
#include "stddef.h"
diff --git
a/src/lib/string.h
b/src/lib/string.h
index 03ba7a00133201fd6730ffbdfe49bc9d6511575f..05b957f297ae78454738e9c41a2cff7e97ee5a17 100644
(file)
--- a/
src/lib/string.h
+++ b/
src/lib/string.h
@@
-1,5
+1,5
@@
-#ifndef LIB_STRING_H
-#define
LIB_STRING_H 1
+#ifndef
__
LIB_STRING_H
+#define
__LIB_STRING_H
#include "stddef.h"
#include "stddef.h"
diff --git
a/src/lib/syscall-nr.h
b/src/lib/syscall-nr.h
index fa9bde91ecdd3008cf1aab568a42accc3b02ae8f..cf934499855829355613e9e4957e6b08ef6b92d3 100644
(file)
--- a/
src/lib/syscall-nr.h
+++ b/
src/lib/syscall-nr.h
@@
-1,5
+1,5
@@
-#ifndef
LIB_SYSCALL_
NR_H
-#define
LIB_SYSCALL_NR_H 1
+#ifndef
__LIB_SYSCALL-
NR_H
+#define
__LIB_SYSCALL-NR_H
/* System call numbers. */
#define SYS_halt 0 /* Halts the operating system. */
/* System call numbers. */
#define SYS_halt 0 /* Halts the operating system. */
diff --git
a/src/lib/user/syscall-stub.h
b/src/lib/user/syscall-stub.h
index 7d5d2e8b018b88f1f1ab18d1d61e443f9dcd8a68..80274bb5d1e4605770777b968956b3bedece4636 100644
(file)
--- a/
src/lib/user/syscall-stub.h
+++ b/
src/lib/user/syscall-stub.h
@@
-1,5
+1,5
@@
-#ifndef
LIB_USER_SYSCALL_
STUB_H
-#define
LIB_USER_SYSCALL_STUB_H 1
+#ifndef
__LIB_USER_SYSCALL-
STUB_H
+#define
__LIB_USER_SYSCALL-STUB_H
int syscall (int nr, ...);
int syscall (int nr, ...);
diff --git
a/src/lib/user/syscall.h
b/src/lib/user/syscall.h
index 8dd88fb440f19abeda8544ac7611a3fd16ba2413..e10d39e1fd47e3e7997c78354bf6f6bfcce2d7e9 100644
(file)
--- a/
src/lib/user/syscall.h
+++ b/
src/lib/user/syscall.h
@@
-1,5
+1,5
@@
-#ifndef LIB_USER_SYSCALL_H
-#define
LIB_USER_SYSCALL_H 1
+#ifndef
__
LIB_USER_SYSCALL_H
+#define
__LIB_USER_SYSCALL_H
#include <stdbool.h>
#include <debug.h>
#include <stdbool.h>
#include <debug.h>
diff --git
a/src/lib/user/user.h
b/src/lib/user/user.h
index e9aebd2ed19e413dbf9c8a435af462847f16a442..6bebf6de2e8d3445e86e93ccf7430ad342944c9a 100644
(file)
--- a/
src/lib/user/user.h
+++ b/
src/lib/user/user.h
@@
-1,5
+1,5
@@
-#ifndef
LIB
_USER_H
-#define
LIB_USER_H 1
+#ifndef
__LIB_USER
_USER_H
+#define
__LIB_USER_USER_H
#ifdef KERNEL
#error This header is user-only.
#ifdef KERNEL
#error This header is user-only.
@@
-11,4
+11,4
@@
void exit (int);
void abort (void);
void exit (int);
void abort (void);
-#endif /* lib/user.h */
+#endif /* lib/user
/user
.h */
diff --git
a/src/threads/init.h
b/src/threads/init.h
index fed649bb60e08a93b4c7c97ac3f1d02b04535653..fafb4924bfd1931fb4ced93a36d8e28fa97c1f7a 100644
(file)
--- a/
src/threads/init.h
+++ b/
src/threads/init.h
@@
-1,9
+1,9
@@
-#ifndef
HEADER
_INIT_H
-#define
HEADER_INIT_H 1
+#ifndef
THREADS
_INIT_H
+#define
THREADS_INIT_H
#include <stddef.h>
/* Physical memory size, in 4 kB pages. */
size_t ram_pages;
#include <stddef.h>
/* Physical memory size, in 4 kB pages. */
size_t ram_pages;
-#endif /* init.h */
+#endif /*
threads/
init.h */
diff --git
a/src/threads/interrupt.h
b/src/threads/interrupt.h
index 40d7b6e139671b584d54ef7fdd5ce49ed25e11d9..5060b9d90bf7d2764b2e1d4e00e785212bca3f7e 100644
(file)
--- a/
src/threads/interrupt.h
+++ b/
src/threads/interrupt.h
@@
-1,5
+1,5
@@
-#ifndef
HEADER
_INTERRUPT_H
-#define
HEADER_INTERRUPT_H 1
+#ifndef
THREADS
_INTERRUPT_H
+#define
THREADS_INTERRUPT_H
#include <stdbool.h>
#include <stdint.h>
#include <stdbool.h>
#include <stdint.h>
@@
-59,4
+59,4
@@
void intr_yield_on_return (void);
void intr_dump_frame (const struct intr_frame *);
const char *intr_name (uint8_t vec);
void intr_dump_frame (const struct intr_frame *);
const char *intr_name (uint8_t vec);
-#endif /* interrupt.h */
+#endif /*
threads/
interrupt.h */
diff --git
a/src/threads/intr-stubs.h
b/src/threads/intr-stubs.h
index 3f2db7e1870d5d0401ef63dd821b73b878a34804..debeaabc075ab3668b78271d028e703481e1b113 100644
(file)
--- a/
src/threads/intr-stubs.h
+++ b/
src/threads/intr-stubs.h
@@
-1,5
+1,5
@@
-#ifndef
HEADER_INTR_
STUBS_H
-#define
HEADER_INTR_
STUBS_H
+#ifndef
THREADS_INTR-
STUBS_H
+#define
THREADS_INTR-
STUBS_H
/* Interrupt stubs.
/* Interrupt stubs.
@@
-17,4
+17,4
@@
extern intr_stub_func *intr_stubs[256];
/* Interrupt return path. */
void intr_exit (void);
/* Interrupt return path. */
void intr_exit (void);
-#endif /* intr-stubs.h */
+#endif /*
threads/
intr-stubs.h */
diff --git
a/src/threads/io.h
b/src/threads/io.h
index b6d1e4ba2afc46869ad3687bcbc4831199c68d83..a3889c205f677532188f556be3af9c8f79dc0de2 100644
(file)
--- a/
src/threads/io.h
+++ b/
src/threads/io.h
@@
-38,8
+38,8
@@
* the copyright notices, if any, listed below.
*/
* the copyright notices, if any, listed below.
*/
-#ifndef
HEADER
_IO_H
-#define
HEADER_IO_H 1
+#ifndef
THREADS
_IO_H
+#define
THREADS_IO_H
#include <stddef.h>
#include <stdint.h>
#include <stddef.h>
#include <stdint.h>
@@
-158,4
+158,4
@@
outsl (uint16_t port, const void *addr, size_t cnt)
: "cc");
}
: "cc");
}
-#endif /* io.h */
+#endif /*
threads/
io.h */
diff --git
a/src/threads/loader.h
b/src/threads/loader.h
index f5d7a9ba794bf2e045789deea123ef37541f122d..b412af362f546f429324d60cee952cd6577ebf73 100644
(file)
--- a/
src/threads/loader.h
+++ b/
src/threads/loader.h
@@
-1,5
+1,5
@@
-#ifndef
HEADER
_LOADER_H
-#define
HEADER
_LOADER_H
+#ifndef
THREADS
_LOADER_H
+#define
THREADS
_LOADER_H
/* Constants fixed by the PC BIOS. */
#define LOADER_BASE 0x7c00 /* Physical address of loader's base. */
/* Constants fixed by the PC BIOS. */
#define LOADER_BASE 0x7c00 /* Physical address of loader's base. */
@@
-30,4
+30,4
@@
#define SEL_KCSEG 0x08 /* Kernel code selector. */
#define SEL_KDSEG 0x10 /* Kernel data selector. */
#define SEL_KCSEG 0x08 /* Kernel code selector. */
#define SEL_KDSEG 0x10 /* Kernel data selector. */
-#endif /* loader.h */
+#endif /*
threads/
loader.h */
diff --git
a/src/threads/malloc.h
b/src/threads/malloc.h
index 8509f6f8999004713b99da90483a6e8ece6d2481..2f191557817347e1f9c8d5c6bf6aacc710d79b79 100644
(file)
--- a/
src/threads/malloc.h
+++ b/
src/threads/malloc.h
@@
-1,5
+1,5
@@
-#ifndef
HEADER
_MALLOC_H
-#define
HEADER
_MALLOC_H
+#ifndef
THREADS
_MALLOC_H
+#define
THREADS
_MALLOC_H
#include <debug.h>
#include <stddef.h>
#include <debug.h>
#include <stddef.h>
@@
-9,4
+9,4
@@
void *malloc (size_t) __attribute__ ((malloc));
void *calloc (size_t, size_t) __attribute__ ((malloc));
void free (void *);
void *calloc (size_t, size_t) __attribute__ ((malloc));
void free (void *);
-#endif /* malloc.h */
+#endif /*
threads/
malloc.h */
diff --git
a/src/threads/mmu.h
b/src/threads/mmu.h
index c66ff1822a2af990de21e9b53d5d3b6a2b639658..4e9340abe962242b01e43b1a03e264252c04910d 100644
(file)
--- a/
src/threads/mmu.h
+++ b/
src/threads/mmu.h
@@
-1,5
+1,5
@@
-#ifndef
HEADER
_MMU_H
-#define
HEADER_MMU_H 1
+#ifndef
THREADS
_MMU_H
+#define
THREADS_MMU_H
#ifndef __ASSEMBLER__
#include <debug.h>
#ifndef __ASSEMBLER__
#include <debug.h>
@@
-85,4
+85,4
@@
vtop (void *vaddr)
#define FLAG_MBS 0x00000002 /* Must be set. */
#define FLAG_IF 0x00000200 /* Interrupt Flag. */
#define FLAG_MBS 0x00000002 /* Must be set. */
#define FLAG_IF 0x00000200 /* Interrupt Flag. */
-#endif /* mmu.h */
+#endif /*
threads/
mmu.h */
diff --git
a/src/threads/paging.h
b/src/threads/paging.h
index 02fa3ca3fcc7099f75e33f60b900f847ad456aea..8481b170fef622ba920754fde8f2f2ec6237cc38 100644
(file)
--- a/
src/threads/paging.h
+++ b/
src/threads/paging.h
@@
-1,5
+1,5
@@
-#ifndef
HEADER
_PAGING_H
-#define
HEADER_PAGING_H 1
+#ifndef
THREADS
_PAGING_H
+#define
THREADS_PAGING_H
#include <stdbool.h>
#include <stdint.h>
#include <stdbool.h>
#include <stdint.h>
@@
-18,4
+18,4
@@
void *pagedir_next (uint32_t *pagedir, void **upage);
void pagedir_activate (uint32_t *pagedir);
void pagedir_activate (uint32_t *pagedir);
-#endif /* paging.h */
+#endif /*
threads/
paging.h */
diff --git
a/src/threads/palloc.h
b/src/threads/palloc.h
index 7250e98e64bc64089acc1f4276fc60e7a8da12c7..ca7824e58c7c9282eda82f14b5b6a0cae6507561 100644
(file)
--- a/
src/threads/palloc.h
+++ b/
src/threads/palloc.h
@@
-1,5
+1,5
@@
-#ifndef
HEADER
_PALLOC_H
-#define
HEADER_PALLOC_H 1
+#ifndef
THREADS
_PALLOC_H
+#define
THREADS_PALLOC_H
#include <stdint.h>
#include <stdint.h>
@@
-13,4
+13,4
@@
void palloc_init (void);
void *palloc_get (enum palloc_flags);
void palloc_free (void *);
void *palloc_get (enum palloc_flags);
void palloc_free (void *);
-#endif /* palloc.h */
+#endif /*
threads/
palloc.h */
diff --git
a/src/threads/switch.h
b/src/threads/switch.h
index 8a2974fcd999bafde09a9e46bfc274ad6dbde4dd..07b805e963d67f642f26e714d91462ec43389a83 100644
(file)
--- a/
src/threads/switch.h
+++ b/
src/threads/switch.h
@@
-1,5
+1,5
@@
-#ifndef
HEADER
_SWITCH_H
-#define
HEADER_SWITCH_H 1
+#ifndef
THREADS
_SWITCH_H
+#define
THREADS_SWITCH_H
#ifndef __ASSEMBLER__
/* switch_thread()'s stack frame. */
#ifndef __ASSEMBLER__
/* switch_thread()'s stack frame. */
@@
-35,4
+35,4
@@
void switch_thunk (void);
#define SWITCH_CUR 20
#define SWITCH_NEXT 24
#define SWITCH_CUR 20
#define SWITCH_NEXT 24
-#endif /* switch.h */
+#endif /*
threads/
switch.h */
diff --git
a/src/threads/synch.h
b/src/threads/synch.h
index c8ac2f446508a793962d455e6d3551e1af56d125..244479f9ae0afe236c12635bbe730cafce881d3d 100644
(file)
--- a/
src/threads/synch.h
+++ b/
src/threads/synch.h
@@
-1,5
+1,5
@@
-#ifndef
HEADER
_SYNCH_H
-#define
HEADER_SYNCH_H 1
+#ifndef
THREADS
_SYNCH_H
+#define
THREADS_SYNCH_H
#include <list.h>
#include <stdbool.h>
#include <list.h>
#include <stdbool.h>
@@
-45,4
+45,4
@@
void cond_signal (struct condition *, struct lock *);
void cond_broadcast (struct condition *, struct lock *);
const char *cond_name (const struct condition *);
void cond_broadcast (struct condition *, struct lock *);
const char *cond_name (const struct condition *);
-#endif /* synch.h */
+#endif /*
threads/
synch.h */
diff --git
a/src/threads/thread.h
b/src/threads/thread.h
index d6a3990f1047d795b4255efa278af5f1a1119e32..95173ffa51fe6f771a25b70ba135b12df090e00c 100644
(file)
--- a/
src/threads/thread.h
+++ b/
src/threads/thread.h
@@
-1,5
+1,5
@@
-#ifndef
HEADER
_THREAD_H
-#define
HEADER_THREAD_H 1
+#ifndef
THREADS
_THREAD_H
+#define
THREADS_THREAD_H
#include <debug.h>
#include <list.h>
#include <debug.h>
#include <list.h>
@@
-108,4
+108,4
@@
void thread_exit (void) NO_RETURN;
void thread_yield (void);
void thread_block (void);
void thread_yield (void);
void thread_block (void);
-#endif /* thread.h */
+#endif /* thread
s/thread
.h */
diff --git
a/src/userprog/addrspace.h
b/src/userprog/addrspace.h
index cf68189eb890f7f29d8d2c02835d48cea1268024..0ab70b880a20c4871a65f1275c48ba6be6ce45c6 100644
(file)
--- a/
src/userprog/addrspace.h
+++ b/
src/userprog/addrspace.h
@@
-1,5
+1,5
@@
-#ifndef
HEADER
_ADDRSPACE_H
-#define
HEADER_ADDRSPACE_H 1
+#ifndef
USERPROG
_ADDRSPACE_H
+#define
USERPROG_ADDRSPACE_H
#include <stdbool.h>
#include <stdbool.h>
@@
-8,4
+8,4
@@
bool addrspace_load (struct thread *, const char *, void (**start) (void));
void addrspace_destroy (struct thread *);
void addrspace_activate (struct thread *);
void addrspace_destroy (struct thread *);
void addrspace_activate (struct thread *);
-#endif /* addrspace.h */
+#endif /*
userprog/
addrspace.h */
diff --git
a/src/userprog/exception.h
b/src/userprog/exception.h
index 37b6142e22450ff07a7669f4ead8aaaed4cd425d..e37841018f6a72cb87687225dcd3f7f26280319d 100644
(file)
--- a/
src/userprog/exception.h
+++ b/
src/userprog/exception.h
@@
-1,6
+1,6
@@
-#ifndef
HEADER
_EXCEPTION_H
-#define
HEADER_EXCEPTION_H 1
+#ifndef
USERPROG
_EXCEPTION_H
+#define
USERPROG_EXCEPTION_H
void exception_init (void);
void exception_init (void);
-#endif /* exception.h */
+#endif /*
userprog/
exception.h */
diff --git
a/src/userprog/gdt.h
b/src/userprog/gdt.h
index 599e40e6526cf706552306a3ea70850cc5ad40e5..81fe50cbd39c9a0a40642e5ed741001dac726b43 100644
(file)
--- a/
src/userprog/gdt.h
+++ b/
src/userprog/gdt.h
@@
-1,5
+1,5
@@
-#ifndef
HEADER
_GDT_H
-#define
HEADER_GDT_H 1
+#ifndef
USERPROG
_GDT_H
+#define
USERPROG_GDT_H
#include "threads/loader.h"
#include "threads/loader.h"
@@
-12,4
+12,4
@@
void gdt_init (void);
void gdt_init (void);
-#endif /* gdt.h */
+#endif /*
userprog/
gdt.h */
diff --git
a/src/userprog/syscall.h
b/src/userprog/syscall.h
index f57676cd784ed46830866da2db80e2456c793fa3..90590967a9f96f9ea359d15c672b815dfb4379cb 100644
(file)
--- a/
src/userprog/syscall.h
+++ b/
src/userprog/syscall.h
@@
-1,6
+1,6
@@
-#ifndef
HEADER
_SYSCALL_H
-#define
HEADER_SYSCALL_H 1
+#ifndef
USERPROG
_SYSCALL_H
+#define
USERPROG_SYSCALL_H
void syscall_init (void);
void syscall_init (void);
-#endif /* syscall.h */
+#endif /*
userprog/
syscall.h */
diff --git
a/src/userprog/tss.h
b/src/userprog/tss.h
index a5476c7dacd91f6dc799ee361ebe3ac843946e24..fa8d47b54efb50969e44e54c7ae2e9df6b90ff99 100644
(file)
--- a/
src/userprog/tss.h
+++ b/
src/userprog/tss.h
@@
-1,5
+1,5
@@
-#ifndef
HEADER
_TSS_H
-#define
HEADER
_TSS_H
+#ifndef
USERPROG
_TSS_H
+#define
USERPROG
_TSS_H
#include <stdint.h>
#include <stdint.h>
@@
-8,4
+8,4
@@
void tss_init (void);
struct tss *tss_get (void);
void tss_set_esp0 (uint8_t *);
struct tss *tss_get (void);
void tss_set_esp0 (uint8_t *);
-#endif /* tss.h */
+#endif /*
userprog/
tss.h */