powerpc/vas: Return credits after handling fault
authorHaren Myneni <haren@linux.ibm.com>
Thu, 16 Apr 2020 06:04:19 +0000 (23:04 -0700)
committerMichael Ellerman <mpe@ellerman.id.au>
Mon, 20 Apr 2020 06:53:00 +0000 (16:53 +1000)
commit461862ef94a88e4b74e177b82bee2c81c6535fae
tree1c97c992a121f58b382c26e23db4100aa6009bca
parentc96c4436aba4c12f1f48369f2f90bc43e12fe36c
powerpc/vas: Return credits after handling fault

NX uses credit mechanism to control the number of requests issued on
a specific window at any point of time. Only send windows and fault
window are used credits. When the request is issued on a given window,
a credit is taken. This credit will be returned after that request is
processed. If credits are not available, returns RMA_Busy for send
window and RMA_Reject for fault window.

NX expects OS to return credit for send window after processing fault
CRB. Also credit has to be returned for fault window after handling
the fault.

Signed-off-by: Sukadev Bhattiprolu <sukadev@linux.vnet.ibm.com>
Signed-off-by: Haren Myneni <haren@linux.ibm.com>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Link: https://lore.kernel.org/r/1587017059.2275.1064.camel@hbabu-laptop
arch/powerpc/platforms/powernv/vas-fault.c
arch/powerpc/platforms/powernv/vas-window.c
arch/powerpc/platforms/powernv/vas.h