remove warnings

pull/2861/head
cyliangtw 2016-09-19 22:10:59 +08:00 committed by ccli8
parent 21e8c5bd52
commit 82ef4ef047
2 changed files with 7 additions and 5 deletions

View File

@ -48,6 +48,7 @@ u8_t tx_buf[TX_DESCRIPTOR_NUM][PACKET_BUFFER_SIZE];
extern void ethernetif_input(u16_t len, u8_t *buf, u32_t s, u32_t ns);
extern void ethernetif_loopback_input(struct pbuf *p);
extern void ack_emac_rx_isr(void);
// PTP source clock is 84MHz (Real chip using PLL). Each tick is 11.90ns
// Assume we want to set each tick to 100ns.
@ -256,7 +257,6 @@ unsigned int m_status;
void EMAC_RX_IRQHandler(void)
{
unsigned int cur_entry, status;
m_status = EMAC->INTSTS & 0xFFFF;
EMAC->INTSTS = m_status;

View File

@ -79,6 +79,8 @@ struct netif *_netif;
unsigned char my_mac_addr[6] = {0x02, 0x00, 0xac, 0x55, 0x66, 0x77};
extern u8_t my_mac_addr[6];
extern int ETH_link_ok(void);
extern void EMAC_RX_Action(void);
sys_sem_t RxReadySem; /**< RX packet ready semaphore */
@ -421,7 +423,7 @@ err_t
/* Packet receive task */
err = sys_sem_new(&RxReadySem, 0);
LWIP_ASSERT("RxReadySem creation error", (err == ERR_OK));
if(err != ERR_OK) LWIP_ASSERT("RxReadySem creation error", (err == ERR_OK));
// In GCC code, DEFAULT_THREAD_STACKSIZE 512 bytes is not enough for rx_task
#if defined (__GNUC__)
// mbed OS 2.0, DEFAULT_THREAD_STACKSIZE*3
@ -482,10 +484,10 @@ typedef struct {
static void __phy_task(void *data) {
struct netif *netif = (struct netif*)data;
PHY_STATE crt_state = {STATE_UNKNOWN, (phy_speed_t)STATE_UNKNOWN, (phy_duplex_t)STATE_UNKNOWN};
PHY_STATE prev_state;
// PHY_STATE crt_state = {STATE_UNKNOWN, (phy_speed_t)STATE_UNKNOWN, (phy_duplex_t)STATE_UNKNOWN};
// PHY_STATE prev_state;
prev_state = crt_state;
// prev_state = crt_state;
while (1) {
// Get current status
// Get the actual PHY link speed