From: Juan Quintela <quintela@redhat.com>
To: qemu-devel@nongnu.org
Cc: Amit Shah <amit.shah@redhat.com>, Thomas Huth <thuth@linux.vnet.ibm.com>
Subject: [Qemu-devel] [PULL 09/13] migration: Remove unused functions
Date: Tue, 17 Mar 2015 16:30:31 +0100 [thread overview]
Message-ID: <1426606235-7238-10-git-send-email-quintela@redhat.com> (raw)
In-Reply-To: <1426606235-7238-1-git-send-email-quintela@redhat.com>
From: Thomas Huth <thuth@linux.vnet.ibm.com>
migrate_rdma_pin_all() and qsb_clone() are completely unused and thus
can be deleted.
Signed-off-by: Thomas Huth <thuth@linux.vnet.ibm.com>
Cc: Juan Quintela <quintela@redhat.com>
Cc: Amit Shah <amit.shah@redhat.com>
Signed-off-by: Juan Quintela <quintela@redhat.com>
---
include/migration/migration.h | 1 -
include/migration/qemu-file.h | 1 -
migration/migration.c | 9 ---------
migration/qemu-file-buf.c | 31 -------------------------------
4 files changed, 42 deletions(-)
diff --git a/include/migration/migration.h b/include/migration/migration.h
index 5e16af6..bf09968 100644
--- a/include/migration/migration.h
+++ b/include/migration/migration.h
@@ -139,7 +139,6 @@ void migrate_add_blocker(Error *reason);
*/
void migrate_del_blocker(Error *reason);
-bool migrate_rdma_pin_all(void);
bool migrate_zero_blocks(void);
bool migrate_auto_converge(void);
diff --git a/include/migration/qemu-file.h b/include/migration/qemu-file.h
index 94a8c97..745a850 100644
--- a/include/migration/qemu-file.h
+++ b/include/migration/qemu-file.h
@@ -133,7 +133,6 @@ bool qemu_file_mode_is_not_valid(const char *mode);
bool qemu_file_is_writable(QEMUFile *f);
QEMUSizedBuffer *qsb_create(const uint8_t *buffer, size_t len);
-QEMUSizedBuffer *qsb_clone(const QEMUSizedBuffer *);
void qsb_free(QEMUSizedBuffer *);
size_t qsb_set_length(QEMUSizedBuffer *qsb, size_t length);
size_t qsb_get_length(const QEMUSizedBuffer *qsb);
diff --git a/migration/migration.c b/migration/migration.c
index 1e44d9b..8465f91 100644
--- a/migration/migration.c
+++ b/migration/migration.c
@@ -579,15 +579,6 @@ void qmp_migrate_set_downtime(double value, Error **errp)
max_downtime = (uint64_t)value;
}
-bool migrate_rdma_pin_all(void)
-{
- MigrationState *s;
-
- s = migrate_get_current();
-
- return s->enabled_capabilities[MIGRATION_CAPABILITY_RDMA_PIN_ALL];
-}
-
bool migrate_auto_converge(void)
{
MigrationState *s;
diff --git a/migration/qemu-file-buf.c b/migration/qemu-file-buf.c
index e56a8ad..16a51a1 100644
--- a/migration/qemu-file-buf.c
+++ b/migration/qemu-file-buf.c
@@ -365,37 +365,6 @@ ssize_t qsb_write_at(QEMUSizedBuffer *qsb, const uint8_t *source,
return count;
}
-/**
- * Create a deep copy of the given QEMUSizedBuffer.
- *
- * @qsb: A QEMUSizedBuffer
- *
- * Returns a clone of @qsb or NULL on allocation failure
- */
-QEMUSizedBuffer *qsb_clone(const QEMUSizedBuffer *qsb)
-{
- QEMUSizedBuffer *out = qsb_create(NULL, qsb_get_length(qsb));
- size_t i;
- ssize_t res;
- off_t pos = 0;
-
- if (!out) {
- return NULL;
- }
-
- for (i = 0; i < qsb->n_iov; i++) {
- res = qsb_write_at(out, qsb->iov[i].iov_base,
- pos, qsb->iov[i].iov_len);
- if (res < 0) {
- qsb_free(out);
- return NULL;
- }
- pos += res;
- }
-
- return out;
-}
-
typedef struct QEMUBuffer {
QEMUSizedBuffer *qsb;
QEMUFile *file;
--
2.1.0
next prev parent reply other threads:[~2015-03-17 15:31 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-03-17 15:30 [Qemu-devel] [PULL 00/13] migration pull queue Juan Quintela
2015-03-17 15:30 ` [Qemu-devel] [PULL 01/13] migration: Avoid qerror_report_err() outside QMP command handlers Juan Quintela
2015-03-17 15:30 ` [Qemu-devel] [PULL 02/13] migration/rdma: clean up qemu_rdma_dest_init a bit Juan Quintela
2015-03-17 15:30 ` [Qemu-devel] [PULL 03/13] migration: Fix some 32 bit compiler errors Juan Quintela
2015-03-17 15:30 ` [Qemu-devel] [PULL 04/13] migration: Fix remaining " Juan Quintela
2015-03-17 15:30 ` [Qemu-devel] [PULL 05/13] migrate_incoming: use hmp_handle_error Juan Quintela
2015-03-17 15:30 ` [Qemu-devel] [PULL 06/13] Warn against the use of the string as uri parameter to migrate-incoming Juan Quintela
2015-03-17 15:30 ` [Qemu-devel] [PULL 07/13] migrate_incoming: Cleanup/clarify error messages Juan Quintela
2015-03-17 15:30 ` [Qemu-devel] [PULL 08/13] arch_init: Count the total number of pages by using helper function Juan Quintela
2015-03-17 15:30 ` Juan Quintela [this message]
2015-03-17 15:30 ` [Qemu-devel] [PULL 10/13] migration: Rename abbreviated macro MIG_STATE_* to MIGRATION_STATUS_* Juan Quintela
2015-03-17 15:30 ` [Qemu-devel] [PULL 11/13] hmp: Rename 'MigrationStatus' to 'HMPMigrationStatus' Juan Quintela
2015-03-17 15:30 ` [Qemu-devel] [PULL 12/13] migration: Convert 'status' of MigrationInfo to use an enum type Juan Quintela
2015-03-17 15:30 ` [Qemu-devel] [PULL 13/13] migration: Expose 'cancelling' status to user Juan Quintela
2015-03-17 18:53 ` [Qemu-devel] [PULL 00/13] migration pull queue Peter Maydell
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=1426606235-7238-10-git-send-email-quintela@redhat.com \
--to=quintela@redhat.com \
--cc=amit.shah@redhat.com \
--cc=qemu-devel@nongnu.org \
--cc=thuth@linux.vnet.ibm.com \
/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).