All of lore.kernel.org
 help / color / mirror / Atom feed
From: Dan Carpenter <dan.carpenter@oracle.com>
To: Tony Luck <tony.luck@intel.com>, Mark Maule <maule@sgi.com>
Cc: Fenghua Yu <fenghua.yu@intel.com>,
	linux-ia64@vger.kernel.org, linux-kernel@vger.kernel.org,
	kernel-janitors@vger.kernel.org
Subject: [patch] [IA64] fix SN_DMA_ADDRTYPE() condition
Date: Fri, 15 Jul 2016 21:12:15 +0000	[thread overview]
Message-ID: <20160715211215.GD19522@mwanda> (raw)

The parentheses are in the wrong place so it causes a static checker
warning.  It means we don't mask away the high bits of dma_flags before
doing the comparison.

Fixes: 83821d3f558d ('[PATCH] PCI: altix: msi support')
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>

diff --git a/arch/ia64/sn/pci/pcibr/pcibr_dma.c b/arch/ia64/sn/pci/pcibr/pcibr_dma.c
index 1e863b2..71c9bf3 100644
--- a/arch/ia64/sn/pci/pcibr/pcibr_dma.c
+++ b/arch/ia64/sn/pci/pcibr/pcibr_dma.c
@@ -82,7 +82,7 @@ pcibr_dmamap_ate32(struct pcidev_info *info,
 	if (IS_PCIX(pcibus_info))
 		ate_flags &= ~(PCI32_ATE_PREF);
 
-	if (SN_DMA_ADDRTYPE(dma_flags = SN_DMA_ADDR_PHYS))
+	if (SN_DMA_ADDRTYPE(dma_flags) = SN_DMA_ADDR_PHYS)
 		xio_addr = IS_PIC_SOFT(pcibus_info) ? PHYS_TO_DMA(paddr) :
 	    					      PHYS_TO_TIODMA(paddr);
 	else

WARNING: multiple messages have this Message-ID (diff)
From: Dan Carpenter <dan.carpenter@oracle.com>
To: Tony Luck <tony.luck@intel.com>, Mark Maule <maule@sgi.com>
Cc: Fenghua Yu <fenghua.yu@intel.com>,
	linux-ia64@vger.kernel.org, linux-kernel@vger.kernel.org,
	kernel-janitors@vger.kernel.org
Subject: [patch] [IA64] fix SN_DMA_ADDRTYPE() condition
Date: Sat, 16 Jul 2016 00:12:15 +0300	[thread overview]
Message-ID: <20160715211215.GD19522@mwanda> (raw)

The parentheses are in the wrong place so it causes a static checker
warning.  It means we don't mask away the high bits of dma_flags before
doing the comparison.

Fixes: 83821d3f558d ('[PATCH] PCI: altix: msi support')
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>

diff --git a/arch/ia64/sn/pci/pcibr/pcibr_dma.c b/arch/ia64/sn/pci/pcibr/pcibr_dma.c
index 1e863b2..71c9bf3 100644
--- a/arch/ia64/sn/pci/pcibr/pcibr_dma.c
+++ b/arch/ia64/sn/pci/pcibr/pcibr_dma.c
@@ -82,7 +82,7 @@ pcibr_dmamap_ate32(struct pcidev_info *info,
 	if (IS_PCIX(pcibus_info))
 		ate_flags &= ~(PCI32_ATE_PREF);
 
-	if (SN_DMA_ADDRTYPE(dma_flags == SN_DMA_ADDR_PHYS))
+	if (SN_DMA_ADDRTYPE(dma_flags) == SN_DMA_ADDR_PHYS)
 		xio_addr = IS_PIC_SOFT(pcibus_info) ? PHYS_TO_DMA(paddr) :
 	    					      PHYS_TO_TIODMA(paddr);
 	else

             reply	other threads:[~2016-07-15 21:12 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-07-15 21:12 Dan Carpenter [this message]
2016-07-15 21:12 ` [patch] [IA64] fix SN_DMA_ADDRTYPE() condition Dan Carpenter

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=20160715211215.GD19522@mwanda \
    --to=dan.carpenter@oracle.com \
    --cc=fenghua.yu@intel.com \
    --cc=kernel-janitors@vger.kernel.org \
    --cc=linux-ia64@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=maule@sgi.com \
    --cc=tony.luck@intel.com \
    /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.