A resend of the series, with all of Eric Engestroems review comments addressed and retested on all combos of intel, nvidia, intel+nvidia prime. Rebased and retested against current Mesa master, otherwise only style fixes and an additional assert for documentation, no real functional changes. Please merge, thanks -mario