netdev: move GetIPAddr() from netlink to netdev

Netlink is for L2; netdev is for L3/L4
This commit is contained in:
Scott Feldman
2023-06-08 23:56:41 -07:00
committed by deadprogram
parent 1b87eff727
commit 044dc8d374
+4
View File
@@ -49,6 +49,10 @@ type netdever interface {
// address in standard dot notation
GetHostByName(name string) (IP, error)
// GetIPAddr returns IP address assigned to the interface, either by
// DHCP or statically
GetIPAddr() (IP, error)
// Berkely Sockets-like interface, Go-ified. See man page for socket(2), etc.
Socket(domain int, stype int, protocol int) (int, error)
Bind(sockfd int, ip IP, port int) error