summaryrefslogtreecommitdiffhomepage
path: root/pkg/tcpip/stack/registration.go
diff options
context:
space:
mode:
authorGhanan Gowripalan <ghanan@google.com>2021-01-15 18:12:50 -0800
committergVisor bot <gvisor-bot@google.com>2021-01-15 18:15:26 -0800
commit2814a032be7b34e4cc0c0607dba8030e74e11208 (patch)
treefc6a023766f5ad1ae5818abd710c997ba657e8bd /pkg/tcpip/stack/registration.go
parentfd5b52c87ff8fbabf2b293fc95ec9f9f04e5621c (diff)
Support GetLinkAddress with neighborCache
Test: integration_test.TestGetLinkAddress PiperOrigin-RevId: 352119404
Diffstat (limited to 'pkg/tcpip/stack/registration.go')
-rw-r--r--pkg/tcpip/stack/registration.go21
1 files changed, 0 insertions, 21 deletions
diff --git a/pkg/tcpip/stack/registration.go b/pkg/tcpip/stack/registration.go
index 0f6ec92c9..68c113b6a 100644
--- a/pkg/tcpip/stack/registration.go
+++ b/pkg/tcpip/stack/registration.go
@@ -835,27 +835,6 @@ type LinkAddressCache interface {
// AddLinkAddress adds a link address to the cache.
AddLinkAddress(nicID tcpip.NICID, addr tcpip.Address, linkAddr tcpip.LinkAddress)
-
- // GetLinkAddress finds the link address corresponding to the remote address
- // (e.g. IP -> MAC).
- //
- // Returns a link address for the remote address, if readily available.
- //
- // Returns ErrWouldBlock if the link address is not readily available, along
- // with a notification channel for the caller to block on. Triggers address
- // resolution asynchronously.
- //
- // If onResolve is provided, it will be called either immediately, if
- // resolution is not required, or when address resolution is complete, with
- // the resolved link address and whether resolution succeeded. After any
- // callbacks have been called, the returned notification channel is closed.
- //
- // If specified, the local address must be an address local to the interface
- // the neighbor cache belongs to. The local address is the source address of
- // a packet prompting NUD/link address resolution.
- //
- // TODO(gvisor.dev/issue/5151): Don't return the link address.
- GetLinkAddress(nicID tcpip.NICID, addr, localAddr tcpip.Address, protocol tcpip.NetworkProtocolNumber, onResolve func(tcpip.LinkAddress, bool)) (tcpip.LinkAddress, <-chan struct{}, *tcpip.Error)
}
// RawFactory produces endpoints for writing various types of raw packets.