Re: [PATCH 1/1] RDMA/rxe: Fix blktests srp lead kernel panic with 64k page size

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 




On 21/10/2023 00:21, Bart Van Assche wrote:
> On 10/19/23 23:54, Zhijian Li (Fujitsu) wrote:
>> Add and Hi Bart,
>>
>> Yi reported a crash[1] when PAGE_SIZE is 64K
>> [1]https://lore.kernel.org/all/CAHj4cs9XRqE25jyVw9rj9YugffLn5+f=1znaBEnu1usLOciD+g@xxxxxxxxxxxxxx/T/
>>
>> The root cause is unknown so far, but I notice that SRP over RXE always uses MR with page_size
>> 4K = MAX(4K, min(device_support_page_size)) even though the device supports 64K page size.
>> * RXE device support 4K ~ 2G page size
>>
>>
>> 4024         /*
>> 4025          * Use the smallest page size supported by the HCA, down to a
>> 4026          * minimum of 4096 bytes. We're unlikely to build large sglists
>> 4027          * out of smaller entries.
>> 4028          */
>> 4029         mr_page_shift           = max(12, ffs(attr->page_size_cap) - 1);
>> 4030         srp_dev->mr_page_size   = 1 << mr_page_shift;
>> 4031         srp_dev->mr_page_mask   = ~((u64) srp_dev->mr_page_size - 1);
>> 4032         max_pages_per_mr        = attr->max_mr_size;
>>
>>
>> I doubt if we can use PAGE_SIZE MR if the device supports it.
> 
> Hi Zhijian,
> 
> Thank you for having Cc-ed me. How about changing "12" in the above code
> into PAGE_SHIFT?


Yeah, after changed to PAGE_SHIFT, it works fine and the crash is gone in my aarch64 environment.


Thanks
Zhijian



> 
> Thanks,
> 
> Bart.




[Index of Archives]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Photo]     [Yosemite News]     [Yosemite Photos]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux