Details

    • Bug
    • Resolution: Unresolved
    • Minor
    • Upstream
    • None
    • 3
    • 17336

    Description

      There are a large number of ioctl cleanups that are needed for Lustre. A start is in http://review.whamcloud.com/10139 but there is more that could be done. The biggest offender is anything using struct libcfs_ioctl_data, which is a horrible structure that passes pointers from userspace to the kernel. Anything using that struct is a candidate for cleanup.

      The complexity is that Lustre ioctls are done in /dev/lnet or /dev/obd and may address any device in the stack (LNDs, OBD devices, etc). At a minimum, the libcfs_ioctl_data should be cleaned up to be a properly packed structure without internal pointers, but better would be proper ioctl structures that do not try to be all things to all users.

      It seems unlikely that we need to keep the lctl device configuration interface anymore (attach, detach, setup, cleanup, dump_cfg, etc), so all userspace commands/structures related to that could be removed.

      Some code (e.g. jt_obd_dump_log()) is obsolete due to liblustre removal and could also be removed outright.

      llapi_get_version() can read the version from /proc/fs/lustre/version via llapi_get_param() or similar, instead of using an ioctl.

      There is probably more, and possibly this needs to be split into several bugs, but at least it is a starting point for such cleanups.

      Attachments

        Issue Links

          Activity

            [LU-6202] clean up ioctl handling

            Oleg Drokin (green@whamcloud.com) merged in patch https://review.whamcloud.com/35993/
            Subject: LU-6202 obd: replace OBD_IOC_NO_TRANSNO with sysfs file
            Project: fs/lustre-release
            Branch: master
            Current Patch Set:
            Commit: 6706bfa81998c999012909e4cfcd1d3dbc347075

            gerrit Gerrit Updater added a comment - Oleg Drokin (green@whamcloud.com) merged in patch https://review.whamcloud.com/35993/ Subject: LU-6202 obd: replace OBD_IOC_NO_TRANSNO with sysfs file Project: fs/lustre-release Branch: master Current Patch Set: Commit: 6706bfa81998c999012909e4cfcd1d3dbc347075

            James Simmons (jsimmons@infradead.org) uploaded a new patch: https://review.whamcloud.com/35993
            Subject: LU-6202 obd: separate client and server specific fields from struct obd_device
            Project: fs/lustre-release
            Branch: master
            Current Patch Set: 1
            Commit: a00b3db4147dbf95433c3b7c1bc0ebe5329b63d8

            adilger Andreas Dilger added a comment - James Simmons (jsimmons@infradead.org) uploaded a new patch: https://review.whamcloud.com/35993 Subject: LU-6202 obd: separate client and server specific fields from struct obd_device Project: fs/lustre-release Branch: master Current Patch Set: 1 Commit: a00b3db4147dbf95433c3b7c1bc0ebe5329b63d8

            Oleg Drokin (green@whamcloud.com) merged in patch https://review.whamcloud.com/33693/
            Subject: LU-6202 utils: remove obsolete l_ioctl2() wrapper
            Project: fs/lustre-release
            Branch: master
            Current Patch Set:
            Commit: b3f3486723084f14493b3866803274576ed9e269

            gerrit Gerrit Updater added a comment - Oleg Drokin (green@whamcloud.com) merged in patch https://review.whamcloud.com/33693/ Subject: LU-6202 utils: remove obsolete l_ioctl2() wrapper Project: fs/lustre-release Branch: master Current Patch Set: Commit: b3f3486723084f14493b3866803274576ed9e269

            Oleg Drokin (green@whamcloud.com) merged in patch https://review.whamcloud.com/33692/
            Subject: LU-6202 misc: remove LIBCFS_IOC_DEBUG_MASK ioctl
            Project: fs/lustre-release
            Branch: master
            Current Patch Set:
            Commit: 70f932c7bfc590c03309bd2a83db20dd6ef5a8d4

            gerrit Gerrit Updater added a comment - Oleg Drokin (green@whamcloud.com) merged in patch https://review.whamcloud.com/33692/ Subject: LU-6202 misc: remove LIBCFS_IOC_DEBUG_MASK ioctl Project: fs/lustre-release Branch: master Current Patch Set: Commit: 70f932c7bfc590c03309bd2a83db20dd6ef5a8d4

            Oleg Drokin (green@whamcloud.com) merged in patch https://review.whamcloud.com/33691/
            Subject: LU-6202 misc: delete OBD_IOC_PING_TARGET ioctl
            Project: fs/lustre-release
            Branch: master
            Current Patch Set:
            Commit: d17d6ef74e522a4b57f2824161788a69f32bd5e7

            gerrit Gerrit Updater added a comment - Oleg Drokin (green@whamcloud.com) merged in patch https://review.whamcloud.com/33691/ Subject: LU-6202 misc: delete OBD_IOC_PING_TARGET ioctl Project: fs/lustre-release Branch: master Current Patch Set: Commit: d17d6ef74e522a4b57f2824161788a69f32bd5e7

            Andreas Dilger (adilger@whamcloud.com) uploaded a new patch: https://review.whamcloud.com/33695
            Subject: LU-6202 utils: allow device_list for non-root users
            Project: fs/lustre-release
            Branch: master
            Current Patch Set: 1
            Commit: dc2798a989f809f55757aae40d85950aa70afd1b

            gerrit Gerrit Updater added a comment - Andreas Dilger (adilger@whamcloud.com) uploaded a new patch: https://review.whamcloud.com/33695 Subject: LU-6202 utils: allow device_list for non-root users Project: fs/lustre-release Branch: master Current Patch Set: 1 Commit: dc2798a989f809f55757aae40d85950aa70afd1b

            Andreas Dilger (adilger@whamcloud.com) uploaded a new patch: https://review.whamcloud.com/33693
            Subject: LU-6202 utils: remove obsolete l_ioctl2() wrapper
            Project: fs/lustre-release
            Branch: master
            Current Patch Set: 1
            Commit: 941ba3ecb03ffcede12527961a59548cf9f8ec36

            gerrit Gerrit Updater added a comment - Andreas Dilger (adilger@whamcloud.com) uploaded a new patch: https://review.whamcloud.com/33693 Subject: LU-6202 utils: remove obsolete l_ioctl2() wrapper Project: fs/lustre-release Branch: master Current Patch Set: 1 Commit: 941ba3ecb03ffcede12527961a59548cf9f8ec36

            Andreas Dilger (adilger@whamcloud.com) uploaded a new patch: https://review.whamcloud.com/33692
            Subject: LU-6202 misc: remove LIBCFS_IOC_DEBUG_MASK ioctl
            Project: fs/lustre-release
            Branch: master
            Current Patch Set: 1
            Commit: e1bc122bfa88b06f873ed2ff5a4cedef308a9660

            gerrit Gerrit Updater added a comment - Andreas Dilger (adilger@whamcloud.com) uploaded a new patch: https://review.whamcloud.com/33692 Subject: LU-6202 misc: remove LIBCFS_IOC_DEBUG_MASK ioctl Project: fs/lustre-release Branch: master Current Patch Set: 1 Commit: e1bc122bfa88b06f873ed2ff5a4cedef308a9660

            Andreas Dilger (adilger@whamcloud.com) uploaded a new patch: https://review.whamcloud.com/33691
            Subject: LU-6202 misc: delete OBD_IOC_PING_TARGT ioctl
            Project: fs/lustre-release
            Branch: master
            Current Patch Set: 1
            Commit: b7f0d6d02f839f3c4757b2048ea7fe226f568c73

            gerrit Gerrit Updater added a comment - Andreas Dilger (adilger@whamcloud.com) uploaded a new patch: https://review.whamcloud.com/33691 Subject: LU-6202 misc: delete OBD_IOC_PING_TARGT ioctl Project: fs/lustre-release Branch: master Current Patch Set: 1 Commit: b7f0d6d02f839f3c4757b2048ea7fe226f568c73

            Oleg Drokin (green@whamcloud.com) merged in patch https://review.whamcloud.com/33284/
            Subject: LU-6202 libcfs: replace libcfs_register_ioctl with a blocking notifier_chain
            Project: fs/lustre-release
            Branch: master
            Current Patch Set:
            Commit: fba98579efc4fe3bb69309041b60d7723475b5e2

            gerrit Gerrit Updater added a comment - Oleg Drokin (green@whamcloud.com) merged in patch https://review.whamcloud.com/33284/ Subject: LU-6202 libcfs: replace libcfs_register_ioctl with a blocking notifier_chain Project: fs/lustre-release Branch: master Current Patch Set: Commit: fba98579efc4fe3bb69309041b60d7723475b5e2

            People

              simmonsja James A Simmons
              adilger Andreas Dilger
              Votes:
              0 Vote for this issue
              Watchers:
              8 Start watching this issue

              Dates

                Created:
                Updated: