Re: [PATCH v4] kernel/resource: Fix locking in request_free_mem_region

2021-04-19 Thread Alistair Popple
On Friday, 16 April 2021 2:19:18 PM AEST Dan Williams wrote: > The revoke_iomem() change seems like something that should be moved > into a leaf helper and not called by __request_free_mem_region() > directly. Ok. I have split this up but left the call to revoke_iomem() in __request_free_mem_regi

Re: [PATCH v4] kernel/resource: Fix locking in request_free_mem_region

2021-04-16 Thread David Hildenbrand
On 16.04.21 06:19, Dan Williams wrote: On Thu, Apr 15, 2021 at 7:58 PM Alistair Popple wrote: request_free_mem_region() is used to find an empty range of physical addresses for hotplugging ZONE_DEVICE memory. It does this by iterating over the range of possible addresses using region_intersect

Re: [PATCH v4] kernel/resource: Fix locking in request_free_mem_region

2021-04-15 Thread Dan Williams
On Thu, Apr 15, 2021 at 7:58 PM Alistair Popple wrote: > > request_free_mem_region() is used to find an empty range of physical > addresses for hotplugging ZONE_DEVICE memory. It does this by iterating > over the range of possible addresses using region_intersects() to see if > the range is free.

[PATCH v4] kernel/resource: Fix locking in request_free_mem_region

2021-04-15 Thread Alistair Popple
request_free_mem_region() is used to find an empty range of physical addresses for hotplugging ZONE_DEVICE memory. It does this by iterating over the range of possible addresses using region_intersects() to see if the range is free. region_intersects() obtains a read lock before walking the resour