pipelimit: fix dynamic pipe limit check

- proper add and check at the same time

(cherry picked from commit b76afe7c0699b936bec3d7bb1c3a740bf08fdb1c)
pipelimit: enhanced docs for pl_check() function

- documented the algorithm and limit parameters

(cherry picked from commit 24e76b1932fa8c4e1136ad82cb582a97c50244c4)