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

Re: [Xen-devel] [PATCH v6 3/4] x86/ioreq server: Handle read-modify-write cases for p2m_ioreq_server pages.



>>> On 09.09.16 at 08:21, <yu.c.zhang@xxxxxxxxxxxxxxx> wrote:
> On 9/9/2016 1:26 PM, Yu Zhang wrote:
>> >>> On 02.09.16 at 12:47, <yu.c.zhang@xxxxxxxxxxxxxxx> wrote:
>> > +static const struct hvm_io_ops mem_ops = {
>> > +    .read = mem_read,
>> > +    .write = null_write
>> > +};
>> > +
>> > +static const struct hvm_io_handler mem_handler = {
>> > +    .ops = &mem_ops
>> > +};
>>
>> I think the mem_ prefix for both objects is a bad one, considering
>> that this isn't suitable for general memory handling.
> 
> How about ioreq_server_read/ops? It is only for this special p2m type.

SGTM.

>> And the comment ahead of the if() now also needs adjustment
>> (perhaps you want to merge the one you add into that one).
>>
> 
> OK. And IIUC, you mean merge to the original comments above the "if (!s)"?
> Like this:
>          /*
>           * For p2m_ioreq_server pages accessed with read-modify-write
>           * instructions, we provide a read handler to copy the data to
>           * the buffer. For other cases, if there is no suitable backing
>           * DM, we just ignore accesses.
>           */
>          if ( !s )

Yes, thanks.

Jan


_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
https://lists.xen.org/xen-devel

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.