From mboxrd@z Thu Jan 1 00:00:00 1970 From: Tamas Lengyel Subject: Re: [PATCH V6 01/13] xen/mem_event: Cleanup of mem_event structures Date: Thu, 12 Mar 2015 13:32:34 +0100 Message-ID: References: <1424218303-11331-1-git-send-email-tamas.lengyel@zentific.com> <1424218303-11331-2-git-send-email-tamas.lengyel@zentific.com> <20150312121337.GC22158@deinos.phlegethon.org> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="===============3605609805802922984==" Return-path: In-Reply-To: <20150312121337.GC22158@deinos.phlegethon.org> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: Tim Deegan Cc: Kevin Tian , wei.liu2@citrix.com, Ian Campbell , Steven Maresca , Stefano Stabellini , Jun Nakajima , Eddie Dong , Ian Jackson , xen-devel@lists.xen.org, Andres Lagar-Cavilla , Jan Beulich , rshriram@cs.ubc.ca, Keir Fraser , Daniel De Graaf , yanghy@cn.fujitsu.com, Razvan Cojocaru List-Id: xen-devel@lists.xenproject.org --===============3605609805802922984== Content-Type: multipart/alternative; boundary=089e01493f6014527a0511169469 --089e01493f6014527a0511169469 Content-Type: text/plain; charset=UTF-8 On Thu, Mar 12, 2015 at 1:13 PM, Tim Deegan wrote: > At 01:11 +0100 on 18 Feb (1424218291), Tamas K Lengyel wrote: > > +struct mem_event_mem_access { > > uint64_t gfn; > > uint64_t offset; > > - uint64_t gla; /* if gla_valid */ > > + uint64_t gla; /* if flags has MEM_ACCESS_GLA_VALID set */ > > + uint32_t flags; /* MEM_ACCESS_* */ > > + uint32_t _pad; > > +}; > > + > > +struct mem_event_mov_to_cr { > > + uint64_t new_value; > > + uint64_t old_value; > > +}; > > + > > +struct mem_event_debug { > > + uint64_t gfn; > > +}; > > > > +struct mem_event_mov_to_msr { > > + uint64_t msr; > > + uint64_t value; > > +}; > > + > > +#define MEM_PAGING_DROP_PAGE (1 << 0) > > +#define MEM_PAGING_EVICT_FAIL (1 << 1) > > + > > +struct mem_event_paging { > > + uint64_t gfn; > > uint32_t p2mt; > > + uint32_t flags; > > +}; > > + > > +struct mem_event_sharing { > > + uint64_t gfn; > > + uint32_t p2mt; > > +}; > > I see you have padded struct mem_event_mem_access to an 8-byte > boundary but not this -- given the union I suppose it makes no > difference but it woud be consistent to add padding here too. > Ack, will do! > > In any case, > > Acked-by: Tim Deegan > > Tim. > Thanks, Tamas --089e01493f6014527a0511169469 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable


On Thu, Mar 12, 2015 at 1:13 PM, Tim Deegan <tim@xen.org> wrot= e:
At 01:11 +0100 on 18 Feb (1424218291), Tamas K Lengyel wrote:
> +struct mem_event_mem_access {
>=C2=A0 =C2=A0 =C2=A0 uint64_t gfn;
>=C2=A0 =C2=A0 =C2=A0 uint64_t offset;
> -=C2=A0 =C2=A0 uint64_t gla; /* if gla_valid */
> +=C2=A0 =C2=A0 uint64_t gla;=C2=A0 =C2=A0/* if flags has MEM_ACCESS_GL= A_VALID set */
> +=C2=A0 =C2=A0 uint32_t flags; /* MEM_ACCESS_* */
> +=C2=A0 =C2=A0 uint32_t _pad;
> +};
> +
> +struct mem_event_mov_to_cr {
> +=C2=A0 =C2=A0 uint64_t new_value;
> +=C2=A0 =C2=A0 uint64_t old_value;
> +};
> +
> +struct mem_event_debug {
> +=C2=A0 =C2=A0 uint64_t gfn;
> +};
>
> +struct mem_event_mov_to_msr {
> +=C2=A0 =C2=A0 uint64_t msr;
> +=C2=A0 =C2=A0 uint64_t value;
> +};
> +
> +#define MEM_PAGING_DROP_PAGE=C2=A0 =C2=A0 =C2=A0 =C2=A0(1 << 0)=
> +#define MEM_PAGING_EVICT_FAIL=C2=A0 =C2=A0 =C2=A0 (1 << 1)
> +
> +struct mem_event_paging {
> +=C2=A0 =C2=A0 uint64_t gfn;
>=C2=A0 =C2=A0 =C2=A0 uint32_t p2mt;
> +=C2=A0 =C2=A0 uint32_t flags;
> +};
> +
> +struct mem_event_sharing {
> +=C2=A0 =C2=A0 uint64_t gfn;
> +=C2=A0 =C2=A0 uint32_t p2mt;
> +};

I see you have padded struct mem_event_mem_access to an 8-byte<= br> boundary but not this -- given the union I suppose it makes no
difference but it woud be consistent to add padding here too.

Ack, will do!
=C2=A0

In any case,

Acked-by: Tim Deegan <tim@xen.org>=

Tim.

Thanks,
Tamas

--089e01493f6014527a0511169469-- --===============3605609805802922984== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ Xen-devel mailing list Xen-devel@lists.xen.org http://lists.xen.org/xen-devel --===============3605609805802922984==--