diff options
Diffstat (limited to 'net/rds/ib_cm.c')
-rw-r--r-- | net/rds/ib_cm.c | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/net/rds/ib_cm.c b/net/rds/ib_cm.c index 31b74f5e61ad..8a09ee7db3c1 100644 --- a/net/rds/ib_cm.c +++ b/net/rds/ib_cm.c | |||
@@ -183,8 +183,17 @@ void rds_ib_cm_connect_complete(struct rds_connection *conn, struct rdma_cm_even | |||
183 | 183 | ||
184 | /* If the peer gave us the last packet it saw, process this as if | 184 | /* If the peer gave us the last packet it saw, process this as if |
185 | * we had received a regular ACK. */ | 185 | * we had received a regular ACK. */ |
186 | if (dp && dp->dp_ack_seq) | 186 | if (dp) { |
187 | rds_send_drop_acked(conn, be64_to_cpu(dp->dp_ack_seq), NULL); | 187 | /* dp structure start is not guaranteed to be 8 bytes aligned. |
188 | * Since dp_ack_seq is 64-bit extended load operations can be | ||
189 | * used so go through get_unaligned to avoid unaligned errors. | ||
190 | */ | ||
191 | __be64 dp_ack_seq = get_unaligned(&dp->dp_ack_seq); | ||
192 | |||
193 | if (dp_ack_seq) | ||
194 | rds_send_drop_acked(conn, be64_to_cpu(dp_ack_seq), | ||
195 | NULL); | ||
196 | } | ||
188 | 197 | ||
189 | rds_connect_complete(conn); | 198 | rds_connect_complete(conn); |
190 | } | 199 | } |