diff options
author | Chris Johns <chrisj@rtems.org> | 2007-12-22 08:27:18 +0000 |
---|---|---|
committer | Chris Johns <chrisj@rtems.org> | 2007-12-22 08:27:18 +0000 |
commit | 1ff9922df0f6e5f129299847d0f5eccbc8d6806c (patch) | |
tree | 07d27ca9b48c51998530281353a246286fdf1698 /cpukit/libblock | |
parent | 2007-12-21 Xi Yang <hiyangxi@gmail.com> (diff) | |
download | rtems-1ff9922df0f6e5f129299847d0f5eccbc8d6806c.tar.bz2 |
2007-12-22 Chris Johns <chrisj@rtems.org>
* configure.ac: fixed bug that always enabled strict order
mutexes.
* score/inline/rtems/score/coremutex.inl: Fixed coding standard.
* score/src/coremutex.c: Add the holder's thread to the lock_mutex
list if the mutex is initialised locked.
* libnetworking/rtems/rtems_glue.c: Changed semaphore error
message to show the error is an rtems-net error.
* libmisc/monitor/mon-network.c: Removed warnings.
* telnetd/icmds.c: Changed shell_* to rtems_shell_*.
* score/Makefile.am: Fixed typo that stopped 'make tags' working.
* libmisc/shell/err.c, libmisc/shell/err.h, libmisc/shell/errx.c,
libmisc/shell/extern-cp.h, libmisc/shell/fts.c,
libmisc/shell/fts.h, libmisc/shell/main_cp.c,
libmisc/shell/utils-cp.c, libmisc/shell/verr.c,
libmisc/shell/verrx.c, libmisc/shell/vwarn.c,
libmisc/shell/vwarnx.c, libmisc/shell/warn.c,
libmisc/shell/warnx.c: New. Ported from BSD.
* libmisc/shell/shellconfig.h: Add the cp command.
* libmisc/Makefile.am: Add the new files to the shell.
* libmisc/shell/shell.c, libmisc/shell/shell.h: Add scripting
support.
* libblock/src/flashdisk.c: Fixed disk drive count size setting
bug.
Diffstat (limited to 'cpukit/libblock')
-rw-r--r-- | cpukit/libblock/src/flashdisk.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/cpukit/libblock/src/flashdisk.c b/cpukit/libblock/src/flashdisk.c index 94cbdb38e2..58bdabae8c 100644 --- a/cpukit/libblock/src/flashdisk.c +++ b/cpukit/libblock/src/flashdisk.c @@ -2002,7 +2002,7 @@ rtems_fdisk_read (rtems_flashdisk* fd, blkdev_request* req) /** * Flash disk WRITE request handler. This primitive copies data from - * supplied buffer to RAM disk and invoke the callout function to inform + * supplied buffer to flash disk and invoke the callout function to inform * upper layer that writing is completed. * * @param req Pointers to the WRITE block device request info. @@ -2340,6 +2340,8 @@ rtems_fdisk_ioctl (dev_t dev, uint32_t req, void* argp) /** * Flash disk device driver initialization. * + * @todo Memory clean up on error is really badly handled. + * * @param major Flash disk major device number. * @param minor Minor device number, not applicable. * @param arg Initialization argument, not applicable. @@ -2419,7 +2421,7 @@ rtems_fdisk_initialize (rtems_device_major_number major, if (!fd->blocks) return RTEMS_NO_MEMORY; - fd->block_count = blocks; + fd->block_count = blocks; fd->devices = calloc (c->device_count, sizeof (rtems_fdisk_device_ctl)); if (!fd->devices) @@ -2471,9 +2473,9 @@ rtems_fdisk_initialize (rtems_device_major_number major, if (ret) rtems_fdisk_error ("compacting of disk failed: %s (%d)", strerror (ret), ret); - - rtems_flashdisk_count = rtems_flashdisk_configuration_size; } + rtems_flashdisk_count = rtems_flashdisk_configuration_size; + return RTEMS_SUCCESSFUL; } |