lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [day] [month] [year] [list]
Date:   Thu, 17 Feb 2022 17:52:49 +0800
From:   kernel test robot <yujie.liu@...el.com>
To:     Jason Gunthorpe <jgg@...dia.com>
CC:     <llvm@...ts.linux.dev>, <kbuild-all@...ts.01.org>,
        "Linux Kernel Mailing List" <linux-kernel@...r.kernel.org>,
        Lu Baolu <baolu.lu@...ux.intel.com>
Subject: [jgunthorpe:iommufd 18/31] drivers/gpu/drm/tegra/drm.c:998:23:
 warning: Value stored to 'domain' during its initialization is never read
 [clang-analyzer-deadcode.DeadStores]

tree:   https://github.com/jgunthorpe/linux iommufd
head:   6b5b3f20ed6b64824c2d447b4f4555fcb390bf3b
commit: ae38950aefd81c9648c5416ec4a5003e4ec03e42 [18/31] drm/tegra: Use the iommu dma_owner mechanism
config: arm-randconfig-c002-20220210 (https://download.01.org/0day-ci/archive/20220216/202202160335.Mb5DqLiM-lkp@intel.com/config)
compiler: clang version 15.0.0 (https://github.com/llvm/llvm-project e8bff9ae54a55b4dbfeb6ba55f723abbd81bf494)
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
         # install arm cross compiling tool for clang build
         # apt-get install binutils-arm-linux-gnueabi
         # https://github.com/jgunthorpe/linux/commit/ae38950aefd81c9648c5416ec4a5003e4ec03e42
         git remote add jgunthorpe https://github.com/jgunthorpe/linux
         git fetch --no-tags jgunthorpe iommufd
         git checkout ae38950aefd81c9648c5416ec4a5003e4ec03e42
         # save the config file to linux build tree
         COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross ARCH=arm clang-analyzer

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


clang-analyzer warnings: (new ones prefixed by >>)

 >> drivers/gpu/drm/tegra/drm.c:998:23: warning: Value stored to 'domain' during its initialization is never read [clang-analyzer-deadcode.DeadStores]
            struct iommu_domain *domain = iommu_get_domain_for_dev(client->dev);
                                 ^~~~~~   ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

vim +/domain +998 drivers/gpu/drm/tegra/drm.c

0c407de5ed1a329 Thierry Reding  2018-05-04   995
aacdf19849734d1 Thierry Reding  2019-02-08   996  void host1x_client_iommu_detach(struct host1x_client *client)
0c407de5ed1a329 Thierry Reding  2018-05-04   997  {
ae38950aefd81c9 Jason Gunthorpe 2021-11-18  @998  	struct iommu_domain *domain = iommu_get_domain_for_dev(client->dev);
608f43ad27ab267 Thierry Reding  2019-12-02   999  	struct drm_device *drm = dev_get_drvdata(client->host);
0c407de5ed1a329 Thierry Reding  2018-05-04  1000  	struct tegra_drm *tegra = drm->dev_private;
0c407de5ed1a329 Thierry Reding  2018-05-04  1001
aacdf19849734d1 Thierry Reding  2019-02-08  1002  	if (client->group) {
ae38950aefd81c9 Jason Gunthorpe 2021-11-18  1003  		iommu_detach_device_shared(tegra->domain, client->dev);
ae38950aefd81c9 Jason Gunthorpe 2021-11-18  1004  		iommu_device_release_dma_owner(client->dev,
ae38950aefd81c9 Jason Gunthorpe 2021-11-18  1005  					       DMA_OWNER_PRIVATE_DOMAIN);
fa6661b7aa0b520 Thierry Reding  2019-10-28  1006  		client->group = NULL;
ae38950aefd81c9 Jason Gunthorpe 2021-11-18  1007  	} else {
ae38950aefd81c9 Jason Gunthorpe 2021-11-18  1008  		iommu_device_release_dma_owner(client->dev, DMA_OWNER_DMA_API);
0c407de5ed1a329 Thierry Reding  2018-05-04  1009  	}
0c407de5ed1a329 Thierry Reding  2018-05-04  1010  }
0c407de5ed1a329 Thierry Reding  2018-05-04  1011

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

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ