Skip to content

Commit 7ba9dc6

Browse files
bentoastdarcagn
authored andcommitted
This is a patch to get the DC to get an IP address via DHCP across a bridge.
We weren't getting an IP address when the Dreamcast wasn't directly connected to the router This seemed to be related to how dcload handles packets. The offer comes across as a non-ARP broadcast packet. So the Dreamcast was just dropping the packet. This patch checks for the type of packet and shunts it to the other packet processing function. TODO: This all feels kind of dirty. I think I saw some circular bits in it as well. I might take a swing at straightening some of this out.
1 parent dac19b9 commit 7ba9dc6

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

target-src/dcload/net.c

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,9 @@ static void process_broadcast(unsigned char *pkt) // arp request
2525
ether_header_t *ether_header = (ether_header_t *)pkt;
2626
arp_header_t *arp_header = (arp_header_t *)(pkt + ETHER_H_LEN);
2727

28+
if (ether_header->type[1] == 0x00)
29+
process_mine(pkt);
30+
2831
if (ether_header->type[1] != 0x06) /* ARP */
2932
return;
3033

0 commit comments

Comments
 (0)