### What this PR does / why we need it? Fixes hang when batch size < DP size. ### Does this PR introduce _any_ user-facing change? None. ### How was this patch tested? After this change, the function in DP case will work now. - vLLM version: v0.10.1.1 - vLLM main: https://github.com/vllm-project/vllm/commit/d9a55204bad7bde505624f4ffb0464d98c86914a Signed-off-by: Yizhou Liu <liu_yizhou@outlook.com>