Skip to content

Commit 89bae05

Browse files
metze-sambasmfrench
authored andcommitted
smb: smbdirect: introduce smbdirect_socket.idle.{keepalive,immediate_work,timer_work}
This will allow client and server to use the common structures in order to share common functions later. Cc: Steve French <smfrench@gmail.com> Cc: Tom Talpey <tom@talpey.com> Cc: Long Li <longli@microsoft.com> Acked-by: Namjae Jeon <linkinjeon@kernel.org> Cc: linux-cifs@vger.kernel.org Cc: samba-technical@lists.samba.org Signed-off-by: Stefan Metzmacher <metze@samba.org> Signed-off-by: Steve French <stfrench@microsoft.com>
1 parent 2baedb2 commit 89bae05

File tree

1 file changed

+15
-0
lines changed

1 file changed

+15
-0
lines changed

fs/smb/common/smbdirect/smbdirect_socket.h

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,12 @@ const char *smbdirect_socket_status_string(enum smbdirect_socket_status status)
4141
return "<unknown>";
4242
}
4343

44+
enum smbdirect_keepalive_status {
45+
SMBDIRECT_KEEPALIVE_NONE,
46+
SMBDIRECT_KEEPALIVE_PENDING,
47+
SMBDIRECT_KEEPALIVE_SENT
48+
};
49+
4450
struct smbdirect_socket {
4551
enum smbdirect_socket_status status;
4652
wait_queue_head_t status_wait;
@@ -71,6 +77,15 @@ struct smbdirect_socket {
7177

7278
struct smbdirect_socket_parameters parameters;
7379

80+
/*
81+
* The state for keepalive and timeout handling
82+
*/
83+
struct {
84+
enum smbdirect_keepalive_status keepalive;
85+
struct work_struct immediate_work;
86+
struct delayed_work timer_work;
87+
} idle;
88+
7489
/*
7590
* The state for posted send buffers
7691
*/

0 commit comments

Comments
 (0)