Files
Ming Lei 5545ba4422 io_uring/cmd: axe duplicate io_uring_cmd_import_fixed_vec() declaration
JIRA: https://issues.redhat.com/browse/RHEL-106845

commit f1774d9d4e104639a9122bde3b1fe58a0c0dcde7
Author: Caleb Sander Mateos <csander@purestorage.com>
Date:   Tue May 20 13:33:36 2025 -0600

    io_uring/cmd: axe duplicate io_uring_cmd_import_fixed_vec() declaration

    io_uring_cmd_import_fixed_vec() is declared in both
    include/linux/io_uring/cmd.h and io_uring/uring_cmd.h. The declarations
    are identical (if redundant) for CONFIG_IO_URING=y. But if
    CONFIG_IO_URING=N, include/linux/io_uring/cmd.h declares the function as
    static inline while io_uring/uring_cmd.h declares it as extern. This
    causes linker errors if the declaration in io_uring/uring_cmd.h is used.

    Remove the declaration in io_uring/uring_cmd.h to avoid linker errors
    and prevent the declarations getting out of sync.

    Signed-off-by: Caleb Sander Mateos <csander@purestorage.com>
    Fixes: ef4902752972 ("io_uring/cmd: introduce io_uring_cmd_import_fixed_vec")
    Link: https://lore.kernel.org/r/20250520193337.1374509-1-csander@purestorage.com
    Signed-off-by: Jens Axboe <axboe@kernel.dk>

Signed-off-by: Ming Lei <ming.lei@redhat.com>
2025-08-26 12:17:07 +08:00

20 lines
566 B
C

// SPDX-License-Identifier: GPL-2.0
#include <linux/io_uring/cmd.h>
#include <linux/io_uring_types.h>
struct io_async_cmd {
struct io_uring_cmd_data data;
struct iou_vec vec;
struct io_uring_sqe sqes[2];
};
int io_uring_cmd(struct io_kiocb *req, unsigned int issue_flags);
int io_uring_cmd_prep(struct io_kiocb *req, const struct io_uring_sqe *sqe);
void io_uring_cmd_cleanup(struct io_kiocb *req);
bool io_uring_try_cancel_uring_cmd(struct io_ring_ctx *ctx,
struct io_uring_task *tctx, bool cancel_all);
void io_cmd_cache_free(const void *entry);