drm/prime: replace NULL with error value in drm_prime_pages_to_sg