-/**
- * Implementation of obd_ops: o_fid_alloc
- *
- * Allocate a FID. There are two cases in which OSP performs
- * FID allocation.
- *
- * 1. FID precreation for data objects, which is done in
- * osp_precreate_fids() instead of this function.
- * 2. FID allocation for each sub-stripe of a striped directory.
- * Similar to other FID clients, OSP requests the sequence
- * from its corresponding remote MDT, which in turn requests
- * sequences from the sequence controller (MDT0).
- *
- * \param[in] env execution environment
- * \param[in] exp export of the OSP
- * \param[out] fid FID being allocated
- * \param[in] unused necessary for the interface but unused.
- *
- * \retval 0 0 FID allocated successfully.
- * \retval 1 1 FID allocated successfully and new sequence
- * requested from seq meta server
- * \retval negative negative errno if FID allocation failed.
- */
-static int osp_fid_alloc(const struct lu_env *env, struct obd_export *exp,
- struct lu_fid *fid, struct md_op_data *unused)
-{
- struct client_obd *cli = &exp->exp_obd->u.cli;
- struct osp_device *osp = lu2osp_dev(exp->exp_obd->obd_lu_dev);
- struct lu_client_seq *seq = cli->cl_seq;
- ENTRY;
-
- LASSERT(osp->opd_obd->u.cli.cl_seq != NULL);
- /* Sigh, fid client is not ready yet */
- LASSERT(osp->opd_obd->u.cli.cl_seq->lcs_exp != NULL);
-
- RETURN(seq_client_alloc_fid(env, seq, fid));
-}
-