lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Mon, 4 May 2009 21:31:39 -0700
From:	adam radford <aradford@...il.com>
To:	Grant Grundler <grundler@...gle.com>
Cc:	Данила Жукоцкий <optimusgd@...il.com>,
	FUJITA Tomonori <fujita.tomonori@....ntt.co.jp>, rjw@...k.pl,
	linux-kernel@...r.kernel.org, kernel-testers@...r.kernel.org
Subject: Re: [Bug #13001] PCI-DMA: Out of IOMMU space

2009/5/4 Grant Grundler <grundler@...gle.com>:
> 2009/5/3 Данила Жукоцкий <optimusgd@...il.com>:
> ...
>> WARNING: at lib/dma-debug.c:607 check_unmap+0x542/0x610()
>> Hardware name: HP xw9400 Workstation
>> 3w-9xxx 0001:45:00.0: DMA-API: device driver tries to free DMA memory
>> it has not allocated [device address=0x0000000000000000] [size=36
>> bytes]
>
> This is definitely a driver bug. Just follow the stack trace back to
> the device driver.
>

I think this is a regression from the scsi_dma_map()/unmap() changes a while
back.

Can you try this patch?

Thanks,

-Adam

diff -Naur linux-2.6.30-rc4/drivers/scsi/3w-9xxx.c
linux-2.6.30-rc4.new/drivers/scsi/3w-9xxx.c
--- linux-2.6.30-rc4/drivers/scsi/3w-9xxx.c	2009-05-04 21:19:49.000000000 -0700
+++ linux-2.6.30-rc4.new/drivers/scsi/3w-9xxx.c	2009-05-04
21:23:59.000000000 -0700
@@ -1978,7 +1978,8 @@
 {
 	struct scsi_cmnd *cmd = tw_dev->srb[request_id];

-	scsi_dma_unmap(cmd);
+	if (cmd->SCp.phase == TW_PHASE_SGLIST)
+		scsi_dma_unmap(cmd);
 } /* End twa_unmap_scsi_data() */

 /* scsi_host_template initializer */
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ