Skip to content

Commit 7925af1

Browse files
committed
Code review: Fix typos and spelling mistakes accross all the files of the project.
1 parent 11faf99 commit 7925af1

30 files changed

+54
-53
lines changed

CMakeLists.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -123,7 +123,7 @@ target_link_options(
123123
PUBLIC ${LAZULI_USER_LINK_FLAGS})
124124

125125
# Generate disassembly listing.
126-
set(LST_TARGET_NAME lst_ouput)
126+
set(LST_TARGET_NAME lst_output)
127127

128128
add_custom_command(
129129
OUTPUT

Dockerfile

+1-1
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
#
88
# This Dockerfile describes the container image that is used as the development
99
# environment for Lazuli. This image is used by kernel and user application
10-
# developpers, as well as for continuous integration.
10+
# developers, as well as for continuous integration.
1111
#
1212
# Man pages are first built in an intermediate image. This has the advantage of
1313
# being platform-independent. The man pages are then copied into the final

README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -156,7 +156,7 @@ https://lazuli.readthedocs.io/en/latest/developing_your_project.html
156156

157157
## Uploading binaries to the target platform
158158

159-
On AVR MCUs, `avrdude` can be used to uplaod the final binary to the target
159+
On AVR MCUs, `avrdude` can be used to upload the final binary to the target
160160
machine.
161161
The script [scripts/AVR/upload.sh](scripts/AVR/upload.sh) can be used for that.
162162
It takes the HEX file as a parameter.

TODO.org

+2-2
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@
5454
* Think about defining the execution of the main() function in the idle task.
5555
** i.e. Execution begins as the idle task, and user tasks are created from the idle task.
5656
** This allows/ease the implementation of Pthread API.
57-
** Carrefully think about priorities.
57+
** Carefully think about priorities.
5858
* For PROGMEM, implement "memcpy_P": Memory_CopyFromProgmem
5959
* Test command "apropos" in man pages of the Docker image.
6060
* In the Docker image, make sure to respect the File Hierarchy Standard
@@ -66,5 +66,5 @@
6666
* Think about renaming the GitHub repository to "LazuliRTOS".
6767
* Host the Lazuli docker image to GitHub instead of docker.io.
6868
* Think about moving libc header files to the directory include/
69-
** See if we can also get rid of directory libc/, as the corresponding functionnalities are actually implemented as kernel modules
69+
** See if we can also get rid of directory libc/, as the corresponding functionalities are actually implemented as kernel modules
7070
* See if it would be necessary to declare all global variables used the scheduler.c and kernel.c as 'volatile'.

doc/a_simple_example.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
A simple example
99
================
1010

11-
Instead of the traditionnal "Hello world", we show here a simple clock
11+
Instead of the traditional "Hello world", we show here a simple clock
1212
application.
1313

1414
This application demonstrates a simple clock that prints the time every second

doc/index.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ provided by Lazuli.
2424
The last chapter of this documentation is the **Kernel** documentation.
2525
It is intended for programmers, who wish to code in the Lazuli kernel, hacking
2626
and improving it.
27-
This documentation will give you detailled information about the inner working
27+
This documentation will give you detailed information about the inner working
2828
of Lazuli.
2929

3030
.. toctree::

doc/introduction.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ Introduction
1212

1313
Lazuli is a preemptive real-time multitasking kernel targeting microcontrollers,
1414
or machines with constrained resources. It allow the microcontroller to run
15-
multiple independant tasks simultaneously, with some of them having hard
15+
multiple independent tasks simultaneously, with some of them having hard
1616
real-time constraints.
1717
Lazuli provides a "time slice" scheduler in order to respect deadlines
1818
constraints of the tasks running in the system.

doc/kernel/about_documentation.rst

+2-2
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ The documentation is rendered in 2 formats:
2121
* **man**: The man page output is used in the Lazuli Docker image.
2222
Any developer using the development environment Docker image can type
2323
``man Lazuli`` to read the exact complete documentation you are now reading.
24-
Thenks to Doxygen, the user can also use ``man`` to obtain the documentation
24+
Thanks to Doxygen, the user can also use ``man`` to obtain the documentation
2525
about any function or symbol used in the project.
2626

2727
Sphinx and reStructuredText
@@ -90,7 +90,7 @@ The API documentation for the project is hosted at
9090
Code comments
9191
^^^^^^^^^^^^^
9292

93-
All C code of the project is documentated using Doxygen code comments.
93+
All C code of the project is documented using Doxygen code comments.
9494
The absence of Doxygen code comments will cause an error during build.
9595

9696
Building Doxygen documentation

doc/kernel/best_practices/think_twice_before_using_enums/think_twice_before_using_enums.rst

+6-6
Original file line numberDiff line numberDiff line change
@@ -25,12 +25,12 @@ constants under a common name:
2525

2626
Most of the time and for the vast majority of usual C code, this practice should
2727
be applied.
28-
Enumerations also have the advantage of beeing true C symbols from the compiler
28+
Enumerations also have the advantage of being true C symbols from the compiler
2929
and debugger point of view.
3030

3131
However, there are a few situations where manipulating integer constants as
3232
enumerations should not be considered, or at least should be taken really
33-
carrefully.
33+
carefully.
3434
These situations happen when enumerations are manipulated as l-values on
3535
specific architectures.
3636

@@ -55,7 +55,7 @@ A consequence on binary interfacing
5555
-----------------------------------
5656

5757
The first consequence of the C specification is that ``enum`` constants don't
58-
have a fixed size accross different architectures, as the size of an ``int``
58+
have a fixed size across different architectures, as the size of an ``int``
5959
varies between architectures/compilers.
6060
This is quite a well-know fact amongst C programmers.
6161

@@ -67,8 +67,8 @@ An argument against *specific* uses of enumerations
6767
---------------------------------------------------
6868

6969
Let's now introduce a sneaky pitfall, that happens *under specific conditions*.
70-
Lazuli RTOS is targetting embedded systems. It is written in ANSI C and aims to
71-
be easily portable accross different architectures.
70+
Lazuli RTOS is targeting embedded systems. It is written in ANSI C and aims to
71+
be easily portable across different architectures.
7272

7373
We take here the example of the AVR architecture, which is a target for the
7474
Lazuli RTOS.
@@ -90,7 +90,7 @@ are often dealing with tiny machines.
9090
It is much more difficult to see these problems and their consequences when
9191
using enumerations rather than integers, because we often rely on standard
9292
header ``<stdint.h>`` when declaring integer variables. We then have a
93-
convinient way to master the size of integer variables right from their
93+
convenient way to master the size of integer variables right from their
9494
declaration.
9595
Unfortunately no equivalent exists for enumerations, and its not easy to spot
9696
their size at a glance when reviewing the source code.

doc/kernel/contributing.rst

+3-3
Original file line numberDiff line numberDiff line change
@@ -66,8 +66,8 @@ The expected format for commit messages is the following:
6666
6767
<Part or module>: <Brief explanation on one line.>
6868
69-
<Detailled explanation if needed.>
70-
<The detailled explanation can be expressed as a list.>
69+
<Detailed explanation if needed.>
70+
<The detailed explanation can be expressed as a list.>
7171
7272
Here are a few examples of real commit messages that follow this format:
7373

@@ -99,7 +99,7 @@ using GitHub Actions, and is triggered on pull-requests.
9999

100100
The project's CI performs the following tasks:
101101

102-
* Execute ``scripts/checklines.sh`` to check for trailing whistespaces, line
102+
* Execute ``scripts/checklines.sh`` to check for trailing whitespaces, line
103103
length, etc.
104104
* Build the Lazuli development environment Docker image from the root
105105
``Dockerfile``.

doc/kernel/repository_tree.rst

+2-2
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
Repository tree
99
===============
1010

11-
We give here an explanation of the main directorites of the repository.
11+
We give here an explanation of the main directories of the repository.
1212
It is displayed here from the root with the command ``tree -d`` with manual
1313
modifications to show only the most important ones.
1414
Comments on the right side have been added manually.
@@ -31,7 +31,7 @@ Comments on the right side have been added manually.
3131
│   │   ├── arch Base directory of arch-specific kernel sources
3232
│   │   └── modules Base directory of kernel modules sources
3333
│   ├── libc Base directory of C files related to libc implementation
34-
│   ├── libc-headers Base direcotry of standard C library header files
34+
│   ├── libc-headers Base directory of standard C library header files
3535
│   │   └── arch-dependent Base directory of arch-dependent libc header files
3636
│   └── unit-tests Unit tests sources
3737
├── templates File templates, used when creating new files

doc/kernel/startup.rst

+2-2
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,8 @@ Assembly - Setting up a C runtime
1313

1414
System startup is divided in 2 parts:
1515

16-
* The first part, written in assembly language, exectutes right after powering
17-
on the system, and has the responsability to set up an operational C runtime.
16+
* The first part, written in assembly language, executes right after powering
17+
on the system, and has the responsibility to set up an operational C runtime.
1818
* The second part, mainly written in C, performs various operations that are
1919
necessary to initialize the data structures of the kernel, before giving hand
2020
to user code.

example-programs/clock24.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ main(void)
5252
Lz_SerialConfiguration serialConfiguration;
5353

5454
/*
55-
* Enable serial tansmission.
55+
* Enable serial transmission.
5656
*/
5757
Lz_Serial_GetConfiguration(&serialConfiguration);
5858
serialConfiguration.enableFlags = LZ_SERIAL_ENABLE_TRANSMIT;

sys/CMakeLists.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -138,7 +138,7 @@ target_compile_options(
138138
${KERNEL_LIBRARY_NAME}
139139
PRIVATE ${LZ_KERNEL_COMPILE_FLAGS})
140140

141-
set(KERNEL_LST_TARGET_NAME kernel_lst_ouput)
141+
set(KERNEL_LST_TARGET_NAME kernel_lst_output)
142142

143143
add_custom_command(
144144
OUTPUT

sys/cmake/avr.toolchain.cmake

+1-1
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ set(CMAKE_SYSTEM_NAME Generic)
2323
set(CMAKE_SYSTEM_PROCESSOR avr)
2424

2525
set(CMAKE_C_COMPILER ${AVR_CC} CACHE FILEPATH "AVR toolchain C compiler.")
26-
set(CMAKE_ASM_COMPILER ${AVR_CC} CACHE FILEPATH "AVR toolchain assmebler.")
26+
set(CMAKE_ASM_COMPILER ${AVR_CC} CACHE FILEPATH "AVR toolchain assembler.")
2727
set(CMAKE_AR ${AVR_AR} CACHE FILEPATH "AVR toolchain static library archiver.")
2828
set(CMAKE_LINKER ${AVR_LD} CACHE FILEPATH "AVR toolchain linker.")
2929
set(CMAKE_NM ${AVR_NM} CACHE FILEPATH "AVR toolchain nm tool.")

sys/cmake/declare_lazuli_module.cmake

+1-1
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
# The macro then adds the declared module in the global list of declared modules.
1818
#
1919
# @param NAME The module name, in lowercase, without prefixing it by "module_".
20-
# @param SUMMARY A string describing the module functionnality.
20+
# @param SUMMARY A string describing the module functionality.
2121
# @param SOURCES A list of the module source files.
2222
#
2323
macro(declare_lazuli_module)

sys/doxygen_main_page.dox

+1-1
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@
3131
* @endcode
3232
*
3333
* All user API types conform to the following naming convention:
34-
* <b>`Lz_XXXXX`</b> where <b>`XXXXX`</b> represents a type writtent in camel
34+
* <b>`Lz_XXXXX`</b> where <b>`XXXXX`</b> represents a type written in camel
3535
* case. Some examples:
3636
* @code{.c}
3737
* Lz_Mutex

sys/include/Lazuli/common.h

+2-2
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@
4444
#endif /* __cplusplus */
4545

4646
/**
47-
* Tell the compiler that the variable X is left unsed.
47+
* Tell the compiler that the variable X is left unused.
4848
*
4949
* @param X The unused variable.
5050
*/
@@ -165,7 +165,7 @@ STATIC_ASSERT(sizeof(uint8_t) == 1,
165165
* @param X An unsigned integer constant representing the position of the bit,
166166
* starting from index 0.
167167
*
168-
* @warning The constant must be specified using an unsigned integer litteral
168+
* @warning The constant must be specified using an unsigned integer literal
169169
* in uppercase.
170170
* e.g. POSITION(2U)
171171
* This is to make static analyzers not complain about using a shift

sys/include/Lazuli/config_static_analysis.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
* The reason for that is that most static code analysis tools operate on
1515
* preprocessed files. By using this file instead of the final config.h, we
1616
* simulate the fact that these configuration constants can take any value.
17-
* So static analysizers don't complain/exclude/assume some parts of source
17+
* So static analysers don't complain/exclude/assume some parts of source
1818
* code.
1919
*
2020
* @warning Some of these definitions can cause problems as there are some

sys/include/Lazuli/lazuli.h

+3-3
Original file line numberDiff line numberDiff line change
@@ -128,7 +128,7 @@ typedef struct {
128128
/**
129129
* Register a new task.
130130
*
131-
* If an error occured during registration of the task _false_ is returned and
131+
* If an error occurred during registration of the task _false_ is returned and
132132
* the task is not included in the set of tasks that will be run.
133133
*
134134
* @param taskEntryPoint The entry point of the task to register.
@@ -140,7 +140,7 @@ typedef struct {
140140
*
141141
* @return
142142
* - _true_ if the task has been registered without error.
143-
* - _false_ if an error occured during registration.
143+
* - _false_ if an error occurred during registration.
144144
*/
145145
bool
146146
Lz_RegisterTask(void (* const taskEntryPoint)(void),
@@ -202,7 +202,7 @@ Lz_Task_Terminate(void);
202202

203203
/**
204204
* Set the calling task to wait for its next activation.
205-
* May be used if the task finnished its work without consuming all of its
205+
* May be used if the task finished its work without consuming all of its
206206
* completion time.
207207
*
208208
* @attention Only tasks with scheduling policy CYCLIC_RT can wait for next

sys/include/Lazuli/list.h

+2-2
Original file line numberDiff line numberDiff line change
@@ -169,7 +169,7 @@ List_IsEmpty(const Lz_LinkedList * const linkedList);
169169
* @param LINKEDLIST A pointer to the Lz_LinkedList to run through.
170170
* @param TYPE The real type of the list elements
171171
* @param ITEM A pointer to a struct of type @p TYPE containing the
172-
* Lz_LinkedListELement.
172+
* Lz_LinkedListElement.
173173
* This pointer will point to the current item of each loop turn.
174174
* This pointer will never be _NULL_ while the loop is running.
175175
* @param MEMBER The name of the member in @p TYPE which bears the
@@ -209,7 +209,7 @@ List_IsEmpty(const Lz_LinkedList * const linkedList);
209209
* @param LINKEDLIST A pointer to the Lz_LinkedList to run through.
210210
* @param TYPE The real type of the list elements
211211
* @param ITEM A pointer to a struct of type @p TYPE containing the
212-
* Lz_LinkedListELement.
212+
* Lz_LinkedListElement.
213213
* This pointer will point to the current item of each loop turn.
214214
* This pointer will never be _NULL_ while the loop is running.
215215
* @param MEMBER The name of the member in @p TYPE which bears the

sys/include/Lazuli/serial.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
* This file describes the interface of serial port configuration.
1212
* Serial port means here UART/USART device.
1313
*
14-
* The configuration is the same for input (Receive/Rx) and ouput
14+
* The configuration is the same for input (Receive/Rx) and output
1515
* (Transmit/Tx).
1616
*/
1717

sys/include/Lazuli/sys/arch/arch.h

+5-4
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
* Provides a simple abstraction API to architecture specific functions.
1212
* This is the API that must be re-implemented if porting to another platform.
1313
*
14-
* This one is taylored after the AVR platform and can be subject to change if
14+
* This one is tailored after the AVR platform and can be subject to change if
1515
* porting to another platform.
1616
*/
1717

@@ -243,10 +243,11 @@ void
243243
Arch_GetSerialConfiguration(Lz_SerialConfiguration * const configuration);
244244

245245
/**
246-
* Configure the seria line according to the parameter.
246+
* Configure the serial line according to the parameter.
247247
*
248-
* @param configuration A pointer to an existing Lz_SerialConfiguration containg
249-
* the full configuration to set up the serial line.
248+
* @param configuration A pointer to an existing Lz_SerialConfiguration
249+
* containing the full configuration to set up the serial
250+
* line.
250251
*/
251252
void
252253
Arch_SetSerialConfiguration(const Lz_SerialConfiguration * const configuration);

sys/include/Lazuli/sys/scheduler.h

+2-2
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ void
4242
Scheduler_Init(void);
4343

4444
/**
45-
* Call the appropriate scheduler to abort the curent running task.
45+
* Call the appropriate scheduler to abort the current running task.
4646
*
4747
* @param sp The stack pointer of the running task after saving its context.
4848
*/
@@ -64,7 +64,7 @@ void
6464
Scheduler_HandleInterrupt(const uint8_t interruptCode);
6565

6666
/**
67-
* This function is called when a clock tick occured, catch by the interrupt
67+
* This function is called when a clock tick occurred, catch by the interrupt
6868
* handler.
6969
*
7070
* @param sp The stack pointer of the current running task after saving its

sys/include/Lazuli/sys/task.h

+3-3
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ typedef u_read_write_atomic_t lz_task_to_scheduler_message_t;
4141

4242
/**
4343
* Set the task to wait for its next activation.
44-
* i.e. It finnished its work without consuming all of its completion time.
44+
* i.e. It finished its work without consuming all of its completion time.
4545
*/
4646
#define WAIT_ACTIVATION ((lz_task_to_scheduler_message_t)1U)
4747

@@ -182,7 +182,7 @@ typedef struct {
182182
}Task;
183183

184184
/**
185-
* This type definition is needed to exlude confusion with the 'volatile'
185+
* This type definition is needed to exclude confusion with the 'volatile'
186186
* type qualifier used in the struct declaration below.
187187
*/
188188
typedef void (*FuncVoidVoid)(void);
@@ -315,7 +315,7 @@ typedef struct {
315315
/**
316316
* Abort the calling task.
317317
*
318-
* This function can be called when some unrecoverable error occured in the
318+
* This function can be called when some unrecoverable error occurred in the
319319
* context of a task (e.g. when a mandatory pointer is _NULL_ as a function
320320
* parameter).
321321
* This will have the consequence of saving the task context (saving all

sys/kern/arch/AVR/avr_arch.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
* @brief Header file specific to the AVR arch module.
99
* @copyright 2018-2020, Remi Andruccioli <[email protected]>
1010
*
11-
* This header file declares all symbol neeed specifically in the AVR arch
11+
* This header file declares all symbol needed specifically in the AVR arch
1212
* module, and not declared in <Lazuli/sys/arch/arch.h>.
1313
*/
1414

sys/kern/modules/clock_24/clock_24.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -108,7 +108,7 @@ Clock24_Increment(void)
108108
/*
109109
* The clock version integer will constantly increment from 0 to its maximum
110110
* value.
111-
* We can let it overflow as it is unsigned. Unsiged overflow is not an
111+
* We can let it overflow as it is unsigned. Unsigned overflow is not an
112112
* undefined behaviour in C89.
113113
*/
114114
++clockVersion;

0 commit comments

Comments
 (0)