On Mon, Sep 23, 2019 at 05:10:43PM -0600, Alex Williamson wrote: > On Mon, 23 Sep 2019 13:43:08 +0200 > Auger Eric <eric.au...@redhat.com> wrote: > > > On 9/23/19 9:51 AM, Peter Xu wrote: > > > On Mon, Sep 23, 2019 at 08:55:51AM +0200, Eric Auger wrote: > > >> @@ -1308,9 +1319,9 @@ static int vfio_connect_container(VFIOGroup > > >> *group, AddressSpace *as, > > >> &address_space_memory); > > >> if (container->error) { > > >> memory_listener_unregister(&container->prereg_listener); > > >> - ret = container->error; > > >> - error_setg(errp, > > >> - "RAM memory listener initialization failed for > > >> container"); > > >> + ret = -1; > > >> + error_propagate_prepend(errp, container->error, > > >> + "RAM memory listener initialization failed: "); > > > > > > (I saw that we've got plenty of prepended prefixes for an error > > > messages. For me I'll disgard quite a few of them because the errors > > > will directly be delivered to the top level user, but this might be > > > too personal as a comment) > > That's true we have a lot of prefix messages. > > > > The output message now is: > > > > "vfio 0000:89:00.0: failed > > to setup container for group 2: memory listener initialization failed: > > Region smmuv3-iommu-memory-region-0-6: device 01.00.0 requires iommu MAP > > notifier which is not currently supported" > > > > Alex, any opinion? > > Peter, I don't really understand what the comment is here. Is it the > number of prepends on the error message? I don't really have an > opinion on that so long as the end message makes sense. Seems like if > we're familiar with the error generation it helps to unwind the > context. Thanks,
True, the only major difference of the error that this series is working on is that the user can easily trigger this simply by plugging a device hence I'm not sure whether that's too long (it's not really a comment and that's why I put it in brackets :). Let's just keep them. Thanks, -- Peter Xu