[IB] mthca: Fix doorbell record resource leak

If we allocate a bunch of doorbell records and then free them, we'll
end up with completely empty pages, which we then free.  However, when
we come back to allocate more doorbell pages, we have to reallocate
those empty pages rather than always trying to take a slot that we've
never used.  If we don't, we eventually use up every slot and fail to
allocate a doorbell record, even though we have plenty of free space.

Signed-off-by: Roland Dreier <rolandd@cisco.com>
1 file changed