milos-linux/net/rds
Breno Leitao 512db8267b rds: mark snapshot pages dirty in rds_info_getsockopt()
rds_info_getsockopt() pins the destination user pages with FOLL_WRITE and
the RDS_INFO_* producers memcpy the snapshot into them through
kmap_atomic(). Because that copy goes through the kernel direct map, the
dirty bit on the user PTE is never set, so unpin_user_pages() releases the
pages without marking them dirty. A file-backed destination page can then
be reclaimed without writeback, silently discarding the copied data.

Use unpin_user_pages_dirty_lock() with make_dirty=true so the modified
pages are marked dirty before they are unpinned.

Fixes: a8c879a7ee ("RDS: Info and stats")
Signed-off-by: Breno Leitao <leitao@debian.org>
Reviewed-by: Allison Henderson <achender@kernel.org>
Link: https://patch.msgid.link/20260608-rds_fix-v1-1-006c88543408@debian.org
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
2026-06-10 08:18:16 -07:00
..
af_rds.c net/rds: Restrict use of RDS/IB to the initial network namespace 2026-04-12 13:33:19 -07:00
bind.c
cong.c Convert 'alloc_obj' family to use the new default GFP_KERNEL argument 2026-02-21 17:09:51 -08:00
connection.c net/rds: zero per-item info buffer before handing it to visitors 2026-04-22 21:05:16 -07:00
ib.c net/rds: Restrict use of RDS/IB to the initial network namespace 2026-04-12 13:33:19 -07:00
ib.h net/rds: Optimize rds_ib_laddr_check 2026-04-12 13:33:19 -07:00
ib_cm.c net: rds: clear i_sends on setup unwind 2026-06-02 13:31:27 -07:00
ib_frmr.c
ib_mr.h
ib_rdma.c net/rds: Optimize rds_ib_laddr_check 2026-04-12 13:33:19 -07:00
ib_recv.c net/rds: Add per cp work queue 2026-01-13 12:27:03 +01:00
ib_ring.c
ib_send.c net/rds: fix NULL deref in rds_ib_send_cqe_handler() on masked atomic completion 2026-06-09 18:32:54 -07:00
ib_stats.c
ib_sysctl.c
info.c rds: mark snapshot pages dirty in rds_info_getsockopt() 2026-06-10 08:18:16 -07:00
info.h
Kconfig
loop.c treewide: Replace kmalloc with kmalloc_obj for non-scalar types 2026-02-21 01:02:28 -08:00
loop.h
Makefile
message.c net/rds: reset op_nents when zerocopy page pin fails 2026-05-11 17:20:02 -07:00
page.c
rdma.c net: rds: fix MR cleanup on copy error 2026-04-23 12:18:08 -07:00
rdma_transport.c
rdma_transport.h
rds.h net/rds: Trigger rds_send_ping() more than once 2026-02-04 20:46:39 -08:00
rds_single_path.h
recv.c net/rds: Trigger rds_send_ping() more than once 2026-02-04 20:46:39 -08:00
send.c rds: update outdated comment 2026-02-25 19:03:55 -08:00
stats.c net/rds: Use the first lane until RDS_EXTHDR_NPATHS arrives 2026-02-04 20:46:39 -08:00
sysctl.c
tcp.c rds_tcp: close NULL deref window in rds_tcp_set_callbacks 2026-05-14 17:06:59 -07:00
tcp.h net/rds: Trigger rds_send_ping() more than once 2026-02-04 20:46:39 -08:00
tcp_connect.c net/rds: rds_tcp_conn_path_shutdown must not discard messages 2026-02-04 20:46:38 -08:00
tcp_listen.c net/rds: fix recursive lock in rds_tcp_conn_slots_available 2026-02-24 10:11:04 +01:00
tcp_recv.c net/rds: rds_tcp_conn_path_shutdown must not discard messages 2026-02-04 20:46:38 -08:00
tcp_send.c net/rds: rds_tcp_conn_path_shutdown must not discard messages 2026-02-04 20:46:38 -08:00
tcp_stats.c
threads.c net/rds: Add per cp work queue 2026-01-13 12:27:03 +01:00
transport.c