1/* 2 * Copyright 2020, Data61 3 * Commonwealth Scientific and Industrial Research Organisation (CSIRO) 4 * ABN 41 687 119 230. 5 * 6 * This software may be distributed and modified according to the terms of 7 * the GNU General Public License version 2. Note that NO WARRANTY is provided. 8 * See "LICENSE_GPLv2.txt" for details. 9 * 10 * @TAG(DATA61_GPL) 11 */ 12#include <platsupport/io.h> 13#include <utils/util.h> 14 15#include "uboot/tx2_configs.h" 16 17#define TX_IRQ BIT(0) 18#define RX_IRQ BIT(1) 19 20void eqos_dma_disable_rxirq(struct tx2_eth_data *dev); 21 22void eqos_dma_enable_rxirq(struct tx2_eth_data *dev); 23 24void eqos_dma_disable_txirq(struct tx2_eth_data *dev); 25 26void eqos_dma_enable_txirq(struct tx2_eth_data *dev); 27 28void eqos_stop(struct tx2_eth_data *dev); 29 30int eqos_start(struct tx2_eth_data *dev); 31 32int eqos_send(struct tx2_eth_data *dev, void *packet, int length); 33 34int eqos_handle_irq(struct tx2_eth_data *dev, int irq); 35 36int eqos_recv(struct tx2_eth_data *dev, uintptr_t packetp); 37 38void *tx2_initialise(uintptr_t base_addr, ps_io_ops_t *io_ops); 39 40void eqos_set_rx_tail_pointer(struct tx2_eth_data *dev); 41