qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Linuxarm] Re: [RFC PATCH v2 07/32] hw/cxl/device: Implement basic


From: Ben Widawsky
Subject: Re: [Linuxarm] Re: [RFC PATCH v2 07/32] hw/cxl/device: Implement basic mailbox (8.2.8.4)
Date: Wed, 6 Jan 2021 11:08:25 -0800

On 21-01-06 10:05:57, Ben Widawsky wrote:
> On 21-01-06 17:40:14, Jonathan Cameron wrote:
> > On Wed, 6 Jan 2021 13:21:23 +0000
> > Jonathan Cameron <Jonathan.Cameron@Huawei.com> wrote:
> > 
> > > On Tue, 5 Jan 2021 08:52:58 -0800
> > > Ben Widawsky <ben.widawsky@intel.com> wrote:
> > > 

[snip]

> 
> I'm sorry you had to debug this. I had fixed this previously and it got lost.
> I'm currently between test applications, so my regression testing isn't great.
> 
> I think the fix should be something like this, but I can't easily test at the
> moment:
> 
> diff --git a/hw/cxl/cxl-device-utils.c b/hw/cxl/cxl-device-utils.c
> index c515d45d20..b38e9b4c17 100644
> --- a/hw/cxl/cxl-device-utils.c
> +++ b/hw/cxl/cxl-device-utils.c
> @@ -102,6 +102,9 @@ static void mailbox_reg_write(void *opaque, hwaddr 
> offset, uint64_t value,
>  {
>      CXLDeviceState *cxl_dstate = opaque;
> 
> +    if (offset >= A_CXL_DEV_CMD_PAYLOAD)
> +        stn_le_p(cxl_dstate->mbox_reg_state, size, value);
> +
>      /*
>       * Lock is needed to prevent concurrent writes as well as to prevent 
> writes
>       * coming in while the firmware is processing. Without background 
> commands
> 
> 
> 

+    if (offset >= A_CXL_DEV_CMD_PAYLOAD) {
+        stn_le_p(cxl_dstate->mbox_reg_state, size, value);
+        return;
+    }
+

[snip]

> 



reply via email to

[Prev in Thread] Current Thread [Next in Thread]