Lines Matching defs:connection
85 #define __drbd_printk_connection(level, connection, fmt, args...) \
86 printk(level "drbd %s: " fmt, (connection)->resource->name, ## args)
225 extern unsigned int drbd_header_size(struct drbd_connection *connection);
242 struct drbd_connection *connection;
319 /* per connection */
344 * or decide, e.g. on connection loss, that we do no longer expect
365 struct drbd_connection *connection;
627 /* flag bits per connection */
633 CONN_WD_ST_CHG_REQ, /* A cluster wide state change on the connection is active */
699 unsigned int connect_cnt; /* Inc each time a connection is established */
720 struct crypto_shash *integrity_tfm; /* checksums we compute, updates protected by connection->data->mutex */
775 static inline bool has_net_conf(struct drbd_connection *connection)
780 has_net_conf = rcu_dereference(connection->net_conf);
808 struct drbd_connection *connection;
831 unsigned int vnr; /* volume number within the connection */
954 struct mutex *state_mutex; /* either own_state_mutex or first_peer_device(device)->connection->cstate_mutex */
962 struct fifo_buffer *rs_plan_s; /* correction values of resync planer (RCU, connection->conn_update) */
1007 struct drbd_connection *connection;
1021 conn_peer_device(struct drbd_connection *connection, int volume_number)
1023 return idr_find(&connection->peer_devices, volume_number);
1035 #define for_each_connection(connection, resource) \
1036 list_for_each_entry(connection, &resource->connections, connections)
1038 #define for_each_connection_rcu(connection, resource) \
1039 list_for_each_entry_rcu(connection, &resource->connections, connections)
1041 #define for_each_connection_safe(connection, tmp, resource) \
1042 list_for_each_entry_safe(connection, tmp, &resource->connections, connections)
1080 extern void drbd_free_sock(struct drbd_connection *connection);
1081 extern int drbd_send(struct drbd_connection *connection, struct socket *sock,
1086 extern int __drbd_send_protocol(struct drbd_connection *connection, enum drbd_packet cmd);
1087 extern int drbd_send_protocol(struct drbd_connection *connection);
1095 extern void drbd_send_b_ack(struct drbd_connection *connection, u32 barrier_nr,
1118 extern void conn_send_sr_reply(struct drbd_connection *connection, enum drbd_state_rv retcode);
1125 extern void conn_md_sync(struct drbd_connection *connection);
1433 extern int conn_lowest_minor(struct drbd_connection *connection);
1448 extern void conn_free_crypto(struct drbd_connection *connection);
1483 extern bool conn_try_outdate_peer(struct drbd_connection *connection);
1484 extern void conn_try_outdate_peer_async(struct drbd_connection *connection);
1485 extern enum drbd_peer_state conn_khelper(struct drbd_connection *connection, char *cmd);
1916 struct drbd_connection *connection =
1917 first_peer_device(device)->connection;
1918 struct drbd_work_queue *q = &connection->sender_work;
1919 if (!test_and_set_bit(DEVICE_WORK_PENDING, &connection->flags))
1930 static inline void wake_ack_receiver(struct drbd_connection *connection)
1932 struct task_struct *task = connection->ack_receiver.task;
1933 if (task && get_t_state(&connection->ack_receiver) == RUNNING)
1937 static inline void request_ping(struct drbd_connection *connection)
1939 set_bit(SEND_PING, &connection->flags);
1940 wake_ack_receiver(connection);
1952 extern int drbd_send_ping(struct drbd_connection *connection);
1953 extern int drbd_send_ping_ack(struct drbd_connection *connection);
2143 nc = rcu_dereference(first_peer_device(device)->connection->net_conf);
2158 /* new io only accepted when there is no connection, ... */
2161 /* ... or there is a well established connection. */
2186 if (first_peer_device(device)->connection->agreed_pro_version < 96)
2270 * until the bitmap is no longer on the fly during connection
2289 connection->sender_work,
2302 return first_peer_device(device)->connection->agreed_pro_version >= 97 &&
2303 first_peer_device(device)->connection->agreed_pro_version != 100;