So to conclude the topic, we would only need this?
Yes, I think this is indeed where we were heading.
However, during the discussion I really liked the idea of passing a pointer to the "advice_setting" to "vadvise()" instead of passing its individual fields. It seems like a cleaner interface, even though it is not directly related to this fix.
Would it make sense to submit that change as a separate patch?