powerpc/powernv: Add opal calls for opencapi
authorFrederic Barrat <fbarrat@linux.vnet.ibm.com>
Tue, 23 Jan 2018 11:31:38 +0000 (12:31 +0100)
committerMichael Ellerman <mpe@ellerman.id.au>
Wed, 24 Jan 2018 00:42:56 +0000 (11:42 +1100)
commit74d656d219b98ef3b96f92439337aa6392a7577d
treef1f31b42e53191da5c16799af316abccc0d46ea4
parent228c2f4103788ba2a8df636f383ec2df33b47b73
powerpc/powernv: Add opal calls for opencapi

Add opal calls to interact with the NPU:

OPAL_NPU_SPA_SETUP: set the Shared Process Area (SPA)
The SPA is a table containing one entry (Process Element) per memory
context which can be accessed by the opencapi device.

OPAL_NPU_SPA_CLEAR_CACHE: clear the context cache
The NPU keeps a cache of recently accessed memory contexts. When a
Process Element is removed from the SPA, the cache for the link must
be cleared.

OPAL_NPU_TL_SET: configure the Transaction Layer
The Transaction Layer specification defines several templates for
messages to be exchanged on the link. During link setup, the host and
device must negotiate what templates are supported on both sides and
at what rates those messages can be sent.

Signed-off-by: Frederic Barrat <fbarrat@linux.vnet.ibm.com>
Acked-by: Andrew Donnellan <andrew.donnellan@au1.ibm.com>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
arch/powerpc/include/asm/opal-api.h
arch/powerpc/include/asm/opal.h
arch/powerpc/platforms/powernv/opal-wrappers.S