2018-04-14 Fred Gleason <fredg@paravelsystems.com>

* Fixed a regression in the HPI audio interface that broke capture
	on adapters lacking DMA bus-mastering support.
This commit is contained in:
Fred Gleason
2018-04-14 12:30:19 -04:00
parent 276e8b8e14
commit 5e3fe7ac5e
2 changed files with 8 additions and 7 deletions

View File

@@ -724,19 +724,17 @@ bool RDHPIRecordStream::GetStream()
}
return false;
}
if(LogHpi(HPI_InStreamHostBufferAllocate(NULL,hpi_stream,dma_buffer_size),
__LINE__)!=0) {
LogHpi(HPI_InStreamHostBufferFree(NULL,hpi_stream),__LINE__);
LogHpi(HPI_InStreamClose(NULL,hpi_stream),__LINE__);
return false;
}
hpi_err=HPI_InStreamHostBufferAllocate(NULL,hpi_stream,dma_buffer_size);
return true;
}
void RDHPIRecordStream::FreeStream()
{
LogHpi(HPI_InStreamHostBufferFree(NULL,hpi_stream),__LINE__);
hpi_err_t hpi_err;
hpi_err=HPI_InStreamHostBufferFree(NULL,hpi_stream);
LogHpi(HPI_InStreamClose(NULL,hpi_stream),__LINE__);
}