Skip to content

Commit

Permalink
common: the yearly spellchecker run
Browse files Browse the repository at this point in the history
  • Loading branch information
kilobyte committed Jan 22, 2022
1 parent 2705a63 commit 070dd2c
Show file tree
Hide file tree
Showing 24 changed files with 57 additions and 55 deletions.
4 changes: 2 additions & 2 deletions doc/libpmem2/pmem2_source_pread_mcsafe.3.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ date: pmem2 API version 1.0
...

[comment]: <> (SPDX-License-Identifier: BSD-3-Clause)
[comment]: <> (Copyright 2021, Intel Corporation)
[comment]: <> (Copyright 2021-2022, Intel Corporation)

[comment]: <> (pmem2_source_pread_mcsafe.3 -- man page for libpmem2 machine safe read/write operations)

Expand Down Expand Up @@ -62,7 +62,7 @@ return 0 on success or a negative error code on failure.
The **pmem2_source_pread_mcsafe**() and **pmem2_source_pwrite_mcsafe**() can fail
with the following errors:

* **PMEM2_E_IO_FAIL** - a physical I/O error occured during the read/write operation,
* **PMEM2_E_IO_FAIL** - a physical I/O error occurred during the read/write operation,
a possible bad block encountered.

* **PMEM2_E_LENGTH_OUT_OF_RANGE** - read/write operation size *size* from
Expand Down
4 changes: 2 additions & 2 deletions doc/libpmem2/pmem2_vm_reservation_extend.3.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ date: pmem2 API version 1.0
...

[comment]: <> (SPDX-License-Identifier: BSD-3-Clause)
[comment]: <> (Copyright 2021, Intel Corporation)
[comment]: <> (Copyright 2021-2022, Intel Corporation)

[comment]: <> (pmem2_vm_reservation_extend.3 -- man page for libpmem2 pmem2_vm_reservation_extend and pmem2_vm_reservation_shrink operations)

Expand Down Expand Up @@ -49,7 +49,7 @@ The **pmem2_vm_reservation_shrink**() function shrinks the reservation by a regi
by *offset* into the reservation and the *size*. For the function to succeed the *size* and
*offset* variables have to be aligned to an appropriate allocation granularity. The region
formed by *offset* and *size* has to belong to the reservation, be empty and it needs to cover
the beggining or the end of the reservation.
the beginning or the end of the reservation.
Shrinking reservation from the middle or shrinking the whole reservation is not supported.

If the **pmem2_vm_reservation_shrink**() succeeds in shrinking a reservation, it releases
Expand Down
4 changes: 2 additions & 2 deletions doc/libpmem2/pmem2_vm_reservation_map_find.3.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ date: pmem2 API version 1.0
...

[comment]: <> (SPDX-License-Identifier: BSD-3-Clause)
[comment]: <> (Copyright 2021, Intel Corporation)
[comment]: <> (Copyright 2021-2022, Intel Corporation)

[comment]: <> (pmem2_vm_reservation_map_find.3 -- man page for libpmem2 pmem2_vm_reservation_map_find operation)

Expand Down Expand Up @@ -48,7 +48,7 @@ int pmem2_vm_reservation_map_find_last(struct pmem2_vm_reservation *rsv,
# DESCRIPTION #
Mappings are inserted to the virtual memory reservation in the order of their virtual
address space location. First mapping represents the earliest mapping in the virtual
addres space contained in a reservation, whereas the last mapping represents the last one.
address space contained in a reservation, whereas the last mapping represents the last one.

The **pmem2_vm_reservation_map_find**() function searches for the earliest mapping,
stored in the virtual memory reservation, intersecting with the interval defined by
Expand Down
4 changes: 2 additions & 2 deletions doc/libpmemset/libpmemset_shutdown_state.7.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ date: pmemset API version 1.0
...

[comment]: <> (SPDX-License-Identifier: BSD-3-Clause)
[comment]: <> (Copyright 2021, Intel Corporation)
[comment]: <> (Copyright 2021-2022, Intel Corporation)

[comment]: <> (libpmemset_shutdown_state.7 -- man page for libpmemset shutdown state)

Expand Down Expand Up @@ -147,7 +147,7 @@ save_sds(struct pmemset *set, struct pmemset_event_context *ctx,

This fragment defines a *save_sds* function that checks if the event type matches
*PMEMSET_EVENT_SDS_UPDATE* and saves the updated SDS wherever user wants. *save_sds*
is then set in a config as a callback for occuring events.
is then set in a config as a callback for occurring events.

```c
struct pmemset_sds sds = PMEMSET_SDS_INITIALIZE();
Expand Down
4 changes: 2 additions & 2 deletions doc/libpmemset/pmemset_config_set_event_callback.3.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ date: pmemset API version 1.0
...

[comment]: <> (SPDX-License-Identifier: BSD-3-Clause)
[comment]: <> (Copyright 2021, Intel Corporation)
[comment]: <> (Copyright 2021-2022, Intel Corporation)

[comment]: <> (pmemset_config_set_event_callback.3 -- man page for pmemset_config_set_event_callback)

Expand Down Expand Up @@ -122,7 +122,7 @@ struct pmemset_event_set {
before **pmemset_memcpy**(3), **pmemset_memmove**(3), **pmemset_memset**(3) completed its work.
Similarly, *copy*, *move*, or *set* fields in the *data* union contain all arguments passed to these functions.
If **PMEMSET_F_MEM_NODRAIN** flag is **not** passed to these functions, a single **PMEMSET_EVENT_DRAIN**
will be fired on the end of opperation.
will be fired on the end of operation.
During these functions "flush" and "drain" operations are performed,
but they will not trigger any additional events.
**PMEMSET_EVENT_FLUSH** and **PMEMSET_EVENT_DRAIN**
Expand Down
4 changes: 2 additions & 2 deletions doc/libpmemset/pmemset_source_alignment.3.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ date: pmemset API version 1.0
...

[comment]: <> (SPDX-License-Identifier: BSD-3-Clause)
[comment]: <> (Copyright 2021, Intel Corporation)
[comment]: <> (Copyright 2021-2022, Intel Corporation)

[comment]: <> (pmemset_source_alignment.3 -- man page for pmemset_source_alignment)

Expand Down Expand Up @@ -50,7 +50,7 @@ error code is returned.

The **pmemset_source_alignment**() can fail with the following errors:

* **PMEMSET_E_INVALID_ALIGNMENT_VALUE** - cannot read aligment for source file
* **PMEMSET_E_INVALID_ALIGNMENT_VALUE** - cannot read alignment for source file
from the *src*.

# SEE ALSO #
Expand Down
4 changes: 2 additions & 2 deletions doc/libpmemset/pmemset_source_pread_mcsafe.3.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ date: pmemset API version 1.0
...

[comment]: <> (SPDX-License-Identifier: BSD-3-Clause)
[comment]: <> (Copyright 2021, Intel Corporation)
[comment]: <> (Copyright 2021-2022, Intel Corporation)

[comment]: <> (pmemset_source_pread_mcsafe.3 -- man page for libpmemset machine safe read/write operations)

Expand Down Expand Up @@ -60,7 +60,7 @@ return 0 on success or a negative error code on failure.
The **pmemset_source_pread_mcsafe**() and **pmemset_source_pwrite_mcsafe**() can fail
with the following errors:

* **PMEMSET_E_IO_FAIL** - a physical I/O error occured during the read/write operation,
* **PMEMSET_E_IO_FAIL** - a physical I/O error occurred during the read/write operation,
a possible bad block encountered.

* **PMEMSET_E_LENGTH_OUT_OF_RANGE** - read/write operation size *size* from
Expand Down
4 changes: 2 additions & 2 deletions doc/libpmemset/pmemset_source_set_sds.3.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ date: pmemset API version 1.0
...

[comment]: <> (SPDX-License-Identifier: BSD-3-Clause)
[comment]: <> (Copyright 2021, Intel Corporation)
[comment]: <> (Copyright 2021-2022, Intel Corporation)

[comment]: <> (pmemset_source_set_sds.3 -- man page for pmemset_source_set_sds)

Expand Down Expand Up @@ -57,7 +57,7 @@ structure.

Shutdown data state parameter *sds* can be initialized for the first time using
**PMEMSET_SDS_INITIALIZE**() macro. Subsequent shutdown states *sds* can be retrieved via
*PMEMSET_EVENT_SDS_UPDATE* event fired everytime an *sds* is updated. For more information
*PMEMSET_EVENT_SDS_UPDATE* event fired every time an *sds* is updated. For more information
please see **pmemset_config_set_event_callback**(3).

When creating a new mapping using **pmemset_map**(3) function, current part state will
Expand Down
4 changes: 2 additions & 2 deletions src/core/ravl_interval.c
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
// SPDX-License-Identifier: BSD-3-Clause
/* Copyright 2020-2021, Intel Corporation */
/* Copyright 2020-2022, Intel Corporation */

/*
* ravl_interval.c -- ravl_interval implementation
Expand Down Expand Up @@ -293,7 +293,7 @@ ravl_interval_find_last(struct ravl_interval *ri)
}

/*
* ravl_interval_find_next -- returns interval successing the one provided
* ravl_interval_find_next -- returns interval succeeding the one provided
*/
struct ravl_interval_node *
ravl_interval_find_next(struct ravl_interval *ri, void *addr)
Expand Down
4 changes: 2 additions & 2 deletions src/deps/miniasync/examples/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#
# SPDX-License-Identifier: BSD-3-Clause
# Copyright 2021, Intel Corporation
# Copyright 2021-2022, Intel Corporation
#

add_custom_target(examples)
Expand All @@ -27,7 +27,7 @@ add_check_whitespace(examples-all
${CMAKE_CURRENT_SOURCE_DIR}/README.md)

# add_example-- function for adding an example.
# Afer the required name parameter, next parameters
# After the required name parameter, next parameters
# passed to this function are example's sources.
function(add_example name)
include_directories(
Expand Down
10 changes: 5 additions & 5 deletions src/libpmem2/mcsafe_ops_posix.c
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
// SPDX-License-Identifier: BSD-3-Clause
/* Copyright 2021, Intel Corporation */
/* Copyright 2021-2022, Intel Corporation */

#include <errno.h>
#include <setjmp.h>
Expand All @@ -24,7 +24,7 @@ static int
mcsafe_op_none(struct pmem2_source *src, void *buf, size_t size,
size_t offset)
{
/* suppres unused parameters */
/* suppress unused parameters */
SUPPRESS_UNUSED(src, buf, size, offset);

ASSERT(0);
Expand All @@ -46,7 +46,7 @@ mcsafe_op_reg_read(struct pmem2_source *src, void *buf, size_t size,
ssize_t retsize = pread(fd, buf, size, (off_t)offset);
if (retsize == -1) {
if (errno == EIO) {
ERR("physical I/O error occured on read operation, "
ERR("physical I/O error occurred on read operation, "
"possible bad block");
return PMEM2_E_IO_FAIL;
}
Expand All @@ -72,7 +72,7 @@ mcsafe_op_reg_write(struct pmem2_source *src, void *buf, size_t size,
ssize_t retsize = pwrite(fd, buf, size, (off_t)offset);
if (retsize == -1) {
if (errno == EIO) {
ERR("physical I/O error occured on write operation, "
ERR("physical I/O error occurred on write operation, "
"possible bad block");
return PMEM2_E_IO_FAIL;
}
Expand Down Expand Up @@ -134,7 +134,7 @@ handle_sigbus_execute_mcsafe_op(struct pmem2_source *src, void *buf,

/* sigsetjmp returns nonzero only when returning from siglongjmp */
if (sigsetjmp(mcsafe_jmp_buf, 1)) {
ERR("physical I/O error occured, possible bad block");
ERR("physical I/O error occurred, possible bad block");
ret = PMEM2_E_IO_FAIL;
goto clnup_null_global_jmp;
}
Expand Down
4 changes: 2 additions & 2 deletions src/libpmem2/mcsafe_ops_windows.c
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
// SPDX-License-Identifier: BSD-3-Clause
/* Copyright 2021, Intel Corporation */
/* Copyright 2021-2022, Intel Corporation */

#include <errno.h>

Expand All @@ -22,7 +22,7 @@ static int
mcsafe_op_none(struct pmem2_source *src, void *buf, size_t size,
size_t offset)
{
/* suppres unused parameters */
/* suppress unused parameters */
SUPPRESS_UNUSED(src, buf, size, offset);

ASSERT(0);
Expand Down
6 changes: 3 additions & 3 deletions src/libpmem2/vm_reservation_windows.c
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
// SPDX-License-Identifier: BSD-3-Clause
/* Copyright 2020-2021, Intel Corporation */
/* Copyright 2020-2022, Intel Corporation */

/*
* vm_reservation_windows.c -- implementation of virtual memory
Expand Down Expand Up @@ -102,7 +102,7 @@ vm_reservation_merge_placeholders(struct pmem2_vm_reservation *rsv, void *addr,
LOG(3, "rsv_addr %p rsv_size %zu", rsv_addr, rsv_size);

/*
* After unmapping from the reservation, it is neccessary to merge
* After unmapping from the reservation, it is necessary to merge
* the unoccupied neighbours so that the placeholders will be available
* for splitting for the required size of the mapping.
*/
Expand Down Expand Up @@ -190,7 +190,7 @@ vm_reservation_split_placeholders(struct pmem2_vm_reservation *rsv, void *addr,
LOG(3, "rsv_addr %p rsv_size %zu", rsv_addr, rsv_size);

/*
* Check wheter there is a mapping just beside the provided placeholder
* Check whether there is a mapping just beside the provided placeholder
* range (addr, addr + length). If the immediate neighboring ranges
* are empty then split the provided range into separate placeholder.
*/
Expand Down
4 changes: 2 additions & 2 deletions src/libpmempool/check_util.c
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
// SPDX-License-Identifier: BSD-3-Clause
/* Copyright 2016-2020, Intel Corporation */
/* Copyright 2016-2022, Intel Corporation */

/*
* check_util.c -- check utility functions
Expand Down Expand Up @@ -652,7 +652,7 @@ check_get_uuid_str(uuid_t uuid)

int ret = util_uuid_to_string(uuid, uuid_str);
if (ret != 0) {
ERR("failed to covert uuid to string");
ERR("failed to convert uuid to string");
return "";
}
return uuid_str;
Expand Down
6 changes: 3 additions & 3 deletions src/libpmemset/map_config.c
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
// SPDX-License-Identifier: BSD-3-Clause
/* Copyright 2021, Intel Corporation */
/* Copyright 2021-2022, Intel Corporation */

/*
* map_config.c -- implementation of common map_config API
Expand Down Expand Up @@ -42,7 +42,7 @@ pmemset_map_config_new(struct pmemset_map_config **map_cfg)
}

/*
* pmemset_map_config_set_offset -- sets offset in the map configuraton struct
* pmemset_map_config_set_offset -- sets offset in the map configuration struct
*/
int
pmemset_map_config_set_offset(struct pmemset_map_config *map_cfg,
Expand All @@ -63,7 +63,7 @@ pmemset_map_config_set_offset(struct pmemset_map_config *map_cfg,
}

/*
* pmemset_map_config_set_length -- sets length in the map configuraton struct
* pmemset_map_config_set_length -- sets length in the map configuration struct
*/
void
pmemset_map_config_set_length(struct pmemset_map_config *map_cfg,
Expand Down
5 changes: 3 additions & 2 deletions src/libpmemset/part.c
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
// SPDX-License-Identifier: BSD-3-Clause
/* Copyright 2020-2021, Intel Corporation */
/* Copyright 2020-2022, Intel Corporation */

/*
* part.c -- implementation of common part API
Expand Down Expand Up @@ -208,7 +208,8 @@ pmemset_part_file_try_ensure_size(struct pmemset_file *f, size_t len,
}

/*
* pmemset_part_map_find -- find the earliest pmem2 mapping in the provied range
* pmemset_part_map_find -- find the earliest pmem2 mapping in the provided
* range
*/
int
pmemset_part_map_find(struct pmemset_part_map *pmap, size_t offset, size_t size,
Expand Down
4 changes: 2 additions & 2 deletions src/libpmemset/source.c
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
// SPDX-License-Identifier: BSD-3-Clause
/* Copyright 2020-2021, Intel Corporation */
/* Copyright 2020-2022, Intel Corporation */

/*
* source.c -- implementation of common config API
Expand Down Expand Up @@ -543,7 +543,7 @@ pmemset_source_get_badblock_detection(struct pmemset_source *src)

/*
* pmemset_source_get_use_count -- retrieve current use count (number of parts
* mapped from this source currenly in use)
* mapped from this source currently in use)
*/
int
pmemset_source_get_use_count(struct pmemset_source *src)
Expand Down
4 changes: 2 additions & 2 deletions src/test/obj_ulog_size/obj_ulog_size.c
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
// SPDX-License-Identifier: BSD-3-Clause
/* Copyright 2019-2021, Intel Corporation */
/* Copyright 2019-2022, Intel Corporation */

/*
* obj_ulog_size.c -- unit tests for pmemobj_action API and
Expand Down Expand Up @@ -902,7 +902,7 @@ do_ctl_snapshots_cache_size(PMEMobjpool *pop)
/*
* manual clear of the previous cache_size value,
* done in order to ensure ctl_get works properly
* and that the test does not succeed accidently
* and that the test does not succeed accidentally
*/
cache_size = 0;

Expand Down
5 changes: 3 additions & 2 deletions src/test/pmem_eADR_functions/TESTS.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!../env.py
# SPDX-License-Identifier: BSD-3-Clause
# Copyright 2021, Intel Corporation
# Copyright 2021-2022, Intel Corporation
#

import testframework as t
Expand Down Expand Up @@ -39,7 +39,8 @@ def run(self, ctx):
match = re.search(regex, log_content)

if match is None:
futils.fail(F"Failed to find any occurence of {self.function_name}"
futils.fail(F"Failed to find any occurrence of "
F"{self.function_name}"
F" with eADR in pmem_{self.testnum}.log")


Expand Down
6 changes: 3 additions & 3 deletions src/test/pmemset_deep_flush/pmemset_deep_flush.c
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
// SPDX-License-Identifier: BSD-3-Clause
/* Copyright 2021, Intel Corporation */
/* Copyright 2021-2022, Intel Corporation */

/*
* pmemset_persist.c -- pmemset_part unittests
Expand Down Expand Up @@ -86,7 +86,7 @@ test_deep_flush_single(const struct test_case *tc, int argc,

/*
* test_deep_flush_multiple_coal - test pmemset_deep_flush
* conbinations on multiple part maps with coalescing
* combinations on multiple part maps with coalescing
*/
static int
test_deep_flush_multiple_coal(const struct test_case *tc, int argc,
Expand Down Expand Up @@ -194,7 +194,7 @@ test_deep_flush_multiple_coal(const struct test_case *tc, int argc,
}

/*
* test_deep_flush_multiple - test pmemset_deep_flush conbinations on multiple
* test_deep_flush_multiple - test pmemset_deep_flush combinations on multiple
* part maps
*/
static int
Expand Down
Loading

0 comments on commit 070dd2c

Please sign in to comment.