Skip to content

Commit 89b596b

Browse files
klassertherbertx
authored andcommitted
crypto: Export crypto_remove_spawns
The upcomming crypto usrerspace configuration api needs to remove the spawns on top on an algorithm, so export crypto_remove_spawns. Signed-off-by: Steffen Klassert <[email protected]> Signed-off-by: Herbert Xu <[email protected]>
1 parent 64a947b commit 89b596b

File tree

2 files changed

+5
-3
lines changed

2 files changed

+5
-3
lines changed

crypto/algapi.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -129,9 +129,8 @@ static void crypto_remove_spawn(struct crypto_spawn *spawn,
129129
BUG_ON(!list_empty(&inst->alg.cra_users));
130130
}
131131

132-
static void crypto_remove_spawns(struct crypto_alg *alg,
133-
struct list_head *list,
134-
struct crypto_alg *nalg)
132+
void crypto_remove_spawns(struct crypto_alg *alg, struct list_head *list,
133+
struct crypto_alg *nalg)
135134
{
136135
u32 new_type = (nalg ?: alg)->cra_flags;
137136
struct crypto_spawn *spawn, *n;
@@ -177,6 +176,7 @@ static void crypto_remove_spawns(struct crypto_alg *alg,
177176
crypto_remove_spawn(spawn, list);
178177
}
179178
}
179+
EXPORT_SYMBOL_GPL(crypto_remove_spawns);
180180

181181
static struct crypto_larval *__crypto_register_alg(struct crypto_alg *alg)
182182
{

crypto/internal.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -86,6 +86,8 @@ struct crypto_alg *crypto_larval_lookup(const char *name, u32 type, u32 mask);
8686
void crypto_larval_error(const char *name, u32 type, u32 mask);
8787
void crypto_alg_tested(const char *name, int err);
8888

89+
void crypto_remove_spawns(struct crypto_alg *alg, struct list_head *list,
90+
struct crypto_alg *nalg);
8991
void crypto_shoot_alg(struct crypto_alg *alg);
9092
struct crypto_tfm *__crypto_alloc_tfm(struct crypto_alg *alg, u32 type,
9193
u32 mask);

0 commit comments

Comments
 (0)