* [PATCH] e4defrag: fix ppc build
@ 2009-08-24 5:09 Eric Sandeen
2009-08-24 13:40 ` Greg Freemyer
2009-08-28 23:41 ` Theodore Tso
0 siblings, 2 replies; 4+ messages in thread
From: Eric Sandeen @ 2009-08-24 5:09 UTC (permalink / raw)
To: linux-ext4; +Cc: Kyle McMartin
From: Kyle McMartin <kyle@mcmartin.ca>
ppc glibc seems to be missing sync_file_range, so we fell back
to the local define, and there ppc differs as well, so the
build was failing.
Thanks to Kyle for the patch w/ the tidy solution.
Signed-off-by: Eric Sandeen <sandeen@redhat.com>
---
diff --git a/misc/e4defrag.c b/misc/e4defrag.c
index 4c83fa3..23f01b8 100644
--- a/misc/e4defrag.c
+++ b/misc/e4defrag.c
@@ -305,8 +305,10 @@ static int posix_fadvise(int fd, loff_t offset, size_t len, int advise)
#warning Using locally defined sync_file_range interface.
#ifndef __NR_sync_file_range
+#ifndef __NR_sync_file_range2 /* ppc */
#error Your kernel headers dont define __NR_sync_file_range
#endif
+#endif
/*
* sync_file_range() - Sync file region.
@@ -318,7 +320,11 @@ static int posix_fadvise(int fd, loff_t offset, size_t len, int advise)
*/
int sync_file_range(int fd, loff_t offset, loff_t length, unsigned int flag)
{
+#ifdef __NR_sync_file_range
return syscall(__NR_sync_file_range, fd, offset, length, flag);
+#else
+ return syscall(__NR_sync_file_range2, fd, flag, offset, length);
+#endif
}
#endif /* ! HAVE_SYNC_FILE_RANGE */
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH] e4defrag: fix ppc build
2009-08-24 5:09 [PATCH] e4defrag: fix ppc build Eric Sandeen
@ 2009-08-24 13:40 ` Greg Freemyer
2009-08-24 19:38 ` Theodore Tso
2009-08-28 23:41 ` Theodore Tso
1 sibling, 1 reply; 4+ messages in thread
From: Greg Freemyer @ 2009-08-24 13:40 UTC (permalink / raw)
To: Eric Sandeen; +Cc: linux-ext4, Kyle McMartin
On Mon, Aug 24, 2009 at 1:09 AM, Eric Sandeen<sandeen@redhat.com> wrote:
> From: Kyle McMartin <kyle@mcmartin.ca>
>
> ppc glibc seems to be missing sync_file_range, so we fell back
> to the local define, and there ppc differs as well, so the
> build was failing.
>
> Thanks to Kyle for the patch w/ the tidy solution.
>
> Signed-off-by: Eric Sandeen <sandeen@redhat.com>
> ---
>
> diff --git a/misc/e4defrag.c b/misc/e4defrag.c
Eric,
Which git repository holds e4defrag.c? I assume it is public.
Greg
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] e4defrag: fix ppc build
2009-08-24 13:40 ` Greg Freemyer
@ 2009-08-24 19:38 ` Theodore Tso
0 siblings, 0 replies; 4+ messages in thread
From: Theodore Tso @ 2009-08-24 19:38 UTC (permalink / raw)
To: Greg Freemyer; +Cc: Eric Sandeen, linux-ext4, Kyle McMartin
On Mon, Aug 24, 2009 at 09:40:51AM -0400, Greg Freemyer wrote:
> On Mon, Aug 24, 2009 at 1:09 AM, Eric Sandeen<sandeen@redhat.com> wrote:
> > From: Kyle McMartin <kyle@mcmartin.ca>
> >
> > ppc glibc seems to be missing sync_file_range, so we fell back
> > to the local define, and there ppc differs as well, so the
> > build was failing.
> >
> > Thanks to Kyle for the patch w/ the tidy solution.
> >
> > Signed-off-by: Eric Sandeen <sandeen@redhat.com>
> > ---
> >
> > diff --git a/misc/e4defrag.c b/misc/e4defrag.c
>
> Eric,
>
> Which git repository holds e4defrag.c? I assume it is public.
>
e4defrag can be found in the 'master', 'next', and 'pu' branches of
the e2fsprogs repository. It's not in the 'maint' branch, so it's not
in any of the e2fsprogs 1.41.x releases. The 'master' branch contains
the in-development work that will be showing up in e2fsprogs 1.42; so
far the big things that there is the on-going merge 64-bit block
number support, and e4defrag.
- Ted
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] e4defrag: fix ppc build
2009-08-24 5:09 [PATCH] e4defrag: fix ppc build Eric Sandeen
2009-08-24 13:40 ` Greg Freemyer
@ 2009-08-28 23:41 ` Theodore Tso
1 sibling, 0 replies; 4+ messages in thread
From: Theodore Tso @ 2009-08-28 23:41 UTC (permalink / raw)
To: Eric Sandeen; +Cc: linux-ext4, Kyle McMartin
On Sun, Aug 23, 2009 at 10:09:58PM -0700, Eric Sandeen wrote:
> From: Kyle McMartin <kyle@mcmartin.ca>
>
> ppc glibc seems to be missing sync_file_range, so we fell back
> to the local define, and there ppc differs as well, so the
> build was failing.
>
> Thanks to Kyle for the patch w/ the tidy solution.
>
> Signed-off-by: Eric Sandeen <sandeen@redhat.com>
Thanks, applied.
- Ted
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2009-08-28 23:41 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-08-24 5:09 [PATCH] e4defrag: fix ppc build Eric Sandeen
2009-08-24 13:40 ` Greg Freemyer
2009-08-24 19:38 ` Theodore Tso
2009-08-28 23:41 ` Theodore Tso
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).