Compare commits

..
Author SHA1 Message Date
Leency 5139f994c4 kernel/network: fix ARP remove on devices other than 0
Check kernel codestyle / Check kernel codestyle (pull_request) Successful in 21s
Test PR / Build (ru_RU) (pull_request) Successful in 1m55s
Test PR / Build (es_ES) (pull_request) Successful in 2m0s
Test PR / Build (en_US) (pull_request) Successful in 2m4s
arp_api .remove forgot the per-device table offset, so it deleted
from device 0's table and shifted device 1's entries into it.
2026-09-30 08:42:55 +03:00
3 changed files with 4 additions and 4 deletions

No files matched your search

+4 -2
View File
@@ -688,10 +688,12 @@ arp_api:
; ecx = # entry
cmp ecx, [ARP_entries + eax]
jae .error
imul ecx, sizeof.ARP_entry
lea esi, [ARP_table + ecx]
mov edi, eax
shr edi, 2
mov esi, edi
imul esi, sizeof.ARP_entry*ARP_TABLE_SIZE
imul ecx, sizeof.ARP_entry
lea esi, [ARP_table + esi + ecx]
call arp_del_entry
ret
-1
View File
@@ -226,7 +226,6 @@ macro socket_init {
mov ecx, 5
rep stosd
rdtsc ; seed, differs from boot to boot
@@:
pseudo_random eax
cmp ax, EPHEMERAL_PORT_MIN
-1
View File
@@ -208,7 +208,6 @@ macro tcp_init {
mov ecx, (6*NET_DEVICES_MAX)
rep stosd
rdtsc ; seed, differs from boot to boot
pseudo_random eax
mov [TCP_sequence_num], eax