Skip to content

Commit 9f0bb95

Browse files
mbpatil369kuba-moo
authored andcommitted
net/rds: suppress page allocation failure error in recv buffer refill
RDS/IB tries to refill the recv buffer in softirq context using GFP_NOWAIT flag. However alloc failure is handled by queueing a work to refill the recv buffer with GFP_KERNEL flag. This means failure to allocate with GFP_NOWAIT isn't fatal. Do not print the PAF warnings if softirq context fails to refill the recv buffer. We will see the PAF warnings when worker also fails to allocate. Signed-off-by: Manjunath Patil <manjunath.b.patil@oracle.com> Reviewed-by: Aruna Ramakrishna <aruna.ramakrishna@oracle.com> Signed-off-by: Jakub Kicinski <kuba@kernel.org>
1 parent 91bca7f commit 9f0bb95

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

‎net/rds/ib_recv.c‎

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -310,8 +310,8 @@ static int rds_ib_recv_refill_one(struct rds_connection *conn,
310310
struct rds_ib_connection *ic = conn->c_transport_data;
311311
struct ib_sge *sge;
312312
int ret = -ENOMEM;
313-
gfp_t slab_mask = GFP_NOWAIT;
314-
gfp_t page_mask = GFP_NOWAIT;
313+
gfp_t slab_mask = gfp;
314+
gfp_t page_mask = gfp;
315315

316316
if (gfp & __GFP_DIRECT_RECLAIM) {
317317
slab_mask = GFP_KERNEL;
@@ -1020,7 +1020,7 @@ void rds_ib_recv_cqe_handler(struct rds_ib_connection *ic,
10201020
rds_ib_stats_inc(s_ib_rx_ring_empty);
10211021

10221022
if (rds_ib_ring_low(&ic->i_recv_ring)) {
1023-
rds_ib_recv_refill(conn, 0, GFP_NOWAIT);
1023+
rds_ib_recv_refill(conn, 0, GFP_NOWAIT | __GFP_NOWARN);
10241024
rds_ib_stats_inc(s_ib_rx_refill_from_cq);
10251025
}
10261026
}

0 commit comments

Comments
 (0)