06/11/2019 22:53, David Marchand: > On Tue, Nov 5, 2019 at 4:15 PM Anatoly Burakov > <anatoly.bura...@intel.com> wrote: > > > > Currently, externally created heaps are supposed to be automatically > > mapped for VFIO DMA by EAL, however they only do so if, at the time of > > heap creation, VFIO is initialized and has at least one device > > available. If no devices are available at the time of heap creation (or > > if devices were available, but were since hot-unplugged, thus dropping > > all VFIO container mappings), then VFIO mapping code would have skipped > > over externally allocated heaps. > > > > The fix is two-fold. First, we allow externally allocated memory > > segments to be marked as "heap" segments. This allows us to distinguish > > between external memory segments that were created via heap API, from > > those that were created via rte_extmem_register() API. > > > > Then, we fix the VFIO code to only skip non-heap external segments. > > Also, since external heaps are not guaranteed to have valid IOVA > > addresses, we will skip those which have invalid IOVA addresses as well. > > > > Fixes: 0f526d674f8e ("malloc: separate creating memseg list and malloc > > heap") > > > > Signed-off-by: Anatoly Burakov <anatoly.bura...@intel.com> > > --- > > > > Notes: > > This cannot be backported to older releases as it breaks the > > API and ABI. A separate fix is in the works for stable. > > I'd say we still have to Cc: stable, on the principle so that the > stable maintainers know there is an issue on this commit.
Yes I agree. Cc: stable should be in this commit log. Adding Cc: stable does not mean the patch can be backported without any effort :)