diff --git a/src/sys/devfs/devfs.c b/src/sys/devfs/devfs.c index bfc4120..3cc93ef 100644 --- a/src/sys/devfs/devfs.c +++ b/src/sys/devfs/devfs.c @@ -32,10 +32,10 @@ #include #include #include +#include #include #include #include -#include /* Spinlock for devfs we should start converting to sem/mutex */ static spinLock_t devfsSpinLock = SPIN_LOCK_INITIALIZER; @@ -44,13 +44,12 @@ struct devfs_info *fsInfo = 0x0; /* Allocate memory for the fsInfo */ - mp->fsInfo = (struct devfs_info *)kmalloc(sizeof(struct devfs_info)); - assert(mp->fsInfo); + if ((mp->fsInfo = (struct devfs_info *)kmalloc(sizeof(struct devfs_info))) == 0x0) + kpanic("devfs: failed to allocate memor\n"); fsInfo = mp->fsInfo; fsInfo->deviceList = 0x0; - - kprintf("DevFS Initialized\n"); + //Return return; } @@ -211,69 +210,5 @@ } /*** - $Log$ - Revision 1.15 2004/07/23 09:10:05 reddawg - ubixfs: cleaned up some functions played with the caching a bit - vfs: renamed a bunch of functions - cleaned up a few misc bugs - - Revision 1.14 2004/07/21 10:02:09 reddawg - devfs: renamed functions - device system: renamed functions - fdc: fixed a few potential bugs and cleaned up some unused variables - strol: fixed definition - endtask: made it print out freepage debug info - kmalloc: fixed a huge memory leak we had some unhandled descriptor insertion so some descriptors were lost - ld: fixed a pointer conversion - file: cleaned up a few unused variables - sched: broke task deletion - kprintf: fixed ogPrintf definition - - Revision 1.13 2004/07/20 22:42:34 reddawg - Fixed up any bugs I could find now to move onto bigger things - - Revision 1.12 2004/07/16 20:17:29 flameshadow - chg: broke the ufs stuff - chg: changed vfsRegisterFS() to accept a fileSystem struct - chg: modified calls to vfsRegisterFS() to pass fileSystem struct - - Revision 1.11 2004/07/14 12:17:52 reddawg - devfs: devFSEnable to devfs_init - Changed Startup Routines - - Revision 1.10 2004/06/28 23:12:58 reddawg - file format now container:/path/to/file - - Revision 1.9 2004/05/26 11:55:25 reddawg - devfs: Added spin locks to fix some possible reentrant issues - - Revision 1.8 2004/05/19 15:31:27 reddawg - Fixed up the rest of the references - - Revision 1.7 2004/05/19 04:07:42 reddawg - kmalloc(size,pid) no more it is no kmalloc(size); the way it should of been - - Revision 1.6 2004/04/28 21:10:40 reddawg - Lots Of changes to make it work with existing os - - Revision 1.5 2004/04/28 03:05:35 reddawg - Cleaned up some debug'n code - - Revision 1.4 2004/04/28 02:37:34 reddawg - More updates for using the new driver subsystem - - Revision 1.3 2004/04/28 02:22:54 reddawg - This is a fiarly large commit but we are starting to use new driver model - all around - - Revision 1.2 2004/04/26 22:22:33 reddawg - DevFS now uses correct size of device - - Revision 1.1.1.1 2004/04/15 12:06:54 reddawg - UbixOS v1.0 - - Revision 1.3 2004/04/13 16:36:33 reddawg - Changed our copyright, it is all now under a BSD-Style license - END ***/