Re: [PATCH 1/1] device-dax: avoid an unnecessary check in alloc_dev_dax_range()

2020-12-17 Thread Leizhen (ThunderTown)
On 2020/11/20 17:22, Zhen Lei wrote: > Swap the calling sequence of krealloc() and __request_region(), call the > latter first. In this way, the value of dev_dax->nr_range does not need to > be considered when __request_region() failed. > > Signed-off-by: Zhen Lei > --- > drivers/dax/bus.c |

Re: [PATCH 1/1] device-dax: avoid an unnecessary check in alloc_dev_dax_range()

2020-12-17 Thread Leizhen (ThunderTown)
On 2020/12/18 11:10, Dan Williams wrote: > On Fri, Nov 20, 2020 at 1:23 AM Zhen Lei wrote: >> >> Swap the calling sequence of krealloc() and __request_region(), call the >> latter first. In this way, the value of dev_dax->nr_range does not need to >> be considered when __request_region()

Re: [PATCH 1/1] device-dax: avoid an unnecessary check in alloc_dev_dax_range()

2020-12-17 Thread Dan Williams
On Fri, Nov 20, 2020 at 1:23 AM Zhen Lei wrote: > > Swap the calling sequence of krealloc() and __request_region(), call the > latter first. In this way, the value of dev_dax->nr_range does not need to > be considered when __request_region() failed. This looks ok, but I think I want to see

[PATCH 1/1] device-dax: avoid an unnecessary check in alloc_dev_dax_range()

2020-11-20 Thread Zhen Lei
Swap the calling sequence of krealloc() and __request_region(), call the latter first. In this way, the value of dev_dax->nr_range does not need to be considered when __request_region() failed. Signed-off-by: Zhen Lei --- drivers/dax/bus.c | 29 - 1 file changed, 12