[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH 5/6] xsm: expanding function related macros in dummy.h
- To: Andrew Cooper <andrew.cooper3@xxxxxxxxxx>, xen-devel@xxxxxxxxxxxxxxxxxxxx
- From: "Daniel P. Smith" <dpsmith@xxxxxxxxxxxxxxxxxxxx>
- Date: Fri, 18 Jun 2021 12:36:58 -0400
- Arc-authentication-results: i=1; mx.zohomail.com; dkim=pass header.i=apertussolutions.com; spf=pass smtp.mailfrom=dpsmith@xxxxxxxxxxxxxxxxxxxx; dmarc=pass header.from=<dpsmith@xxxxxxxxxxxxxxxxxxxx>
- Arc-message-signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1624034223; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:MIME-Version:Message-ID:References:Subject:To; bh=fwD4j2C0XcqU9HM5vAwXuMOllkmXuq+LYI6CbhHLhMc=; b=YnYNUqng8458qQdgPlM0cfXEb7j1ss5yQl/0yBBbX07kHv4RA8diF2a7Fe5sWiCzynTq9dep4AKMkidj/w8VdNhxIAHl/SNBNcvf/SEcNyHu8VHs3c3UgbOMU9p5QQmeNiq4Bn73VVhDuYg2isyEozcipyq7DzD8GEljD9hhQZA=
- Arc-seal: i=1; a=rsa-sha256; t=1624034223; cv=none; d=zohomail.com; s=zohoarc; b=HXK2h/vHO++iqp8YBYGlicqV1WC3M3K552YSTsSOwaydlmoypxXLGS2QTfCZfJNobbVbM/82FUSmMvuN/eNS+vANcip4dVpEe9XQzsFJVEwDsQ4fqy6m39o8I6WTwS+eR0zxKHXjmM02AlrWVHYFICsasWNroPmHSC27PpRJCEM=
- Cc: Stefano Stabellini <sstabellini@xxxxxxxxxx>, Julien Grall <julien@xxxxxxx>, Volodymyr Babchuk <Volodymyr_Babchuk@xxxxxxxx>, George Dunlap <george.dunlap@xxxxxxxxxx>, Ian Jackson <iwj@xxxxxxxxxxxxxx>, Jan Beulich <jbeulich@xxxxxxxx>, Wei Liu <wl@xxxxxxx>, Roger Pau Monné <roger.pau@xxxxxxxxxx>, Tamas K Lengyel <tamas@xxxxxxxxxxxxx>, Tim Deegan <tim@xxxxxxx>, Juergen Gross <jgross@xxxxxxxx>, Alexandru Isaila <aisaila@xxxxxxxxxxxxxxx>, Petre Pircalabu <ppircalabu@xxxxxxxxxxxxxxx>, Dario Faggioli <dfaggioli@xxxxxxxx>, Paul Durrant <paul@xxxxxxx>, Daniel De Graaf <dgdegra@xxxxxxxxxxxxx>, persaur@xxxxxxxxx, christopher.w.clark@xxxxxxxxx, adam.schwalm@xxxxxxxxxx, scott.davis@xxxxxxxxxx
- Delivery-date: Fri, 18 Jun 2021 16:38:36 +0000
- List-id: Xen developer discussion <xen-devel.lists.xenproject.org>
On 6/18/21 8:03 AM, Andrew Cooper wrote:
> On 18/06/2021 00:39, Daniel P. Smith wrote:
>> diff --git a/xen/xsm/dummy.h b/xen/xsm/dummy.h
>> index 7e2bb09dac..0f8ea163af 100644
>> --- a/xen/xsm/dummy.h
>> +++ b/xen/xsm/dummy.h
>> @@ -9,7 +9,7 @@
>> *
>> *
>> * Each XSM hook implementing an access check should have its first
>> parameter
>> - * preceded by XSM_DEFAULT_ARG (or use XSM_DEFAULT_VOID if it has no
>> + * preceded by (or use XSM_DEFAULT_VOID if it has no
>> * arguments). The first non-declaration statement shold be
>> XSM_ASSERT_ACTION
>> * with the expected type of the hook, which will either define or check
>> the
>> * value of action.
>> @@ -47,14 +47,12 @@ void __xsm_action_mismatch_detected(void);
>> * xsm_default_t argument available, so the value from the assertion is
>> used to
>> * initialize the variable.
>> */
>> -#define XSM_INLINE __maybe_unused
>
> Nothing in a header file should ever need __maybe_unused. Now that the
> !XSM case has been untangled, I think this can be dropped, rather than
> expanded inline.
ack
>> -
>> -#define XSM_DEFAULT_ARG /* */
>> #define XSM_DEFAULT_VOID void
>
> XSM_DEFAULT_VOID needs to disappear too. I can't see what it is even
> doing before the cleanup, because if it is missing, you'll fail the
> compile for using K&R style functions.
ack, will drop
v/r,
dps
|