All of lore.kernel.org
 help / color / mirror / Atom feed
From: Cyril Hrubis <chrubis@suse.cz>
To: Andrea Cervesato <andrea.cervesato@suse.de>
Cc: ltp@lists.linux.it
Subject: Re: [LTP] [PATCH v2 1/7] Add fallback definitions for lapi/fs.h
Date: Wed, 24 Jul 2024 18:29:00 +0200	[thread overview]
Message-ID: <ZqErzC4PMRrrk929@yuki> (raw)
In-Reply-To: <20240723-ioctl_ficlone-v2-1-33075bbc117f@suse.com>

Hi!
> diff --git a/configure.ac b/configure.ac
> index 1f8796c87..4d466f052 100644
> --- a/configure.ac
> +++ b/configure.ac
> @@ -177,6 +177,7 @@ AC_CHECK_TYPES([struct acct_v3],,,[#include <sys/acct.h>])
>  AC_CHECK_TYPES([struct af_alg_iv, struct sockaddr_alg],,,[# include <linux/if_alg.h>])
>  AC_CHECK_TYPES([struct fanotify_event_info_fid, struct fanotify_event_info_error,
>  		struct fanotify_event_info_header, struct fanotify_event_info_pidfd],,,[#include <sys/fanotify.h>])
> +AC_CHECK_TYPES([struct file_clone_range],,,[#include <linux/fs.h>])
>  AC_CHECK_TYPES([struct file_dedupe_range],,,[#include <linux/fs.h>])
>  
>  AC_CHECK_TYPES([struct file_handle],,,[
> diff --git a/include/lapi/fs.h b/include/lapi/fs.h
> index 635979b02..0e8d646d8 100644
> --- a/include/lapi/fs.h
> +++ b/include/lapi/fs.h
> @@ -20,6 +20,15 @@
>  #include <limits.h>
>  #include "lapi/abisize.h"
>  
> +#ifndef HAVE_FILE_CLONE_RANGE
> +struct file_clone_range {
> +	int64_t src_fd;
> +	uint64_t src_offset;
> +	uint64_t src_length;
> +	uint64_t dest_offset;
> +};
> +#endif

Sigh, this is still horribly broken even when I fixed the macro to
HAVE_STRUCT_FILE_CLONE_RANGE that is because:

commit b857f8723f30a4b9554bf6b0ff8fa52fd07e8b60
Author: Li Wang <liwang@redhat.com>
Date:   Fri Aug 5 14:34:01 2022 +0800

    lapi/fsmount: resolve conflict in different header files


However the CI seems to work fine if I remove the HAVE_MOUNT_SETATTR
check with:

 #define LAPI_FS_H__

 #include "config.h"
-#ifndef HAVE_MOUNT_SETATTR
-# ifdef HAVE_LINUX_FS_H
-#  include <linux/fs.h>
-# endif
+
+#ifdef HAVE_LINUX_FS_H
+# include <linux/fs.h>
 #endif

 #include <sys/user.h>


@Li do we still need that ifdef or can we get rid of it?

-- 
Cyril Hrubis
chrubis@suse.cz

-- 
Mailing list info: https://lists.linux.it/listinfo/ltp

  parent reply	other threads:[~2024-07-24 16:29 UTC|newest]

Thread overview: 29+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-07-23  7:15 [LTP] [PATCH v2 0/7] Add ioctl_ficlone testing suite Andrea Cervesato
2024-07-23  7:15 ` [LTP] [PATCH v2 1/7] Add fallback definitions for lapi/fs.h Andrea Cervesato
2024-07-24 11:52   ` Cyril Hrubis
2024-07-24 16:29   ` Cyril Hrubis [this message]
2024-07-25  7:11     ` Li Wang
2024-07-25  9:18       ` Cyril Hrubis
2024-07-25 12:55       ` Petr Vorel
2024-07-25 15:17         ` Cyril Hrubis
2024-07-26 12:03           ` Li Wang
2024-07-23  7:15 ` [LTP] [PATCH v2 2/7] Add ioctl_ficlone01 test Andrea Cervesato
2024-07-23  7:15 ` [LTP] [PATCH v2 3/7] Add ioctl_ficlone02 test Andrea Cervesato
2024-07-29 11:53   ` Petr Vorel
2024-07-29 11:53     ` Petr Vorel
2024-07-29 12:03     ` Cyril Hrubis
2024-07-29 12:03       ` Cyril Hrubis
2024-07-29 21:29       ` Petr Vorel
2024-07-29 21:29         ` Petr Vorel
2024-07-23  7:15 ` [LTP] [PATCH v2 4/7] Add ioctl_ficlone03 test Andrea Cervesato
2024-07-24 12:20   ` Cyril Hrubis
2024-07-23  7:15 ` [LTP] [PATCH v2 5/7] Add ioctl_ficlonerange01 test Andrea Cervesato
2024-07-24 15:24   ` Cyril Hrubis
2024-07-24 15:34     ` Cyril Hrubis
2024-07-23  7:15 ` [LTP] [PATCH v2 6/7] Add ioctl_ficlonerange02 test Andrea Cervesato
2024-07-24 15:37   ` Cyril Hrubis
2024-07-23  7:15 ` [LTP] [PATCH v2 7/7] Add ioctl_ficlone04 test Andrea Cervesato
2024-07-24 15:42   ` Cyril Hrubis
2024-07-24 19:36     ` Andrea Cervesato via ltp
2024-07-24 20:06       ` Cyril Hrubis
2024-07-25  7:16         ` Andrea Cervesato via ltp

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=ZqErzC4PMRrrk929@yuki \
    --to=chrubis@suse.cz \
    --cc=andrea.cervesato@suse.de \
    --cc=ltp@lists.linux.it \
    /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.