Moving to Bank3

This commit is contained in:
Rob Emery committed 2026-10-10 09:49:52 +01:00
1 parent 1ebee4d6e9
commit 735672ccf1
3 files changed
+6 -9

No files matched your search

+1 -1
View File
@@ -33,7 +33,7 @@
extern __code const struct machine machine; extern __code const struct machine machine;
extern __xdata bool stp_enabled; extern __xdata bool stp_enabled;
extern __code const uint8_t log_to_phys_port[9]; extern __code const uint8_t log_to_phys_port[9];
extern __xdata uint8_t lldp_enabled; extern __xdata bool lldp_enabled;
extern volatile __xdata uint32_t ticks; extern volatile __xdata uint32_t ticks;
extern volatile __xdata uint8_t sfr_data[4]; extern volatile __xdata uint8_t sfr_data[4];
+4 -4
View File
@@ -1,5 +1,5 @@
#pragma codeseg BANK2 #pragma codeseg BANK3
#pragma constseg BANK2 #pragma constseg BANK3
#include "rtl837x_common.h" #include "rtl837x_common.h"
#include "rtl837x_lldp.h" #include "rtl837x_lldp.h"
@@ -10,7 +10,7 @@
#include "uip/uip.h" #include "uip/uip.h"
#include "machine.h" #include "machine.h"
extern __xdata uint8_t lldp_enabled; extern __xdata bool lldp_enabled;
extern __code const struct machine machine; extern __code const struct machine machine;
uint8_t lldp_seconds; uint8_t lldp_seconds;
@@ -178,4 +178,4 @@ void lldp_sysdesc(uint8_t *p, uint16_t *len) __banked
p[(*len)++] = *mp++; p[(*len)++] = *mp++;
} }
p[(*len)-machine_name_length-1] = machine_name_length; p[(*len)-machine_name_length-1] = machine_name_length;
} }
+1 -4
View File
@@ -128,7 +128,7 @@ __xdata uint8_t tx_seq;
__xdata bool stp_enabled; __xdata bool stp_enabled;
__xdata uint8_t igmpEnabled; __xdata uint8_t igmpEnabled;
__xdata uint8_t lldp_enabled; __xdata bool lldp_enabled;
__xdata char hostname[24]; /* device hostname, default set at boot, see rtl837x_common.h */ __xdata char hostname[24]; /* device hostname, default set at boot, see rtl837x_common.h */
__code const uint16_t bit_mask[16] = { __code const uint16_t bit_mask[16] = {
@@ -1072,9 +1072,6 @@ void handle_rx(void)
&& uip_buf[3] == 0x00 && uip_buf[4] == 0x00 && uip_buf[5] == 0x0e && uip_buf[12] == 0x88 && uip_buf[3] == 0x00 && uip_buf[4] == 0x00 && uip_buf[5] == 0x0e && uip_buf[12] == 0x88
&& uip_buf[13] == 0xcc) { //LLDP Mac + EtherType check && uip_buf[13] == 0xcc) { //LLDP Mac + EtherType check
// LLDP packets shouldn't be passed elsewhere // LLDP packets shouldn't be passed elsewhere
if(uip_len){
print_string("LLDP received\n");
}
} else if (ETH_IN->ether_type == HTONS(0x0806)) { // ARP } else if (ETH_IN->ether_type == HTONS(0x0806)) { // ARP
uip_arp_arpin(); uip_arp_arpin();
if (uip_len) { if (uip_len) {