From: Stefan Richter Date: Wed, 29 Aug 2007 17:40:28 +0000 (+0200) Subject: firewire: fw-ohci: missing dma_unmap_single X-Git-Tag: v2.6.24-rc1~825^2~5 X-Git-Url: http://pilppa.com/gitweb/?a=commitdiff_plain;h=ab88ca488b8af66c3defa165874e81e695319a19;p=linux-2.6-omap-h63xx.git firewire: fw-ohci: missing dma_unmap_single at_context_queue_packet() didn't clean up in an early exit path. Signed-off-by: Stefan Richter Signed-off-by: Kristian Høgsberg --- diff --git a/drivers/firewire/fw-ohci.c b/drivers/firewire/fw-ohci.c index a3337482552..ec70c9f9117 100644 --- a/drivers/firewire/fw-ohci.c +++ b/drivers/firewire/fw-ohci.c @@ -680,6 +680,9 @@ at_context_queue_packet(struct context *ctx, struct fw_packet *packet) /* FIXME: Document how the locking works. */ if (ohci->generation != packet->generation) { + if (packet->payload_length > 0) + dma_unmap_single(ohci->card.device, payload_bus, + packet->payload_length, DMA_TO_DEVICE); packet->ack = RCODE_GENERATION; return -1; }