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

Re: [PATCH] tools/libxc: use uint32_t for pirq in xc_domain_irq_permission


  • To: Julien Grall <julien@xxxxxxx>
  • From: Jan Beulich <jbeulich@xxxxxxxx>
  • Date: Wed, 7 Jul 2021 14:54:03 +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-SenderADCheck; bh=sUDZAlZQr1ai+cbfSbAY7rmRuHxnzvUDZskGO0Bzo9I=; b=EvE8hAGDH2h8XtUcd/78Esl2ljUqIiWH5vOmMXdGsyIPGg2ZIsLt4CEn6HA7r+CrUeq8ybhhxO0jkYAxFSyTaeqiiUzYcZKr20TwasR87UIy4kuc1nitunQXkhXo3LkhxlCt6oxtD3nYj3lHfeVouKf6Qt5zvZgLzVOZQztg7yIfSyNW5zkK8z0qGnwbV6EoZsnv/E66X9m35bwoPssOnwBAnDlkLGpMcZxYvcSQGStHu0IgiSSXHK9LbuaZzqR8ARhY2i6svsVpo/iSoCQBmDrX0oLwr8HAvxuM3lwyK3p68YgZ6KjKnNM0tpU8IbCXqpTvigp2Ui28YfWVQuYMlw==
  • Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=KRHEDvKw5ovTD0sWJKDpFTZE5jzrwJqsnLVvYGDmrzYXjhW05cSMTYu7SSDQvRc1D59vQILfa7gYCzqmaMk8sZPIKb/KxNBy6rmHnPxHWhBRVBrB/oRis6WM2OeOXBu+jmSa9dW7Zt3zun///DM3rgsPIPU4Nv14bkSABG3s/uacS6QTAKgqGTk+HNOtVnfCMyeGzLHYVoNQOJ4NfD1A2FHm9N1Bn+mWKo4ZkUqvVmwZSRpREkWYPtP4bmI23Q0qlIbJUrw0+qi7I4ERisj0bnoIR6tGeX93VZYHo6TaUfmyXuy+07xrMf7o9utpps5czuPGl6myseeykxBX5xwNqQ==
  • Authentication-results: citrix.com; dkim=none (message not signed) header.d=none;citrix.com; dmarc=none action=none header.from=suse.com;
  • Cc: iwj@xxxxxxxxxxxxxx, wl@xxxxxxx, andrew.cooper3@xxxxxxxxxx, george.dunlap@xxxxxxxxxx, sstabellini@xxxxxxxxxx, jgross@xxxxxxxx, christian.lindig@xxxxxxxxxx, dave@xxxxxxxxxx, xen-devel@xxxxxxxxxxxxxxxxxxxx, Igor Druzhinin <igor.druzhinin@xxxxxxxxxx>
  • Delivery-date: Wed, 07 Jul 2021 12:54:13 +0000
  • List-id: Xen developer discussion <xen-devel.lists.xenproject.org>

On 07.07.2021 14:51, Julien Grall wrote:
> On 07/07/2021 02:02, Igor Druzhinin wrote:
>> Current unit8_t for pirq argument in this interface is too restrictive
>> causing failures on modern hardware with lots of GSIs. That extends down to
>> XEN_DOMCTL_irq_permission ABI structure where it needs to be fixed up
>> as well. Internal Xen structures appear to be fine. Existing users of
>> the interface in tree (libxl, ocaml and python bindings) are already using
>> int for pirq representation that should be wide enough.
> 
> By "int", I am assuming you imply "signed int", is that correct?
> 
> If so, should the function xc_domain_irq_permission() interface take an 
> int in parameter and check it is not negative?

Please let's not make things worse than they are, the more that
./CODING_STYLE is unambiguous in cases like this one. If we mean
non-negative values, the type used should be an unsigned one. In
pre-existing code this will obviously only get changed over time.

Jan




 


Rackspace

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