From: Frank Li <Frank.li@nxp.com>
To: "Thomas Weißschuh" <linux@weissschuh.net>
Cc: Vinod Koul <vkoul@kernel.org>, Frank Li <Frank.Li@kernel.org>,
dmaengine@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH 2/4] dmaengine: ioatdma: move sysfs entry definition out of header
Date: Wed, 4 Mar 2026 11:02:25 -0500 [thread overview]
Message-ID: <aahXkROc8TkgeoLM@lizhi-Precision-Tower-5810> (raw)
In-Reply-To: <20260302-sysfs-const-ioat-v1-2-1229ee1c83f3@weissschuh.net>
On Mon, Mar 02, 2026 at 11:15:54PM +0100, Thomas Weißschuh wrote:
> This structure is only ever used from sysfs.c.
>
> Move its definition there.
better descript which structure.
Move struct ioat_sysfs_entry into sysfs.c because it is only used in it.
Frank
>
> Signed-off-by: Thomas Weißschuh <linux@weissschuh.net>
> ---
> drivers/dma/ioat/dma.h | 6 ------
> drivers/dma/ioat/sysfs.c | 6 ++++++
> 2 files changed, 6 insertions(+), 6 deletions(-)
>
> diff --git a/drivers/dma/ioat/dma.h b/drivers/dma/ioat/dma.h
> index 27d2b411853f..e187f3a7e968 100644
> --- a/drivers/dma/ioat/dma.h
> +++ b/drivers/dma/ioat/dma.h
> @@ -140,12 +140,6 @@ struct ioatdma_chan {
> int prev_intr_coalesce;
> };
>
> -struct ioat_sysfs_entry {
> - struct attribute attr;
> - ssize_t (*show)(struct dma_chan *, char *);
> - ssize_t (*store)(struct dma_chan *, const char *, size_t);
> -};
> -
> /**
> * struct ioat_sed_ent - wrapper around super extended hardware descriptor
> * @hw: hardware SED
> diff --git a/drivers/dma/ioat/sysfs.c b/drivers/dma/ioat/sysfs.c
> index 5da9b0a7b2bb..709d672bae51 100644
> --- a/drivers/dma/ioat/sysfs.c
> +++ b/drivers/dma/ioat/sysfs.c
> @@ -14,6 +14,12 @@
>
> #include "../dmaengine.h"
>
> +struct ioat_sysfs_entry {
> + struct attribute attr;
> + ssize_t (*show)(struct dma_chan *, char *);
> + ssize_t (*store)(struct dma_chan *, const char *, size_t);
> +};
> +
> static ssize_t cap_show(struct dma_chan *c, char *page)
> {
> struct dma_device *dma = c->device;
>
> --
> 2.53.0
>
next prev parent reply other threads:[~2026-03-04 16:02 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-03-02 22:15 [PATCH 0/4] dmaengine: ioatdma: some sysfs cleanups and constifications Thomas Weißschuh
2026-03-02 22:15 ` [PATCH 1/4] dmaengine: ioatdma: make some sysfs structures static Thomas Weißschuh
2026-03-02 22:56 ` Dave Jiang
2026-03-04 16:00 ` Frank Li
2026-03-02 22:15 ` [PATCH 2/4] dmaengine: ioatdma: move sysfs entry definition out of header Thomas Weißschuh
2026-03-04 16:02 ` Frank Li [this message]
2026-03-02 22:15 ` [PATCH 3/4] dmaengine: ioatdma: make ioat_ktype const Thomas Weißschuh
2026-03-02 22:49 ` Dave Jiang
2026-03-04 16:03 ` Frank Li
2026-03-02 22:15 ` [PATCH 4/4] dmaengine: ioatdma: make sysfs attributes const Thomas Weißschuh
2026-03-02 22:50 ` Dave Jiang
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=aahXkROc8TkgeoLM@lizhi-Precision-Tower-5810 \
--to=frank.li@nxp.com \
--cc=Frank.Li@kernel.org \
--cc=dmaengine@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux@weissschuh.net \
--cc=vkoul@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®