]> www.infradead.org Git - users/jedix/linux-maple.git/commit
crypto: ccp - Change ISR handler method for a v5 CCP
authorGary R Hook <gary.hook@amd.com>
Fri, 21 Apr 2017 15:50:14 +0000 (10:50 -0500)
committerSomasundaram Krishnasamy <somasundaram.krishnasamy@oracle.com>
Thu, 24 Aug 2017 17:57:17 +0000 (10:57 -0700)
commitd8eb003c7dbc8d04b88e82dd6db5d8728779b988
tree41a4dae57a7c7a2878722cfedd353d233e8e4ae8
parentd46be1e8fd6bdabbba7c1eb6f4344bcf2442be29
crypto: ccp - Change ISR handler method for a v5 CCP

Orabug: 26644685

The CCP has the ability to perform several operations simultaneously,
but only one interrupt.  When implemented as a PCI device and using
MSI-X/MSI interrupts, use a tasklet model to service interrupts. By
disabling and enabling interrupts from the CCP, coupled with the
queuing that tasklets provide, we can ensure that all events
(occurring on the device) are recognized and serviced.

This change fixes a problem wherein 2 or more busy queues can cause
notification bits to change state while a (CCP) interrupt is being
serviced, but after the queue state has been evaluated. This results
in the event being 'lost' and the queue hanging, waiting to be
serviced. Since the status bits are never fully de-asserted, the
CCP never generates another interrupt (all bits zero -> one or more
bits one), and no further CCP operations will be executed.

Cc: <stable@vger.kernel.org> # 4.9.x+
Signed-off-by: Gary R Hook <gary.hook@amd.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
(cherry picked from commit 6263b51eb3190d30351360fd168959af7e3a49a9)
Signed-off-by: Somasundaram Krishnasamy <somasundaram.krishnasamy@oracle.com>
Reviewed-by: Jack Vogel <jack.vogel@oracle.com>
drivers/crypto/ccp/ccp-dev-v5.c