summaryrefslogtreecommitdiffstats
path: root/cpukit/libmisc (follow)
Commit message (Collapse)AuthorAgeFilesLines
* cpukit/fdt: Free index before containerHEADmasterKinsey Moore34 min.1-2/+2
| | | | | | | Ensure that the index is released before the structure containing it is freed and NULLed. Updates #4460
* cpukit/fdt: Check correct allocationKinsey Moore34 min.1-1/+1
| | | | | | | | The second allocation check was mistakenly rechecking the first allocation. It now checks the correct allocation and ensures that names is not NULL. Updates #4462
* libmisc/shell: Add an 'rtems' command to report a running buildChris Johns2022-08-031-0/+156
| | | | - Report version, cpu, bsp, tools and options.
* cpukit: Fixes for GCC 12 warningsChris Johns2022-06-152-0/+6
| | | | Updates #6442
* cpukit/libmisc: Add file headers and licensesRyan Long2022-05-043-3/+90
| | | | | These files had no file header, copyright, or license. Based on git history, added appropriate copyright and license.
* shell: Add rtems_shell_run_main_loop()Sebastian Huber2022-04-061-0/+25
| | | | | | | In contrast to rtems_shell_main_loop(), this new function does not perform all sorts of initialization based on environment settings. For example, due to the use of isatty() in rtems_shell_main_loop() it is impossible to run an interactive shell through a socket connection.
* shell: Move rtems_shell_init_environment() callSebastian Huber2022-04-061-2/+2
| | | | | Move rtems_shell_init_environment() call to rtems_shell_set_shell_env() since this function uses the POSIX key.
* shell: Add and use SHELL_MAGICSebastian Huber2022-04-061-3/+5
|
* shell: Simplify rtems_shell_dup_current_env()Sebastian Huber2022-04-061-10/+7
| | | | Do not assign members already provided by the global environment.
* shell: Refactor rtems_shell_main_loop()Sebastian Huber2022-04-061-134/+150
| | | | | Disentangle the shell main loop from setup and teardown code. Move main loop into shell_main_loop().
* shell: Move line editor output checkSebastian Huber2022-04-061-44/+38
| | | | | Move call to isatty() to caller of rtems_shell_line_editor(). This avoids a dependency on isatty() in rtems_shell_line_editor().
* libmisc/untar: Use a larger block size to read and write filesChris Johns2022-04-061-20/+33
| | | | | | | - A larger block size lets files systems work better. On JFFS a 512 byte compressed block means lots of small flash updates Closes #4635
* Update email address of Fernando Ruiz Casas to <fruizcasas@gmail.com>Joel Sherrill2022-04-0531-158/+211
| | | | This was requested to be executed prior to relicensing to BSD-2.
* cpukit/libmisc/dumpbuf/dumpbuf.c: Manually change license to BSD-2Joel Sherrill2022-04-021-3/+20
| | | | | | | There was a typo in the license text and this file was missed by the script. Updates #3053
* cpukit/libmisc/monitor/: Manually change to BSD-2 licenseJoel Sherrill2022-03-2419-50/+562
| | | | | | | | | | | | | | This code did not have any copyrights or licenses and a bit of archeology was needed to determine authorship. This code was in the initial import into the RTEMS CVS repository when it was established in May 1995. There was very little, if any, code not written by OAR Corporation in that initial import. After discussion with Chris Johns, it was determined that this code was from OAR Corporation and that he had added a few features later. Both Chris Johns and OAR Corporation have given permission to relicense. Updates #3053.
* cpukit/libmisc/untar: Change license to BSD-2Joel Sherrill2022-03-223-9/+66
| | | | Updates #3053.
* cpukit/libmisc/check: Change license to BSD-2Joel Sherrill2022-03-221-3/+22
| | | | Updates #3053.
* cpukit/libmisc/serdbg: Change license to BSD-2Joel Sherrill2022-03-223-9/+66
| | | | Updates #3053.
* cpukit/libmisc/rtems-fdt: Change license to BSD-2Joel Sherrill2022-03-222-6/+44
| | | | Updates #3053.
* cpukit/libmisc/redirector: Manually change license to BSD-2Joel Sherrill2022-03-221-7/+27
| | | | Updates #3053.
* cpukit/libmisc/mouse: Change license to BSD-2Joel Sherrill2022-03-221-3/+22
| | | | Updates #3053.
* cpukit/libmisc/fsmount/fsmount.c: Manual header clean upJoel Sherrill2022-03-221-3/+1
|
* cpukit/libmisc/fsmount: Change license to BSD-2.Joel Sherrill2022-03-221-3/+22
| | | | Updates #3053.
* cpukit/libmisc/dumpbuf: Change license to BSD-2Joel Sherrill2022-03-221-0/+2
| | | | Updates #3053.
* cpukit/libmisc/dummy: Change license to BSD-2.Joel Sherrill2022-03-221-3/+22
| | | | Updates #3053.
* cpukit/libmisc/devnull/devzero.c: Change license to BSD-2Joel Sherrill2022-03-221-3/+22
| | | | Updates #3053.
* cpukit/libmisc/cpuuse: Change license to BSD-2Joel Sherrill2022-03-226-18/+132
| | | | Updates #3053.
* cpukit/libmisc/capture: Manually change license to BSD-2Joel Sherrill2022-03-227-112/+212
| | | | | | | These files did not follow the standard format and needed to be changed manually. Updates #3053.
* cpukit/capture: Change license to BSD-2Joel Sherrill2022-03-222-6/+44
| | | | Updates #3053.
* cpukit/libmisc/bspcmdline: Change license to BSD-2Joel Sherrill2022-03-224-12/+88
| | | | Updates #3053.
* shell: Avoid potential stack corruptionSebastian Huber2022-03-161-7/+1
| | | | | | | | | | | The rtems_shell_init() passed the address of a stack variable (exit_code) to rtems_shell_run(). If wait == false, then the stack variable goes out of scope but may be accessed by the created shell thread. The rtems_shell_script() was affected by the same problem. Close #4629.
* cpukit: Automated IMD header file clean upChristian Mauderer2022-03-104-4/+4
| | | | | | Use the same form of IMD in all copyright lines Update #4625.
* bsps and cpukit: Manual file header clean upChristian Mauderer2022-03-102-26/+23
| | | | Updates #4625.
* cpukit/: Scripted embedded brains header file clean upJoel Sherrill2022-03-1015-88/+1
| | | | Updates #4625.
* libmisc/serdbg: Manual header clean upJoel Sherrill2022-03-102-45/+29
| | | | Updates #4625.
* cpukit: Prevent error with disabled stack checkerKinsey Moore2022-01-271-0/+5
| | | | | | | | | | | When the stack checker is not enabled, the stack checker reporting function can still be called. This prevents that call from performing a null memory access in trying to find the high water mark if the stack checker was never initialized. This also introduces a test to ensure this call does not cause a crash. Closes #4588
* libmisc/rtems-fdt: close() file 'bf'Ryan Long2021-12-171-0/+1
| | | | | | | | close() file 'bf' to avoid leaking descriptor. CID 1437645: Resource leak in rtems_fdt_load(). Closes #4297
* untar: Make behavior similar to GNU or BSD tarChristian Mauderer2021-12-091-20/+37
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | RTEMS untar implementation had problems with overwriting or integrating archives into existing directory structures. This patch adapts the behavior to mimic that of a GNU tar or BSD tar and extends the tar01 test to check for the behavior. That is: * If a directory structure exists, the files from the archive will be integrated. Existing files are overwritten. * If a file exists and the archive contains a directory with the same name, the file is removed and a directory is created. In the above example: if l1/l2 is a file it will be overwritten with a new directory. * If a directory exists and the archive contains a file with the same name, the directory will be replaced if it is empty. If it contains files, the result is an error. * An archive also can contain only a file without the parent directories. If in that case one of the parent directories exists as a file extracting the archive results in an error. In the example: if l1/l2 is a file and the archive doesn't contain the directories but only the file l1/l2/x.txt that would be an error. * In case of an error, it is possible that the archive has been partially extracted. Closes #4568
* rtems: Move scheduler directives to own headerSebastian Huber2021-12-021-0/+1
| | | | | | Move all rtems_scheduler_* directives to the new header file <rtems/rtems/scheduler.h>. Add a Scheduler Manager API and implementation group.
* rtems: Fix rate monotonic statisticsSebastian Huber2021-10-253-3/+4
| | | | | | | | | | | | | | | The rate monotonic period statistics were affected by rtems_cpu_usage_reset(). The logic to detect and work around a CPU usage reset was broken. The Thread_Contol::cpu_time_used is changed to contain the processor time used throughout the entire lifetime of the thread. The new member Thread_Contol::cpu_time_used_at_last_reset is added to contain the processor time used at the time of the last reset through rtems_cpu_usage_reset(). This decouples the resets of the CPU usage and the rate monotonic period statistics. Update #4528.
* libmisc/shell: Check the shell command pointers when adding a commandChris Johns2021-08-211-0/+5
|
* libmisc/fdt: fix node initialise error with RTEMS_DEBUGChris Johns2021-08-211-0/+2
|
* rtems: Fix rtems_partition_return_buffer()Sebastian Huber2021-08-121-2/+3
| | | | | | | | The rtems_partition_return_buffer() wrongly accepted which were exactly at the buffer area end. Use the buffer area limit address for the range checking. Close #4490.
* main_edit.c: get rid of malloc warningRyan Long2021-06-091-8/+8
| | | | | | A warning was present when building RTEMS that stated that the argument for malloc() exceeded the maximum object size. To get rid of this, I changed many places where 'int' was being used to 'size_t'.
* cpukit/libmisc/monitor: Fix src/dest overlap of strcpy in mon-editor.cHarrison Edward Gerber2021-05-281-1/+11
| | | | | | See also CID 1399727 Closes #4444
* main_help.c: Do not care what char is returned by getchar()Ryan Long2021-05-281-1/+1
| | | | | | CID 1437650: Unchecked return value from library in rtems_shell_help(). Closes #4291
* main_cp.c: Ignore return value from stat()Ryan Long2021-05-281-0/+6
| | | | | | CID 26051: Unchecked return value from library in main_cp(). Closes #4365
* gen_uuid.c: Ignore return values from fcntl()Ryan Long2021-05-281-0/+6
| | | | | | | CID 1049146: Unchecked return value from library in get_clock(). CID 1049147: Unchecked return value from library in get_random_fd(). Closes #4280
* stackchk: Fixed 32bit pointersStephen Clark2021-05-051-1/+2
| | | | | | Using 32bit types like uint32_t for pointers creates issues on 64 bit architectures like AArch64. Replaced occurrences of these with uintptr_t, which will work for both 32 and 64 bit architectures.
* rtems-fdt: Fixed 32bit pointersStephen Clark2021-05-051-2/+2
| | | | | | Using 32bit types like uint32_t for pointers creates issues on 64 bit architectures like AArch64. Replaced occurrences of these with uintptr_t, which will work for both 32 and 64 bit architectures.