Re: [RDMA PATCH 01/16] i40iw: Fix overflow of region length

Mustafa Ismail
2016-04-12T18:09:10Z

On Mon, Apr 11, 2016 at 02:23:24AM -0700, Leon Romanovsky wrote:
> On Thu, Apr 07, 2016 at 11:30:49AM -0500, Mustafa Ismail wrote:
> > Change region_length to u64 as a region can be > 4GB.
>
> I suppose that you will have a casting warning while setting u64 variable to u32 variable.
> $grep -r pbl_depth drivers/infiniband/hw/i40iw/*
> drivers/infiniband/hw/i40iw/i40iw_verbs.c: u32 pbl_depth = 0;
> drivers/infiniband/hw/i40iw/i40iw_verbs.c: pbl_depth = region_length >> 12;

I did not see any warnings from zero day testing. Good catch. We will fix in V2.
Thanks.