diff options
Diffstat (limited to 'fs/xfs/support')
-rw-r--r-- | fs/xfs/support/ktrace.c | 4 | ||||
-rw-r--r-- | fs/xfs/support/uuid.c | 8 | ||||
-rw-r--r-- | fs/xfs/support/uuid.h | 1 |
3 files changed, 3 insertions, 10 deletions
diff --git a/fs/xfs/support/ktrace.c b/fs/xfs/support/ktrace.c index 0b75d302508..a34ef05489b 100644 --- a/fs/xfs/support/ktrace.c +++ b/fs/xfs/support/ktrace.c | |||
@@ -89,7 +89,7 @@ ktrace_alloc(int nentries, unsigned int __nocast sleep) | |||
89 | if (sleep & KM_SLEEP) | 89 | if (sleep & KM_SLEEP) |
90 | panic("ktrace_alloc: NULL memory on KM_SLEEP request!"); | 90 | panic("ktrace_alloc: NULL memory on KM_SLEEP request!"); |
91 | 91 | ||
92 | kmem_free(ktp, sizeof(*ktp)); | 92 | kmem_free(ktp); |
93 | 93 | ||
94 | return NULL; | 94 | return NULL; |
95 | } | 95 | } |
@@ -126,7 +126,7 @@ ktrace_free(ktrace_t *ktp) | |||
126 | } else { | 126 | } else { |
127 | entries_size = (int)(ktp->kt_nentries * sizeof(ktrace_entry_t)); | 127 | entries_size = (int)(ktp->kt_nentries * sizeof(ktrace_entry_t)); |
128 | 128 | ||
129 | kmem_free(ktp->kt_entries, entries_size); | 129 | kmem_free(ktp->kt_entries); |
130 | } | 130 | } |
131 | 131 | ||
132 | kmem_zone_free(ktrace_hdr_zone, ktp); | 132 | kmem_zone_free(ktrace_hdr_zone, ktp); |
diff --git a/fs/xfs/support/uuid.c b/fs/xfs/support/uuid.c index 493a6ecf859..5830c040ea7 100644 --- a/fs/xfs/support/uuid.c +++ b/fs/xfs/support/uuid.c | |||
@@ -17,7 +17,7 @@ | |||
17 | */ | 17 | */ |
18 | #include <xfs.h> | 18 | #include <xfs.h> |
19 | 19 | ||
20 | static mutex_t uuid_monitor; | 20 | static DEFINE_MUTEX(uuid_monitor); |
21 | static int uuid_table_size; | 21 | static int uuid_table_size; |
22 | static uuid_t *uuid_table; | 22 | static uuid_t *uuid_table; |
23 | 23 | ||
@@ -132,9 +132,3 @@ uuid_table_remove(uuid_t *uuid) | |||
132 | ASSERT(i < uuid_table_size); | 132 | ASSERT(i < uuid_table_size); |
133 | mutex_unlock(&uuid_monitor); | 133 | mutex_unlock(&uuid_monitor); |
134 | } | 134 | } |
135 | |||
136 | void __init | ||
137 | uuid_init(void) | ||
138 | { | ||
139 | mutex_init(&uuid_monitor); | ||
140 | } | ||
diff --git a/fs/xfs/support/uuid.h b/fs/xfs/support/uuid.h index b6f5922199b..cff5b607d44 100644 --- a/fs/xfs/support/uuid.h +++ b/fs/xfs/support/uuid.h | |||
@@ -22,7 +22,6 @@ typedef struct { | |||
22 | unsigned char __u_bits[16]; | 22 | unsigned char __u_bits[16]; |
23 | } uuid_t; | 23 | } uuid_t; |
24 | 24 | ||
25 | extern void uuid_init(void); | ||
26 | extern void uuid_create_nil(uuid_t *uuid); | 25 | extern void uuid_create_nil(uuid_t *uuid); |
27 | extern int uuid_is_nil(uuid_t *uuid); | 26 | extern int uuid_is_nil(uuid_t *uuid); |
28 | extern int uuid_equal(uuid_t *uuid1, uuid_t *uuid2); | 27 | extern int uuid_equal(uuid_t *uuid1, uuid_t *uuid2); |