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

Re: [PATCH] xsm/flask: code style formatting


  • To: Jan Beulich <jbeulich@xxxxxxxx>
  • From: "Daniel P. Smith" <dpsmith@xxxxxxxxxxxxxxxxxxxx>
  • Date: Tue, 26 Apr 2022 06:49:31 -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=1650970224; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:MIME-Version:Message-ID:References:Subject:To; bh=3NQrrNyZoAl0l1fOEv3Xq3z7Xgge+LjZzQZC2mC6AAI=; b=nsBqNXT+aDzm//EV9+QzlDRujpBx/zxnG/Z9gf817YDhilhgahRtW6o9NC3/P4P6gftXFPucMYEDmOShqqyW762fLPjQN52Iu4NzvAlyuU9OUzGFLmVC9twn9bMJ+V7MvhSotG3DGfTJ5DPqOtmfS8n5KYbll+wrIM2HWEyjTCM=
  • Arc-seal: i=1; a=rsa-sha256; t=1650970224; cv=none; d=zohomail.com; s=zohoarc; b=VA/LgwvKPyhMEL87ZqPVOX+nNpOGv7cDnLFnV7DcptEDb90erKtqd+0dT+/J709R+epTxNU6tZPM99k22ErjEXIrmhidRDtF34neaIaelEOEw0THD6I8kW79/BIblJTxKBRBDJKYEK2MP/kxMdBSFEncxjozyLIrM9fY/v9U0cY=
  • Cc: "jandryuk@xxxxxxxxx" <jandryuk@xxxxxxxxx>, Daniel De Graaf <dgdegra@xxxxxxxxxxxxx>, "xen-devel@xxxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxxx>, Andrew Cooper <Andrew.Cooper3@xxxxxxxxxx>
  • Delivery-date: Tue, 26 Apr 2022 10:50:33 +0000
  • List-id: Xen developer discussion <xen-devel.lists.xenproject.org>



On 4/26/22 04:38, Jan Beulich wrote:
On 23.04.2022 01:07, Andrew Cooper wrote:
On 22/04/2022 20:43, Daniel P. Smith wrote:
diff --git a/xen/xsm/flask/hooks.c b/xen/xsm/flask/hooks.c
index 0bf63ffa84..e2ebbc7716 100644
--- a/xen/xsm/flask/hooks.c
+++ b/xen/xsm/flask/hooks.c
@@ -120,8 +121,8 @@ static int get_irq_sid(int irq, u32 *sid, struct 
avc_audit_data *ad)
          struct irq_desc *desc = irq_to_desc(irq);
          if ( desc->msi_desc && desc->msi_desc->dev ) {

I've elected to also fix this misplaced brace while committing.

Ack.

              struct pci_dev *dev = desc->msi_desc->dev;
-            u32 sbdf = (dev->seg << 16) | (dev->bus << 8) | dev->devfn;
-            if (ad) {
+            uint32_t sbdf = (dev->seg << 16) | (dev->bus << 8) | dev->devfn;
+            if ( ad ) {

Brace on newline, and in the subsequent hunk.  Can be fixed on commit.

Otherwise, LGTM.  Acked-by: Andrew Cooper <andrew.cooper3@xxxxxxxxxx>

Strictly speaking the u32 -> uint32_t conversion was getting us only
half the mileage, but I've committed the change as is (in this regard)
nevertheless. In many of the cases "unsigned int" or alike should be
used instead.

Thank you, I can add a review of uint{X}_t usage to the list of updates for flask.

v/r,
dps



 


Rackspace

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