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

Re: [XEN PATCH] ioreq: include arch-specific ioreq header in <xen/ioreq.h>


  • To: Nicola Vetrini <nicola.vetrini@xxxxxxxxxxx>
  • From: Jan Beulich <jbeulich@xxxxxxxx>
  • Date: Fri, 1 Sep 2023 09:36:10 +0200
  • Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=suse.com; dmarc=pass action=none header.from=suse.com; dkim=pass header.d=suse.com; arc=none
  • Arc-message-signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=DbeZHPuLd0FdzTnmQLzPC1BzwpcIcK69pwrxEUw1Uf0=; b=jZSBvN8kakHyWuu0mayNihiF/bvPR9gRXIxtH+fxp5JR7m1cy+3XFdlyZAxL6+XNORIMQxmmn6G6+kZbef7A3HR8R3mKndk+18jMXh+/Y0E2ejE7OpdS14c8PbSPZQtThnXOO2mEMzI6sE7hG/bC3ybv972WWcsK69r4jk1mq65X7mMHiOtNRRKUKMvx/uFj5ojU3injC8M6XmKQjzi2OYR8xvMQO2BsrE3b/WsZNOgeZa/8Nl3BqGIJMcvOz/nu8+VJFztwmF4C0DGdoeZ0YZ1zY68RzFKYf8gg4bxCPPGsFlF3YmhUi4Lz2N94/YmBy3PcVv8ac7Wa/tquLYJRDg==
  • Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=oTF6LrKzdc5kLRMBUKdFSK2zBAn7DpORe0fuqkpfYN7Nf9dklVzcEzBwVNry++tlFyTUOVTsH5kz+ViW18bvJ4YLDsXuhCwyeVzlcNihK7LLOlPKh0Ynz8Z0ZPlj68f2EUSmhYU3h6lQZHybOW15kA2ZIxzJaTPmeJHNvVEFKzrQpjczPc7P2juFxzqZE38tXMBoDaPZJJ5l6WYsHrzG5z8jte1PPC+rFIuhxeSdIlU4+DTC8kFue6wiDyNdK0KzNXiZnEwmaEIMcfEgRPsmF48AYOQAwHvKTwGFp+nJcQUzSia6a3OWSZrj6VsQ4tuU6VKUAnLiQu1ofv3jO23vcQ==
  • Authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=suse.com;
  • Cc: sstabellini@xxxxxxxxxx, michal.orzel@xxxxxxx, xenia.ragiadakou@xxxxxxx, ayan.kumar.halder@xxxxxxx, consulting@xxxxxxxxxxx, Julien Grall <julien@xxxxxxx>, Bertrand Marquis <bertrand.marquis@xxxxxxx>, Volodymyr Babchuk <Volodymyr_Babchuk@xxxxxxxx>, Paul Durrant <paul@xxxxxxx>, xen-devel@xxxxxxxxxxxxxxxxxxxx
  • Delivery-date: Fri, 01 Sep 2023 07:36:20 +0000
  • List-id: Xen developer discussion <xen-devel.lists.xenproject.org>

On 01.09.2023 09:13, Nicola Vetrini wrote:
> On 28/08/2023 09:59, Jan Beulich wrote:
>> On 25.08.2023 17:02, Nicola Vetrini wrote:
>>> The common header file for ioreq should include the arch-specific one.
>>
>> To be honest I'm not convinced of "should" here. There are two aspects
>> to consider: On one hand it is good practice to do what you say. Otoh 
>> it
>> introduces a needless dependency, and it'll require new arch-es 
>> (RISC-V,
>> PPC at present) to introduce another dummy header just to satisfy the
>> xen/ioreq.h use in common/memory.c. Therefore, _if_ we want to go this
>> route, besides a wording change here I think ...
>>
> 
> Since including both <xen/ioreq.h> and the arch-specific one was 
> requested to be changed
> in previous series, I was trying to apply the same pattern here.
> If you prefer not to change the current layout then the fix is even 
> simpler: I'll just
> include <asm/ioreq.h> in xen/arch/arm/ioreq.c, which is where it's 
> missing.
> 
>>> --- a/xen/include/xen/ioreq.h
>>> +++ b/xen/include/xen/ioreq.h
>>> @@ -20,6 +20,7 @@
>>>  #define __XEN_IOREQ_H__
>>>
>>>  #include <xen/sched.h>
>>> +#include <asm/ioreq.h>
>>
>> ... this #include wants to be conditional upon CONFIG_IOREQ_SERVER 
>> being
>> defined. (I'm actually surprised that there's no respective #ifdef in
>> that header, meaning types defined there are available even when the
>> functionality was turned off.)
> 
> The two functions in question are actually guarded by an #ifdef 
> CONFIG_IOREQ_SERVER
> in arch/arm/include/asm/ioreq.h (in the #else branch some stubs are 
> defined)

Well, I don't see how an #ifdef there helps with the aspect mentioned
earlier (new arch-es needing to needlessly provide such a header as long
as the #include here is unconditional).

Jan



 


Rackspace

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