mbox series

[0/2] ocxl: Move SPA and TL definitions

Message ID 20191009151109.13752-1-clombard@linux.vnet.ibm.com (mailing list archive)
Headers show
Series ocxl: Move SPA and TL definitions | expand

Message

Christophe Lombard Oct. 9, 2019, 3:11 p.m. UTC
This series moves the definition and the management of scheduled process area
(SPA) and of the templates (Transaction Layer) for an ocxl card, using the
OCAPI interface. The code is now located in the specific arch powerpc platform.
These patches will help for a futur implementation of the ocxl driver in QEMU.

The Open Coherently Attached Processor Interface (OCAPI) is used to
allow an Attached Functional Unit (AFU) to connect to the Processor
Chip's system bus in a high speed and cache coherent manner.

It builds on top of the existing ocxl driver.

It has been tested in a bare-metal environment using the memcpy and
the AFP AFUs.

christophe lombard (2):
  powerpc/powernv: ocxl move SPA definition
  powerpc/powernv: ocxl move TL definition

 arch/powerpc/include/asm/pnv-ocxl.h   |  30 +-
 arch/powerpc/platforms/powernv/ocxl.c | 378 +++++++++++++++++++++++---
 drivers/misc/ocxl/afu_irq.c           |   1 -
 drivers/misc/ocxl/config.c            |  89 +-----
 drivers/misc/ocxl/link.c              | 347 +++++++----------------
 drivers/misc/ocxl/ocxl_internal.h     |  12 -
 drivers/misc/ocxl/trace.h             |  34 +--
 7 files changed, 467 insertions(+), 424 deletions(-)

Comments

Daniel Axtens Oct. 9, 2019, 10:19 p.m. UTC | #1
Hi Christophe,

As well as the checkpatch warnings noted on Patchwork
(https://patchwork.ozlabs.org/patch/1173804/ and
https://patchwork.ozlabs.org/patch/1173805/), I noticed:

Applying: powerpc/powernv: ocxl move SPA definition
.git/rebase-apply/patch:405: new blank line at EOF.                                                                                  
+               
warning: 1 line adds whitespace errors.

Regards,
Daniel

christophe lombard <clombard@linux.vnet.ibm.com> writes:

> This series moves the definition and the management of scheduled process area
> (SPA) and of the templates (Transaction Layer) for an ocxl card, using the
> OCAPI interface. The code is now located in the specific arch powerpc platform.
> These patches will help for a futur implementation of the ocxl driver in QEMU.
>
> The Open Coherently Attached Processor Interface (OCAPI) is used to
> allow an Attached Functional Unit (AFU) to connect to the Processor
> Chip's system bus in a high speed and cache coherent manner.
>
> It builds on top of the existing ocxl driver.
>
> It has been tested in a bare-metal environment using the memcpy and
> the AFP AFUs.
>
> christophe lombard (2):
>   powerpc/powernv: ocxl move SPA definition
>   powerpc/powernv: ocxl move TL definition
>
>  arch/powerpc/include/asm/pnv-ocxl.h   |  30 +-
>  arch/powerpc/platforms/powernv/ocxl.c | 378 +++++++++++++++++++++++---
>  drivers/misc/ocxl/afu_irq.c           |   1 -
>  drivers/misc/ocxl/config.c            |  89 +-----
>  drivers/misc/ocxl/link.c              | 347 +++++++----------------
>  drivers/misc/ocxl/ocxl_internal.h     |  12 -
>  drivers/misc/ocxl/trace.h             |  34 +--
>  7 files changed, 467 insertions(+), 424 deletions(-)
>
> -- 
> 2.21.0
Andrew Donnellan Oct. 10, 2019, 10:34 p.m. UTC | #2
On 10/10/19 2:11 am, christophe lombard wrote:
> This series moves the definition and the management of scheduled process area
> (SPA) and of the templates (Transaction Layer) for an ocxl card, using the
> OCAPI interface. The code is now located in the specific arch powerpc platform.
> These patches will help for a futur implementation of the ocxl driver in QEMU.

Could you explain more about this?


Andrew


> 
> The Open Coherently Attached Processor Interface (OCAPI) is used to
> allow an Attached Functional Unit (AFU) to connect to the Processor
> Chip's system bus in a high speed and cache coherent manner.
> 
> It builds on top of the existing ocxl driver.
> 
> It has been tested in a bare-metal environment using the memcpy and
> the AFP AFUs.
> 
> christophe lombard (2):
>    powerpc/powernv: ocxl move SPA definition
>    powerpc/powernv: ocxl move TL definition
> 
>   arch/powerpc/include/asm/pnv-ocxl.h   |  30 +-
>   arch/powerpc/platforms/powernv/ocxl.c | 378 +++++++++++++++++++++++---
>   drivers/misc/ocxl/afu_irq.c           |   1 -
>   drivers/misc/ocxl/config.c            |  89 +-----
>   drivers/misc/ocxl/link.c              | 347 +++++++----------------
>   drivers/misc/ocxl/ocxl_internal.h     |  12 -
>   drivers/misc/ocxl/trace.h             |  34 +--
>   7 files changed, 467 insertions(+), 424 deletions(-)
>
Christophe Lombard Oct. 11, 2019, 8:06 a.m. UTC | #3
On 11/10/2019 00:34, Andrew Donnellan wrote:
> On 10/10/19 2:11 am, christophe lombard wrote:
>> This series moves the definition and the management of scheduled 
>> process area
>> (SPA) and of the templates (Transaction Layer) for an ocxl card, using 
>> the
>> OCAPI interface. The code is now located in the specific arch powerpc 
>> platform.
>> These patches will help for a futur implementation of the ocxl driver 
>> in QEMU.
> 
> Could you explain more about this?
> 

The Scheduled Processes Area and the configuration of the Transaction
Layer are specific to the AFU and more generally to the Opencapi
device.
Running the ocxl module in a guest environment, and later in several 
guests in parallel, using the same Opencapi device and the same AFus, 
involves to have a common code handling the SPA. This explains why these 
parts of the ocxl driver will move to arch powerpc platform running on 
the host.

Thanks.


> 
> Andrew
> 
> 
>>
>> The Open Coherently Attached Processor Interface (OCAPI) is used to
>> allow an Attached Functional Unit (AFU) to connect to the Processor
>> Chip's system bus in a high speed and cache coherent manner.
>>
>> It builds on top of the existing ocxl driver.
>>
>> It has been tested in a bare-metal environment using the memcpy and
>> the AFP AFUs.
>>
>> christophe lombard (2):
>>    powerpc/powernv: ocxl move SPA definition
>>    powerpc/powernv: ocxl move TL definition
>>
>>   arch/powerpc/include/asm/pnv-ocxl.h   |  30 +-
>>   arch/powerpc/platforms/powernv/ocxl.c | 378 +++++++++++++++++++++++---
>>   drivers/misc/ocxl/afu_irq.c           |   1 -
>>   drivers/misc/ocxl/config.c            |  89 +-----
>>   drivers/misc/ocxl/link.c              | 347 +++++++----------------
>>   drivers/misc/ocxl/ocxl_internal.h     |  12 -
>>   drivers/misc/ocxl/trace.h             |  34 +--
>>   7 files changed, 467 insertions(+), 424 deletions(-)
>>
>
Christophe Lombard Oct. 11, 2019, 9:10 a.m. UTC | #4
On 11/10/2019 10:06, christophe lombard wrote:
> On 11/10/2019 00:34, Andrew Donnellan wrote:
>> On 10/10/19 2:11 am, christophe lombard wrote:
>>> This series moves the definition and the management of scheduled 
>>> process area
>>> (SPA) and of the templates (Transaction Layer) for an ocxl card, 
>>> using the
>>> OCAPI interface. The code is now located in the specific arch powerpc 
>>> platform.
>>> These patches will help for a futur implementation of the ocxl driver 
>>> in QEMU.
>>
>> Could you explain more about this?
>>
> 
> The Scheduled Processes Area and the configuration of the Transaction
> Layer are specific to the AFU and more generally to the Opencapi
> device.
> Running the ocxl module in a guest environment, and later in several 
> guests in parallel, using the same Opencapi device and the same AFus, 
> involves to have a common code handling the SPA. This explains why these 
> parts of the ocxl driver will move to arch powerpc platform running on 
> the host.
> 
> Thanks.
> 

Implementation of the ocxl driver running on a QEMU guest environment 
will be detailed in the following patches but basically, a new ocxl vfio 
driver, running in the host, will interact, in side, with the SPA, using 
the pnv_ api(s) and on the other hand will interact, through ioctl 
commands, with the guest(s). Ocxl, running in the guest, through hcalls 
(handled by QEMU) will configure the device and interact with the vfio 
through ioctl commands.

> 
>>
>> Andrew
>>
>>
>>>
>>> The Open Coherently Attached Processor Interface (OCAPI) is used to
>>> allow an Attached Functional Unit (AFU) to connect to the Processor
>>> Chip's system bus in a high speed and cache coherent manner.
>>>
>>> It builds on top of the existing ocxl driver.
>>>
>>> It has been tested in a bare-metal environment using the memcpy and
>>> the AFP AFUs.
>>>
>>> christophe lombard (2):
>>>    powerpc/powernv: ocxl move SPA definition
>>>    powerpc/powernv: ocxl move TL definition
>>>
>>>   arch/powerpc/include/asm/pnv-ocxl.h   |  30 +-
>>>   arch/powerpc/platforms/powernv/ocxl.c | 378 +++++++++++++++++++++++---
>>>   drivers/misc/ocxl/afu_irq.c           |   1 -
>>>   drivers/misc/ocxl/config.c            |  89 +-----
>>>   drivers/misc/ocxl/link.c              | 347 +++++++----------------
>>>   drivers/misc/ocxl/ocxl_internal.h     |  12 -
>>>   drivers/misc/ocxl/trace.h             |  34 +--
>>>   7 files changed, 467 insertions(+), 424 deletions(-)
>>>
>>
>