All of lore.kernel.org
 help / color / mirror / Atom feed
From: Julien Grall <julien@xen.org>
To: Jan Beulich <jbeulich@suse.com>
Cc: "xen-devel@lists.xenproject.org" <xen-devel@lists.xenproject.org>,
	Stefano Stabellini <sstabellini@kernel.org>
Subject: Re: [PATCH 4/8] Arm: prune #include-s needed by domain.h
Date: Mon, 20 Jul 2020 10:09:41 +0100	[thread overview]
Message-ID: <2cc66fdb-1da2-16cd-717a-3248d136821c@xen.org> (raw)
In-Reply-To: <931149db-2daf-6d72-0330-c938b5084eb6@suse.com>



On 20/07/2020 09:17, Jan Beulich wrote:
> On 17.07.2020 16:44, Julien Grall wrote:
>> On 15/07/2020 11:39, Jan Beulich wrote:
>>> --- a/xen/include/asm-arm/domain.h
>>> +++ b/xen/include/asm-arm/domain.h
>>> @@ -2,7 +2,7 @@
>>>    #define __ASM_DOMAIN_H__
>>>    
>>>    #include <xen/cache.h>
>>> -#include <xen/sched.h>
>>> +#include <xen/timer.h>
>>>    #include <asm/page.h>
>>>    #include <asm/p2m.h>
>>>    #include <asm/vfp.h>
>>> @@ -11,8 +11,6 @@
>>>    #include <asm/vgic.h>
>>>    #include <asm/vpl011.h>
>>>    #include <public/hvm/params.h>
>>> -#include <xen/serial.h>
>>
>> While we don't need the rbtree.h, we technically need serial.h for using
>> vuart_info.
> 
> The only reference to it is
> 
>          const struct vuart_info     *info;
> 
> which doesn't require a definition nor even a forward declaration
> of struct vuart_info. It should just be source files instantiating
> a struct or de-referencing pointers to one that actually need to
> see the full declaration. 

Ah yes. I got confused because you introduced a forward declaration of 
struct vcpu. But this is because you need it to declare the function 
prototype.

> The only source file doing so (vuart.c)
> already includes xen/serial.h. (In fact, it being just a single
> source file doing so, the struct definition could [and imo should]
> be moved there. The type can be entirely opaque to the rest of the
> code base, as - over time - we've been doing for other structs.)

There are definitely more use of vuart_info within the code base. All 
the UART on Arm will fill up the structure (see drivers/char/pl011.c) 
for instance.

So the definition is in the correct place.

Cheers,

-- 
Julien Grall


  reply	other threads:[~2020-07-20  9:10 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-07-15 10:29 [PATCH 0/8] x86: build adjustments Jan Beulich
2020-07-15 10:37 ` [PATCH 1/8] x86/EFI: sanitize build logic Jan Beulich
2020-07-15 10:37 ` [PATCH 2/8] x86: don't build with EFI support in shim-exclusive mode Jan Beulich
2020-07-15 10:38 ` [PATCH 3/8] x86: shrink struct arch_{vcpu,domain} when !HVM Jan Beulich
2020-07-15 10:39 ` [PATCH 4/8] Arm: prune #include-s needed by domain.h Jan Beulich
2020-07-15 16:54   ` Stefano Stabellini
2020-07-17 14:44   ` Julien Grall
2020-07-20  8:17     ` Jan Beulich
2020-07-20  9:09       ` Julien Grall [this message]
2020-07-20 11:28         ` Jan Beulich
2020-07-20 15:15           ` Julien Grall
2020-07-20 16:17             ` Julien Grall
2020-07-15 10:40 ` [PATCH 5/8] bitmap: move to/from xenctl_bitmap conversion helpers Jan Beulich
2020-07-20 16:20   ` Julien Grall
2020-07-21  7:31     ` Jan Beulich
2020-07-15 10:40 ` [PATCH 6/8] x86: move domain_cpu_policy_changed() Jan Beulich
2020-07-15 10:41 ` [PATCH 7/8] x86: move cpu_{up,down}_helper() Jan Beulich
2020-07-15 10:41 ` [PATCH 8/8] x86: don't include domctl and alike in shim-exclusive builds Jan Beulich

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=2cc66fdb-1da2-16cd-717a-3248d136821c@xen.org \
    --to=julien@xen.org \
    --cc=jbeulich@suse.com \
    --cc=sstabellini@kernel.org \
    --cc=xen-devel@lists.xenproject.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.