[libvirt] [PATCH] Remove unused functions from domain_conf

Remove virDomainDevicePCIAddressEqual and virDomainDeviceDriveAddressEqual, which are defined but not used anywhere. * src/conf/domain_conf.[ch]: Remove virDomainDevicePCIAddressEqual and virDomainDeviceDriveAddressEqual. --- src/conf/domain_conf.c | 24 ------------------------ src/conf/domain_conf.h | 4 ---- 2 files changed, 0 insertions(+), 28 deletions(-) diff --git a/src/conf/domain_conf.c b/src/conf/domain_conf.c index 7f3df78..df35209 100644 --- a/src/conf/domain_conf.c +++ b/src/conf/domain_conf.c @@ -972,30 +972,6 @@ static int virDomainDeviceInfoFormat(virBufferPtr buf, #ifndef PROXY -int virDomainDevicePCIAddressEqual(virDomainDevicePCIAddressPtr a, - virDomainDevicePCIAddressPtr b) -{ - if (a->domain == b->domain && - a->bus == b->bus && - a->slot == b->slot && - a->function == b->function) - return 1; - - return 0; -} - - -int virDomainDeviceDriveAddressEqual(virDomainDeviceDriveAddressPtr a, - virDomainDeviceDriveAddressPtr b) -{ - if (a->controller == b->controller && - a->bus == b->bus && - a->unit == b->unit) - return 1; - - return 0; -} - static int virDomainDevicePCIAddressParseXML(xmlNodePtr node, diff --git a/src/conf/domain_conf.h b/src/conf/domain_conf.h index d9b2f28..307d9b5 100644 --- a/src/conf/domain_conf.h +++ b/src/conf/domain_conf.h @@ -743,10 +743,6 @@ void virDomainWatchdogDefFree(virDomainWatchdogDefPtr def); void virDomainVideoDefFree(virDomainVideoDefPtr def); void virDomainHostdevDefFree(virDomainHostdevDefPtr def); void virDomainDeviceDefFree(virDomainDeviceDefPtr def); -int virDomainDevicePCIAddressEqual(virDomainDevicePCIAddressPtr a, - virDomainDevicePCIAddressPtr b); -int virDomainDeviceDriveAddressEqual(virDomainDeviceDriveAddressPtr a, - virDomainDeviceDriveAddressPtr b); int virDomainDeviceAddressIsValid(virDomainDeviceInfoPtr info, int type); int virDomainDevicePCIAddressIsValid(virDomainDevicePCIAddressPtr addr); -- 1.6.6

On Wed, Feb 17, 2010 at 01:27:23PM +0000, Matthew Booth wrote:
Remove virDomainDevicePCIAddressEqual and virDomainDeviceDriveAddressEqual, which are defined but not used anywhere.
* src/conf/domain_conf.[ch]: Remove virDomainDevicePCIAddressEqual and virDomainDeviceDriveAddressEqual. --- src/conf/domain_conf.c | 24 ------------------------ src/conf/domain_conf.h | 4 ---- 2 files changed, 0 insertions(+), 28 deletions(-)
diff --git a/src/conf/domain_conf.c b/src/conf/domain_conf.c index 7f3df78..df35209 100644 --- a/src/conf/domain_conf.c +++ b/src/conf/domain_conf.c @@ -972,30 +972,6 @@ static int virDomainDeviceInfoFormat(virBufferPtr buf,
#ifndef PROXY
-int virDomainDevicePCIAddressEqual(virDomainDevicePCIAddressPtr a, - virDomainDevicePCIAddressPtr b) -{ - if (a->domain == b->domain && - a->bus == b->bus && - a->slot == b->slot && - a->function == b->function) - return 1; - - return 0; -} - - -int virDomainDeviceDriveAddressEqual(virDomainDeviceDriveAddressPtr a, - virDomainDeviceDriveAddressPtr b) -{ - if (a->controller == b->controller && - a->bus == b->bus && - a->unit == b->unit) - return 1; - - return 0; -} -
static int virDomainDevicePCIAddressParseXML(xmlNodePtr node, diff --git a/src/conf/domain_conf.h b/src/conf/domain_conf.h index d9b2f28..307d9b5 100644 --- a/src/conf/domain_conf.h +++ b/src/conf/domain_conf.h @@ -743,10 +743,6 @@ void virDomainWatchdogDefFree(virDomainWatchdogDefPtr def); void virDomainVideoDefFree(virDomainVideoDefPtr def); void virDomainHostdevDefFree(virDomainHostdevDefPtr def); void virDomainDeviceDefFree(virDomainDeviceDefPtr def); -int virDomainDevicePCIAddressEqual(virDomainDevicePCIAddressPtr a, - virDomainDevicePCIAddressPtr b); -int virDomainDeviceDriveAddressEqual(virDomainDeviceDriveAddressPtr a, - virDomainDeviceDriveAddressPtr b); int virDomainDeviceAddressIsValid(virDomainDeviceInfoPtr info, int type); int virDomainDevicePCIAddressIsValid(virDomainDevicePCIAddressPtr addr);
Hum, virDomainDevicePCIAddressEqual is actually exposed in src/libvirt_private.syms so that would have to be cleaned up there too. If no ongoing patches is needing them I'm fine removeing those, Daniel -- Daniel Veillard | libxml Gnome XML XSLT toolkit http://xmlsoft.org/ daniel@veillard.com | Rpmfind RPM search engine http://rpmfind.net/ http://veillard.com/ | virtualization library http://libvirt.org/

On 17/02/10 17:08, Daniel Veillard wrote:
Hum, virDomainDevicePCIAddressEqual is actually exposed in src/libvirt_private.syms so that would have to be cleaned up there too. If no ongoing patches is needing them I'm fine removeing those,
Hadn't spotted that. Attached new patch which touches src/libvirt_private.syms. Matt -- Matthew Booth, RHCA, RHCSS Red Hat Engineering, Virtualisation Team M: +44 (0)7977 267231 GPG ID: D33C3490 GPG FPR: 3733 612D 2D05 5458 8A8A 1600 3441 EA19 D33C 3490

On Wed, Feb 17, 2010 at 05:18:40PM +0000, Matthew Booth wrote:
On 17/02/10 17:08, Daniel Veillard wrote:
Hum, virDomainDevicePCIAddressEqual is actually exposed in src/libvirt_private.syms so that would have to be cleaned up there too. If no ongoing patches is needing them I'm fine removeing those,
Hadn't spotted that. Attached new patch which touches src/libvirt_private.syms.
Matt -- Matthew Booth, RHCA, RHCSS Red Hat Engineering, Virtualisation Team
M: +44 (0)7977 267231 GPG ID: D33C3490 GPG FPR: 3733 612D 2D05 5458 8A8A 1600 3441 EA19 D33C 3490
From 5612c7c7a5969a84cc97f50ad2bdf9070ef95210 Mon Sep 17 00:00:00 2001 From: Matthew Booth <mbooth@redhat.com> Date: Wed, 17 Feb 2010 13:25:41 +0000 Subject: [PATCH] Remove unused functions from domain_conf
Remove virDomainDevicePCIAddressEqual and virDomainDeviceDriveAddressEqual, which are defined but not used anywhere.
* src/conf/domain_conf.[ch] src/libvirt_private.syms: Remove virDomainDevicePCIAddressEqual and virDomainDeviceDriveAddressEqual. --- src/conf/domain_conf.c | 24 ------------------------ src/conf/domain_conf.h | 4 ---- src/libvirt_private.syms | 1 - 3 files changed, 0 insertions(+), 29 deletions(-)
Okay, pushed, thanks ! Daniel -- Daniel Veillard | libxml Gnome XML XSLT toolkit http://xmlsoft.org/ daniel@veillard.com | Rpmfind RPM search engine http://rpmfind.net/ http://veillard.com/ | virtualization library http://libvirt.org/
participants (2)
-
Daniel Veillard
-
Matthew Booth