remove redundant code in zynqmp-r5-axu4ev bsp

This commit is contained in:
Wang-Huachen 2021-05-16 10:00:17 +08:00
parent 41d55a4d47
commit b57278f830
5 changed files with 0 additions and 42 deletions

View File

@ -55,11 +55,7 @@ struct xemac_s {
enum xemac_types type;
int topology_index;
void *state;
#if 0
sys_sem_t sem_rx_data_available;
#else
struct eth_device *rt_eth_device;
#endif
#if defined(OS_IS_FREERTOS) && defined(__arm__) && !defined(ARMR5)
TimerHandle_t xTimer;
#endif

View File

@ -197,29 +197,6 @@ xemac_add(struct netif *netif,
}
}
#if 0
/*
* The input thread calls lwIP to process any received packets.
* This thread waits until a packet is received (sem_rx_data_available),
* and then calls xemacif_input which processes 1 packet at a time.
*/
void
xemacif_input_thread(struct netif *netif)
{
struct xemac_s *emac = (struct xemac_s *)netif->state;
while (1) {
/* sleep until there are packets to process
* This semaphore is set by the packet receive interrupt
* routine.
*/
sys_sem_wait(&emac->sem_rx_data_available);
/* move all received packets to lwIP */
xemacif_input(netif);
}
}
#endif
int
xemacif_input(struct netif *netif)
{

View File

@ -353,9 +353,6 @@ static err_t low_level_init(struct netif *netif)
netif->flags |= NETIF_FLAG_IGMP;
#endif
#if 0
sys_sem_new(&xemac->sem_rx_data_available, 0);
#endif
/* obtain config of this emac */
mac_config = (XEmacPs_Config *)xemacps_lookup_config((unsigned)(UINTPTR)netif->state);

View File

@ -513,11 +513,7 @@ void emacps_recv_handler(void *arg)
/* free up the BD's */
XEmacPs_BdRingFree(rxring, bd_processed, rxbdset);
setup_rx_bds(xemacpsif, rxring);
#if 0
sys_sem_signal(&xemac->sem_rx_data_available);
#else
eth_device_ready(xemac->rt_eth_device);
#endif
}
#ifdef OS_IS_FREERTOS

View File

@ -108,14 +108,6 @@ void Xil_DCacheInvalidate(void)
currmask = mfcpsr();
mtcpsr(currmask | IRQ_FIQ_MASK);
#if 0
stack_end = (u32 )&_stack_end;
stack_start = (u32 )&__undef_stack;
stack_size = stack_start-stack_end;
/* Flush stack memory to save return address */
Xil_DCacheFlushRange(stack_end, stack_size);
#endif
mtcp(XREG_CP15_CACHE_SIZE_SEL, 0);
/*invalidate all D cache*/