qemu-devel
[Top][All Lists]
Advanced

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

Re: [PATCH v2 7/9] linux-user: Split linux-user internals out of qemu.h


From: Richard Henderson
Subject: Re: [PATCH v2 7/9] linux-user: Split linux-user internals out of qemu.h
Date: Sun, 12 Sep 2021 09:28:07 -0700
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.13.0

On 9/8/21 8:44 AM, Peter Maydell wrote:
qemu.h is included in various non-linux-user files (which
mostly want the TaskState struct and the functions for
doing usermode access to guest addresses like lock_user(),
unlock_user(), get_user*(), etc).

Split out the parts that are only used in linux-user itself
into a new user-internals.h. This leaves qemu.h with basically
three things:
  * the definition of the TaskState struct
  * the user-access functions and macros
  * do_brk()
all of which are needed by code outside linux-user that
includes qemu.h.

The addition of all the extra #include lines was done with
   sed -i '/include.*qemu\.h/a #include "user-internals.h"' $(git grep -l 
'include.*qemu\.h' linux-user)
(and then undoing the change to fpa11.h).

Signed-off-by: Peter Maydell<peter.maydell@linaro.org>
---

Reviewed-by: Richard Henderson <richard.henderson@linaro.org>

r~



reply via email to

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