[kbuild] [peterz-queue:sched/core-sched 16/29] kernel/sched/core.c:4049:6: sparse: sparse: context imbalance in 'wake_up_new_task' - wrong count at exit

2021-04-15 Thread kernel test robot
CC: kbuild-...@lists.01.org
TO: Peter Zijlstra 

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/peterz/queue.git 
sched/core-sched
head:   aa17e873016be2a89e8cb3c0fe044801874b3ea5
commit: d264c7c1defc2280317a692e046aad5e7676d021 [16/29] sched: Use 
raw_spin_rq_*lock*() helpers
:: branch date: 12 hours ago
:: commit date: 12 hours ago
config: h8300-randconfig-s031-20210415 (attached as .config)
compiler: h8300-linux-gcc (GCC) 9.3.0
reproduce:
wget 
https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O 
~/bin/make.cross
chmod +x ~/bin/make.cross
# apt-get install sparse
# sparse version: v0.6.3-280-g2cd6d34e-dirty
# 
https://git.kernel.org/pub/scm/linux/kernel/git/peterz/queue.git/commit/?id=d264c7c1defc2280317a692e046aad5e7676d021
git remote add peterz-queue 
https://git.kernel.org/pub/scm/linux/kernel/git/peterz/queue.git
git fetch --no-tags peterz-queue sched/core-sched
git checkout d264c7c1defc2280317a692e046aad5e7676d021
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross C=1 
CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' W=1 ARCH=h8300 

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot 


sparse warnings: (new ones prefixed by >>)
   kernel/sched/core.c:816:38: sparse: sparse: incorrect type in initializer 
(different address spaces) @@ expected struct task_struct *curr @@ got 
struct task_struct [noderef] __rcu *curr @@
   kernel/sched/core.c:816:38: sparse: expected struct task_struct *curr
   kernel/sched/core.c:816:38: sparse: got struct task_struct [noderef] 
__rcu *curr
   kernel/sched/core.c:1936:33: sparse: sparse: incorrect type in argument 1 
(different address spaces) @@ expected struct task_struct *p @@ got 
struct task_struct [noderef] __rcu *curr @@
   kernel/sched/core.c:1936:33: sparse: expected struct task_struct *p
   kernel/sched/core.c:1936:33: sparse: got struct task_struct [noderef] 
__rcu *curr
   kernel/sched/core.c:1936:68: sparse: sparse: incorrect type in argument 1 
(different address spaces) @@ expected struct task_struct *tsk @@ got 
struct task_struct [noderef] __rcu *curr @@
   kernel/sched/core.c:1936:68: sparse: expected struct task_struct *tsk
   kernel/sched/core.c:1936:68: sparse: got struct task_struct [noderef] 
__rcu *curr
   kernel/sched/core.c:4759:38: sparse: sparse: incorrect type in initializer 
(different address spaces) @@ expected struct task_struct *curr @@ got 
struct task_struct [noderef] __rcu *curr @@
   kernel/sched/core.c:4759:38: sparse: expected struct task_struct *curr
   kernel/sched/core.c:4759:38: sparse: got struct task_struct [noderef] 
__rcu *curr
   kernel/sched/core.c:5641:14: sparse: sparse: incorrect type in assignment 
(different address spaces) @@ expected struct task_struct *prev @@ got 
struct task_struct [noderef] __rcu *curr @@
   kernel/sched/core.c:5641:14: sparse: expected struct task_struct *prev
   kernel/sched/core.c:5641:14: sparse: got struct task_struct [noderef] 
__rcu *curr
   kernel/sched/core.c:6300:17: sparse: sparse: incompatible types in 
comparison expression (different address spaces):
   kernel/sched/core.c:6300:17: sparse:struct task_struct *
   kernel/sched/core.c:6300:17: sparse:struct task_struct [noderef] __rcu *
   kernel/sched/core.c:6507:22: sparse: sparse: incompatible types in 
comparison expression (different address spaces):
   kernel/sched/core.c:6507:22: sparse:struct task_struct [noderef] __rcu *
   kernel/sched/core.c:6507:22: sparse:struct task_struct *
   kernel/sched/core.c:10192:25: sparse: sparse: incorrect type in argument 1 
(different address spaces) @@ expected struct task_struct *p @@ got 
struct task_struct [noderef] __rcu *curr @@
   kernel/sched/core.c:10192:25: sparse: expected struct task_struct *p
   kernel/sched/core.c:10192:25: sparse: got struct task_struct [noderef] 
__rcu *curr
   kernel/sched/core.c:377:6: sparse: sparse: context imbalance in 
'raw_spin_rq_lock_nested' - wrong count at exit
   kernel/sched/core.c:382:6: sparse: sparse: context imbalance in 
'raw_spin_rq_trylock' - wrong count at exit
   kernel/sched/core.c:387:6: sparse: sparse: context imbalance in 
'raw_spin_rq_unlock' - unexpected unlock
   kernel/sched/core.c:406:36: sparse: sparse: context imbalance in 
'__task_rq_lock' - wrong count at exit
   kernel/sched/core.c:447:36: sparse: sparse: context imbalance in 
'task_rq_lock' - wrong count at exit
   kernel/sched/core.c:1927:33: sparse: sparse: dereference of noderef 
expression
   kernel/sched/core.c:1928:19: sparse: sparse: dereference of noderef 
expression
   kernel/sched/core.c:1929:37: sparse: sparse: dereference of noderef 
expression
   kernel/sched/co

[kbuild] Re: drivers/gpu/drm/msm/adreno/a3xx_gpu.c:600 a3xx_gpu_init() error: passing non negative 1 to ERR_PTR

2021-04-15 Thread Dan Carpenter
On Thu, Apr 15, 2021 at 04:21:01PM -0700, Rob Clark wrote:
> > > 5785dd7a8ef0de Akhil P Oommen 2020-10-28  571 icc_path = 
> > > devm_of_icc_get(&pdev->dev, "gfx-mem");
> > > 5785dd7a8ef0de Akhil P Oommen 2020-10-28  572 ret = 
> > > IS_ERR(icc_path);
> > > 5785dd7a8ef0de Akhil P Oommen 2020-10-28  573 if (ret)
> > > 5785dd7a8ef0de Akhil P Oommen 2020-10-28  574 goto fail;
> > >
> > > IS_ERR() returns/true false so this will lead to an Oops in the caller.
> > >
> > >   icc_path = devm_of_icc_get(&pdev->dev, "gfx-mem");
> > >   if (IS_ERR(icc_path)) {
> > >   ret = PTR_ERR(icc_path);
> > >   goto fail;
> > >   }
> > Agree.
> >
> > >
> > > 5785dd7a8ef0de Akhil P Oommen 2020-10-28  575
> > > 5785dd7a8ef0de Akhil P Oommen 2020-10-28  576 ocmem_icc_path = 
> > > devm_of_icc_get(&pdev->dev, "ocmem");
> > > 5785dd7a8ef0de Akhil P Oommen 2020-10-28  577 ret = 
> > > IS_ERR(ocmem_icc_path);
> > > 5785dd7a8ef0de Akhil P Oommen 2020-10-28  578 if (ret) {
> > > 5785dd7a8ef0de Akhil P Oommen 2020-10-28  579 /* allow 
> > > -ENODATA, ocmem icc is optional */
> > > 5785dd7a8ef0de Akhil P Oommen 2020-10-28  580 if (ret != 
> > > -ENODATA)
> > > 5785dd7a8ef0de Akhil P Oommen 2020-10-28  581 
> > > goto fail;
> > >
> > > Same.  ret is true/false so it can't be equal to -ENODATA, plus the
> > > caller will Oops.
> > >
> > > Btw, this patch removed the assignments:
> > >
> > >   gpu->icc_path = of_icc_get(dev, "gfx-mem");
> > >   gpu->ocmem_icc_path = of_icc_get(dev, "ocmem");
> > >
> > > So I think "gpu->icc_path" and "gpu->ocmem_icc_path" are always
> > > NULL/unused and they should be removed.
> > >
> > Agree. Will share a fix.
> > Thanks, Dan.
> 
> gpu->ocmem_icc_path/icc_path is used on older devices.. it sounds like
> we broke some older devices and no one has noticed yet?

This is error paths and dead code.  Probably no one is affected in
real life.

regards,
dan carpenter
___
kbuild mailing list -- kbuild@lists.01.org
To unsubscribe send an email to kbuild-le...@lists.01.org


[kbuild] sound/soc/intel/catpt/loader.c:654 catpt_first_boot_firmware() warn: consider using resource_size() here

2021-04-15 Thread kernel test robot
CC: kbuild-...@lists.01.org
CC: linux-ker...@vger.kernel.org
TO: Cezary Rojewski 
CC: Mark Brown 
CC: Andy Shevchenko 

Hi Cezary,

First bad commit (maybe != root cause):

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git 
master
head:   7e25f40eab52c57ff6772d27d2aef3640a3237d7
commit: 6cbfa11d2694b8a1e46d6834fb9705d5589e3ef1 ASoC: Intel: Select catpt and 
deprecate haswell
date:   7 months ago
:: branch date: 9 hours ago
:: commit date: 7 months ago
config: i386-randconfig-m021-20210416 (attached as .config)
compiler: gcc-9 (Debian 9.3.0-22) 9.3.0

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot 
Reported-by: Dan Carpenter 

smatch warnings:
sound/soc/intel/catpt/loader.c:654 catpt_first_boot_firmware() warn: consider 
using resource_size() here

vim +654 sound/soc/intel/catpt/loader.c

a9aa6fb3eb6c7e Cezary Rojewski 2020-09-29  637  
a9aa6fb3eb6c7e Cezary Rojewski 2020-09-29  638  int 
catpt_first_boot_firmware(struct catpt_dev *cdev)
a9aa6fb3eb6c7e Cezary Rojewski 2020-09-29  639  {
a9aa6fb3eb6c7e Cezary Rojewski 2020-09-29  640  struct resource *res;
a9aa6fb3eb6c7e Cezary Rojewski 2020-09-29  641  int ret;
a9aa6fb3eb6c7e Cezary Rojewski 2020-09-29  642  
a9aa6fb3eb6c7e Cezary Rojewski 2020-09-29  643  ret = 
catpt_boot_firmware(cdev, false);
a9aa6fb3eb6c7e Cezary Rojewski 2020-09-29  644  if (ret) {
a9aa6fb3eb6c7e Cezary Rojewski 2020-09-29  645  
dev_err(cdev->dev, "basefw boot failed: %d\n", ret);
a9aa6fb3eb6c7e Cezary Rojewski 2020-09-29  646  return ret;
a9aa6fb3eb6c7e Cezary Rojewski 2020-09-29  647  }
a9aa6fb3eb6c7e Cezary Rojewski 2020-09-29  648  
a9aa6fb3eb6c7e Cezary Rojewski 2020-09-29  649  /* restrict FW Core 
dump area */
a9aa6fb3eb6c7e Cezary Rojewski 2020-09-29  650  
__request_region(&cdev->dram, 0, 0x200, NULL, 0);
a9aa6fb3eb6c7e Cezary Rojewski 2020-09-29  651  /* restrict entire area 
following BASE_FW - highest offset in DRAM */
a9aa6fb3eb6c7e Cezary Rojewski 2020-09-29  652  for (res = 
cdev->dram.child; res->sibling; res = res->sibling)
a9aa6fb3eb6c7e Cezary Rojewski 2020-09-29  653  ;
a9aa6fb3eb6c7e Cezary Rojewski 2020-09-29 @654  
__request_region(&cdev->dram, res->end + 1,

:: The code at line 654 was first introduced by commit
:: a9aa6fb3eb6c7e0e7e117b3f2dfafef8c45b9ea6 ASoC: Intel: catpt: Firmware 
loading and context restore

:: TO: Cezary Rojewski 
:: CC: Mark Brown 

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


.config.gz
Description: application/gzip
___
kbuild mailing list -- kbuild@lists.01.org
To unsubscribe send an email to kbuild-le...@lists.01.org


[kbuild] [agd5f:drm-next 53/61] drivers/pci/quirks.c:317:18: warning: Unused variable: rdev [unusedVariable]

2021-04-15 Thread kernel test robot
CC: kbuild-...@lists.01.org
TO: Prike Liang 
CC: Alex Deucher 
CC: Shyam Sundar S K 
CC: Chaitanya Kulkarni 

tree:   https://gitlab.freedesktop.org/agd5f/linux.git drm-next
head:   0739b4816007d29311a25f3a96c4c678a943309a
commit: 9597624ef6067bab1500d0273a43d4f90e62e929 [53/61] nvme: put some AMD 
PCIE downstream NVME device to simple suspend/resume path
:: branch date: 5 hours ago
:: commit date: 5 hours ago
compiler: aarch64-linux-gcc (GCC) 9.3.0

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot 


cppcheck possible warnings: (new ones prefixed by >>, may not real problems)

>> drivers/pci/quirks.c:317:18: warning: Unused variable: rdev [unusedVariable]
struct pci_dev *rdev;
^

vim +317 drivers/pci/quirks.c

^1da177e4c3f41 Linus Torvalds 2005-04-16  314  
9597624ef6067b Prike Liang2021-03-17  315  static void 
quirk_amd_nvme_fixup(struct pci_dev *dev)
9597624ef6067b Prike Liang2021-03-17  316  {
9597624ef6067b Prike Liang2021-03-17 @317   struct pci_dev *rdev;
9597624ef6067b Prike Liang2021-03-17  318  
9597624ef6067b Prike Liang2021-03-17  319   dev->dev_flags |= 
PCI_DEV_FLAGS_AMD_NVME_SIMPLE_SUSPEND;
9597624ef6067b Prike Liang2021-03-17  320   pci_info(dev, "AMD simple 
suspend opt enabled\n");
9597624ef6067b Prike Liang2021-03-17  321  

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-...@lists.01.org
___
kbuild mailing list -- kbuild@lists.01.org
To unsubscribe send an email to kbuild-le...@lists.01.org


[kbuild] drivers/platform/surface/aggregator/controller.c:968 ssam_dsm_load_u32() warn: should '((((1))) << func)' be a 64 bit type?

2021-04-15 Thread kernel test robot
CC: kbuild-...@lists.01.org
CC: linux-ker...@vger.kernel.org
TO: Maximilian Luz 
CC: Hans de Goede 

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git 
master
head:   7e25f40eab52c57ff6772d27d2aef3640a3237d7
commit: c167b9c7e3d6131b4a4865c112a3dbc86d2e997d platform/surface: Add Surface 
Aggregator subsystem
date:   3 months ago
:: branch date: 3 hours ago
:: commit date: 3 months ago
config: i386-randconfig-m021-20210415 (attached as .config)
compiler: gcc-9 (Debian 9.3.0-22) 9.3.0

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot 
Reported-by: Dan Carpenter 

smatch warnings:
drivers/platform/surface/aggregator/controller.c:968 ssam_dsm_load_u32() warn: 
should '1))) << func)' be a 64 bit type?

vim +968 drivers/platform/surface/aggregator/controller.c

c167b9c7e3d6131 Maximilian Luz 2020-12-21  962  
c167b9c7e3d6131 Maximilian Luz 2020-12-21  963  static int 
ssam_dsm_load_u32(acpi_handle handle, u64 funcs, u64 func, u32 *ret)
c167b9c7e3d6131 Maximilian Luz 2020-12-21  964  {
c167b9c7e3d6131 Maximilian Luz 2020-12-21  965  union acpi_object *obj;
c167b9c7e3d6131 Maximilian Luz 2020-12-21  966  u64 val;
c167b9c7e3d6131 Maximilian Luz 2020-12-21  967  
c167b9c7e3d6131 Maximilian Luz 2020-12-21 @968  if (!(funcs & 
BIT(func)))
c167b9c7e3d6131 Maximilian Luz 2020-12-21  969  return 0; /* 
Not supported, leave *ret at its default value */
c167b9c7e3d6131 Maximilian Luz 2020-12-21  970  
c167b9c7e3d6131 Maximilian Luz 2020-12-21  971  obj = 
acpi_evaluate_dsm_typed(handle, &SSAM_SSH_DSM_GUID,
c167b9c7e3d6131 Maximilian Luz 2020-12-21  972  
  SSAM_SSH_DSM_REVISION, func, NULL,
c167b9c7e3d6131 Maximilian Luz 2020-12-21  973  
  ACPI_TYPE_INTEGER);
c167b9c7e3d6131 Maximilian Luz 2020-12-21  974  if (!obj)
c167b9c7e3d6131 Maximilian Luz 2020-12-21  975  return -EIO;
c167b9c7e3d6131 Maximilian Luz 2020-12-21  976  
c167b9c7e3d6131 Maximilian Luz 2020-12-21  977  val = 
obj->integer.value;
c167b9c7e3d6131 Maximilian Luz 2020-12-21  978  ACPI_FREE(obj);
c167b9c7e3d6131 Maximilian Luz 2020-12-21  979  
c167b9c7e3d6131 Maximilian Luz 2020-12-21  980  if (val > U32_MAX)
c167b9c7e3d6131 Maximilian Luz 2020-12-21  981  return -ERANGE;
c167b9c7e3d6131 Maximilian Luz 2020-12-21  982  
c167b9c7e3d6131 Maximilian Luz 2020-12-21  983  *ret = val;
c167b9c7e3d6131 Maximilian Luz 2020-12-21  984  return 0;
c167b9c7e3d6131 Maximilian Luz 2020-12-21  985  }
c167b9c7e3d6131 Maximilian Luz 2020-12-21  986  

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


.config.gz
Description: application/gzip
___
kbuild mailing list -- kbuild@lists.01.org
To unsubscribe send an email to kbuild-le...@lists.01.org


[kbuild] Re: [PATCH v18 1/2] scsi: ufs: Enable power management for wlun

2021-04-15 Thread Dan Carpenter
Hi Asutosh,

url:
https://github.com/0day-ci/linux/commits/Asutosh-Das/Enable-power-management-for-ufs-wlun/20210415-030146
base:   https://git.kernel.org/pub/scm/linux/kernel/git/mkp/scsi.git for-next
config: i386-randconfig-m021-20210415 (attached as .config)
compiler: gcc-9 (Debian 9.3.0-22) 9.3.0

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot 
Reported-by: Dan Carpenter 

New smatch warnings:
drivers/scsi/ufs/ufshcd.c:9017 ufshcd_wl_resume() error: potentially 
dereferencing uninitialized 'hba'.
drivers/scsi/ufs/ufshcd.c:9141 ufshcd_system_suspend() error: uninitialized 
symbol 'ret'.
drivers/scsi/ufs/ufshcd.c:9166 ufshcd_system_resume() error: uninitialized 
symbol 'ret'.

Old smatch warnings:
drivers/scsi/ufs/ufshcd.c:5112 ufshcd_uic_cmd_compl() error: we previously 
assumed 'hba->active_uic_cmd' could be null (see line 5100)

vim +/hba +9017 drivers/scsi/ufs/ufshcd.c

9bad6c1c707d2a Asutosh Das2021-04-14  8998  
9bad6c1c707d2a Asutosh Das2021-04-14  8999  static int 
ufshcd_wl_resume(struct device *dev)
9bad6c1c707d2a Asutosh Das2021-04-14  9000  {
9bad6c1c707d2a Asutosh Das2021-04-14  9001  struct scsi_device 
*sdev = to_scsi_device(dev);
9bad6c1c707d2a Asutosh Das2021-04-14  9002  struct ufs_hba *hba;
^^^

9bad6c1c707d2a Asutosh Das2021-04-14  9003  int ret = 0;
9bad6c1c707d2a Asutosh Das2021-04-14  9004  ktime_t start = 
ktime_get();
9bad6c1c707d2a Asutosh Das2021-04-14  9005  
9bad6c1c707d2a Asutosh Das2021-04-14  9006  if 
(pm_runtime_suspended(dev))
9bad6c1c707d2a Asutosh Das2021-04-14  9007  goto out;


9bad6c1c707d2a Asutosh Das2021-04-14  9008  
9bad6c1c707d2a Asutosh Das2021-04-14  9009  hba = 
shost_priv(sdev->host);
9bad6c1c707d2a Asutosh Das2021-04-14  9010  
9bad6c1c707d2a Asutosh Das2021-04-14  9011  ret = 
__ufshcd_wl_resume(hba, UFS_SYSTEM_PM);
9bad6c1c707d2a Asutosh Das2021-04-14  9012  if (ret)
9bad6c1c707d2a Asutosh Das2021-04-14  9013  
dev_err(&sdev->sdev_gendev, "%s failed: %d\n", __func__, ret);
9bad6c1c707d2a Asutosh Das2021-04-14  9014  out:
9bad6c1c707d2a Asutosh Das2021-04-14  9015  
trace_ufshcd_wl_resume(dev_name(dev), ret,
9bad6c1c707d2a Asutosh Das2021-04-14  9016  
ktime_to_us(ktime_sub(ktime_get(), start)),
9bad6c1c707d2a Asutosh Das2021-04-14 @9017  
hba->curr_dev_pwr_mode, hba->uic_link_state);

^^
Uninitialized.

9bad6c1c707d2a Asutosh Das2021-04-14  9018  if (!ret)
9bad6c1c707d2a Asutosh Das2021-04-14  9019  
hba->is_sys_suspended = false;
9bad6c1c707d2a Asutosh Das2021-04-14  9020  up(&hba->host_sem);
9bad6c1c707d2a Asutosh Das2021-04-14  9021  return ret;
9bad6c1c707d2a Asutosh Das2021-04-14  9022  }

  [ snip ]

57d104c153d3d6 Subhash Jadavani   2014-09-25  9131  int 
ufshcd_system_suspend(struct ufs_hba *hba)
7a3e97b0dc4bba Santosh Yaraganavi 2012-02-29  9132  {
9bad6c1c707d2a Asutosh Das2021-04-14  9133  int ret;
7ff5ab47363334 Subhash Jadavani   2016-12-22  9134  ktime_t start = 
ktime_get();
57d104c153d3d6 Subhash Jadavani   2014-09-25  9135  
9bad6c1c707d2a Asutosh Das2021-04-14  9136  if 
(pm_runtime_suspended(hba->dev))
57d104c153d3d6 Subhash Jadavani   2014-09-25  9137  goto out;


3b1d05807a9a68 Vinayak Holikatti  2013-02-25  9138  
9bad6c1c707d2a Asutosh Das2021-04-14  9139  ret = 
ufshcd_suspend(hba);
57d104c153d3d6 Subhash Jadavani   2014-09-25  9140  out:
7ff5ab47363334 Subhash Jadavani   2016-12-22 @9141  
trace_ufshcd_system_suspend(dev_name(hba->dev), ret,

^^^
"ret" uninitialized.

7ff5ab47363334 Subhash Jadavani   2016-12-22  9142  
ktime_to_us(ktime_sub(ktime_get(), start)),
73eba2be9203c0 Subhash Jadavani   2017-01-10  9143  
hba->curr_dev_pwr_mode, hba->uic_link_state);
57d104c153d3d6 Subhash Jadavani   2014-09-25  9144  return ret;
57d104c153d3d6 Subhash Jadavani   2014-09-25  9145  }
57d104c153d3d6 Subhash Jadavani   2014-09-25  9146  
EXPORT_SYMBOL(ufshcd_system_suspend);
57d104c153d3d6 Subhash Jadavani   2014-09-25  9147  
57d104c153d3d6 Subhash Jadavani   2014-09-25  9148  /**
57d104c153d3d6 Subhash Jadavani   2014-09-25  9149   * ufshcd_system_resume - 
sys

[kbuild] Re: [RFC PATCH 4/4] xfs: support shrinking empty AGs

2021-04-15 Thread kernel test robot
CC: kbuild-...@lists.01.org
In-Reply-To: <20210414195240.1802221-5-hsiang...@redhat.com>
References: <20210414195240.1802221-5-hsiang...@redhat.com>
TO: Gao Xiang 

Hi Gao,

[FYI, it's a private test report for your RFC patch.]
[auto build test WARNING on xfs-linux/for-next]
[also build test WARNING on next-20210415]
[cannot apply to xiang-erofs/dev-test v5.12-rc7]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch]

url:
https://github.com/0day-ci/linux/commits/Gao-Xiang/xfs-support-shrinking-empty-AGs/20210415-035456
base:   https://git.kernel.org/pub/scm/fs/xfs/xfs-linux.git for-next
:: branch date: 19 hours ago
:: commit date: 19 hours ago
config: x86_64-randconfig-m001-20210415 (attached as .config)
compiler: gcc-9 (Debian 9.3.0-22) 9.3.0

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot 
Reported-by: Dan Carpenter 

smatch warnings:
fs/xfs/xfs_fsops.c:114 xfs_shrinkfs_deactivate_ags() error: uninitialized 
symbol 'error'.

vim +/error +114 fs/xfs/xfs_fsops.c

c789c83c7ef8f98 Gao Xiang 2021-03-23   83  
cc44e74a238999c Gao Xiang 2021-04-15   84  static int
cc44e74a238999c Gao Xiang 2021-04-15   85  xfs_shrinkfs_deactivate_ags(
cc44e74a238999c Gao Xiang 2021-04-15   86   struct xfs_mount*mp,
cc44e74a238999c Gao Xiang 2021-04-15   87   xfs_agnumber_t  
oagcount,
cc44e74a238999c Gao Xiang 2021-04-15   88   xfs_agnumber_t  
nagcount)
cc44e74a238999c Gao Xiang 2021-04-15   89  {
cc44e74a238999c Gao Xiang 2021-04-15   90   xfs_agnumber_t  agno;
cc44e74a238999c Gao Xiang 2021-04-15   91   int error;
cc44e74a238999c Gao Xiang 2021-04-15   92  
cc44e74a238999c Gao Xiang 2021-04-15   93   /* confirm AGs pending for 
shrinking are all inactive */
cc44e74a238999c Gao Xiang 2021-04-15   94   for (agno = nagcount; agno < 
oagcount; ++agno) {
cc44e74a238999c Gao Xiang 2021-04-15   95   struct xfs_buf *agfbp, 
*agibp;
cc44e74a238999c Gao Xiang 2021-04-15   96   struct xfs_perag *pag = 
xfs_perag_get(mp, agno);
cc44e74a238999c Gao Xiang 2021-04-15   97  
cc44e74a238999c Gao Xiang 2021-04-15   98   
down_write(&pag->pag_inactive_rwsem);
cc44e74a238999c Gao Xiang 2021-04-15   99   /* need to lock agi, 
agf buffers here to close all races */
cc44e74a238999c Gao Xiang 2021-04-15  100   error = 
xfs_read_agi(mp, NULL, agno, &agibp);
cc44e74a238999c Gao Xiang 2021-04-15  101   if (!error) {
cc44e74a238999c Gao Xiang 2021-04-15  102   error = 
xfs_alloc_read_agf(mp, NULL, agno, 0, &agfbp);
cc44e74a238999c Gao Xiang 2021-04-15  103   if (!error) {
cc44e74a238999c Gao Xiang 2021-04-15  104   
pag->pag_inactive = true;
cc44e74a238999c Gao Xiang 2021-04-15  105   
xfs_buf_relse(agfbp);
cc44e74a238999c Gao Xiang 2021-04-15  106   }
cc44e74a238999c Gao Xiang 2021-04-15  107   
xfs_buf_relse(agibp);
cc44e74a238999c Gao Xiang 2021-04-15  108   }
cc44e74a238999c Gao Xiang 2021-04-15  109   
up_write(&pag->pag_inactive_rwsem);
cc44e74a238999c Gao Xiang 2021-04-15  110   xfs_perag_put(pag);
cc44e74a238999c Gao Xiang 2021-04-15  111   if (error)
cc44e74a238999c Gao Xiang 2021-04-15  112   break;
cc44e74a238999c Gao Xiang 2021-04-15  113   }
cc44e74a238999c Gao Xiang 2021-04-15 @114   return error;
cc44e74a238999c Gao Xiang 2021-04-15  115  }
cc44e74a238999c Gao Xiang 2021-04-15  116  

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


.config.gz
Description: application/gzip
___
kbuild mailing list -- kbuild@lists.01.org
To unsubscribe send an email to kbuild-le...@lists.01.org


[kbuild] Re: [PATCH v18 1/2] scsi: ufs: Enable power management for wlun

2021-04-15 Thread kernel test robot
CC: kbuild-...@lists.01.org
In-Reply-To: 

References: 

TO: Asutosh Das 
TO: c...@codeaurora.org
TO: martin.peter...@oracle.com
TO: adrian.hun...@intel.com
TO: linux-s...@vger.kernel.org
CC: Asutosh Das 
CC: linux-arm-...@vger.kernel.org
CC: Alim Akhtar 
CC: Avri Altman 
CC: "James E.J. Bottomley" 
CC: Pedro Sousa 

Hi Asutosh,

I love your patch! Perhaps something to improve:

[auto build test WARNING on mkp-scsi/for-next]
[also build test WARNING on scsi/for-next next-20210415]
[cannot apply to tip/perf/core v5.12-rc7]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch]

url:
https://github.com/0day-ci/linux/commits/Asutosh-Das/Enable-power-management-for-ufs-wlun/20210415-030146
base:   https://git.kernel.org/pub/scm/linux/kernel/git/mkp/scsi.git for-next
:: branch date: 19 hours ago
:: commit date: 19 hours ago
config: i386-randconfig-m021-20210415 (attached as .config)
compiler: gcc-9 (Debian 9.3.0-22) 9.3.0

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot 
Reported-by: Dan Carpenter 

New smatch warnings:
drivers/scsi/ufs/ufshcd.c:9017 ufshcd_wl_resume() error: potentially 
dereferencing uninitialized 'hba'.
drivers/scsi/ufs/ufshcd.c:9141 ufshcd_system_suspend() error: uninitialized 
symbol 'ret'.
drivers/scsi/ufs/ufshcd.c:9166 ufshcd_system_resume() error: uninitialized 
symbol 'ret'.

Old smatch warnings:
drivers/scsi/ufs/ufshcd.c:5112 ufshcd_uic_cmd_compl() error: we previously 
assumed 'hba->active_uic_cmd' could be null (see line 5100)

vim +/hba +9017 drivers/scsi/ufs/ufshcd.c

9bad6c1c707d2a Asutosh Das2021-04-14  8998  
9bad6c1c707d2a Asutosh Das2021-04-14  8999  static int 
ufshcd_wl_resume(struct device *dev)
9bad6c1c707d2a Asutosh Das2021-04-14  9000  {
9bad6c1c707d2a Asutosh Das2021-04-14  9001  struct scsi_device 
*sdev = to_scsi_device(dev);
9bad6c1c707d2a Asutosh Das2021-04-14  9002  struct ufs_hba *hba;
9bad6c1c707d2a Asutosh Das2021-04-14  9003  int ret = 0;
9bad6c1c707d2a Asutosh Das2021-04-14  9004  ktime_t start = 
ktime_get();
9bad6c1c707d2a Asutosh Das2021-04-14  9005  
9bad6c1c707d2a Asutosh Das2021-04-14  9006  if 
(pm_runtime_suspended(dev))
9bad6c1c707d2a Asutosh Das2021-04-14  9007  goto out;
9bad6c1c707d2a Asutosh Das2021-04-14  9008  
9bad6c1c707d2a Asutosh Das2021-04-14  9009  hba = 
shost_priv(sdev->host);
9bad6c1c707d2a Asutosh Das2021-04-14  9010  
9bad6c1c707d2a Asutosh Das2021-04-14  9011  ret = 
__ufshcd_wl_resume(hba, UFS_SYSTEM_PM);
9bad6c1c707d2a Asutosh Das2021-04-14  9012  if (ret)
9bad6c1c707d2a Asutosh Das2021-04-14  9013  
dev_err(&sdev->sdev_gendev, "%s failed: %d\n", __func__, ret);
9bad6c1c707d2a Asutosh Das2021-04-14  9014  out:
9bad6c1c707d2a Asutosh Das2021-04-14  9015  
trace_ufshcd_wl_resume(dev_name(dev), ret,
9bad6c1c707d2a Asutosh Das2021-04-14  9016  
ktime_to_us(ktime_sub(ktime_get(), start)),
9bad6c1c707d2a Asutosh Das2021-04-14 @9017  
hba->curr_dev_pwr_mode, hba->uic_link_state);
9bad6c1c707d2a Asutosh Das2021-04-14  9018  if (!ret)
9bad6c1c707d2a Asutosh Das2021-04-14  9019  
hba->is_sys_suspended = false;
9bad6c1c707d2a Asutosh Das2021-04-14  9020  up(&hba->host_sem);
9bad6c1c707d2a Asutosh Das2021-04-14  9021  return ret;
9bad6c1c707d2a Asutosh Das2021-04-14  9022  }
9bad6c1c707d2a Asutosh Das2021-04-14  9023  #endif
9bad6c1c707d2a Asutosh Das2021-04-14  9024  
9bad6c1c707d2a Asutosh Das2021-04-14  9025  static void 
ufshcd_wl_shutdown(struct device *dev)
9bad6c1c707d2a Asutosh Das2021-04-14  9026  {
9bad6c1c707d2a Asutosh Das2021-04-14  9027  struct scsi_device 
*sdev = to_scsi_device(dev);
9bad6c1c707d2a Asutosh Das2021-04-14  9028  struct ufs_hba *hba;
9bad6c1c707d2a Asutosh Das2021-04-14  9029  
9bad6c1c707d2a Asutosh Das2021-04-14  9030  hba = 
shost_priv(sdev->host);
9bad6c1c707d2a Asutosh Das2021-04-14  9031  
9bad6c1c707d2a Asutosh Das2021-04-14  9032  down(&hba->host_sem);
9bad6c1c707d2a Asutosh Das2021-04-14  9033  hba->shutting_down = 
true;
9bad6c1c707d2a Asutosh Das2021-04-14  9034  up(&hba->host_sem);
9bad6c1c707d2a Asutosh Das2021-04-14  9035  
9bad6c1c707d2a Asutosh Das2021-04-14  9036  /* Turn on everything 
while shutting down */
9bad6c1c707d2a Asutosh Das2021-04-14  9037  
ufshcd_rpm_get_sync(hba);
9bad6c1c707d2a Asutosh Das2021-04-14  9038  
sc

[kbuild] Re: [PATCH 13/15] usb: dwc2: Add exit hibernation mode before removing drive

2021-04-15 Thread Dan Carpenter
Hi Artur,

https://git-scm.com/docs/git-format-patch ]

url:
https://github.com/0day-ci/linux/commits/Artur-Petrosyan/usb-dwc2-Update-exit-hibernation-when-port-reset-is-asserted/20210415-144021
 
base:   https://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb.git  
usb-testing
config: i386-randconfig-m021-20210415 (attached as .config)
compiler: gcc-9 (Debian 9.3.0-22) 9.3.0

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot 
Reported-by: Dan Carpenter 

smatch warnings:
drivers/usb/dwc2/platform.c:324 dwc2_driver_remove() error: potentially 
dereferencing uninitialized 'gr'.

vim +/gr +324 drivers/usb/dwc2/platform.c

5b9974b13e3648 drivers/staging/dwc2/platform.c Matthijs Kooijman  2013-04-22  
316  static int dwc2_driver_remove(struct platform_device *dev)
5b9974b13e3648 drivers/staging/dwc2/platform.c Matthijs Kooijman  2013-04-22  
317  {
5b9974b13e3648 drivers/staging/dwc2/platform.c Matthijs Kooijman  2013-04-22  
318   struct dwc2_hsotg *hsotg = platform_get_drvdata(dev);
8e4dbc0200040a drivers/usb/dwc2/platform.c Artur Petrosyan2021-04-15  
319   struct dwc2_gregs_backup *gr;

  ^^
b46b1ef7b0da5c drivers/usb/dwc2/platform.c Artur Petrosyan2021-04-08  
320   int ret = 0;
b46b1ef7b0da5c drivers/usb/dwc2/platform.c Artur Petrosyan2021-04-08  
321  
8e4dbc0200040a drivers/usb/dwc2/platform.c Artur Petrosyan2021-04-15  
322   /* Exit Hibernation when driver is removed. */
8e4dbc0200040a drivers/usb/dwc2/platform.c Artur Petrosyan2021-04-15  
323   if (hsotg->hibernated) {
8e4dbc0200040a drivers/usb/dwc2/platform.c Artur Petrosyan2021-04-15 
@324   if (gr->gotgctl & GOTGCTL_CURMODE_HOST) {

^^^
8e4dbc0200040a drivers/usb/dwc2/platform.c Artur Petrosyan2021-04-15  
325   ret = dwc2_exit_hibernation(hsotg, 0, 0, 1);
8e4dbc0200040a drivers/usb/dwc2/platform.c Artur Petrosyan2021-04-15  
326   if (ret)
8e4dbc0200040a drivers/usb/dwc2/platform.c Artur Petrosyan2021-04-15  
327   dev_err(hsotg->dev,
8e4dbc0200040a drivers/usb/dwc2/platform.c Artur Petrosyan2021-04-15  
328   "exit hibernation failed.\n");
8e4dbc0200040a drivers/usb/dwc2/platform.c Artur Petrosyan2021-04-15  
329   } else {
8e4dbc0200040a drivers/usb/dwc2/platform.c Artur Petrosyan2021-04-15  
330   ret = dwc2_exit_hibernation(hsotg, 0, 0, 0);
8e4dbc0200040a drivers/usb/dwc2/platform.c Artur Petrosyan2021-04-15  
331   if (ret)
8e4dbc0200040a drivers/usb/dwc2/platform.c Artur Petrosyan2021-04-15  
332   dev_err(hsotg->dev,
8e4dbc0200040a drivers/usb/dwc2/platform.c Artur Petrosyan2021-04-15  
333   "exit hibernation failed.\n");
8e4dbc0200040a drivers/usb/dwc2/platform.c Artur Petrosyan2021-04-15  
334   }
8e4dbc0200040a drivers/usb/dwc2/platform.c Artur Petrosyan2021-04-15  
335   }

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


.config.gz
Description: application/gzip
___
kbuild mailing list -- kbuild@lists.01.org
To unsubscribe send an email to kbuild-le...@lists.01.org
___
kbuild mailing list -- kbuild@lists.01.org
To unsubscribe send an email to kbuild-le...@lists.01.org


[kbuild] Re: [PATCH 13/15] usb: dwc2: Add exit hibernation mode before removing drive

2021-04-15 Thread kernel test robot
CC: kbuild-...@lists.01.org
In-Reply-To: 

References: 

TO: Artur Petrosyan 
TO: Felipe Balbi 
TO: "Greg Kroah-Hartman" 
TO: Minas Harutyunyan 
TO: linux-...@vger.kernel.org
TO: linux-ker...@vger.kernel.org
CC: John Youn 
CC: Artur Petrosyan 

Hi Artur,

Thank you for the patch! Perhaps something to improve:

[auto build test WARNING on usb/usb-testing]
[also build test WARNING on next-20210414]
[cannot apply to peter.chen-usb/for-usb-next linus/master 
balbi-usb/testing/next v5.12-rc7]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch]

url:
https://github.com/0day-ci/linux/commits/Artur-Petrosyan/usb-dwc2-Update-exit-hibernation-when-port-reset-is-asserted/20210415-144021
base:   https://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb.git 
usb-testing
:: branch date: 6 hours ago
:: commit date: 6 hours ago
config: i386-randconfig-m021-20210415 (attached as .config)
compiler: gcc-9 (Debian 9.3.0-22) 9.3.0

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot 
Reported-by: Dan Carpenter 

smatch warnings:
drivers/usb/dwc2/platform.c:324 dwc2_driver_remove() error: potentially 
dereferencing uninitialized 'gr'.

vim +/gr +324 drivers/usb/dwc2/platform.c

09a75e85779014 drivers/usb/dwc2/platform.c Marek Szyprowski   2015-10-14  
304  
5b9974b13e3648 drivers/staging/dwc2/platform.c Matthijs Kooijman  2013-04-22  
305  /**
5b9974b13e3648 drivers/staging/dwc2/platform.c Matthijs Kooijman  2013-04-22  
306   * dwc2_driver_remove() - Called when the DWC_otg core is unregistered 
with the
5b9974b13e3648 drivers/staging/dwc2/platform.c Matthijs Kooijman  2013-04-22  
307   * DWC_otg driver
5b9974b13e3648 drivers/staging/dwc2/platform.c Matthijs Kooijman  2013-04-22  
308   *
5b9974b13e3648 drivers/staging/dwc2/platform.c Matthijs Kooijman  2013-04-22  
309   * @dev: Platform device
5b9974b13e3648 drivers/staging/dwc2/platform.c Matthijs Kooijman  2013-04-22  
310   *
5b9974b13e3648 drivers/staging/dwc2/platform.c Matthijs Kooijman  2013-04-22  
311   * This routine is called, for example, when the rmmod command is 
executed. The
5b9974b13e3648 drivers/staging/dwc2/platform.c Matthijs Kooijman  2013-04-22  
312   * device may or may not be electrically present. If it is present, the 
driver
5b9974b13e3648 drivers/staging/dwc2/platform.c Matthijs Kooijman  2013-04-22  
313   * stops device processing. Any resources used on behalf of this device are
5b9974b13e3648 drivers/staging/dwc2/platform.c Matthijs Kooijman  2013-04-22  
314   * freed.
5b9974b13e3648 drivers/staging/dwc2/platform.c Matthijs Kooijman  2013-04-22  
315   */
5b9974b13e3648 drivers/staging/dwc2/platform.c Matthijs Kooijman  2013-04-22  
316  static int dwc2_driver_remove(struct platform_device *dev)
5b9974b13e3648 drivers/staging/dwc2/platform.c Matthijs Kooijman  2013-04-22  
317  {
5b9974b13e3648 drivers/staging/dwc2/platform.c Matthijs Kooijman  2013-04-22  
318   struct dwc2_hsotg *hsotg = platform_get_drvdata(dev);
8e4dbc0200040a drivers/usb/dwc2/platform.c Artur Petrosyan2021-04-15  
319   struct dwc2_gregs_backup *gr;
b46b1ef7b0da5c drivers/usb/dwc2/platform.c Artur Petrosyan2021-04-08  
320   int ret = 0;
b46b1ef7b0da5c drivers/usb/dwc2/platform.c Artur Petrosyan2021-04-08  
321  
8e4dbc0200040a drivers/usb/dwc2/platform.c Artur Petrosyan2021-04-15  
322   /* Exit Hibernation when driver is removed. */
8e4dbc0200040a drivers/usb/dwc2/platform.c Artur Petrosyan2021-04-15  
323   if (hsotg->hibernated) {
8e4dbc0200040a drivers/usb/dwc2/platform.c Artur Petrosyan2021-04-15 
@324   if (gr->gotgctl & GOTGCTL_CURMODE_HOST) {
8e4dbc0200040a drivers/usb/dwc2/platform.c Artur Petrosyan2021-04-15  
325   ret = dwc2_exit_hibernation(hsotg, 0, 0, 1);
8e4dbc0200040a drivers/usb/dwc2/platform.c Artur Petrosyan2021-04-15  
326   if (ret)
8e4dbc0200040a drivers/usb/dwc2/platform.c Artur Petrosyan2021-04-15  
327   dev_err(hsotg->dev,
8e4dbc0200040a drivers/usb/dwc2/platform.c Artur Petrosyan2021-04-15  
328   "exit hibernation failed.\n");
8e4dbc0200040a drivers/usb/dwc2/platform.c Artur Petrosyan2021-04-15  
329   } else {
8e4dbc0200040a drivers/usb/dwc2/platform.c Artur Petrosyan2021-04-15  
330   ret = dwc2_exit_hibernation(hsotg, 0, 0, 0);
8e4dbc0200040a drivers/usb/dwc2/platform.c Artur Petrosyan2021-04-15  
331   if (ret)
8e4dbc0200040a drivers/usb/dwc2/platform.c Artur Petrosyan2021-04-15  
332   dev_err(hsotg->dev,
8e4dbc0200040a drivers/usb

[kbuild] drivers/atm/nicstar.c:2691:37: sparse: sparse: context imbalance in 'ns_poll' - different lock contexts for basic block

2021-04-15 Thread kernel test robot
CC: kbuild-...@lists.01.org
CC: linux-ker...@vger.kernel.org
TO: Stafford Horne 

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git 
master
head:   7f75285ca572eaabc028cf78c6ab5473d0d160be
commit: c1d55d50139bea6bfe964458272a93dd899efb83 asm-generic/io.h: Fix sparse 
warnings on big-endian architectures
date:   8 months ago
:: branch date: 13 hours ago
:: commit date: 8 months ago
config: ia64-randconfig-s032-20210415 (attached as .config)
compiler: ia64-linux-gcc (GCC) 9.3.0
reproduce:
wget 
https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O 
~/bin/make.cross
chmod +x ~/bin/make.cross
# apt-get install sparse
# sparse version: v0.6.3-280-g2cd6d34e-dirty
# 
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=c1d55d50139bea6bfe964458272a93dd899efb83
git remote add linus 
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
git fetch --no-tags linus master
git checkout c1d55d50139bea6bfe964458272a93dd899efb83
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross C=1 
CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' W=1 ARCH=ia64 

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot 


sparse warnings: (new ones prefixed by >>)
   drivers/atm/nicstar.c:542:17: sparse: sparse: incorrect type in assignment 
(different base types) @@ expected unsigned int [usertype] word_2 @@ 
got restricted __le32 [usertype] @@
   drivers/atm/nicstar.c:542:17: sparse: expected unsigned int [usertype] 
word_2
   drivers/atm/nicstar.c:542:17: sparse: got restricted __le32 [usertype]
   drivers/atm/nicstar.c:561:17: sparse: sparse: incorrect type in assignment 
(different base types) @@ expected unsigned int [usertype] word_4 @@ 
got restricted __le32 [usertype] @@
   drivers/atm/nicstar.c:561:17: sparse: expected unsigned int [usertype] 
word_4
   drivers/atm/nicstar.c:561:17: sparse: got restricted __le32 [usertype]
   drivers/atm/nicstar.c:1149:29: sparse: sparse: cast to restricted __le32
   drivers/atm/nicstar.c:1154:56: sparse: sparse: cast to restricted __le32
   drivers/atm/nicstar.c:1484:30: sparse: sparse: cast to restricted __le32
   drivers/atm/nicstar.c:1490:44: sparse: sparse: incorrect type in assignment 
(different base types) @@ expected unsigned int [usertype] word_1 @@ 
got restricted __le32 [usertype] @@
   drivers/atm/nicstar.c:1490:44: sparse: expected unsigned int [usertype] 
word_1
   drivers/atm/nicstar.c:1490:44: sparse: got restricted __le32 [usertype]
   drivers/atm/nicstar.c:1493:44: sparse: sparse: incorrect type in assignment 
(different base types) @@ expected unsigned int [usertype] word_2 @@ 
got restricted __le32 [usertype] @@
   drivers/atm/nicstar.c:1493:44: sparse: expected unsigned int [usertype] 
word_2
   drivers/atm/nicstar.c:1493:44: sparse: got restricted __le32 [usertype]
   drivers/atm/nicstar.c:1673:29: sparse: sparse: incorrect type in assignment 
(different base types) @@ expected unsigned int [usertype] word_2 @@ 
got restricted __le32 [usertype] @@
   drivers/atm/nicstar.c:1673:29: sparse: expected unsigned int [usertype] 
word_2
   drivers/atm/nicstar.c:1673:29: sparse: got restricted __le32 [usertype]
   drivers/atm/nicstar.c:1674:29: sparse: sparse: incorrect type in assignment 
(different base types) @@ expected unsigned int [usertype] word_3 @@ 
got restricted __le32 [usertype] @@
   drivers/atm/nicstar.c:1674:29: sparse: expected unsigned int [usertype] 
word_3
   drivers/atm/nicstar.c:1674:29: sparse: got restricted __le32 [usertype]
   drivers/atm/nicstar.c:1675:29: sparse: sparse: incorrect type in assignment 
(different base types) @@ expected unsigned int [usertype] word_4 @@ 
got restricted __le32 [usertype] @@
   drivers/atm/nicstar.c:1675:29: sparse: expected unsigned int [usertype] 
word_4
   drivers/atm/nicstar.c:1675:29: sparse: got restricted __le32 [usertype]
   drivers/atm/nicstar.c:1684:29: sparse: sparse: incorrect type in assignment 
(different base types) @@ expected unsigned int [usertype] word_2 @@ 
got restricted __le32 [usertype] @@
   drivers/atm/nicstar.c:1684:29: sparse: expected unsigned int [usertype] 
word_2
   drivers/atm/nicstar.c:1684:29: sparse: got restricted __le32 [usertype]
   drivers/atm/nicstar.c:1685:29: sparse: sparse: incorrect type in assignment 
(different base types) @@ expected unsigned int [usertype] word_3 @@ 
got restricted __le32 [usertype] @@
   drivers/atm/nicstar.c:1685:29: sparse: expected unsigned int [usertype] 
word_3
   drivers/atm/nicstar.c:1685:29: sparse: got restricted __le32 [usertype]
   drivers/atm/nicstar.c:1688:29: sparse: sparse: incorrect type in assignment 
(different base types)

kbuild@lists.01.org

2021-04-15 Thread kernel test robot
CC: kbuild-...@lists.01.org
CC: linux-ker...@vger.kernel.org
CC: x...@kernel.org
TO: Thomas Gleixner 
CC: Ingo Molnar 

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/tip/tip.git locking/core
head:   a51a327f3bcdcb1a37ed9325ad07e1456cd4d426
commit: 70c80103aafdeae99126694bc1cd54de016bc258 [13/16] locking/rtmutex: 
Consolidate the fast/slowpath invocation
:: branch date: 2 weeks ago
:: commit date: 2 weeks ago
config: parisc-randconfig-m031-20210415 (attached as .config)
compiler: hppa-linux-gcc (GCC) 9.3.0

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot 
Reported-by: Dan Carpenter 

smatch warnings:
kernel/locking/rtmutex.c:1375 rt_mutex_slowunlock() warn: inconsistent returns 
'&lock->wait_lock'.
kernel/locking/rtmutex.c:1375 rt_mutex_slowunlock() warn: inconsistent returns 
'flags'.

vim +1375 kernel/locking/rtmutex.c

70c80103aafdea kernel/locking/rtmutex.c Thomas Gleixner   2021-03-26  
1311  
23f78d4a03c53c kernel/rtmutex.c Ingo Molnar   2006-06-27  
1312  /*
802ab58da74bb4 kernel/locking/rtmutex.c Sebastian Andrzej Siewior 2015-06-17  
1313   * Slow path to release a rt-mutex.
aa2bfe55366552 kernel/locking/rtmutex.c Peter Zijlstra2017-03-23  
1314   *
aa2bfe55366552 kernel/locking/rtmutex.c Peter Zijlstra2017-03-23  
1315   * Return whether the current task needs to call rt_mutex_postunlock().
23f78d4a03c53c kernel/rtmutex.c Ingo Molnar   2006-06-27  
1316   */
70c80103aafdea kernel/locking/rtmutex.c Thomas Gleixner   2021-03-26  
1317  static void __sched rt_mutex_slowunlock(struct rt_mutex *lock)
23f78d4a03c53c kernel/rtmutex.c Ingo Molnar   2006-06-27  
1318  {
70c80103aafdea kernel/locking/rtmutex.c Thomas Gleixner   2021-03-26  
1319  DEFINE_WAKE_Q(wake_q);
b4abf91047cf05 kernel/locking/rtmutex.c Thomas Gleixner   2016-01-13  
1320  unsigned long flags;
b4abf91047cf05 kernel/locking/rtmutex.c Thomas Gleixner   2016-01-13  
1321  
b4abf91047cf05 kernel/locking/rtmutex.c Thomas Gleixner   2016-01-13  
1322  /* irqsave required to support early boot calls */
b4abf91047cf05 kernel/locking/rtmutex.c Thomas Gleixner   2016-01-13  
1323  raw_spin_lock_irqsave(&lock->wait_lock, flags);
23f78d4a03c53c kernel/rtmutex.c Ingo Molnar   2006-06-27  
1324  
23f78d4a03c53c kernel/rtmutex.c Ingo Molnar   2006-06-27  
1325  debug_rt_mutex_unlock(lock);
23f78d4a03c53c kernel/rtmutex.c Ingo Molnar   2006-06-27  
1326  
27e35715df54cb kernel/locking/rtmutex.c Thomas Gleixner   2014-06-11  
1327  /*
27e35715df54cb kernel/locking/rtmutex.c Thomas Gleixner   2014-06-11  
1328   * We must be careful here if the fast path is enabled. If we
27e35715df54cb kernel/locking/rtmutex.c Thomas Gleixner   2014-06-11  
1329   * have no waiters queued we cannot set owner to NULL here
27e35715df54cb kernel/locking/rtmutex.c Thomas Gleixner   2014-06-11  
1330   * because of:
27e35715df54cb kernel/locking/rtmutex.c Thomas Gleixner   2014-06-11  
1331   *
27e35715df54cb kernel/locking/rtmutex.c Thomas Gleixner   2014-06-11  
1332   * foo->lock->owner = NULL;
27e35715df54cb kernel/locking/rtmutex.c Thomas Gleixner   2014-06-11  
1333   *  rtmutex_lock(foo->lock);   <- fast path
27e35715df54cb kernel/locking/rtmutex.c Thomas Gleixner   2014-06-11  
1334   *  free = atomic_dec_and_test(foo->refcnt);
27e35715df54cb kernel/locking/rtmutex.c Thomas Gleixner   2014-06-11  
1335   *  rtmutex_unlock(foo->lock); <- fast path
27e35715df54cb kernel/locking/rtmutex.c Thomas Gleixner   2014-06-11  
1336   *  if (free)
27e35715df54cb kernel/locking/rtmutex.c Thomas Gleixner   2014-06-11  
1337   *  kfree(foo);
27e35715df54cb kernel/locking/rtmutex.c Thomas Gleixner   2014-06-11  
1338   * raw_spin_unlock(foo->lock->wait_lock);
27e35715df54cb kernel/locking/rtmutex.c Thomas Gleixner   2014-06-11  
1339   *
27e35715df54cb kernel/locking/rtmutex.c Thomas Gleixner   2014-06-11  
1340   * So for the fastpath enabled kernel:
27e35715df54cb kernel/locking/rtmutex.c Thomas Gleixner   2014-06-11  
1341   *
27e35715df54cb kernel/locking/rtmutex.c Thomas Gleixner   2014-06-11  
1342   * Nothing can set the waiters bit as long as we hold
27e35715df54cb kernel/locking/rtmutex.c Thomas Gleixner   2014-06-11  
1343   * lock->wait_lock. So we do the following sequence:
27e35715df54cb kernel/locking/rtmutex.c Thomas Gleixner   2014-06-11  
1344   *
27e35715df54cb kernel/locking/rtmutex.c Thomas Gleixner