git: a8165edb50ab - main - fwcam: release the IR DMA channel when starting the stream fails

Adrian Chadd <[email protected]>
Newsgroups gmane.os.freebsd.devel.cvs.src
Message-ID <6a78b277.399dc.22a42952__1224.29412310652$1786295006$gmane$org@gitrepo.freebsd.org>
The branch main has been updated by adrian:

URL: https://cgit.FreeBSD.org/src/commit/?id=a8165edb50ab323241fa622f720d724bc5f22150

commit a8165edb50ab323241fa622f720d724bc5f22150
Author:     Abdelkader Boudih <[email protected]>
AuthorDate: 2026-08-09 16:59:26 +0000
Commit:     Adrian Chadd <[email protected]>
CommitDate: 2026-08-09 16:59:29 +0000

    fwcam: release the IR DMA channel when starting the stream fails
    
    Disabled the IR DMA channel on the error path, which clears the flag and
    frees the descriptor blocks before the chunks go away.
    
    Reviewed by:    adrian
    Differential Revision:  https://reviews.freebsd.org/D58502
---
 sys/dev/firewire/fwcam.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/sys/dev/firewire/fwcam.c b/sys/dev/firewire/fwcam.c
index c98eb7a9894c..e2b53935597b 100644
--- a/sys/dev/firewire/fwcam.c
+++ b/sys/dev/firewire/fwcam.c
@@ -534,6 +534,9 @@ fwcam_iso_start(struct fwcam_softc *sc)
 	return (0);
 
 fail:
+	if (xferq->flag & FWXFERQ_RUNNING)
+		fc->irx_disable(fc, dma_ch);
+
 	fw_iso_free_chunks(xferq, M_FWCAM);
 	xferq->flag &= ~(FWXFERQ_MODEMASK | FWXFERQ_OPEN | FWXFERQ_STREAM |
 	    FWXFERQ_EXTBUF | FWXFERQ_HANDLER | FWXFERQ_CHTAGMASK);
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.