Skip to content

Commit 579ba85

Browse files
srabinovdavem330
authored andcommitted
RDS: fix congestion map corruption for PAGE_SIZE > 4k
When PAGE_SIZE > 4k single page can contain 2 RDS fragments. If 'rds_ib_cong_recv' ignore the RDS fragment offset in to the page it then read the data fragment as far congestion map update and lead to corruption of the RDS connection far congestion map. Signed-off-by: Shamir Rabinovitch <[email protected]> Signed-off-by: David S. Miller <[email protected]>
1 parent e98499a commit 579ba85

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

net/rds/ib_recv.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -796,7 +796,7 @@ static void rds_ib_cong_recv(struct rds_connection *conn,
796796

797797
addr = kmap_atomic(sg_page(&frag->f_sg));
798798

799-
src = addr + frag_off;
799+
src = addr + frag->f_sg.offset + frag_off;
800800
dst = (void *)map->m_page_addrs[map_page] + map_off;
801801
for (k = 0; k < to_copy; k += 8) {
802802
/* Record ports that became uncongested, ie

0 commit comments

Comments
 (0)