In rds_ib_recv_init_ring(), an excess array element is incorrectly
initialized. This is not an OOB situation, as the sge array is
initialized to eight entries. With a fragment size of a maximum of 16KiB
and a page size of minimum 4KiB, then num_send_sge can at most become
five.
Orabug:
29004503
Signed-off-by: Zhu Yanjun <yanjun.zhu@oracle.com>
Reviewed-by: HÃ¥kon Bugge <haakon.bugge@oracle.com>
Signed-off-by: Brian Maly <brian.maly@oracle.com>
sge->length = sizeof(struct rds_header);
sge->lkey = ic->i_mr->lkey;
- for (j = 1; j <= num_send_sge; j++) {
+ for (j = 1; j < num_send_sge; j++) {
sge = recv->r_sge + j;
sge->addr = 0;
sge->length = PAGE_SIZE;