Skip to content

Commit

Permalink
Fix typos in modules/icp/
Browse files Browse the repository at this point in the history
Reviewed-by: Ryan Moeller <[email protected]>
Reviewed-by: Richard Laager <[email protected]>
Reviewed-by: Brian Behlendorf <[email protected]>
Signed-off-by: Andrea Gelmini <[email protected]>
Closes #9239
  • Loading branch information
Gelma authored and tonyhutter committed Jan 22, 2020
1 parent bcfa658 commit 8c01eb1
Show file tree
Hide file tree
Showing 12 changed files with 22 additions and 22 deletions.
6 changes: 3 additions & 3 deletions module/icp/algs/skein/skein_block.c
Original file line number Diff line number Diff line change
Expand Up @@ -159,7 +159,7 @@ Skein_256_Process_Block(Skein_256_Ctxt_t *ctx, const uint8_t *blkPtr,
ts[r + (R) + 2] = ts[r + (R) - 1]; \
Skein_Show_R_Ptr(BLK_BITS, &ctx->h, SKEIN_RND_KEY_INJECT, Xptr);

/* loop thru it */
/* loop through it */
for (r = 1; r < 2 * RCNT; r += 2 * SKEIN_UNROLL_256)
#endif
{
Expand Down Expand Up @@ -385,7 +385,7 @@ Skein_512_Process_Block(Skein_512_Ctxt_t *ctx, const uint8_t *blkPtr,
ts[r + (R)+2] = ts[r + (R) - 1]; \
Skein_Show_R_Ptr(BLK_BITS, &ctx->h, SKEIN_RND_KEY_INJECT, Xptr);

/* loop thru it */
/* loop through it */
for (r = 1; r < 2 * RCNT; r += 2 * SKEIN_UNROLL_512)
#endif /* end of looped code definitions */
{
Expand Down Expand Up @@ -667,7 +667,7 @@ Skein1024_Process_Block(Skein1024_Ctxt_t *ctx, const uint8_t *blkPtr,
ts[r + (R) + 2] = ts[r + (R) - 1]; \
Skein_Show_R_Ptr(BLK_BITS, &ctx->h, SKEIN_RND_KEY_INJECT, Xptr);

/* loop thru it */
/* loop through it */
for (r = 1; r <= 2 * RCNT; r += 2 * SKEIN_UNROLL_1024)
#endif
{
Expand Down
4 changes: 2 additions & 2 deletions module/icp/api/kcf_ctxops.c
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@
*
* Returns:
* CRYPTO_SUCCESS when the context template is successfully created.
* CRYPTO_HOST_MEMEORY: mem alloc failure
* CRYPTO_HOST_MEMORY: mem alloc failure
* CRYPTO_ARGUMENTS_BAD: NULL storage for the ctx template.
* RYPTO_MECHANISM_INVALID: invalid mechanism 'mech'.
*/
Expand Down Expand Up @@ -123,7 +123,7 @@ crypto_create_ctx_template(crypto_mechanism_t *mech, crypto_key_t *key,
* crypto_create_ctx_template()
*
* Description:
* Frees the inbedded crypto_spi_ctx_template_t, then the
* Frees the embedded crypto_spi_ctx_template_t, then the
* kcf_ctx_template_t.
*
* Context:
Expand Down
2 changes: 1 addition & 1 deletion module/icp/asm-x86_64/aes/THIRDPARTYLICENSE.openssl
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@
* must display the following acknowledgement:
* "This product includes cryptographic software written by
* Eric Young ([email protected])"
* The word 'cryptographic' can be left out if the rouines from the library
* The word 'cryptographic' can be left out if the routines from the library
* being used are not cryptographic related :-).
* 4. If you include any Windows specific code (or a derivative thereof) from
* the apps directory (application code) you must include an acknowledgement:
Expand Down
2 changes: 1 addition & 1 deletion module/icp/asm-x86_64/aes/aesopt.h
Original file line number Diff line number Diff line change
Expand Up @@ -327,7 +327,7 @@ extern "C" {
* On some systems speed will be improved by aligning the AES large lookup
* tables on particular boundaries. This define should be set to a power of
* two giving the desired alignment. It can be left undefined if alignment
* is not needed. This option is specific to the Micrsoft VC++ compiler -
* is not needed. This option is specific to the Microsoft VC++ compiler -
* it seems to sometimes cause trouble for the VC++ version 6 compiler.
*/

Expand Down
2 changes: 1 addition & 1 deletion module/icp/core/kcf_mech_tabs.c
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ kcf_mech_entry_tab_t kcf_mech_tabs_tab[KCF_LAST_OPSCLASS + 1] = {
* Per-algorithm internal thresholds for the minimum input size of before
* offloading to hardware provider.
* Dispatching a crypto operation to a hardware provider entails paying the
* cost of an additional context switch. Measurments with Sun Accelerator 4000
* cost of an additional context switch. Measurements with Sun Accelerator 4000
* shows that 512-byte jobs or smaller are better handled in software.
* There is room for refinement here.
*
Expand Down
12 changes: 6 additions & 6 deletions module/icp/core/kcf_sched.c
Original file line number Diff line number Diff line change
Expand Up @@ -182,7 +182,7 @@ kcf_areqnode_alloc(kcf_provider_desc_t *pd, kcf_context_t *ictx,
* reached, signal the creator thread for more threads.
*
* If the two conditions above are not met, we don't need to do
* any thing. The request will be picked up by one of the
* anything. The request will be picked up by one of the
* worker threads when it becomes available.
*/
static int
Expand Down Expand Up @@ -1182,7 +1182,7 @@ kcf_aop_done(kcf_areq_node_t *areq, int error)

/*
* Handle recoverable errors. This has to be done first
* before doing any thing else in this routine so that
* before doing anything else in this routine so that
* we do not change the state of the request.
*/
if (error != CRYPTO_SUCCESS && IS_RECOVERABLE(error)) {
Expand Down Expand Up @@ -1432,7 +1432,7 @@ crypto_cancel_req(crypto_req_id_t id)
/*
* There is no interface to remove an entry
* once it is on the taskq. So, we do not do
* any thing for a hardware provider.
* anything for a hardware provider.
*/
break;
default:
Expand Down Expand Up @@ -1535,7 +1535,7 @@ kcf_misc_kstat_update(kstat_t *ksp, int rw)
}

/*
* Allocate and initiatize a kcf_dual_req, used for saving the arguments of
* Allocate and initialize a kcf_dual_req, used for saving the arguments of
* a dual operation or an atomic operation that has to be internally
* simulated with multiple single steps.
* crq determines the memory allocation flags.
Expand All @@ -1551,7 +1551,7 @@ kcf_alloc_req(crypto_call_req_t *crq)
if (kcr == NULL)
return (NULL);

/* Copy the whole crypto_call_req struct, as it isn't persistant */
/* Copy the whole crypto_call_req struct, as it isn't persistent */
if (crq != NULL)
kcr->kr_callreq = *crq;
else
Expand Down Expand Up @@ -1579,7 +1579,7 @@ kcf_next_req(void *next_req_arg, int status)
kcf_provider_desc_t *pd = NULL;
crypto_dual_data_t *ct = NULL;

/* Stop the processing if an error occured at this step */
/* Stop the processing if an error occurred at this step */
if (error != CRYPTO_SUCCESS) {
out:
areq->an_reqarg = next_req->kr_callreq;
Expand Down
2 changes: 1 addition & 1 deletion module/icp/illumos-crypto.c
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@
* will use the generic implementation.
*
* 7) Removing sha384 and sha512 code: The sha code was actually very
* wasy to port. However, the generic sha384 and sha512 code actually
* easy to port. However, the generic sha384 and sha512 code actually
* exceeds the stack size on arm and powerpc architectures. In an effort
* to remove warnings, this code was removed.
*
Expand Down
2 changes: 1 addition & 1 deletion module/icp/include/sys/crypto/impl.h
Original file line number Diff line number Diff line change
Expand Up @@ -237,7 +237,7 @@ typedef struct kcf_provider_list {
struct kcf_provider_desc *pl_provider;
} kcf_provider_list_t;

/* atomic operations in linux implictly form a memory barrier */
/* atomic operations in linux implicitly form a memory barrier */
#define membar_exit()

/*
Expand Down
6 changes: 3 additions & 3 deletions module/icp/include/sys/crypto/sched_impl.h
Original file line number Diff line number Diff line change
Expand Up @@ -381,7 +381,7 @@ typedef struct kcf_pool {

/*
* cv & lock for the condition where more threads need to be
* created. kp_user_lock also protects the three fileds above.
* created. kp_user_lock also protects the three fields above.
*/
kcondvar_t kp_user_cv; /* Creator cond. variable */
kmutex_t kp_user_lock; /* Creator lock */
Expand Down Expand Up @@ -448,13 +448,13 @@ typedef struct kcf_ntfy_elem {
* The following values are based on the assumption that it would
* take around eight cpus to load a hardware provider (This is true for
* at least one product) and a kernel client may come from different
* low-priority interrupt levels. We will have CYRPTO_TASKQ_MIN number
* low-priority interrupt levels. We will have CRYPTO_TASKQ_MIN number
* of cached taskq entries. The CRYPTO_TASKQ_MAX number is based on
* a throughput of 1GB/s using 512-byte buffers. These are just
* reasonable estimates and might need to change in future.
*/
#define CRYPTO_TASKQ_THREADS 8
#define CYRPTO_TASKQ_MIN 64
#define CRYPTO_TASKQ_MIN 64
#define CRYPTO_TASKQ_MAX 2 * 1024 * 1024

extern int crypto_taskq_threads;
Expand Down
2 changes: 1 addition & 1 deletion module/icp/include/sys/crypto/spi.h
Original file line number Diff line number Diff line change
Expand Up @@ -699,7 +699,7 @@ typedef struct crypto_provider_info {

/*
* Provider status passed by a provider to crypto_provider_notification(9F)
* and returned by the provider_stauts(9E) entry point.
* and returned by the provider_status(9E) entry point.
*/
#define CRYPTO_PROVIDER_READY 0
#define CRYPTO_PROVIDER_BUSY 1
Expand Down
2 changes: 1 addition & 1 deletion module/icp/os/modhash.c
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@
* The number returned need _not_ be between 0 and nchains. The mod_hash
* code will take care of doing that. The second argument (after the
* key) to the hashing function is a void * that represents
* hash_alg_data-- this is provided so that the hashing algrorithm can
* hash_alg_data-- this is provided so that the hashing algorithm can
* maintain some state across calls, or keep algorithm-specific
* constants associated with the hash table.
*
Expand Down
2 changes: 1 addition & 1 deletion module/icp/spi/kcf_spi.c
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@
* minalloc and maxalloc values to be used for taskq_create().
*/
int crypto_taskq_threads = CRYPTO_TASKQ_THREADS;
int crypto_taskq_minalloc = CYRPTO_TASKQ_MIN;
int crypto_taskq_minalloc = CRYPTO_TASKQ_MIN;
int crypto_taskq_maxalloc = CRYPTO_TASKQ_MAX;

static void remove_provider(kcf_provider_desc_t *);
Expand Down

0 comments on commit 8c01eb1

Please sign in to comment.