Commit Graph

350 Commits

Author SHA1 Message Date
Chris Johns
731186395a 2009-01-23 Chris Johns <chrisj@rtems.org>
* libmisc/shell/shell.c: Fix command line parsing of valid
	characters.
2009-01-23 00:12:31 +00:00
Ralf Corsepius
031deada15 Add __attribute__((unused)) to unused function args. 2009-01-02 13:04:13 +00:00
Ralf Corsepius
b7cfd627b3 Add missing initializers. 2008-12-23 05:00:57 +00:00
Joel Sherrill
eb96196183 2008-12-19 Sebastian Huber <sebastian.huber@embedded-brains.de>
* libblock/src/ide_part_table.c: Fixed NULL pointer access.
	* libmisc/monitor/mon-command.c, libmisc/monitor/mon-editor.c,
	libmisc/monitor/mon-monitor.c, libmisc/monitor/monitor.h,
	libmisc/shell/cmds.c: The list of registered monitor commands is now
	private and only accessible via a lookup and iterate function.
2008-12-19 14:59:35 +00:00
Joel Sherrill
b6bebc3bed 2008-12-18 Joel Sherrill <joel.sherrill@oarcorp.com>
* libmisc/shell/cmds.c: Revert back to public. Used to execute monitor
	commands in test code.
2008-12-18 17:14:26 +00:00
Joel Sherrill
e41eaa881a 2008-12-18 Sebastian Huber <sebastian.huber@embedded-brains.de>
* libmisc/serdbg/termios_printk.c, libmisc/serdbg/termios_printk.h:
	Fixed incompatible return value.

	* libmisc/cpuuse/cpuusagereport.c: Changed output format.

	* libmisc/Makefile.am, libmisc/monitor/mon-editor.c: New file.

	* libmisc/capture/capture-cli.c, libmisc/monitor/mon-command.c,
	libmisc/monitor/mon-monitor.c, libmisc/monitor/mon-object.c,
	libmisc/monitor/mon-prmisc.c, libmisc/monitor/mon-symbols.c,
	libmisc/monitor/monitor.h, libmisc/shell/cat_file.c,
	libmisc/shell/cmds.c, libmisc/shell/internal.h,
	libmisc/shell/main_help.c, libmisc/shell/shell.c,
	libmisc/shell/shell.h, libmisc/shell/shell_cmdset.c,
	libmisc/shell/shell_getchar.c, libmisc/shell/str2int.c: Various global
	data is now read only.  Added 'const' qualifier to many pointer
	parameters.  It is no longer possible to remove monitor commands.
	Moved monitor line editor into a separate file to avoid unnecessary
	dependencies.
2008-12-18 15:25:27 +00:00
Joel Sherrill
e47948c218 2008-12-16 Joel Sherrill <joel.sherrill@oarcorp.com>
* libmisc/monitor/mon-config.c: Configuration table entry
	work_space_size was not removed.
2008-12-16 23:36:19 +00:00
Joel Sherrill
26fb4aadcd 2008-12-16 Joel Sherrill <joel.sherrill@oarcorp.com>
* libblock/src/bdbuf.c, libmisc/capture/capture-cli.c,
	libmisc/capture/capture.c, libmisc/mw-fb/mw_uid.c,
	rtems/include/rtems/rtems/support.h, score/Makefile.am,
	score/include/rtems/score/tod.h, score/src/coretod.c,
	score/src/coretodtickle.c: Eliminate all public use of TOD conversion
	routines. Eliminate _TOD_Microseconds_per_tick and let every place
	use the field directly from the Configuration Table. This required
	moving some methods from macros to bodies.
	* score/src/coretodmsecstoticks.c, score/src/coretodtickspersec.c,
	score/src/coretodusectoticks.c: New files.
2008-12-16 20:53:34 +00:00
Joel Sherrill
aac75d3b9b 2008-12-15 Joel Sherrill <joel.sherrill@oarcorp.com>
* itron/include/rtems/itron/itronapi.h, libmisc/capture/capture.c,
	libmisc/monitor/mon-config.c, libmisc/monitor/mon-driver.c,
	libmisc/monitor/mon-itask.c, libmisc/monitor/mon-mpci.c,
	posix/include/rtems/posix/config.h,
	posix/include/rtems/posix/posixapi.h,
	rtems/include/rtems/rtems/config.h,
	rtems/include/rtems/rtems/rtemsapi.h, rtems/src/taskinitusers.c,
	sapi/include/confdefs.h, sapi/include/rtems/config.h,
	sapi/include/rtems/init.h, sapi/src/exinit.c, sapi/src/itronapi.c,
	sapi/src/posixapi.c, sapi/src/rtemsapi.c, score/src/isr.c,
	score/src/thread.c, score/src/threadcreateidle.c,
	score/src/threadstackallocate.c, score/src/threadstackfree.c,
	score/src/wkspace.c: Eliminate pointers to API configuration tables
	in the main configuration table. Reference the main configuration
	table and the API configuration tables directly using the confdefs.h
	version rather than obtaining a pointer to it. This eliminated some
	variables, a potential fatal error, some unnecessary default
	configuration structures. Overall, about a 4.5% reduction in the code
	size for minimum and hello on the SPARC.
2008-12-15 19:21:01 +00:00
Ralf Corsepius
1cb54d1f38 #include <stdint.h> instead of <rtems/stdint.h>. 2008-12-11 00:47:56 +00:00
Ralf Corsepius
6706278315 Remove stray "\". 2008-12-10 23:01:51 +00:00
Joel Sherrill
c16bcc009b 2008-12-08 Joel Sherrill <joel.sherrill@oarcorp.com>
* libcsupport/src/__times.c, libmisc/cpuuse/cpuusagereport.c,
	libmisc/cpuuse/cpuusagereset.c, posix/src/clockgettime.c,
	posix/src/pthread.c, posix/src/timersettime.c,
	rtems/include/rtems/rtems/ratemon.h,
	rtems/src/clockgetsecondssinceepoch.c, rtems/src/clockgetuptime.c,
	rtems/src/ratemongetstatus.c, rtems/src/ratemonperiod.c,
	rtems/src/ratemonreportstatistics.c, rtems/src/taskwakewhen.c,
	rtems/src/timerfirewhen.c, rtems/src/timerserver.c,
	rtems/src/timerserverfirewhen.c, score/Makefile.am,
	score/preinstall.am, score/include/rtems/score/thread.h,
	score/include/rtems/score/tod.h, score/src/coretod.c,
	score/src/coretodget.c, score/src/coretodgetuptime.c,
	score/src/coretodset.c, score/src/coretodtickle.c,
	score/src/threaddispatch.c, score/src/threadinitialize.c: Add
	SuperCore handler Timestamp to provide an opaque class for the
	representation and manipulation of uptime, time of day, and the
	difference between two timestamps. By using SuperCore Timestamp, it
	is clear which methods and APIs really have to be struct timespec and
	which can be in an optimized native format.
	* score/include/rtems/score/timestamp.h,
	score/src/coretodgetuptimetimespec.c: New files.
2008-12-08 19:41:31 +00:00
Joel Sherrill
1fae7b43d7 2008-10-15 Joel Sherrill <joel.sherrill@oarcorp.com>
PR 1331/networking
	* libmisc/shell/shell.c, telnetd/check_passwd.c, telnetd/telnetd.c,
	telnetd/telnetd.h: Improve comments and explanation of options to
	rtems_telnetd_initialize. Add extra newline to login sequence from
	shell.
2008-10-15 17:37:16 +00:00
Joel Sherrill
9a79f1b42c 2008-10-02 Joel Sherrill <joel.sherrill@oarcorp.com>
* libmisc/shell/utils-cp.c: Do not put a 64K buffer on the stack.
2008-10-02 21:31:54 +00:00
Joel Sherrill
2cc1b43b57 2008-10-02 Joel Sherrill <joel.sherrill@oarcorp.com>
* libmisc/monitor/mon-monitor.c, rtems/include/rtems/rtems/types.h: Do
	not have fp context type when no hardware or software floating point
	is available.
2008-10-02 21:00:37 +00:00
Joel Sherrill
b079fe33e4 2008-10-02 Joel Sherrill <joel.sherrill@oarcorp.com>
* libmisc/shell/main_cp.c, libmisc/shell/main_ls.c,
	libmisc/shell/main_mv.c, libmisc/shell/main_netstats.c,
	libmisc/shell/main_rm.c, libmisc/shell/shell_script.c: Newlib >
	1.16.0 requires __need_getopt_newlib to be defined to get visibility
	on the reentrancy extensions.
2008-10-02 20:16:16 +00:00
Joel Sherrill
caf0e53e8f 2008-10-01 Gene Smith <gene.smith@siemens.com>
PR 1328/cpukit
	* libmisc/shell/main_mdump.c, libmisc/shell/main_mwdump.c: Fix printing
	of more than 256 bytes.
2008-10-01 20:02:34 +00:00
Joel Sherrill
af70ed5b19 2008-09-19 Joel Sherrill <joel.sherrill@oarcorp.com>
* libmisc/shell/main_mallocinfo.c, libmisc/shell/main_wkspaceinfo.c:
	Include information on whether C Program Heap and RTEMS Workspace are
	separate.
2008-09-19 16:15:21 +00:00
Joel Sherrill
a5b6cdda58 2008-09-08 Joel Sherrill <joel.sherrill@oarcorp.com>
* libcsupport/include/rtems/libio_.h, libcsupport/src/libio_sockets.c,
	libfs/src/dosfs/fat.h, libfs/src/dosfs/msdos.h,
	libfs/src/imfs/deviceio.c, libmisc/monitor/mon-monitor.c,
	libmisc/monitor/mon-object.c, libmisc/monitor/mon-symbols.c,
	libmisc/monitor/monitor.h, libmisc/stackchk/internal.h,
	rtems/inline/rtems/rtems/part.inl, score/include/rtems/system.h,
	score/include/rtems/score/bitfield.h, score/src/mpci.c,
	score/src/objectextendinformation.c, score/src/threadmp.c: Remove
	extraneous spaces.
2008-09-08 15:19:34 +00:00
Ralf Corsepius
bd5b34e564 Add missing initializers. 2008-09-07 07:02:47 +00:00
Joel Sherrill
ff9059586c 2008-09-03 Cindy Cicalese <cicalese@mitre.org>
* libmisc/shell/shell.c: FALSE accidentally changed to true in switch
	to bool type.
2008-09-03 18:57:51 +00:00
Ralf Corsepius
11672356e7 Convert to using "bool". 2008-09-01 11:28:56 +00:00
Ralf Corsepius
2326f0d934 Convert to using "bool". 2008-09-01 09:35:34 +00:00
Ralf Corsepius
937ec606fb Convert to using "bool". 2008-09-01 09:12:43 +00:00
Joel Sherrill
f3db4ac83a 2008-08-27 Joel Sherrill <joel.sherrill@OARcorp.com>
* libmisc/Makefile.am, libmisc/shell/shell.c, libmisc/shell/shell.h:
	Split out rtems_shell_get_prompt() so it can be overridden by the
	user.
	* libmisc/shell/shell_getprompt.c: New file.
2008-08-27 12:48:41 +00:00
Ralf Corsepius
135910afe0 Convert to using bool. 2008-08-26 12:21:36 +00:00
Ralf Corsepius
347a3feee3 Stop using old-style function-definitions. 2008-08-25 11:03:14 +00:00
Ralf Corsepius
d024ff49c4 Use memset instead of bzero. 2008-08-21 13:06:53 +00:00
Ralf Corsepius
9ac81fe2ea 2008-08-21 Ralf Corsépius <ralf.corsepius@rtems.org>
* libmisc/shell/internal.h: Don't include "config.h".
	Adjust header guard.
2008-08-21 12:30:23 +00:00
Ralf Corsepius
575babcf49 Include "config.h". 2008-08-21 12:29:02 +00:00
Ralf Corsepius
86f89be4a3 Use memset instead of bzero. 2008-08-21 06:07:07 +00:00
Joel Sherrill
aa4a3f1ac4 2008-08-20 Joel Sherrill <joel.sherrill@OARcorp.com>
* libmisc/dummy/dummy.c: Add missing initializers.
	* score/src/threadinitialize.c: Change type of loop counter.
2008-08-20 22:24:09 +00:00
Joel Sherrill
ccec63e98d 2008-08-20 Joel Sherrill <joel.sherrill@OARcorp.com>
* libcsupport/src/error.c, libmisc/dummy/dummy.c,
	rtems/src/rtemsobjectgetapiclassname.c,
	rtems/src/rtemsobjectgetapiname.c: Add 0 for missing initializers.
2008-08-20 19:31:24 +00:00
Joel Sherrill
1487880d2c 2008-08-18 Joel Sherrill <joel.sherrill@oarcorp.com>
* libcsupport/include/rtems/libcsupport.h, libcsupport/src/scandir.c,
	libmisc/cpuuse/cpuusagereset.c, libmisc/monitor/mon-monitor.c,
	libmisc/serdbg/serdbg.c, libmisc/serdbg/serdbg.h,
	libnetworking/netinet/in_cksum_powerpc.h, shttpd/compat_rtems.h: Fix
	warnings.
2008-08-18 21:16:42 +00:00
Joel Sherrill
3b14b7adab 2008-08-05 Sebastian Huber <sebastian.huber@embedded-brains.de>
* libmisc/monitor/monitor.h, rtems/include/rtems/rtems/tasks.h,
	score/include/rtems/score/thread.h, score/src/threadreset.c,
	score/src/threadrestart.c, score/src/threadstart.c: New type
	Thread_Entry_numeric_type for numeric arguments in thread entry
	functions with at least one numeric argument.
2008-08-08 13:50:28 +00:00
Chris Johns
8192e4ff61 2008-08-07 Chris Johns <chrisj@rtems.org>
* libcsupport/src/_rename_r.c: Fixed return code bug. Add a check
	to see if the 'to' path was a directory and removed the directory.

	* libmisc/Makefile.am, libmisc/shell/shellconfig.h: Added the mv command.

	* libmisc/shell/main_mv.c, libmisc/shell/pathnames-mv.h: New.
2008-08-07 02:23:11 +00:00
Joel Sherrill
46cb968176 2008-08-05 Joel Sherrill <joel.sherrill@OARcorp.com>
PR 741/networking
	* libmisc/dummy/dummy.c: Add dummy network configuration.
2008-08-05 16:33:03 +00:00
Joel Sherrill
f773c0122a 2008-08-04 Sebastian Huber <sebastian.huber@embedded-brains.de>
* rtems/include/rtems/rtems/sem.h, rtems/src/semobtain.c:
	Changed option set type to rtems_option.

	* score/src/objectgetinfo.c: Check return value of
	_Objects_API_maximum_class().

	* libmisc/monitor/mon-mpci.c, libmisc/monitor/monitor.h,
	rtems/include/rtems/rtems/message.h, rtems/src/msgmp.c,
	rtems/src/msgqallocate.c, rtems/src/msgqbroadcast.c,
	rtems/src/msgqcreate.c, rtems/src/msgqreceive.c, rtems/src/msgqsend.c,
	rtems/src/msgqurgent.c, score/include/rtems/score/coremsg.h,
	score/include/rtems/score/mpci.h, score/include/rtems/score/thread.h,
	score/inline/rtems/score/coremsg.inl, score/src/coremsg.c,
	score/src/coremsgbroadcast.c, score/src/coremsgseize.c,
	score/src/coremsgsubmit.c:
	Removed parameters of _Message_queue_Allocate().  Changed option set
	type to rtems_option.  Changed type of maximum message and packet size
	to size_t.  Changed the input buffer type for message send functions to
	"const void *".  Changed the pointer to the second return argument in
	the thread wait information to a union.  This union can contain a
	pointer to an immutable or a mutable object.  This is somewhat fragile.
	An alternative would be to add a third pointer for immutable objects,
	but this would increase the structure size.
2008-08-05 13:32:39 +00:00
Ralf Corsepius
ee0c82f413 Add missing prototypes. 2008-08-02 05:16:26 +00:00
Joel Sherrill
23bfd0cd27 2008-07-31 Joel Sherrill <joel.sherrill@OARcorp.com>
* libmisc/shell/main_rm.c: sys/mount.h is not available when networking
	is disabled but luckily it is not even needed to compile.
2008-07-31 15:02:48 +00:00
Ralf Corsepius
f48873dfec Add missing prototypes. 2008-07-31 06:31:20 +00:00
Ralf Corsepius
0929315249 Remove classinfo_tester. 2008-07-31 06:31:04 +00:00
Joel Sherrill
a4a95e61b1 2008-07-29 Tim Cussins <timcussins@eml.cc>
* ChangeLog, libmisc/monitor/mon-object.c: Add mising RTEMS_POSIX_API
	conditional.
2008-07-29 20:54:51 +00:00
Ralf Corsepius
2b6436090d Remove stray arg from function call. 2008-07-29 11:51:37 +00:00
Ralf Corsepius
30b8ac1cc4 Add missing prototypes. 2008-07-29 11:49:50 +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
Joel Sherrill
e6ee171252 2008-07-23 Joel Sherrill <joel.sherrill@oarcorp.com>
* libmisc/shell/shell_script.c: Clean up code for command not found
	including the error message.
2008-07-23 20:28:13 +00:00
Joel Sherrill
bd5762ddfc 2008-07-23 Joel Sherrill <joel.sherrill@oarcorp.com>
* libmisc/monitor/mon-extension.c, libmisc/monitor/mon-itask.c,
	libmisc/monitor/mon-part.c, libmisc/monitor/mon-prmisc.c,
	libmisc/monitor/mon-queue.c, libmisc/monitor/mon-region.c,
	libmisc/monitor/mon-sema.c, libmisc/monitor/mon-task.c,
	libmisc/monitor/monitor.h: Use rtems_object_get_name() instead of
	internal routine. This makes it possible to also print string names
	of POSIX objects. Adjust task report to realign since we can have
	longer names.
2008-07-23 19:51:08 +00:00
Joel Sherrill
00a2d366a6 2008-07-17 Joel Sherrill <joel.sherrill@oarcorp.com>
* libmisc/monitor/mon-monitor.c, libmisc/monitor/mon-object.c,
	libmisc/monitor/monitor.h, libmisc/shell/main_chmod.c,
	libmisc/shell/main_tty.c, libmisc/shell/main_umask.c,
	libmisc/shell/main_whoami.c: Add pthread command to monitor when
	POSIX is enabled. Remove include of rtems/monitor.h from files not
	related.
2008-07-17 15:43:56 +00:00
Joel Sherrill
c702dd809e 2008-07-16 Joel Sherrill <joel.sherrill@oarcorp.com>
* libmisc/shell/shellconfig.h, libmisc/stackchk/stackchk.h: Fix typos.
2008-07-16 20:32:23 +00:00