mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: kernel test robot <lkp@intel.com>
To: Maxime Ripard <maxime@cerno.tech>
Cc: kbuild-all@lists.01.org, linux-kernel@vger.kernel.org,
	Joerg Roedel <jroedel@suse.de>
Subject: drivers/iommu/sun50i-iommu.c:890:14: warning: variable 'iova' set but not used
Date: Fri, 31 Jul 2020 23:49:54 +0800	[thread overview]
Message-ID: <202007312350.PhZJvuP9%lkp@intel.com> (raw)

[-- Attachment #1: Type: text/plain, Size: 3329 bytes --]

Hi Maxime,

FYI, the error/warning still remains.

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head:   d8b9faec54ae4bc2fff68bcd0befa93ace8256ce
commit: 4100b8c229b328358cc4a82f5042dbf22f1c1ccb iommu: Add Allwinner H6 IOMMU driver
date:   3 months ago
config: ia64-randconfig-r003-20200731 (attached as .config)
compiler: ia64-linux-gcc (GCC) 9.3.0
reproduce (this is a W=1 build):
        wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        git checkout 4100b8c229b328358cc4a82f5042dbf22f1c1ccb
        # save the attached .config to linux build tree
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=ia64 

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>

All warnings (new ones prefixed by >>):

   drivers/iommu/sun50i-iommu.c: In function 'sun50i_dte_get_page_table':
   drivers/iommu/sun50i-iommu.c:486:16: warning: unused variable 'flags' [-Wunused-variable]
     486 |  unsigned long flags;
         |                ^~~~~
   drivers/iommu/sun50i-iommu.c: In function 'sun50i_iommu_unmap':
   drivers/iommu/sun50i-iommu.c:561:13: warning: variable 'pte_dma' set but not used [-Wunused-but-set-variable]
     561 |  dma_addr_t pte_dma;
         |             ^~~~~~~
   drivers/iommu/sun50i-iommu.c:559:23: warning: unused variable 'iommu' [-Wunused-variable]
     559 |  struct sun50i_iommu *iommu = sun50i_domain->iommu;
         |                       ^~~~~
   drivers/iommu/sun50i-iommu.c: In function 'sun50i_iommu_probe_device':
   drivers/iommu/sun50i-iommu.c:749:22: warning: unused variable 'group' [-Wunused-variable]
     749 |  struct iommu_group *group;
         |                      ^~~~~
   drivers/iommu/sun50i-iommu.c: In function 'sun50i_iommu_irq':
>> drivers/iommu/sun50i-iommu.c:890:14: warning: variable 'iova' set but not used [-Wunused-but-set-variable]
     890 |  phys_addr_t iova;
         |              ^~~~

vim +/iova +890 drivers/iommu/sun50i-iommu.c

   886	
   887	static irqreturn_t sun50i_iommu_irq(int irq, void *dev_id)
   888	{
   889		struct sun50i_iommu *iommu = dev_id;
 > 890		phys_addr_t iova;
   891		u32 status;
   892	
   893		spin_lock(&iommu->iommu_lock);
   894	
   895		status = iommu_read(iommu, IOMMU_INT_STA_REG);
   896		if (!(status & IOMMU_INT_MASK)) {
   897			spin_unlock(&iommu->iommu_lock);
   898			return IRQ_NONE;
   899		}
   900	
   901		if (status & IOMMU_INT_INVALID_L2PG)
   902			iova = sun50i_iommu_handle_pt_irq(iommu,
   903							  IOMMU_INT_ERR_ADDR_L2_REG,
   904							  IOMMU_L2PG_INT_REG);
   905		else if (status & IOMMU_INT_INVALID_L1PG)
   906			iova = sun50i_iommu_handle_pt_irq(iommu,
   907							  IOMMU_INT_ERR_ADDR_L1_REG,
   908							  IOMMU_L1PG_INT_REG);
   909		else
   910			iova = sun50i_iommu_handle_perm_irq(iommu);
   911	
   912		iommu_write(iommu, IOMMU_INT_CLR_REG, status);
   913	
   914		iommu_write(iommu, IOMMU_RESET_REG, ~status);
   915		iommu_write(iommu, IOMMU_RESET_REG, status);
   916	
   917		spin_unlock(&iommu->iommu_lock);
   918	
   919		return IRQ_HANDLED;
   920	}
   921	

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org

[-- Attachment #2: .config.gz --]
[-- Type: application/gzip, Size: 37106 bytes --]

             reply	other threads:[~2020-07-31 16:14 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-07-31 15:49 kernel test robot [this message]
2020-08-25 13:58 kernel test robot

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=202007312350.PhZJvuP9%lkp@intel.com \
    --to=lkp@intel.com \
    --cc=jroedel@suse.de \
    --cc=kbuild-all@lists.01.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=maxime@cerno.tech \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®