NFSv4.1: change nfs4_free_slot parameters for dynamic slots
Signed-off-by: Andy Adamson <andros@netapp.com> Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
This commit is contained in:
parent
aacd553727
commit
aabd0b40b3
|
@ -363,9 +363,8 @@ static void renew_lease(const struct nfs_server *server, unsigned long timestamp
|
||||||
* Must be called while holding tbl->slot_tbl_lock
|
* Must be called while holding tbl->slot_tbl_lock
|
||||||
*/
|
*/
|
||||||
static void
|
static void
|
||||||
nfs4_free_slot(struct nfs4_slot_table *tbl, struct nfs4_slot *free_slot)
|
nfs4_free_slot(struct nfs4_slot_table *tbl, u8 free_slotid)
|
||||||
{
|
{
|
||||||
int free_slotid = free_slot - tbl->slots;
|
|
||||||
int slotid = free_slotid;
|
int slotid = free_slotid;
|
||||||
|
|
||||||
BUG_ON(slotid < 0 || slotid >= NFS4_MAX_SLOT_TABLE);
|
BUG_ON(slotid < 0 || slotid >= NFS4_MAX_SLOT_TABLE);
|
||||||
|
@ -430,7 +429,7 @@ static void nfs41_sequence_free_slot(struct nfs4_sequence_res *res)
|
||||||
}
|
}
|
||||||
|
|
||||||
spin_lock(&tbl->slot_tbl_lock);
|
spin_lock(&tbl->slot_tbl_lock);
|
||||||
nfs4_free_slot(tbl, res->sr_slot);
|
nfs4_free_slot(tbl, res->sr_slot - tbl->slots);
|
||||||
nfs4_check_drain_fc_complete(res->sr_session);
|
nfs4_check_drain_fc_complete(res->sr_session);
|
||||||
spin_unlock(&tbl->slot_tbl_lock);
|
spin_unlock(&tbl->slot_tbl_lock);
|
||||||
res->sr_slot = NULL;
|
res->sr_slot = NULL;
|
||||||
|
|
Reference in New Issue