Hi Michal,
url:
https://github.com/0day-ci/linux/commits/Michal-Rostecki/Add-roundrobin-r...
base: 92bf22614b21a2706f4993b278017e437f7785b3
config: i386-randconfig-m021-20210209 (attached as .config)
compiler: gcc-9 (Debian 9.3.0-15) 9.3.0
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
Reported-by: Dan Carpenter <dan.carpenter(a)oracle.com>
New smatch warnings:
fs/btrfs/volumes.c:635 btrfs_check_mixed() error: uninitialized symbol
'prev_device'.
Old smatch warnings:
fs/btrfs/volumes.c:1264 open_fs_devices() error: we previously assumed
'latest_dev' could be null (see line 1252)
vim +/prev_device +635 fs/btrfs/volumes.c
bd7608b9a9bbf6 Michal Rostecki 2021-02-09 629 static bool btrfs_check_mixed(struct
btrfs_fs_devices *fs_devices,
bd7608b9a9bbf6 Michal Rostecki 2021-02-09 630 bool new_device_rotating)
bd7608b9a9bbf6 Michal Rostecki 2021-02-09 631 {
bd7608b9a9bbf6 Michal Rostecki 2021-02-09 632 struct btrfs_device *device,
*prev_device;
bd7608b9a9bbf6 Michal Rostecki 2021-02-09 633
bd7608b9a9bbf6 Michal Rostecki 2021-02-09 634 list_for_each_entry(device,
&fs_devices->devices, dev_list) {
bd7608b9a9bbf6 Michal Rostecki 2021-02-09 @635 if (prev_device == NULL &&
^^^^^^^^^^^^^^^^^^^
Uninitialized.
bd7608b9a9bbf6 Michal Rostecki 2021-02-09 636 device->rotating !=
new_device_rotating)
bd7608b9a9bbf6 Michal Rostecki 2021-02-09 637 return true;
bd7608b9a9bbf6 Michal Rostecki 2021-02-09 638 if (prev_device != NULL &&
bd7608b9a9bbf6 Michal Rostecki 2021-02-09 639 (device->rotating !=
prev_device->rotating ||
bd7608b9a9bbf6 Michal Rostecki 2021-02-09 640 device->rotating !=
new_device_rotating))
bd7608b9a9bbf6 Michal Rostecki 2021-02-09 641 return true;
bd7608b9a9bbf6 Michal Rostecki 2021-02-09 642
bd7608b9a9bbf6 Michal Rostecki 2021-02-09 643 prev_device = device;
bd7608b9a9bbf6 Michal Rostecki 2021-02-09 644 }
bd7608b9a9bbf6 Michal Rostecki 2021-02-09 645
bd7608b9a9bbf6 Michal Rostecki 2021-02-09 646 return false;
bd7608b9a9bbf6 Michal Rostecki 2021-02-09 647 }
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org