swrast: avoid calling _mesa_get_srgb_format_linear() inside a loop