linux-fsdevel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Chung-Chiang Cheng <shepjeng@gmail.com>
To: christian.brauner@ubuntu.com, linux-fsdevel@vger.kernel.org,
	linux-kernel@vger.kernel.org, jamorris@linux.microsoft.com,
	axboe@kernel.dk, dhowells@redhat.com,
	ernesto.mnd.fernandez@gmail.com,
	Al Viro <viro@zeniv.linux.org.uk>
Cc: "Synology/Chung-Chiang Cheng" <cccheng@synology.com>
Subject: Re: [PATCH] hfsplus: report create_date to kstat.btime
Date: Fri, 25 Jun 2021 11:07:34 +0800	[thread overview]
Message-ID: <CAHuHWtkqMeT3UwKH3zMr5j782U9UcwrdjXdqVHLND2MLi8rQKg@mail.gmail.com> (raw)
In-Reply-To: <20210416172147.8736-1-cccheng@synology.com>

From: Chung-Chiang Cheng <cccheng@synology.com>

There's no HFSPLUS maintainer now. Could anyone help to review this
patch or give feedback?

On Sat, Apr 17, 2021 at 1:21 AM Chung-Chiang Cheng <shepjeng@gmail.com> wrote:
>
> The create_date field of inode in hfsplus is corresponding to kstat.btime
> and could be reported in statx.
>
> Signed-off-by: Chung-Chiang Cheng <cccheng@synology.com>
> ---
>  fs/hfsplus/inode.c | 5 +++++
>  1 file changed, 5 insertions(+)
>
> diff --git a/fs/hfsplus/inode.c b/fs/hfsplus/inode.c
> index 078c5c8a5156..aab3388a0fd7 100644
> --- a/fs/hfsplus/inode.c
> +++ b/fs/hfsplus/inode.c
> @@ -278,6 +278,11 @@ int hfsplus_getattr(struct user_namespace *mnt_userns, const struct path *path,
>         struct inode *inode = d_inode(path->dentry);
>         struct hfsplus_inode_info *hip = HFSPLUS_I(inode);
>
> +       if (request_mask & STATX_BTIME) {
> +               stat->result_mask |= STATX_BTIME;
> +               stat->btime = hfsp_mt2ut(hip->create_date);
> +       }
> +
>         if (inode->i_flags & S_APPEND)
>                 stat->attributes |= STATX_ATTR_APPEND;
>         if (inode->i_flags & S_IMMUTABLE)
> --
> 2.25.1
>

  reply	other threads:[~2021-06-25  3:07 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-04-16 17:21 [PATCH] hfsplus: report create_date to kstat.btime Chung-Chiang Cheng
2021-06-25  3:07 ` Chung-Chiang Cheng [this message]
2021-06-28 17:04 ` Viacheslav Dubeyko

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=CAHuHWtkqMeT3UwKH3zMr5j782U9UcwrdjXdqVHLND2MLi8rQKg@mail.gmail.com \
    --to=shepjeng@gmail.com \
    --cc=axboe@kernel.dk \
    --cc=cccheng@synology.com \
    --cc=christian.brauner@ubuntu.com \
    --cc=dhowells@redhat.com \
    --cc=ernesto.mnd.fernandez@gmail.com \
    --cc=jamorris@linux.microsoft.com \
    --cc=linux-fsdevel@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=viro@zeniv.linux.org.uk \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).