Uploaded image for project: 'Lustre'
  1. Lustre
  2. LU-17948

error: 'struct inode' has no member named 'i_mtime'

Details

    • Bug
    • Resolution: Fixed
    • Minor
    • Lustre 2.16.0
    • Lustre 2.16.0
    • None
    • 3
    • 9223372036854775807

    Description

      While building Ubuntu 24.04 on master branch, it failed as follows:

      /root/lustre-release/lustre/llite/pcc.c: In function 'pcc_try_readonly_open_attach':
      /root/lustre-release/lustre/llite/pcc.c:1691:32: error: 'struct inode' has no member named 'i_mtime'; did you mean '__i_mtime'?
       1691 |         item.pm_mtime = inode->i_mtime.tv_sec;
            |                                ^~~~~~~
            |                                __i_mtime
      

      The issue was introduced by the following commit:

      commit 3835f4d31e6f0cad8a9fca989f056dde018a1f06
      Author:     Qian Yingjin <qian@ddn.com>
      AuthorDate: Thu Aug 6 16:29:21 2020 +0800
      Commit:     Oleg Drokin <green@whamcloud.com>
      CommitDate: Wed Jun 5 04:48:06 2024 +0000
      
          LU-13881 pcc: comparator support for PCC rules
      

      Attachments

        Activity

          [LU-17948] error: 'struct inode' has no member named 'i_mtime'
          yujian Jian Yu added a comment -

          Landed for Lustre 2.16.0.

          yujian Jian Yu added a comment - Landed for Lustre 2.16.0.

          "Oleg Drokin <green@whamcloud.com>" merged in patch https://review.whamcloud.com/c/fs/lustre-release/+/55417/
          Subject: LU-17948 pcc: fix llapi_pcc_del() -Werror=enum-int-mismatch
          Project: fs/lustre-release
          Branch: master
          Current Patch Set:
          Commit: 5ef6f3459355e16fd27427e45ff417e93589c960

          gerrit Gerrit Updater added a comment - "Oleg Drokin <green@whamcloud.com>" merged in patch https://review.whamcloud.com/c/fs/lustre-release/+/55417/ Subject: LU-17948 pcc: fix llapi_pcc_del() -Werror=enum-int-mismatch Project: fs/lustre-release Branch: master Current Patch Set: Commit: 5ef6f3459355e16fd27427e45ff417e93589c960

          "Oleg Drokin <green@whamcloud.com>" merged in patch https://review.whamcloud.com/c/fs/lustre-release/+/55416/
          Subject: LU-17948 llite: replace i_mtime.tv_sec with inode_get_mtime_sec()
          Project: fs/lustre-release
          Branch: master
          Current Patch Set:
          Commit: 37486afa73573be6b4ce363038a9ce27d36101ee

          gerrit Gerrit Updater added a comment - "Oleg Drokin <green@whamcloud.com>" merged in patch https://review.whamcloud.com/c/fs/lustre-release/+/55416/ Subject: LU-17948 llite: replace i_mtime.tv_sec with inode_get_mtime_sec() Project: fs/lustre-release Branch: master Current Patch Set: Commit: 37486afa73573be6b4ce363038a9ce27d36101ee

          "Jian Yu <yujian@whamcloud.com>" uploaded a new patch: https://review.whamcloud.com/c/fs/lustre-release/+/55417
          Subject: LU-17948 pcc: fix llapi_pcc_del() -Werror=enum-int-mismatch
          Project: fs/lustre-release
          Branch: master
          Current Patch Set: 1
          Commit: 56c9415c8dc2d5341565c016602f5ddea1bf4851

          gerrit Gerrit Updater added a comment - "Jian Yu <yujian@whamcloud.com>" uploaded a new patch: https://review.whamcloud.com/c/fs/lustre-release/+/55417 Subject: LU-17948 pcc: fix llapi_pcc_del() -Werror=enum-int-mismatch Project: fs/lustre-release Branch: master Current Patch Set: 1 Commit: 56c9415c8dc2d5341565c016602f5ddea1bf4851

          "Jian Yu <yujian@whamcloud.com>" uploaded a new patch: https://review.whamcloud.com/c/fs/lustre-release/+/55416
          Subject: LU-17948 llite: replace i_mtime.tv_sec with inode_get_mtime_sec()
          Project: fs/lustre-release
          Branch: master
          Current Patch Set: 1
          Commit: 01ad420a20d5c3f08c50b35c76a25e4499d519fc

          gerrit Gerrit Updater added a comment - "Jian Yu <yujian@whamcloud.com>" uploaded a new patch: https://review.whamcloud.com/c/fs/lustre-release/+/55416 Subject: LU-17948 llite: replace i_mtime.tv_sec with inode_get_mtime_sec() Project: fs/lustre-release Branch: master Current Patch Set: 1 Commit: 01ad420a20d5c3f08c50b35c76a25e4499d519fc
          yujian Jian Yu added a comment -

          More failures with pcc codes:

          liblustreapi_pcc.c:755:5: error: conflicting types for 'llapi_pcc_del' due to enum/integer mismatch; have 'int(const char *, const char *, enum lu_pcc_cleanup_flags)' [-Werror=enum-int-mismatch]
            755 | int llapi_pcc_del(const char *mntpath, const char *pccpath,
                |     ^~~~~~~~~~~~~
          In file included from liblustreapi_pcc.c:35:
          /root/lustre-release/lustre/include/lustre/lustreapi.h:724:5: note: previous declaration of 'llapi_pcc_del' with type 'int(const char *, const char *, __u32)' {aka 'int(const char *, const char *, unsigned int)'}
            724 | int llapi_pcc_del(const char *mntpath, const char *pccpath, __u32 flags);
                |     ^~~~~~~~~~~~~
          liblustreapi_pcc.c:790:5: error: conflicting types for 'llapi_pcc_clear' due to enum/integer mismatch; have 'int(const char *, enum lu_pcc_cleanup_flags)' [-Werror=enum-int-mismatch]
            790 | int llapi_pcc_clear(const char *mntpath, enum lu_pcc_cleanup_flags flags)
                |     ^~~~~~~~~~~~~~~
          /root/lustre-release/lustre/include/lustre/lustreapi.h:725:5: note: previous declaration of 'llapi_pcc_clear' with type 'int(const char *, __u32)' {aka 'int(const char *, unsigned int)'}
            725 | int llapi_pcc_clear(const char *mntpath, __u32 flags);
                |     ^~~~~~~~~~~~~~~
          
          yujian Jian Yu added a comment - More failures with pcc codes: liblustreapi_pcc.c:755:5: error: conflicting types for 'llapi_pcc_del' due to enum/integer mismatch; have 'int(const char *, const char *, enum lu_pcc_cleanup_flags)' [-Werror=enum-int-mismatch] 755 | int llapi_pcc_del(const char *mntpath, const char *pccpath, | ^~~~~~~~~~~~~ In file included from liblustreapi_pcc.c:35: /root/lustre-release/lustre/include/lustre/lustreapi.h:724:5: note: previous declaration of 'llapi_pcc_del' with type 'int(const char *, const char *, __u32)' {aka 'int(const char *, const char *, unsigned int)'} 724 | int llapi_pcc_del(const char *mntpath, const char *pccpath, __u32 flags); | ^~~~~~~~~~~~~ liblustreapi_pcc.c:790:5: error: conflicting types for 'llapi_pcc_clear' due to enum/integer mismatch; have 'int(const char *, enum lu_pcc_cleanup_flags)' [-Werror=enum-int-mismatch] 790 | int llapi_pcc_clear(const char *mntpath, enum lu_pcc_cleanup_flags flags) | ^~~~~~~~~~~~~~~ /root/lustre-release/lustre/include/lustre/lustreapi.h:725:5: note: previous declaration of 'llapi_pcc_clear' with type 'int(const char *, __u32)' {aka 'int(const char *, unsigned int)'} 725 | int llapi_pcc_clear(const char *mntpath, __u32 flags); | ^~~~~~~~~~~~~~~

          People

            yujian Jian Yu
            yujian Jian Yu
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: