UbixOS V2
2.0
thread.c
Go to the documentation of this file.
1
/*****************************************************************************************
2
Copyright (c) 2002-2004 The UbixOS Project
3
All rights reserved.
4
5
Redistribution and use in source and binary forms, with or without modification, are
6
permitted provided that the following conditions are met:
7
8
Redistributions of source code must retain the above copyright notice, this list of
9
conditions, the following disclaimer and the list of authors. Redistributions in binary
10
form must reproduce the above copyright notice, this list of conditions, the following
11
disclaimer and the list of authors in the documentation and/or other materials provided
12
with the distribution. Neither the name of the UbixOS Project nor the names of its
13
contributors may be used to endorse or promote products derived from this software
14
without specific prior written permission.
15
16
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY
17
EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
18
MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL
19
THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
20
SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT
21
OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
22
HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR
23
TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
24
SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
25
26
$Id: thread.c 54 2016-01-11 01:29:55Z reddawg $
27
28
*****************************************************************************************/
29
30
#include <
ubixfs/ubixfs.h
>
31
#include <
ubixos/kpanic.h
>
32
#include <
vfs/vfs.h
>
33
#include <
lib/kprintf.h
>
34
35
static
struct
{
36
int
mounts
;
37
} ubixFS_Info;
38
39
void
ubixfs_thread
(
struct
vfs_mountPoint
*mp) {
40
mpi_message_t
myMsg;
41
42
ubixFS_Info.mounts = 0;
43
44
if
(mp == 0x0)
45
kpanic
(
"bah"
);
46
47
if
(
mpi_createMbox
(
"ubixfs"
) != 0x0) {
48
kpanic
(
"Error: Error creating mailbox: ubixfs\n"
);
49
}
50
while
(1) {
51
if
(
mpi_fetchMessage
(
"ubixfs"
,&myMsg) == 0x0) {
52
switch
(myMsg.
header
) {
53
default
:
54
kprintf
(
"Unhandled Message: %i\n"
,myMsg.
header
);
55
break
;
56
}
57
}
58
}
59
}
60
61
/***
62
$Log: thread.c,v $
63
Revision 1.2 2006/12/05 14:10:21 reddawg
64
Workign Distro
65
66
Revision 1.1.1.1 2006/06/01 12:46:17 reddawg
67
ubix2
68
69
Revision 1.2 2005/10/12 00:13:37 reddawg
70
Removed
71
72
Revision 1.1.1.1 2005/09/26 17:24:41 reddawg
73
no message
74
75
Revision 1.3 2004/08/14 11:23:02 reddawg
76
Changes
77
78
Revision 1.2 2004/07/23 09:10:06 reddawg
79
ubixfs: cleaned up some functions played with the caching a bit
80
vfs: renamed a bunch of functions
81
cleaned up a few misc bugs
82
83
Revision 1.1 2004/06/28 18:12:44 reddawg
84
We need these files
85
86
END
87
***/
mpi_fetchMessage
int mpi_fetchMessage(char *, mpi_message_t *)
Definition:
system.c:187
vfs.h
ubixfs_thread
void ubixfs_thread(struct vfs_mountPoint *mp)
Definition:
thread.c:38
mpi_message::header
uInt32 header
Definition:
mpi.h:39
kpanic
void kpanic(const char *fmt,...)
print panic message and halt system
Definition:
kpanic.c:41
vfs_mountPoint
Definition:
mount.h:66
kpanic.h
kprintf.h
mounts
int mounts
Definition:
thread.c:61
ubixfs.h
mpi_message
Definition:
mpi.h:37
kprintf
int kprintf(const char *,...)
Definition:
kprintf.c:259
mpi_createMbox
int mpi_createMbox(char *)
Definition:
system.c:68
C:
Dev
git
UbixOS
sys
fs
ubixfs
thread.c
Generated by
1.8.16