Various tweaks together with @kpj