diff options
author | Khem Raj <raj.khem@gmail.com> | 2014-02-14 00:15:46 -0800 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2014-02-14 12:24:59 +0000 |
commit | f3fa7577e8153b537948cf48711ffe03dbab6b3b (patch) | |
tree | f6dfef495b8057accd0e2d8fab718142ab328a76 /meta/recipes-core/systemd | |
parent | 0e5cfef90ff762b33da6dc301dfc9cb3947c8a02 (diff) | |
download | openembedded-core-f3fa7577e8153b537948cf48711ffe03dbab6b3b.tar.gz openembedded-core-f3fa7577e8153b537948cf48711ffe03dbab6b3b.tar.bz2 openembedded-core-f3fa7577e8153b537948cf48711ffe03dbab6b3b.zip |
systemd: Refresh patches for uclibc
With recent patches added some of uclibc specific patches need
to be refreshed.
Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-core/systemd')
-rw-r--r-- | meta/recipes-core/systemd/systemd/systemd-pam-fix-fallocate.patch | 53 |
1 files changed, 26 insertions, 27 deletions
diff --git a/meta/recipes-core/systemd/systemd/systemd-pam-fix-fallocate.patch b/meta/recipes-core/systemd/systemd/systemd-pam-fix-fallocate.patch index 7cf9626539..d1740efc5c 100644 --- a/meta/recipes-core/systemd/systemd/systemd-pam-fix-fallocate.patch +++ b/meta/recipes-core/systemd/systemd/systemd-pam-fix-fallocate.patch @@ -1,11 +1,11 @@ Upstream-Status: Denied [no desire for uclibc support] Signed-off-by: Khem Raj <raj.khem@gmail.com> -Index: git/src/journal/journal-file.c +Index: systemd-208/src/journal/journal-file.c =================================================================== ---- git.orig/src/journal/journal-file.c 2012-09-02 09:49:15.126089594 -0700 -+++ git/src/journal/journal-file.c 2012-09-02 09:49:17.118089670 -0700 -@@ -34,6 +34,8 @@ +--- systemd-208.orig/src/journal/journal-file.c 2014-02-14 00:05:05.000000000 -0800 ++++ systemd-208/src/journal/journal-file.c 2014-02-14 00:08:41.338821677 -0800 +@@ -38,6 +38,8 @@ #include "compress.h" #include "fsprg.h" @@ -14,16 +14,16 @@ Index: git/src/journal/journal-file.c #define DEFAULT_DATA_HASH_TABLE_SIZE (2047ULL*sizeof(HashItem)) #define DEFAULT_FIELD_HASH_TABLE_SIZE (333ULL*sizeof(HashItem)) -@@ -262,7 +264,7 @@ +@@ -316,7 +318,7 @@ static int journal_file_allocate(JournalFile *f, uint64_t offset, uint64_t size) { - uint64_t old_size, new_size; + uint64_t old_size, new_size, file_size; - int r; + int r = 0; assert(f); -@@ -307,10 +309,25 @@ +@@ -359,9 +361,24 @@ /* Note that the glibc fallocate() fallback is very inefficient, hence we try to minimize the allocation area as we can. */ @@ -31,29 +31,28 @@ Index: git/src/journal/journal-file.c r = posix_fallocate(f->fd, old_size, new_size - old_size); if (r != 0) return -r; - +#else -+ /* Use good old method to write zeros into the journal file -+ perhaps very inefficient yet working. */ -+ if(new_size > old_size) { -+ char *buf = alloca(new_size - old_size); -+ off_t oldpos = lseek(f->fd, 0, SEEK_CUR); -+ bzero(buf, new_size - old_size); -+ lseek(f->fd, old_size, SEEK_SET); -+ r = write(f->fd, buf, new_size - old_size); -+ lseek(f->fd, oldpos, SEEK_SET); -+ } -+ if (r < 0) -+ return -errno; ++ /* Use good old method to write zeros into the journal file ++ perhaps very inefficient yet working. */ ++ if(new_size > old_size) { ++ char *buf = alloca(new_size - old_size); ++ off_t oldpos = lseek(f->fd, 0, SEEK_CUR); ++ bzero(buf, new_size - old_size); ++ lseek(f->fd, old_size, SEEK_SET); ++ r = write(f->fd, buf, new_size - old_size); ++ lseek(f->fd, oldpos, SEEK_SET); ++ } ++ if (r < 0) ++ return -errno; +#endif /* HAVE_POSIX_FALLOCATE */ - if (fstat(f->fd, &f->last_stat) < 0) - return -errno; -Index: git/src/journal/journald-kmsg.c + /* Increase the file size a bit further than this, so that we + * we can create larger memory maps to cache */ +Index: systemd-208/src/journal/journald-kmsg.c =================================================================== ---- git.orig/src/journal/journald-kmsg.c 2012-09-02 09:49:15.130089595 -0700 -+++ git/src/journal/journald-kmsg.c 2012-09-02 12:26:17.326447895 -0700 -@@ -404,6 +404,7 @@ +--- systemd-208.orig/src/journal/journald-kmsg.c 2014-02-14 00:05:05.000000000 -0800 ++++ systemd-208/src/journal/journald-kmsg.c 2014-02-14 00:05:47.498823000 -0800 +@@ -407,6 +407,7 @@ int server_open_kernel_seqnum(Server *s) { int fd; @@ -61,7 +60,7 @@ Index: git/src/journal/journald-kmsg.c uint64_t *p; assert(s); -@@ -417,8 +418,19 @@ +@@ -420,8 +421,19 @@ log_error("Failed to open /run/systemd/journal/kernel-seqnum, ignoring: %m"); return 0; } |