e1000: More transmit changes...
This commit is contained in:
parent
6dce5659ec
commit
4b21b9f1fd
29
apps/upload.krk
Normal file
29
apps/upload.krk
Normal file
@ -0,0 +1,29 @@
|
|||||||
|
#!/bin/kuroko
|
||||||
|
|
||||||
|
import socket
|
||||||
|
import fileio
|
||||||
|
|
||||||
|
import kuroko
|
||||||
|
|
||||||
|
let b
|
||||||
|
with fileio.open(kuroko.argv[1],'rb') as f:
|
||||||
|
b = f.read()
|
||||||
|
|
||||||
|
let endpoint = kuroko.argv[2]
|
||||||
|
|
||||||
|
if ':' in endpoint:
|
||||||
|
let x = endpoint.split(':')
|
||||||
|
endpoint = (x[0], int(x[1]))
|
||||||
|
|
||||||
|
print("Uploading",len(b),"byte(s) to",endpoint)
|
||||||
|
|
||||||
|
let s = socket.socket()
|
||||||
|
|
||||||
|
s.connect(endpoint)
|
||||||
|
|
||||||
|
print("Connected...")
|
||||||
|
|
||||||
|
s.send(b)
|
||||||
|
|
||||||
|
print("Done.")
|
||||||
|
|
@ -254,7 +254,7 @@ static void send_packet(struct e1000_nic * device, uint8_t* payload, size_t payl
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
tx_head = read_command(device, E1000_REG_TXDESCHEAD);
|
tx_head = read_command(device, E1000_REG_TXDESCHEAD);
|
||||||
} while (next_tx == tx_head);
|
} while ((next_tx + 1) % E1000_NUM_TX_DESC == tx_head);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user