Beispiel #1
0
void esp_dma_enable(void *opaque, int level)
{
	ESPState *s = (ESPState*)opaque;
	if (level) {
        s->dma_enabled = 1;
        if (s->dma_cb) {
            if (s->dma_cb(s))
				s->dma_cb = NULL;
        }
    } else {
        s->dma_enabled = 0;
    }
}
Beispiel #2
0
static void esp_dma_enable(void *opaque, int irq, int level)
{
    DeviceState *d = opaque;
    ESPState *s = container_of(d, ESPState, busdev.qdev);

    if (level) {
        s->dma_enabled = 1;
        DPRINTF("Raise enable\n");
        if (s->dma_cb) {
            s->dma_cb(s);
            s->dma_cb = NULL;
        }
    } else {
        DPRINTF("Lower enable\n");
        s->dma_enabled = 0;
    }
}
Beispiel #3
0
static void esp_dma_enable(void *opaque, int irq, int level)
{
    DeviceState *d = opaque;
    ESPState *s = container_of(d, ESPState, busdev.qdev);

    if (level) {
        s->dma_enabled = 1;
        trace_esp_dma_enable();
        if (s->dma_cb) {
            s->dma_cb(s);
            s->dma_cb = NULL;
        }
    } else {
        trace_esp_dma_disable();
        s->dma_enabled = 0;
    }
}