[oe-commits] Andrea Adami : kexec-tools-klibc-static_2.0.1: revised patchset/ Tested on arm. Bump PR.
git version control
git at git.openembedded.org
Mon Oct 5 23:17:05 UTC 2009
Module: openembedded.git
Branch: org.openembedded.dev
Commit: c518a888a6e5a8180a6e5dddfc7e686d2707a365
URL: http://gitweb.openembedded.net/?p=openembedded.git&a=commit;h=c518a888a6e5a8180a6e5dddfc7e686d2707a365
Author: Andrea Adami <andrea.adami at gmail.com>
Date: Tue Oct 6 01:13:43 2009 +0200
kexec-tools-klibc-static_2.0.1: revised patchset/Tested on arm. Bump PR.
---
recipes/kexec/files/kexec-tools-2-klibc.patch | 17 ++++++++++++++---
recipes/kexec/kexec-tools-klibc-static_2.0.1.bb | 2 +-
2 files changed, 15 insertions(+), 4 deletions(-)
diff --git a/recipes/kexec/files/kexec-tools-2-klibc.patch b/recipes/kexec/files/kexec-tools-2-klibc.patch
index 43b2ebc..2196249 100644
--- a/recipes/kexec/files/kexec-tools-2-klibc.patch
+++ b/recipes/kexec/files/kexec-tools-2-klibc.patch
@@ -143,7 +143,7 @@ Index: kexec-tools-2.0.1/purgatory/string.c
Index: kexec-tools-2.0.1/kexec/kexec.c
===================================================================
--- kexec-tools-2.0.1.orig/kexec/kexec.c 2008-02-24 14:15:46.950825917 +0100
-+++ kexec-tools-2.0.1/kexec/kexec.c 2009-10-05 23:19:39.000000000 +0200
++++ kexec-tools-2.0.1/kexec/kexec.c 2009-10-06 00:37:01.000000000 +0200
@@ -38,9 +38,9 @@
#include "config.h"
@@ -171,7 +171,7 @@ Index: kexec-tools-2.0.1/kexec/kexec.c
int ret;
FILE *fp;
+ char *endptr;
-+ char *line = NULL;
++ char *line[3];
fp = fopen("/sys/kernel/kexec_loaded", "r");
if (fp == NULL)
@@ -187,7 +187,13 @@ Index: kexec-tools-2.0.1/kexec/kexec.c
fclose(fp);
return ret;
}
-@@ -994,9 +1002,14 @@
+@@ -990,17 +998,23 @@
+ {
+ FILE *fp;
+ size_t len;
+- char *line = NULL;
++ const int sizeof_line = 1024;
++ char *line = malloc(sizeof_line); /* according to strdup() later */
fp = fopen("/proc/cmdline", "r");
if (!fp)
@@ -204,6 +210,11 @@ Index: kexec-tools-2.0.1/kexec/kexec.c
if (line) {
/* strip newline */
+- *(line + strlen(line) - 1) = 0;
++ line[strlen(line) - 1] = '\0';
+
+ remove_parameter(line, "BOOT_IMAGE");
+ if (kexec_flags & KEXEC_ON_CRASH)
Index: kexec-tools-2.0.1/kexec/arch/arm/kexec-zImage-arm.c
===================================================================
diff --git a/recipes/kexec/kexec-tools-klibc-static_2.0.1.bb b/recipes/kexec/kexec-tools-klibc-static_2.0.1.bb
index b9586f0..2dbd1c2 100644
--- a/recipes/kexec/kexec-tools-klibc-static_2.0.1.bb
+++ b/recipes/kexec/kexec-tools-klibc-static_2.0.1.bb
@@ -3,7 +3,7 @@ require kexec-tools2.inc
DEFAULT_PREFERENCE = "-1"
-PR = "r0"
+PR = "r1"
DEPENDS = "klibc"
SRC_URI += "file://kexec-tools-2-headers.patch;patch=1 \
More information about the Openembedded-commits
mailing list