host: libbladeRF: fix compile errors on cyapi.c (#42)

* host: libbladeRF: fix async.h include in cyapi.c

* host: libbladeRF: add devinfo.h include to cyapi.c

* host: libbladeRF: cyapi.c: swear profusely at MSVC
This commit is contained in:
Rey Tucker 2018-04-26 17:47:24 -04:00 • committed by Rey Tucker
commit 4cae7e59ee

View file

@ -30,9 +30,11 @@ extern "C" {
#include <errno.h>
#include "bladeRF.h" /* Firmware interface */
#include "devinfo.h"
#include "backend/backend.h"
#include "backend/usb/usb.h"
#include "async.h"
#include "streaming/async.h"
#include "helpers/timeout.h"
#include "log.h"
}
@ -624,7 +626,7 @@ static int cyapi_stream(void *driver, struct bladerf_stream *stream,
MUTEX_LOCK(&stream->lock);
for (unsigned int i = 0; i < data->num_transfers && status == 0; i++) {
if (dir == BLADERF_TX) {
if ((layout & BLADERF_DIRECTION_MASK) == BLADERF_TX) {
next_buffer = stream->cb(stream->dev, stream, &meta, NULL,
stream->samples_per_buffer,
stream->user_data);
@ -821,7 +823,7 @@ extern "C" {
};
struct usb_driver usb_driver_cypress = {
FIELD_INIT(.fn, &cypress_fns),
FIELD_INIT(.id, BLADERF_BACKEND_CYPRESS),
FIELD_INIT(.fn, &cypress_fns)
};
}