code: func (srv *Server) SetupConn(fd net.Conn, flags connFlag, dialDest *enode.Node) error {
  	c := &conn{fd: fd, transport: srv.newTransport(fd), flags: flags, cont: make(chan error)}
  	err := srv.setupConn(c, flags, dialDest)
  	if err != nil {
  		c.close(err)
  		srv.log.Trace("Setting up connection failed", "addr", fd.RemoteAddr(), "err", err)
  	}
  	return err
  }
docs: // SetupConn runs the handshakes and attempts to add the connection
  // as a peer. It returns when the connection has been added as a peer
  // or the handshakes have failed.