From: Tejun Heo Date: Mon, 11 Dec 2006 17:15:31 +0000 (+0900) Subject: [PATCH] libata: don't initialize sg in ata_exec_internal() if DMA_NONE (take #2) X-Git-Tag: v2.6.20-rc2~123^2~5 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=33480a0ede8dcc7e6483054279008f972bd56fd3;p=pandora-kernel.git [PATCH] libata: don't initialize sg in ata_exec_internal() if DMA_NONE (take #2) Calling sg_init_one() with NULL buf causes oops on certain configurations. Don't initialize sg in ata_exec_internal() if DMA_NONE and make the function complain if @buf is NULL when dma_dir isn't DMA_NONE. While at it, fix comment. The problem is discovered and initial patch was submitted by Arnd Bergmann. Signed-off-by: Tejun Heo Cc: Arnd Bergmann Signed-off-by: Jeff Garzik --- Reading git-diff-tree failed