Commit Graph

28 Commits

Author SHA1 Message Date
Joel Sherrill
9b4422a251 Remove All CVS Id Strings Possible Using a Script
Script does what is expected and tries to do it as
smartly as possible.

+ remove occurrences of two blank comment lines
  next to each other after Id string line removed.
+ remove entire comment blocks which only exited to
  contain CVS Ids
+ If the processing left a blank line at the top of
  a file, it was removed.
2012-05-11 08:44:13 -05:00
Sebastian Huber
b467782b53 libblock: Add rtems_bdbuf_set_block_size()
The new function rtems_bdbuf_set_block_size() must be used to set the
block size of a disk device.  It will check if the block size is valid
and set the new fields block_to_media_block_shift and bds_per_group of
the rtems_disk_device structure.  This helps to avoid complex arithmetic
operations in the block device buffer get and read path.
2012-04-12 10:42:43 +02:00
Chris Johns
8aa608df32 2010-05-18 Chris Johns <chrisj@rtems.org>
* libblock/src/diskdevs.c, libblock/include/rtems/blkdev.h,
        libblock/src/bdbuf.c: PR 1448/filesystem.

        * libblock/include/rtems/blkdev.h, libblock/src/bdbuf.c: PR
        1514/filesystem.
2010-05-18 02:14:05 +00:00
Sebastian Huber
c8522fd2c4 2010-05-17 Oleg Kravtsov <Oleg.Kravtsov@oktetlabs.ru>
PR 1449/cpukit
	* libblock/src/diskdevs.c: rtems_disk_next() will now implicitly
	obtain the returned disk.
	* libblock/include/rtems/diskdevs.h: Documentation.
2010-05-17 08:08:30 +00:00
Sebastian Huber
b1d4e42edd 2010-04-29 Sebastian Huber <sebastian.huber@embedded-brains.de>
PR1507
	* libblock/src/bdbuf.c: Avoid NULL pointer access.

	* libblock/src/diskdevs.c: Fixed bounds check in rtems_disk_next().
2010-04-29 11:34:59 +00:00
Thomas Doerfler
bdac0eed0c fixed disk delete
Obtain/release disk during open/close
2010-04-09 12:28:24 +00:00
Joel Sherrill
391b4dda25 2010-03-11 Joel Sherrill <joel.sherrill@oarcorp.com>
* ftpd/ftpd.c, httpd/uemf.c, httpd/um.c, httpd/webs.c,
	httpd/websuemf.c, libblock/src/diskdevs.c,
	libmisc/capture/capture-cli.c, libmisc/monitor/mon-network.c,
	libmisc/shell/hexdump-odsyntax.c, libmisc/shell/main_ifconfig.c,
	libmisc/uuid/parse.c, libnetworking/lib/ftpfs.c,
	libnetworking/libc/gethostbyht.c, libnetworking/libc/getnetnamadr.c,
	libnetworking/libc/inet_network.c,
	libnetworking/rtems/rtems_mii_ioctl.c,
	score/src/objectgetnameasstring.c: Fix warnings for ctype methods.
2010-03-11 19:12:30 +00:00
Chris Johns
cca94a248b 2010-02-19 Chris Johns <chrisj@rtems.org>
* libblock/src/diskdevs.c: Create the devices as block devices.

        * libmisc/shell/main_debugrfs.c, libmisc/shell/main_mkrfs.c,
        libmisc/shell/main_mount_rfs.c: New.

        * libmisc/shell/main_msdosfmt.c: Change the command to mkdos and
        alias the old name.

        * libmisc/shell/shellconfig.h, libmisc/Makefile.am: Add RFS
        support.

        * libfs/src/rfs/rtems-rfs-shell.c,
        libfs/src/rfs/rtems-rfs-shell.h: Move the format command code into
        the shell file.
2010-02-19 03:23:11 +00:00
Ralf Corsepius
18daff9b95 Whitespace removal. 2009-11-29 13:35:32 +00:00
Thomas Doerfler
e41369ef8c * libblock/include/rtems/diskdevs.h: Documentation. Added field to
rtems_disk_device.
        * libblock/include/rtems/blkdev.h: New request code
        RTEMS_BLKIO_DELETED.
        * libblock/src/diskdevs.c: Major rewrite.  Changed the way disks are
        deleted.  Disks will be now deleted if they are not in use or upon
        last release.  The IO control handler will be invoked if a physical
        disk is deleted with the RTEMS_BLKIO_DELETED request code.  Logical
        disks increase now the usage count of the associated physical disk.
        * libblock/include/rtems/ramdisk.h: Documentation.
        * libblock/src/ramdisk-driver.c: Compile trace support conditionally.
2009-10-20 07:53:19 +00:00
Thomas Doerfler
b96e09cb42 * libblock/include/rtems/diskdevs.h: Added driver data pointer to IO
control function.  The IO control handler takes now the disk device as
        first parameter instead of the physical device number.
        * cpukit/libblock/include/rtems/blkdev.h, libblock/src/bdbuf.c,
        libblock/src/blkdev.c, libblock/src/diskdevs.c, libblock/src/nvdisk.c,
        libblock/src/flashdisk.c, libblock/src/ramdisk.c: Update for block
        device API change.
2009-10-13 07:58:33 +00:00
Chris Johns
eb649786c8 2009-10-08 Chris Johns <chrisj@rtems.org>
* Makefile.am, preinstall.am: Added statvfs.h.
        * libcsupport/Makefile.am: Add statvfs.c.
        * libcsupport/include/sys/statvfs.h, libcsupport/src/statvfs.c:
        New.
        * libcsupport/include/rtems/libio.h: Add a file system handler for
        the statvfs call.
        * libfs/src/devfs/devfs_init.c, libfs/src/dosfs/msdos_init.c,
        libfs/src/imfs/imfs_init.c, libfs/src/nfsclient/src/nfs.c: Set the
        statvfs handler to NULL.
        * include/rtems/fs.h: Add a second node access field for the RFS
        file system to hold a directory offset while the existing field
        holds the inode number. This save a rescan of the directory when
        working with directories.
        * libblock/include/rtems/bdbuf.h: Added references and user fields
        to the buffer descriptor.
        * libblock/src/bdbuf.c: Added dynamic buffer support for different
        block sizes. Fixed a number of bugs.
        * libblock/src/blkdev.c: Release the disk device on an error.
        * libblock/src/diskdevs.c: Set the block size to the media block
        size during initialisation of the disk device.
        * libblock/src/flashdisk.c, libblock/src/nvdisk.c,
        libblock/src/ramdisk.c: Updated the drivers to handle variable
        block sizes.
        * libfs/src/dosfs/fat.c, libfs/src/dosfs/fat.h: Release any
        buffers when an error occurs. The FAT buffer layer hangs onto a
        single buffer while mounted. This should be fixed.
        * sapi/inline/rtems/chain.inl: Added rtems_chain_set_off_chain,
        rtems_chain_is_node_off_chain, and rtems_chain_previous.
        * score/inline/rtems/score/chain.inl: Added _Chain_Set_off_chain,
        and _Chain_Is_node_off_chain.
        * libmisc/shell/main_ln.c, libmisc/shell/main_mknod.c,
        libmisc/shell/mknod-pack_dev.c, libmisc/shell/mknod-pack_dev.h:
        New shell commands.
        * libmisc/Makefile.am, libmisc/shell/shellconfig.h: Added ln and
        mknod commands.
        * libmisc/shell/hexdump-display.c: Fixed the reopen bug which
        showed up as a free with a bad pointer.
        * libmisc/shell/main_mount.c: List the user adding file system
        when listing the available file systems to mount.
        * libmisc/shell/utils-cp.c: Remove the fixed static copy buffer
        and use a large dynamic buffer.
        * score/inline/rtems/score/address.inl, score/src/coremsgsubmit.c,
        score/src/objectallocate.c, score/src/objectfree.c: Remove
        warnings.
2009-10-08 07:07:36 +00:00
Chris Johns
0d15414ed6 009-08-05 Chris Johns <chrisj@rtems.org>
* libmisc/dummy/dummy-networking.c: New.
        * libmisc/dummy/dummy.c, libmisc/Makefile.am: Move
        trhe networking configuration into a separate file so
        configuration varations do not cause conflicts.
        * score/inline/rtems/score/object.inl,
        score/include/rtems/score/object.h: Remove warnings.
        * score/inline/rtems/score/object.inl: Add _Chain_First,
        _Chain_Last, _Chain_Mext, and _Chain_Previous.
        * sapi/inline/rtems/chain.inl: Add rtems_chain_first,
        rtems_chain_last, rtems_chain_mext, and rtems_chain_previous.
        * libblock/include/rtems/diskdevs.h: Remove the bdbuf pool id and
        block_size_log2. Add media_block_size.
        * libblock/src/diskdevs.c: Remove size restrictions on block
        size. Add media block size initialisation. Remove comment to clean
        up the bdbuf cache.
        * libblock/src/blkdev.c: Remove references to
        block_size_log2. Allow any block size.
        * libblock/include/rtems/bdbuf.h, libblock/src/bdbuf.c: Remove all
        references to pools and make the cache handle demand driver
        variable buffer size allocation. Added worker threads support the
        swapout task.
        * sapi/include/confdefs.h: Updated the bdbuf configutation.
2009-08-05 00:00:54 +00:00
Joel Sherrill
4670d91898 2009-05-15 Sebastian Huber <sebastian.huber@embedded-brains.de>
* Doxygen.in: Fixed project name.  Added project number.  Enabled auto
	brief.  Disabled include graphs.
	* include/rtems/irq-extension.h, libblock/include/rtems/bdpart.h,
	libblock/include/rtems/bdbuf.h, libblock/include/rtems/bdpart.h,
	libblock/include/rtems/blkdev.h, libblock/include/rtems/diskdevs.h,
	libblock/include/rtems/ramdisk.h, libblock/src/bdbuf.c,
	libblock/src/blkdev.c, libblock/src/diskdevs.c, libblock/src/ramdisk.c:
	Documentation.
	* libblock/src/bdpart.c: Documentation.  Fixed NULL pointer access.
2009-05-15 12:52:12 +00:00
Chris Johns
57aa979e4f 2009-04-29 Sebastian Huber <sebastian.huber@embedded-brains.de>
* sapi/include/confdefs.h, libblock/include/rtems/bdbuf.h: Changed
        type of rtems_bdbuf_pool_configuration_size to size_t.

        * libblock/include/rtems/bdbuf.h, libblock/include/rtems/blkdev.h,
        libblock/include/rtems/diskdevs.h, libblock/src/bdbuf.c,
        libblock/src/blkdev.c, libblock/src/diskdevs.c: Buffer pool
        allocation is now cache aligned.  The cache functions are
        currently not available on all platforms so the cache line size is
        fixed to 32 bytes for now.  Changed various integer types which
        refer to block sizes, numbers and indexes.  Fixed logical block
        indexes in buffer get and read function.  It is now possible to
        delete logical disks.  Modified documentation
2009-04-29 08:51:07 +00:00
Ralf Corsepius
4f971343a5 Convert to using "bool". 2008-09-01 07:44:48 +00:00
Ralf Corsepius
e03c37ae5b s/rtems_boolean/bool/g. 2008-08-25 15:07:58 +00:00
Joel Sherrill
cec5c069b0 2008-08-21 Joel Sherrill <joel.sherrill@OARcorp.com>
* libblock/include/rtems/bdbuf.h, libblock/include/rtems/diskdevs.h,
	libblock/src/bdbuf.c, libblock/src/blkdev.c, libblock/src/diskdevs.c,
	libblock/src/ramdisk.c: Eliminate sign mismatch warnings.
2008-08-21 16:17:35 +00:00
Chris Johns
b7898e271c 2008-08-06 Brett Swimley <brett.swimley@aedbozeman.com>
* libblock/src/diskdevs.c: PR1192. Update the disktap pointer
	after the realloc.
2008-08-06 04:17:46 +00:00
Chris Johns
904ced08bb 2008-08-06 Till Straumann <strauman@slac.stanford.edu>
* libblock/src/diskdevs.c: PR1269. Delete the semaphore rather
	than release it.
2008-08-06 04:04:59 +00:00
Chris Johns
3899a5379f 2008-07-29 Chris Johns <chrisj@rtems.org>
* libblock/Makefile.am: Removed src/show_bdbuf.c.

	* libblock/src/show_bdbuf.c: Removed.

	* libblock/include/rtems/bdbuf.h, cpukit/libblock/src/bdbuf.c:
	Rewritten the bdbuf code. Remove pre-emption disable, score
	access, fixed many bugs and increased performance.

	* libblock/include/rtems/blkdev.h: Added
	RTEMS_BLKDEV_CAPABILITIES block device request. Cleaned up
	comments. Added block and user fields to the sg buffer
	request. Move to rtems_* namespace.

	* libblock/include/rtems/diskdevs.h,
	cpukit/libblock/src/diskdevs.c: Move to rtems_* namespace. Add a
	capabilities field for drivers. Change rtems_disk_lookup to
	rtems_disk_obtain to match the release call. You do not lookup and
	release a disk, you obtain and release a disk.

	* libblock/include/rtems/ide_part_table.h,
	libblock/include/rtems/ramdisk.h, libblock/src/ide_part_table.c:
	Move to rtems_* namespace.

	* libblock/include/rtems/nvdisk.h: Formatting change.

	* libblock/src/blkdev.c: Move to rtems_* namespace. Change
	rtems_disk_lookup to rtems_disk_obtain

	* libblock/src/flashdisk.c: Move to rtems_* namespace. Use the new
	support for the block number in the scatter/grather request
	struct. This allows non-continuous buffer requests for those
	drivers that can support increasing performance.

	* libblock/src/nvdisk.c: Move to rtems_* namespace. Removed
	warnings. Added better error checking. Fixed some comments.

	* libblock/src/ramdisk.c: Move to rtems_* namespace. Added some
	trace functions to help debugging upper layers. Use the new
	support for the block number in the scatter/grather request
	struct. This allows non-continuous buffer requests for those
	drivers that can support increasing performance.

	* libfs/src/dosfs/fat.c, libfs/src/dosfs/fat.h: Use new chains
	API. Removed temporary hack and changed
	set_errno_and_return_minus_one to
	rtems_set_errno_and_return_minus_one. Move fat_buf_access from
	header and stopped it being inlined. Updated to libblock changes.

	* libfs/src/dosfs/fat_fat_operations.c,
	libfs/src/dosfs/fat_file.c, libfs/src/dosfs/msdos_create.c,
	libfs/src/dosfs/msdos_dir.c, libfs/src/dosfs/msdos_eval.c,
	libfs/src/dosfs/msdos_file.c, libfs/src/dosfs/msdos_format.c,
	libfs/src/dosfs/msdos_free.c, libfs/src/dosfs/msdos_initsupp.c,
	libfs/src/dosfs/msdos_misc.c, libfs/src/dosfs/msdos_mknod.c: Use
	new chains API. Removed temporary hack and changed
	set_errno_and_return_minus_one to
	rtems_set_errno_and_return_minus_one. Updated to libblock changes.

	* libmisc/Makefile.am: Add new ls and rm command files.

	* libmisc/shell/cmp-ls.c, libmisc/shell/extern-ls.h,
	libmisc/shell/filemode.c, libmisc/shell/print-ls.c,
	libmisc/shell/pwcache.c, libmisc/shell/utils-ls.c,
	libmisc/shell/vis.c, shell/vis.h: New.

	* libmisc/shell/extern-cp.h, libmisc/shell/main_cp.c,
	libmisc/shell/utils-cp.c: Fixed the usage call bug.

	* libmisc/shell/main_blksync.c: Updated to the new block IO ioctl
	command.

	* libmisc/shell/main_ls.c, libmisc/shell/main_rm.c: Updated to BSD
	commands with more features.

	* score/src/coremutex.c: Fix the strick order mutex code.

	* libmisc/shell/shell.c: Change shell tasks mode to be timeslice
	and no ASR.

	* sapi/include/confdefs.h: Change ata_driver_task_priority to
	rtems_ata_driver_task_priority. Add the new BD buf cache
	parameters with defaults.

	* score/src/interr.c: Do not return if the CPU halt call returns.
2008-07-29 02:21:15 +00:00
Thomas Doerfler
bf95ccb506 Added const qualifier to various pointers and data tables to
reduce size of data area.
	IMFS: Fixed creation of symbolic links to avoid a compiler warning.
	DOSFS: Use LibBlock instead of read() to read the boot record.
2008-05-27 10:34:15 +00:00
Ralf Corsepius
08885d631d Fix typo. 2005-01-05 18:17:01 +00:00
Ralf Corsepius
8b961495bb Remove stray white spaces. 2004-04-17 08:15:17 +00:00
Ralf Corsepius
048dcd2b3a Remove stray white spaces. 2004-04-15 14:50:20 +00:00
Ralf Corsepius
006fa1ef77 2003-11-20 Ralf Corsepius <corsepiu@faw.uni-ulm.de>
* Makefile.am: AM_CPPFLAGS += -I$(top_builddir).
	Use AM_CPPFLAGS instead of AM_CFLAGS.
	* src/ata.c: Include config.h.
	* src/bdbuf.c: Ditto.
	* src/blkdev.c: Ditto.
	* src/diskdevs.c: Ditto.
	* src/ide_part_table.c: Ditto.
	* src/ramdisk.c: Ditto.
2003-11-20 12:14:50 +00:00
Ralf Corsepius
f1c22e019f 2002-11-15 Ralf Corsepius <corsepiu@faw.uni-ulm.de>
* src/diskdevs.c: Include <unistd.h> to remove warning.
2002-11-15 14:18:28 +00:00
Joel Sherrill
e51bd967cd 2002-02-28 Joel Sherrill <joel@OARcorp.com>
* Submitted by Victor V. Vengerov <vvv@oktet.ru> and merged
	into the RTEMS source.
	* ChangeLog, Makefile.am, README, configure.ac, include/Makefile.am,
	include/rtems/bdbuf.h, include/rtems/blkdev.h, include/rtems/diskdevs.h,
	include/rtems/ramdisk.h, include/rtems/.cvsignore, include/.cvsignore,
	src/Makefile.am, src/bdbuf.c, src/blkdev.c, src/diskdevs.c,
	src/ramdisk.c, src/.cvsignore, .cvsignore: New files.
2002-02-28 20:39:54 +00:00