qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v3 0/2] ide: Fix incorrect handling of some PRDTs and add the corresponding unit-test
@ 2019-12-23 17:51 Alexander Popov
  2019-12-23 17:51 ` [PATCH v3 1/2] ide: Fix incorrect handling of some PRDTs in ide_dma_cb() Alexander Popov
                   ` (4 more replies)
  0 siblings, 5 replies; 13+ messages in thread
From: Alexander Popov @ 2019-12-23 17:51 UTC (permalink / raw)
  To: Michael S . Tsirkin, John Snow, qemu-block, qemu-devel,
	qemu-stable, pmatouse, sstabellini, mdroth, pjp, Paolo Bonzini,
	Andrea Arcangeli, Kashyap Chamarthy, Darren Kenny, Kevin Wolf,
	Thomas Huth, Laurent Vivier, Alexander Popov

Fuzzing the Linux kernel with syzkaller allowed to find how to crash qemu
using a special SCSI_IOCTL_SEND_COMMAND. It hits the assertion in
ide_dma_cb() introduced in the commit a718978ed58a in July 2015.

This patch series fixes incorrect handling of some PRDTs in ide_dma_cb()
and improves the ide-test to cover more PRDT cases (including one
that causes that particular qemu crash).

Changes from v2 (thanks to Kevin Wolf for the feedback):
 - the assertion about prepare_buf() return value is improved;
 - the patch order is reversed to keep the tree bisectable;
 - the unit-test performance is improved -- now it runs 8 seconds
   instead of 3 minutes on my laptop.

Alexander Popov (2):
  ide: Fix incorrect handling of some PRDTs in ide_dma_cb()
  tests/ide-test: Create a single unit-test covering more PRDT cases

 hw/ide/core.c    |  30 +++++---
 tests/ide-test.c | 174 ++++++++++++++++++++---------------------------
 2 files changed, 96 insertions(+), 108 deletions(-)

-- 
2.23.0



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

end of thread, other threads:[~2020-01-23 10:53 UTC | newest]

Thread overview: 13+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-12-23 17:51 [PATCH v3 0/2] ide: Fix incorrect handling of some PRDTs and add the corresponding unit-test Alexander Popov
2019-12-23 17:51 ` [PATCH v3 1/2] ide: Fix incorrect handling of some PRDTs in ide_dma_cb() Alexander Popov
2020-01-07  7:34   ` Kevin Wolf
2019-12-23 17:51 ` [PATCH v3 2/2] tests/ide-test: Create a single unit-test covering more PRDT cases Alexander Popov
2020-01-07  7:44   ` Kevin Wolf
2020-01-07 22:39     ` Alexander Popov
2020-01-08  9:23       ` Kevin Wolf
2019-12-28 12:28 ` [PATCH v3 0/2] ide: Fix incorrect handling of some PRDTs and add the corresponding unit-test Alexander Popov
2020-01-22 11:53 ` Alexander Popov
2020-01-22 12:23   ` Kevin Wolf
2020-01-22 21:06     ` John Snow
2020-01-22 23:14 ` John Snow
2020-01-23 10:52   ` Alexander Popov

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).