[bug report] block, bfq: decrease burst size when queues in burst exit

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello Paolo Valente,

This is a semi-automatic email about new static checker warnings.

The patch 7cb04004fa37: "block, bfq: decrease burst size when queues 
in burst exit" from Sep 21, 2017, leads to the following Smatch 
complaint:

block/bfq-iosched.c:3730 bfq_put_queue()
	 error: we previously assumed 'bfqq->bfqd' could be null (see line 3720)

block/bfq-iosched.c
  3719	
  3720		if (bfqq->bfqd)
                    ^^^^^^^^^^
Check for NULL.

  3721			bfq_log_bfqq(bfqq->bfqd, bfqq, "put_queue: %p %d",
  3722				     bfqq, bfqq->ref);
  3723	
  3724		bfqq->ref--;
  3725		if (bfqq->ref)
  3726			return;
  3727	
  3728		if (bfq_bfqq_sync(bfqq) && !hlist_unhashed(&bfqq->burst_list_node)) {
  3729			hlist_del_init(&bfqq->burst_list_node);
  3730			bfqq->bfqd->burst_size--;
                        ^^^^^^^^^^^^^^^^^^^^^^
Patch adds an unchecked dereference.

  3731		}
  3732	

regards,
dan carpenter



[Index of Archives]     [Linux RAID]     [Linux SCSI]     [Linux ATA RAID]     [IDE]     [Linux Wireless]     [Linux Kernel]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Device Mapper]

  Powered by Linux