Uploaded image for project: 'Lustre'
  1. Lustre
  2. LU-1185 FID on OST
  3. LU-2682

clean up direct _id and _seq access, use ost_id everywhere

Details

    • Technical task
    • Resolution: Fixed
    • Major
    • Lustre 2.4.0
    • Lustre 2.4.0
    • None
    • 6269

    Description

      There are a number of cleanups that should be done for the ost_id members of various structures.

      Access/copying the individual _id and _seq fields should be replaced with the _oi field, and compatibility macros for accessing the individual fields should be removed.

      POID/DOID macros should be introduced to print out the _oi fields, similar to PFID/DFID is used for lu_fid fields. Johann had a patch for doing some of this in http://review.whamcloud.com/2004 that needs to be refreshed and resubmitted.

      Attachments

        Issue Links

          Activity

            [LU-2682] clean up direct _id and _seq access, use ost_id everywhere
            pjones Peter Jones added a comment -

            Landed for 2.4

            pjones Peter Jones added a comment - Landed for 2.4
            di.wang Di Wang added a comment - http://review.whamcloud.com/5601

            Di, I still see a lot of code like:

                    oa->o_id = lsm->lsm_object_id;
                    oa->o_seq = lsm->lsm_object_seq;
            

            that should be replaced with:

                    oa->o_oi = lsm->lsm_object_oid;
            

            also, lsm_object_oid should be renamed lsm_oi or lsm_ostid so that it is not confused with f_oid.

            adilger Andreas Dilger added a comment - Di, I still see a lot of code like: oa->o_id = lsm->lsm_object_id; oa->o_seq = lsm->lsm_object_seq; that should be replaced with: oa->o_oi = lsm->lsm_object_oid; also, lsm_object_oid should be renamed lsm_oi or lsm_ostid so that it is not confused with f_oid.

            As part of this ost_id cleanup patch, please rename lsm_object_oid to lsm_oi or lsm_ostid, if it hasn't been done through a refresh of http://review.whamcloud.com/3081. It would be good to use a similar field name "_oi" or "_ostid" for other ost_id members in other structures as well.

            adilger Andreas Dilger added a comment - As part of this ost_id cleanup patch, please rename lsm_object_oid to lsm_oi or lsm_ostid , if it hasn't been done through a refresh of http://review.whamcloud.com/3081 . It would be good to use a similar field name " _oi" or " _ostid" for other ost_id members in other structures as well.

            People

              di.wang Di Wang
              adilger Andreas Dilger
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: