linux-raid.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* re: md: raid 10 supports TRIM
@ 2012-08-16 11:02 Dan Carpenter
       [not found] ` <502DAEB3.6080302@fusionio.com>
  0 siblings, 1 reply; 5+ messages in thread
From: Dan Carpenter @ 2012-08-16 11:02 UTC (permalink / raw)
  To: shli; +Cc: linux-raid

Hello Shaohua Li,

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

The patch d61b764704ca: "md: raid 10 supports TRIM" from Aug 15, 
2012, leads to the following Smatch complaint:

drivers/md/raid10.c:3510 run()
	 warn: variable dereferenced before check 'mddev->queue' (see line 3508)

drivers/md/raid10.c
  3507	
  3508		blk_queue_max_discard_sectors(mddev->queue, mddev->chunk_sectors);
                                              ^^^^^^^^^^^^
New dereference.

  3509		chunk_size = mddev->chunk_sectors << 9;
  3510		if (mddev->queue) {
                    ^^^^^^^^^^^^
Old check.

  3511			blk_queue_io_min(mddev->queue, chunk_size);
  3512			if (conf->geo.raid_disks % conf->geo.near_copies)

regards,
dan carpenter


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2012-08-17 23:51 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-08-16 11:02 md: raid 10 supports TRIM Dan Carpenter
     [not found] ` <502DAEB3.6080302@fusionio.com>
2012-08-17  4:00   ` Shaohua Li
2012-08-17  8:41     ` Jan Ceuleers
2012-08-17  9:28       ` NeilBrown
2012-08-17 23:51     ` NeilBrown

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).