Skip to contentSkip to conversation

staging: rdma: shift wrapping bug in c2_get_dma_mr()

PATCH In review Dan Carpenter 3 participants 3 messages Jan 8, 2016 – Jan 19, 2016

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 staging: rdma: shift wrapping bug in c2_get_dma_mr()

We should be using all 64 bits of page_list[i] instead of just the lower 32.

drivers/staging/rdma/amso1100/c2_provider.c +1 -1
index de8d10e..ac6a6ff 100644
@@ -361,7 +361,7 @@ static struct ib_mr *c2_get_dma_mr(struct ib_pd *pd, int acc)
 	}
 
 	for (i = 0; i < pbl_depth; i++)
-		page_list[i] = (i << page_shift);
+		page_list[i] = ((u64)i << page_shift);
 
 	mr = kmalloc(sizeof(*mr), GFP_KERNEL);
 	if (!mr) {
#1 lore raw

Looks fine.

Doug: what's the status of the staged out drivers? I thought we were going to delete them for 4.5?

#2 lore raw
Quoted 5 lines · Christoph Hellwig

Looks fine.

Doug: what's the status of the staged out drivers? I thought we were going to delete them for 4.5?

I am. They will be going away shortly.

Signature · 2 lines
Doug Ledford <[email protected]>
              GPG KeyID: 0E572FDD