From: "Darrick J. Wong" <djwong@kernel.org>
To: Christoph Hellwig <hch@infradead.org>
Cc: Carlos Maiolino <cem@kernel.org>, xfs <linux-xfs@vger.kernel.org>
Subject: Re: [PATCH] libfrog: emulate deprecated attrlist functionality in libattr
Date: Thu, 19 Sep 2024 09:04:59 -0700 [thread overview]
Message-ID: <20240919160459.GJ182218@frogsfrogsfrogs> (raw)
In-Reply-To: <ZuwuhwTDwvUyqXj1@infradead.org>
On Thu, Sep 19, 2024 at 07:00:39AM -0700, Christoph Hellwig wrote:
> > @@ -0,0 +1,34 @@
> > +/* SPDX-License-Identifier: GPL-2.0-or-later */
> > +/*
> > + * Copyright (c) 2024 Oracle. All Rights Reserved.
> > + * Author: Darrick J. Wong <djwong@kernel.org>
> > + */
> > +#ifndef __LIBFROG_FAKELIBATTR_H__
> > +#define __LIBFROG_FAKELIBATTR_H__
> > +
> > +struct attrlist_cursor;
>
> Maybe this file could use a common that it emulates libattr APIs /
> helpers?
/* This file emulates APIs from the deprecated libattr. */
> > + struct xfs_attrlist_cursor cur = { };
> > char attrbuf[XFS_XATTR_LIST_MAX];
> > char keybuf[XATTR_NAME_MAX + 1];
> > - struct attrlist *attrlist = (struct attrlist *)attrbuf;
> > - struct attrlist_ent *ent;
> > + struct xfs_attrlist *attrlist = (struct xfs_attrlist *)attrbuf;
>
> Overly long line. And as mentioned in reply to Carlos version of this
> we're probably better of just dynamically allocating the buffer here and
> do away with the casting.
I'll make a prep patch that turns all those into dynamic allocations.
> The rest looks good to me.
<nod>
--D
prev parent reply other threads:[~2024-09-19 16:05 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-09-18 21:00 [PATCH] libfrog: emulate deprecated attrlist functionality in libattr Darrick J. Wong
2024-09-19 14:00 ` Christoph Hellwig
2024-09-19 16:04 ` Darrick J. Wong [this message]
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=20240919160459.GJ182218@frogsfrogsfrogs \
--to=djwong@kernel.org \
--cc=cem@kernel.org \
--cc=hch@infradead.org \
--cc=linux-xfs@vger.kernel.org \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.