Пример #1
0
int32 CFE_PSP_InitSSR( uint32 bus, uint32 device, char * DeviceName )
{
   int32     ReturnCode = CFE_PSP_ERROR;
   device_t  xbd = NULLDEV;
   STATUS error = OK;

#ifdef USE_VXWORKS_ATA_DRIVER
   xbd = xbdRamDiskDevCreate (BLOCKSIZE, DISKSIZE, 0, DeviceName);
   if (xbd == NULLDEV)
   {
       ReturnCode = CFE_PSP_ERROR;
   }
   else
   {
      /* 
      ** Format the RAM disk for HRFS. Allow for upto a 1000 files/directories 
      ** and let HRFS determine the logical block size.
      */

      error = hrfsFormat(DeviceName, 0ll, 0, 1000);
      if (error != OK)
      {
         ReturnCode = CFE_PSP_ERROR;
      }
      else
      {
         ReturnCode = CFE_PSP_SUCCESS;
      }
   }
#endif

   return(ReturnCode);
   
}
Пример #2
0
void usrIosExtraInit (void)
    {
    excShowInit ();                     /* exception show routines */
    jobLibInit (JOB_TASK_STACK_SIZE);   /* miscellaneous support task */
    excInit (MAX_ISR_JOBS);             /* interrupt-level job facility */
    logInit (consoleFd, MAX_LOG_MSGS);  /* message logging */
    nbioLogInit (consoleFd, INIT_NBIO_MSGS); /* non-blocking message logging */
    pipeDrv ();                         /* pipes */
    aioPxLibInit (MAX_LIO_CALLS);       /* POSIX asynchronous IO */
    aioSysInit (MAX_AIO_SYS_TASKS, 				AIO_TASK_PRIORITY, AIO_TASK_STACK_SIZE); /* provides AIO functionality to non-AIO drivers */
    stdioInit ();                       /* buffered IO library */
    fioLibInit ();                      /* formatting for printf, scanf, etc. */
    floatInit ();                       /* allow printf and others to format floats correctly */
    erfLibInit (ERF_MAX_USR_CATEGORIES, ERF_MAX_USR_TYPES); /* Event Reporting Framework */
    devInit (DEVICE_MANAGER_MAX_NUM_DEVICES); /* Device Manager */
    xbdInit ();                         /* Extended Block Device */
    fsMonitorInit ();                   /* File System Monitor */
    fsEventUtilLibInit ();              /* File System Event Utilities */
    rawFsInit (NUM_RAWFS_FILES);        /* Raw block device file system interface */
    ptyDrv ();                          /* Allows communication between processes */
    usrRomfsConfig ();                  /* Read-only memory based file system */
    xbdRamDiskDevCreate (RAM_DISK_BLK_SIZE,                                                     RAM_DISK_SIZE,                                                         FALSE,                                                                 RAM_DISK_DEV_NAME); /* Create an XBD based RAM disk */
    usrBootLineParse (BOOT_LINE_ADRS);  /* parse some boot device configuration info  */
    usrPassFsInit (PASSFS_CACHE);       /* direct access to host filesystem */
    virtualDiskInit ();                 /* VxSim virtual disk to emulate a VxWorks disk driver. */
    }