Commit 8ad1f4bf authored by Ziye Yang's avatar Ziye Yang Committed by Tomasz Zawadzki
Browse files

lib/sock: remove spdk_sock_set_priority



Since the related feature is already contained in
spdk_sock_listen and spdk_sock_connect functions,
we no longer need this function.

Signed-off-by: default avatarZiye Yang <ziye.yang@intel.com>
Change-Id: I1eafff0d139fa266a355fbee2bf0fc3947db69fc
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/1876


Community-CI: Mellanox Build Bot
Community-CI: Broadcom CI
Reviewed-by: default avatarShuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: default avatarBen Walker <benjamin.walker@intel.com>
Tested-by: default avatarSPDK CI Jenkins <sys_sgci@intel.com>
parent a2201d05
Loading
Loading
Loading
Loading
+5 −0
Original line number Diff line number Diff line
@@ -106,6 +106,11 @@ and `spdk_thread_poll`.

Poll groups per session have been replaced by SPDK threads per vhost controller.

### sock

Remove `spdk_sock_set_priority` function since the feature to set the sock priority will be
contained in two new functions, i.e., `spdk_sock_listen_ext` and `spdk_sock_connect_ext`.

## v20.01

### bdev
+0 −10
Original line number Diff line number Diff line
@@ -217,16 +217,6 @@ int spdk_sock_set_recvlowat(struct spdk_sock *sock, int nbytes);
 */
int spdk_sock_set_recvbuf(struct spdk_sock *sock, int sz);

/**
 * Set priority for the given socket.
 *
 * \param sock Socket to set the priority.
 * \param priority Priority given by the user.
 *
 * \return 0 on success, -1 on failure.
 */
int spdk_sock_set_priority(struct spdk_sock *sock, int priority);

/**
 * Set send buffer size for the given socket.
 *
+0 −1
Original line number Diff line number Diff line
@@ -105,7 +105,6 @@ struct spdk_net_impl {
	int (*set_recvlowat)(struct spdk_sock *sock, int nbytes);
	int (*set_recvbuf)(struct spdk_sock *sock, int sz);
	int (*set_sendbuf)(struct spdk_sock *sock, int sz);
	int (*set_priority)(struct spdk_sock *sock, int priority);

	bool (*is_ipv6)(struct spdk_sock *sock);
	bool (*is_ipv4)(struct spdk_sock *sock);
+0 −9
Original line number Diff line number Diff line
@@ -875,15 +875,6 @@ _spdk_nvmf_tcp_handle_connect(struct spdk_nvmf_transport *transport,
	SPDK_DEBUGLOG(SPDK_LOG_NVMF_TCP, "New connection accepted on %s port %s\n",
		      port->trid->traddr, port->trid->trsvcid);

	if (transport->opts.sock_priority) {
		rc = spdk_sock_set_priority(sock, transport->opts.sock_priority);
		if (rc) {
			SPDK_ERRLOG("Failed to set the priority of the socket\n");
			spdk_sock_close(&sock);
			return;
		}
	}

	tqpair = calloc(1, sizeof(struct spdk_nvmf_tcp_qpair));
	if (tqpair == NULL) {
		SPDK_ERRLOG("Could not allocate new connection.\n");
+1 −1
Original line number Diff line number Diff line
@@ -34,7 +34,7 @@
SPDK_ROOT_DIR := $(abspath $(CURDIR)/../..)
include $(SPDK_ROOT_DIR)/mk/spdk.common.mk

SO_VER := 2
SO_VER := 3
SO_MINOR := 0
SO_SUFFIX := $(SO_VER).$(SO_MINOR)

Loading