From: qiaonuohan <qiaonuohan@cn.fujitsu.com>
To: lcapitulino@redhat.com, qemu-devel@nongnu.org
Cc: qiaonuohan <qiaonuohan@cn.fujitsu.com>
Subject: [Qemu-devel] [PATCH v9 01/14] dump: const-qualify the buf of WriteCoreDumpFunction
Date: Tue, 18 Feb 2014 14:11:25 +0800 [thread overview]
Message-ID: <1392703898-20083-2-git-send-email-qiaonuohan@cn.fujitsu.com> (raw)
In-Reply-To: <1392703898-20083-1-git-send-email-qiaonuohan@cn.fujitsu.com>
WriteCoreDumpFunction is a function pointer that points to the function used to
write content in "buf" into core file, so "buf" should be const-qualify.
Signed-off-by: Qiao Nuohan <qiaonuohan@cn.fujitsu.com>
Reviewed-by: Laszlo Ersek <lersek@redhat.com>
---
dump.c | 2 +-
include/qom/cpu.h | 3 ++-
2 files changed, 3 insertions(+), 2 deletions(-)
diff --git a/dump.c b/dump.c
index 80a9116..42622de 100644
--- a/dump.c
+++ b/dump.c
@@ -99,7 +99,7 @@ static void dump_error(DumpState *s, const char *reason)
dump_cleanup(s);
}
-static int fd_write_vmcore(void *buf, size_t size, void *opaque)
+static int fd_write_vmcore(const void *buf, size_t size, void *opaque)
{
DumpState *s = opaque;
size_t written_size;
diff --git a/include/qom/cpu.h b/include/qom/cpu.h
index 367eda1..d734be8 100644
--- a/include/qom/cpu.h
+++ b/include/qom/cpu.h
@@ -28,7 +28,8 @@
#include "qemu/tls.h"
#include "qemu/typedefs.h"
-typedef int (*WriteCoreDumpFunction)(void *buf, size_t size, void *opaque);
+typedef int (*WriteCoreDumpFunction)(const void *buf, size_t size,
+ void *opaque);
/**
* vaddr:
--
1.7.1
next prev parent reply other threads:[~2014-02-18 6:13 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-02-18 6:11 [Qemu-devel] [PATCH v9 00/14] Make 'dump-guest-memory' dump in kdump-compressed format qiaonuohan
2014-02-18 6:11 ` qiaonuohan [this message]
2014-02-18 6:11 ` [Qemu-devel] [PATCH v9 02/14] dump: add argument to write_elfxx_notes qiaonuohan
2014-02-18 6:11 ` [Qemu-devel] [PATCH v9 03/14] dump: add API to write header of flatten format qiaonuohan
2014-02-18 6:11 ` [Qemu-devel] [PATCH v9 04/14] dump: add API to write vmcore qiaonuohan
2014-02-18 6:11 ` [Qemu-devel] [PATCH v9 05/14] dump: add API to write elf notes to buffer qiaonuohan
2014-02-18 6:11 ` [Qemu-devel] [PATCH v9 06/14] dump: add support for lzo/snappy qiaonuohan
2014-02-18 6:11 ` [Qemu-devel] [PATCH v9 07/14] dump: add members to DumpState and init some of them qiaonuohan
2014-02-18 6:11 ` [Qemu-devel] [PATCH v9 08/14] dump: add API to write dump header qiaonuohan
2014-02-18 6:11 ` [Qemu-devel] [PATCH v9 09/14] dump: add API to write dump_bitmap qiaonuohan
2014-02-18 6:11 ` [Qemu-devel] [PATCH v9 10/14] dump: add APIs to operate DataCache qiaonuohan
2014-02-18 6:11 ` [Qemu-devel] [PATCH v9 11/14] dump: add API to write dump pages qiaonuohan
2014-02-18 6:11 ` [Qemu-devel] [PATCH v9 12/14] dump: make kdump-compressed format available for 'dump-guest-memory' qiaonuohan
2014-02-18 6:11 ` [Qemu-devel] [PATCH v9 13/14] Define the architecture for compressed dump format qiaonuohan
2014-02-18 6:11 ` [Qemu-devel] [PATCH v9 14/14] dump: add 'query-dump-guest-memory-capability' command qiaonuohan
2014-02-28 17:05 ` [Qemu-devel] [PATCH v9 00/14] Make 'dump-guest-memory' dump in kdump-compressed format Luiz Capitulino
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=1392703898-20083-2-git-send-email-qiaonuohan@cn.fujitsu.com \
--to=qiaonuohan@cn.fujitsu.com \
--cc=lcapitulino@redhat.com \
--cc=qemu-devel@nongnu.org \
/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 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).