Skip to content

Commit

Permalink
Revert "crypto: caam/jr - Remove extra memory barrier during job ring…
Browse files Browse the repository at this point in the history
… dequeue"

This reverts commit bbfcac5.

It caused a crash regression on powerpc:

https://lore.kernel.org/linux-crypto/87pnp2aflz.fsf@concordia.ellerman.id.au/

Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
  • Loading branch information
Herbert Xu committed May 9, 2019
1 parent 8c65d35 commit cbc22b0
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 9 deletions.
2 changes: 1 addition & 1 deletion drivers/crypto/caam/jr.c
Original file line number Diff line number Diff line change
Expand Up @@ -213,7 +213,7 @@ static void caam_jr_dequeue(unsigned long devarg)
mb();

/* set done */
wr_reg32_relaxed(&jrp->rregs->outring_rmvd, 1);
wr_reg32(&jrp->rregs->outring_rmvd, 1);

jrp->out_ring_read_index = (jrp->out_ring_read_index + 1) &
(JOBR_DEPTH - 1);
Expand Down
8 changes: 0 additions & 8 deletions drivers/crypto/caam/regs.h
Original file line number Diff line number Diff line change
Expand Up @@ -96,14 +96,6 @@ cpu_to_caam(16)
cpu_to_caam(32)
cpu_to_caam(64)

static inline void wr_reg32_relaxed(void __iomem *reg, u32 data)
{
if (caam_little_end)
writel_relaxed(data, reg);
else
writel_relaxed(cpu_to_be32(data), reg);
}

static inline void wr_reg32(void __iomem *reg, u32 data)
{
if (caam_little_end)
Expand Down

0 comments on commit cbc22b0

Please sign in to comment.