File tree Expand file tree Collapse file tree 1 file changed +8
-3
lines changed
features/FEATURE_LWIP/lwip-interface/lwip-eth/arch/TARGET_NUVOTON/TARGET_NUC472 Expand file tree Collapse file tree 1 file changed +8
-3
lines changed Original file line number Diff line number Diff line change 24
24
#include "nuc472_eth.h"
25
25
#include "lwip/opt.h"
26
26
#include "lwip/def.h"
27
-
27
+ #include "toolchain.h"
28
28
29
29
#define ETH_TRIGGER_RX () do{EMAC->RXST = 0;}while(0)
30
30
#define ETH_TRIGGER_TX () do{EMAC->TXST = 0;}while(0)
33
33
#define ETH_DISABLE_TX () do{EMAC->CTL &= ~EMAC_CTL_TXON;}while(0)
34
34
#define ETH_DISABLE_RX () do{EMAC->CTL &= ~EMAC_CTL_RXON;}while(0)
35
35
36
+ /*
36
37
#ifdef __ICCARM__
37
38
#pragma data_alignment=4
38
39
struct eth_descriptor rx_desc[RX_DESCRIPTOR_NUM];
@@ -41,10 +42,14 @@ struct eth_descriptor tx_desc[TX_DESCRIPTOR_NUM];
41
42
struct eth_descriptor rx_desc[RX_DESCRIPTOR_NUM] __attribute__ ((aligned(4)));
42
43
struct eth_descriptor tx_desc[TX_DESCRIPTOR_NUM] __attribute__ ((aligned(4)));
43
44
#endif
45
+ */
46
+ struct eth_descriptor rx_desc [RX_DESCRIPTOR_NUM ] MBED_ALIGN (4 );
47
+ struct eth_descriptor tx_desc [TX_DESCRIPTOR_NUM ] MBED_ALIGN (4 );
48
+
44
49
struct eth_descriptor volatile * cur_tx_desc_ptr , * cur_rx_desc_ptr , * fin_tx_desc_ptr ;
45
50
46
- u8_t rx_buf [RX_DESCRIPTOR_NUM ][PACKET_BUFFER_SIZE ];
47
- u8_t tx_buf [TX_DESCRIPTOR_NUM ][PACKET_BUFFER_SIZE ];
51
+ u8_t rx_buf [RX_DESCRIPTOR_NUM ][PACKET_BUFFER_SIZE ] MBED_ALIGN ( 4 ) ;
52
+ u8_t tx_buf [TX_DESCRIPTOR_NUM ][PACKET_BUFFER_SIZE ] MBED_ALIGN ( 4 ) ;
48
53
49
54
extern void ethernetif_input (u16_t len , u8_t * buf , u32_t s , u32_t ns );
50
55
extern void ethernetif_loopback_input (struct pbuf * p );
You can’t perform that action at this time.
0 commit comments