Index: src/libvirt.c =================================================================== RCS file: /data/cvs/libxen/src/libvirt.c,v retrieving revision 1.182 diff -u -r1.182 libvirt.c --- src/libvirt.c 4 Dec 2008 21:46:34 -0000 1.182 +++ src/libvirt.c 17 Dec 2008 14:25:57 -0000 @@ -257,8 +257,22 @@ #ifdef ENABLE_DEBUG debugEnv = getenv("LIBVIRT_DEBUG"); - if (debugEnv && *debugEnv && *debugEnv != '0') - debugFlag = 1; + if (debugEnv && *debugEnv && *debugEnv != '0') { + if (STREQ(debugEnv, "2") || STREQ(debugEnv, "info")) + virLogSetDefaultPriority(VIR_LOG_INFO); + else if (STREQ(debugEnv, "3") || STREQ(debugEnv, "warning")) + virLogSetDefaultPriority(VIR_LOG_WARN); + else if (STREQ(debugEnv, "4") || STREQ(debugEnv, "error")) + virLogSetDefaultPriority(VIR_LOG_ERROR); + else + virLogSetDefaultPriority(VIR_LOG_DEBUG); + } + debugEnv = getenv("LIBVIRT_LOG_FILTERS"); + if (debugEnv) + virLogParseFilters(debugEnv); + debugEnv = getenv("LIBVIRT_LOG_OUTPUTS"); + if (debugEnv) + virLogParseOutputs(debugEnv); #endif DEBUG0("register drivers"); @@ -734,7 +748,7 @@ virGetVersion(unsigned long *libVer, const char *type, unsigned long *typeVer) { - DEBUG("libVir=%p, type=%s, typeVer=%p", libVer, type, typeVer); + DEBUG("%s libVir=%p, type=%s, typeVer=%p", __FUNCTION__, libVer, type, typeVer); if (!initialized) if (virInitialize() < 0) @@ -980,7 +994,7 @@ if (virInitialize() < 0) return NULL; - DEBUG("name=%s", name); + DEBUG("%s name=%s", __FUNCTION__, name); return do_open (name, NULL, 0); } @@ -1003,7 +1017,7 @@ if (virInitialize() < 0) return NULL; - DEBUG("name=%s", name); + DEBUG("%s name=%s", __FUNCTION__, name); return do_open (name, NULL, VIR_CONNECT_RO); } @@ -1030,7 +1044,7 @@ if (virInitialize() < 0) return NULL; - DEBUG("name=%s, auth=%p, flags=%d", name, auth, flags); + DEBUG("%s name=%s, auth=%p, flags=%d", __FUNCTION__, name, auth, flags); return do_open (name, auth, flags); } @@ -1048,7 +1062,7 @@ int virConnectClose(virConnectPtr conn) { - DEBUG("conn=%p", conn); + DEBUG("%s conn=%p", __FUNCTION__, conn); if (!VIR_IS_CONNECT(conn)) return (-1); @@ -1073,7 +1087,7 @@ int virDrvSupportsFeature (virConnectPtr conn, int feature) { - DEBUG("conn=%p, feature=%d", conn, feature); + DEBUG("%s conn=%p, feature=%d", __FUNCTION__, conn, feature); if (!VIR_IS_CONNECT(conn)) return (-1); @@ -1096,7 +1110,7 @@ virConnectGetType(virConnectPtr conn) { const char *ret; - DEBUG("conn=%p", conn); + DEBUG("%s conn=%p", __FUNCTION__, conn); if (!VIR_IS_CONNECT(conn)) { virLibConnError(NULL, VIR_ERR_INVALID_CONN, __FUNCTION__); @@ -1126,7 +1140,7 @@ int virConnectGetVersion(virConnectPtr conn, unsigned long *hvVer) { - DEBUG("conn=%p, hvVer=%p", conn, hvVer); + DEBUG("%s conn=%p, hvVer=%p", __FUNCTION__, conn, hvVer); if (!VIR_IS_CONNECT(conn)) { virLibConnError(NULL, VIR_ERR_INVALID_CONN, __FUNCTION__); @@ -1160,7 +1174,7 @@ char * virConnectGetHostname (virConnectPtr conn) { - DEBUG("conn=%p", conn); + DEBUG("%s conn=%p", __FUNCTION__, conn); if (!VIR_IS_CONNECT(conn)) { virLibConnError(NULL, VIR_ERR_INVALID_CONN, __FUNCTION__); @@ -1194,7 +1208,7 @@ { char *name; - DEBUG("conn=%p", conn); + DEBUG("%s conn=%p", __FUNCTION__, conn); if (!VIR_IS_CONNECT(conn)) { virLibConnError(NULL, VIR_ERR_INVALID_CONN, __FUNCTION__); @@ -1230,7 +1244,7 @@ virConnectGetMaxVcpus(virConnectPtr conn, const char *type) { - DEBUG("conn=%p, type=%s", conn, type); + DEBUG("%s conn=%p, type=%s", __FUNCTION__, conn, type); if (!VIR_IS_CONNECT(conn)) { virLibConnError(NULL, VIR_ERR_INVALID_CONN, __FUNCTION__); @@ -1257,7 +1271,7 @@ int virConnectListDomains(virConnectPtr conn, int *ids, int maxids) { - DEBUG("conn=%p, ids=%p, maxids=%d", conn, ids, maxids); + DEBUG("%s conn=%p, ids=%p, maxids=%d", __FUNCTION__, conn, ids, maxids); if (!VIR_IS_CONNECT(conn)) { virLibConnError(NULL, VIR_ERR_INVALID_CONN, __FUNCTION__); @@ -1287,7 +1301,7 @@ int virConnectNumOfDomains(virConnectPtr conn) { - DEBUG("conn=%p", conn); + DEBUG("%s conn=%p", __FUNCTION__, conn); if (!VIR_IS_CONNECT(conn)) { virLibConnError(NULL, VIR_ERR_INVALID_CONN, __FUNCTION__); @@ -1318,7 +1332,7 @@ virConnectPtr virDomainGetConnect (virDomainPtr dom) { - DEBUG("dom=%p", dom); + DEBUG("%s dom=%p", __FUNCTION__, dom); if (!VIR_IS_DOMAIN (dom)) { virLibDomainError (NULL, VIR_ERR_INVALID_DOMAIN, __FUNCTION__); @@ -1346,7 +1360,7 @@ virDomainCreateXML(virConnectPtr conn, const char *xmlDesc, unsigned int flags) { - DEBUG("conn=%p, xmlDesc=%s, flags=%d", conn, xmlDesc, flags); + DEBUG("%s conn=%p, xmlDesc=%s, flags=%d", __FUNCTION__, conn, xmlDesc, flags); if (!VIR_IS_CONNECT(conn)) { virLibConnError(NULL, VIR_ERR_INVALID_CONN, __FUNCTION__); @@ -1402,7 +1416,7 @@ virDomainPtr virDomainLookupByID(virConnectPtr conn, int id) { - DEBUG("conn=%p, id=%d", conn, id); + DEBUG("%s conn=%p, id=%d", __FUNCTION__, conn, id); if (!VIR_IS_CONNECT(conn)) { virLibConnError(NULL, VIR_ERR_INVALID_CONN, __FUNCTION__); @@ -1433,7 +1447,7 @@ virDomainPtr virDomainLookupByUUID(virConnectPtr conn, const unsigned char *uuid) { - DEBUG("conn=%p, uuid=%s", conn, uuid); + DEBUG("%s conn=%p, uuid=%s", __FUNCTION__, conn, uuid); if (!VIR_IS_CONNECT(conn)) { virLibConnError(NULL, VIR_ERR_INVALID_CONN, __FUNCTION__); @@ -1468,7 +1482,7 @@ unsigned char uuid[VIR_UUID_BUFLEN]; int ret; - DEBUG("conn=%p, uuidstr=%s", conn, uuidstr); + DEBUG("%s conn=%p, uuidstr=%s", __FUNCTION__, conn, uuidstr); if (!VIR_IS_CONNECT(conn)) { virLibConnError(NULL, VIR_ERR_INVALID_CONN, __FUNCTION__); @@ -1516,7 +1530,7 @@ virDomainPtr virDomainLookupByName(virConnectPtr conn, const char *name) { - DEBUG("conn=%p, name=%s", conn, name); + DEBUG("%s conn=%p, name=%s", __FUNCTION__, conn, name); if (!VIR_IS_CONNECT(conn)) { virLibConnError(NULL, VIR_ERR_INVALID_CONN, __FUNCTION__); @@ -1550,7 +1564,7 @@ { virConnectPtr conn; - DEBUG("domain=%p", domain); + DEBUG("%s domain=%p", __FUNCTION__, domain); if (!VIR_IS_CONNECTED_DOMAIN(domain)) { virLibDomainError(NULL, VIR_ERR_INVALID_DOMAIN, __FUNCTION__); @@ -1582,7 +1596,7 @@ int virDomainFree(virDomainPtr domain) { - DEBUG("domain=%p", domain); + DEBUG("%s domain=%p", __FUNCTION__, domain); if (!VIR_IS_DOMAIN(domain)) { virLibDomainError(NULL, VIR_ERR_INVALID_DOMAIN, __FUNCTION__); @@ -1609,7 +1623,7 @@ virDomainSuspend(virDomainPtr domain) { virConnectPtr conn; - DEBUG("domain=%p", domain); + DEBUG("%s domain=%p", __FUNCTION__, domain); if (!VIR_IS_CONNECTED_DOMAIN(domain)) { virLibDomainError(NULL, VIR_ERR_INVALID_DOMAIN, __FUNCTION__); @@ -1643,7 +1657,7 @@ virDomainResume(virDomainPtr domain) { virConnectPtr conn; - DEBUG("domain=%p", domain); + DEBUG("%s domain=%p", __FUNCTION__, domain); if (!VIR_IS_CONNECTED_DOMAIN(domain)) { virLibDomainError(NULL, VIR_ERR_INVALID_DOMAIN, __FUNCTION__); @@ -1680,7 +1694,7 @@ { char filepath[4096]; virConnectPtr conn; - DEBUG("domain=%p, to=%s", domain, to); + DEBUG("%s domain=%p, to=%s", __FUNCTION__, domain, to); if (!VIR_IS_CONNECTED_DOMAIN(domain)) { virLibDomainError(NULL, VIR_ERR_INVALID_DOMAIN, __FUNCTION__); @@ -1736,7 +1750,7 @@ virDomainRestore(virConnectPtr conn, const char *from) { char filepath[4096]; - DEBUG("conn=%p, from=%s", conn, from); + DEBUG("%s conn=%p, from=%s", __FUNCTION__, conn, from); if (!VIR_IS_CONNECT(conn)) { virLibConnError(NULL, VIR_ERR_INVALID_CONN, __FUNCTION__); @@ -1794,7 +1808,7 @@ { char filepath[4096]; virConnectPtr conn; - DEBUG("domain=%p, to=%s, flags=%d", domain, to, flags); + DEBUG("%s domain=%p, to=%s, flags=%d", __FUNCTION__, domain, to, flags); if (!VIR_IS_CONNECTED_DOMAIN(domain)) { virLibDomainError(NULL, VIR_ERR_INVALID_DOMAIN, __FUNCTION__); @@ -1854,7 +1868,7 @@ virDomainShutdown(virDomainPtr domain) { virConnectPtr conn; - DEBUG("domain=%p", domain); + DEBUG("%s domain=%p", __FUNCTION__, domain); if (!VIR_IS_CONNECTED_DOMAIN(domain)) { virLibDomainError(NULL, VIR_ERR_INVALID_DOMAIN, __FUNCTION__); @@ -1889,7 +1903,7 @@ virDomainReboot(virDomainPtr domain, unsigned int flags) { virConnectPtr conn; - DEBUG("domain=%p, flags=%u", domain, flags); + DEBUG("%s domain=%p, flags=%u", __FUNCTION__, domain, flags); if (!VIR_IS_CONNECTED_DOMAIN(domain)) { virLibDomainError(NULL, VIR_ERR_INVALID_DOMAIN, __FUNCTION__); @@ -1921,7 +1935,7 @@ const char * virDomainGetName(virDomainPtr domain) { - DEBUG("domain=%p", domain); + DEBUG("%s domain=%p", __FUNCTION__, domain); if (!VIR_IS_DOMAIN(domain)) { virLibDomainError(NULL, VIR_ERR_INVALID_DOMAIN, __FUNCTION__); @@ -1942,7 +1956,7 @@ int virDomainGetUUID(virDomainPtr domain, unsigned char *uuid) { - DEBUG("domain=%p, uuid=%p", domain, uuid); + DEBUG("%s domain=%p, uuid=%p", __FUNCTION__, domain, uuid); if (!VIR_IS_DOMAIN(domain)) { virLibDomainError(NULL, VIR_ERR_INVALID_DOMAIN, __FUNCTION__); @@ -1972,7 +1986,7 @@ virDomainGetUUIDString(virDomainPtr domain, char *buf) { unsigned char uuid[VIR_UUID_BUFLEN]; - DEBUG("domain=%p, buf=%p", domain, buf); + DEBUG("%s domain=%p, buf=%p", __FUNCTION__, domain, buf); if (!VIR_IS_DOMAIN(domain)) { virLibDomainError(NULL, VIR_ERR_INVALID_DOMAIN, __FUNCTION__); @@ -2001,7 +2015,7 @@ unsigned int virDomainGetID(virDomainPtr domain) { - DEBUG("domain=%p", domain); + DEBUG("%s domain=%p", __FUNCTION__, domain); if (!VIR_IS_DOMAIN(domain)) { virLibDomainError(NULL, VIR_ERR_INVALID_DOMAIN, __FUNCTION__); @@ -2023,7 +2037,7 @@ virDomainGetOSType(virDomainPtr domain) { virConnectPtr conn; - DEBUG("domain=%p", domain); + DEBUG("%s domain=%p", __FUNCTION__, domain); if (!VIR_IS_DOMAIN(domain)) { virLibDomainError(NULL, VIR_ERR_INVALID_DOMAIN, __FUNCTION__); @@ -2053,7 +2067,7 @@ virDomainGetMaxMemory(virDomainPtr domain) { virConnectPtr conn; - DEBUG("domain=%p", domain); + DEBUG("%s domain=%p", __FUNCTION__, domain); if (!VIR_IS_CONNECTED_DOMAIN(domain)) { virLibDomainError(NULL, VIR_ERR_INVALID_DOMAIN, __FUNCTION__); @@ -2085,7 +2099,7 @@ virDomainSetMaxMemory(virDomainPtr domain, unsigned long memory) { virConnectPtr conn; - DEBUG("domain=%p, memory=%lu", domain, memory); + DEBUG("%s domain=%p, memory=%lu", __FUNCTION__, domain, memory); if (domain == NULL) { TODO @@ -2128,7 +2142,7 @@ virDomainSetMemory(virDomainPtr domain, unsigned long memory) { virConnectPtr conn; - DEBUG("domain=%p, memory=%lu", domain, memory); + DEBUG("%s domain=%p, memory=%lu", __FUNCTION__, domain, memory); if (domain == NULL) { TODO @@ -2171,7 +2185,7 @@ virDomainGetInfo(virDomainPtr domain, virDomainInfoPtr info) { virConnectPtr conn; - DEBUG("domain=%p, info=%p", domain, info); + DEBUG("%s domain=%p, info=%p", __FUNCTION__, domain, info); if (!VIR_IS_CONNECTED_DOMAIN(domain)) { virLibDomainError(NULL, VIR_ERR_INVALID_DOMAIN, __FUNCTION__); @@ -2208,7 +2222,7 @@ virDomainGetXMLDesc(virDomainPtr domain, int flags) { virConnectPtr conn; - DEBUG("domain=%p, flags=%d", domain, flags); + DEBUG("%s domain=%p, flags=%d", __FUNCTION__, domain, flags); if (!VIR_IS_DOMAIN(domain)) { virLibDomainError(NULL, VIR_ERR_INVALID_DOMAIN, __FUNCTION__); @@ -2286,7 +2300,7 @@ char *cookie = NULL; char *dom_xml = NULL; int cookielen = 0, ret, version = 0; - DEBUG("domain=%p, dconn=%p, flags=%lu, dname=%s, uri=%s, bandwidth=%lu", + DEBUG("%s domain=%p, dconn=%p, flags=%lu, dname=%s, uri=%s, bandwidth=%lu", __FUNCTION__, domain, dconn, flags, dname, uri, bandwidth); if (!VIR_IS_DOMAIN (domain)) { @@ -2419,7 +2433,7 @@ const char *dname, unsigned long bandwidth) { - DEBUG("dconn=%p, cookie=%p, cookielen=%p, uri_in=%s, uri_out=%p, flags=%lu, dname=%s, bandwidth=%lu", dconn, cookie, cookielen, uri_in, uri_out, flags, dname, bandwidth); + DEBUG("%s dconn=%p, cookie=%p, cookielen=%p, uri_in=%s, uri_out=%p, flags=%lu, dname=%s, bandwidth=%lu", __FUNCTION__, dconn, cookie, cookielen, uri_in, uri_out, flags, dname, bandwidth); if (!VIR_IS_CONNECT (dconn)) { virLibConnError (NULL, VIR_ERR_INVALID_CONN, __FUNCTION__); @@ -2449,7 +2463,7 @@ unsigned long bandwidth) { virConnectPtr conn; - DEBUG("domain=%p, cookie=%p, cookielen=%d, uri=%s, flags=%lu, dname=%s, bandwidth=%lu", domain, cookie, cookielen, uri, flags, dname, bandwidth); + DEBUG("%s domain=%p, cookie=%p, cookielen=%d, uri=%s, flags=%lu, dname=%s, bandwidth=%lu", __FUNCTION__, domain, cookie, cookielen, uri, flags, dname, bandwidth); if (!VIR_IS_DOMAIN (domain)) { virLibDomainError (NULL, VIR_ERR_INVALID_DOMAIN, __FUNCTION__); @@ -2478,7 +2492,7 @@ const char *uri, unsigned long flags) { - DEBUG("dconn=%p, dname=%s, cookie=%p, cookielen=%d, uri=%s, flags=%lu", dconn, dname, cookie, cookielen, uri, flags); + DEBUG("%s dconn=%p, dname=%s, cookie=%p, cookielen=%d, uri=%s, flags=%lu", __FUNCTION__, dconn, dname, cookie, cookielen, uri, flags); if (!VIR_IS_CONNECT (dconn)) { virLibConnError (NULL, VIR_ERR_INVALID_CONN, __FUNCTION__); @@ -2510,7 +2524,7 @@ unsigned long bandwidth, const char *dom_xml) { - DEBUG("dconn=%p, cookie=%p, cookielen=%p, uri_in=%s, uri_out=%p, flags=%lu, dname=%s, bandwidth=%lu, dom_xml=%s", dconn, cookie, cookielen, uri_in, uri_out, flags, dname, bandwidth, dom_xml); + DEBUG("%s dconn=%p, cookie=%p, cookielen=%p, uri_in=%s, uri_out=%p, flags=%lu, dname=%s, bandwidth=%lu, dom_xml=%s", __FUNCTION__, dconn, cookie, cookielen, uri_in, uri_out, flags, dname, bandwidth, dom_xml); if (!VIR_IS_CONNECT (dconn)) { virLibConnError (NULL, VIR_ERR_INVALID_CONN, __FUNCTION__); @@ -2540,7 +2554,7 @@ unsigned long flags, int retcode) { - DEBUG("dconn=%p, dname=%s, cookie=%p, cookielen=%d, uri=%s, flags=%lu, retcode=%d", dconn, dname, cookie, cookielen, uri, flags, retcode); + DEBUG("%s dconn=%p, dname=%s, cookie=%p, cookielen=%d, uri=%s, flags=%lu, retcode=%d", __FUNCTION__, dconn, dname, cookie, cookielen, uri, flags, retcode); if (!VIR_IS_CONNECT (dconn)) { virLibConnError (NULL, VIR_ERR_INVALID_CONN, __FUNCTION__); @@ -2570,7 +2584,7 @@ int virNodeGetInfo(virConnectPtr conn, virNodeInfoPtr info) { - DEBUG("conn=%p, info=%p", conn, info); + DEBUG("%s conn=%p, info=%p", __FUNCTION__, conn, info); if (!VIR_IS_CONNECT(conn)) { virLibConnError(NULL, VIR_ERR_INVALID_CONN, __FUNCTION__); @@ -2601,7 +2615,7 @@ char * virConnectGetCapabilities (virConnectPtr conn) { - DEBUG("conn=%p", conn); + DEBUG("%s conn=%p", __FUNCTION__, conn); if (!VIR_IS_CONNECT (conn)) { virLibConnError (NULL, VIR_ERR_INVALID_CONN, __FUNCTION__); @@ -2626,7 +2640,7 @@ unsigned long long virNodeGetFreeMemory(virConnectPtr conn) { - DEBUG("conn=%p", conn); + DEBUG("%s conn=%p", __FUNCTION__, conn); if (!VIR_IS_CONNECT (conn)) { virLibConnError (NULL, VIR_ERR_INVALID_CONN, __FUNCTION__); @@ -2654,7 +2668,7 @@ { virConnectPtr conn; char *schedtype; - DEBUG("domain=%p, nparams=%p", domain, nparams); + DEBUG("%s domain=%p, nparams=%p", __FUNCTION__, domain, nparams); if (!VIR_IS_CONNECTED_DOMAIN(domain)) { virLibDomainError(NULL, VIR_ERR_INVALID_DOMAIN, __FUNCTION__); @@ -2691,7 +2705,7 @@ virSchedParameterPtr params, int *nparams) { virConnectPtr conn; - DEBUG("domain=%p, params=%p, nparams=%p", domain, params, nparams); + DEBUG("%s domain=%p, params=%p, nparams=%p", __FUNCTION__, domain, params, nparams); if (!VIR_IS_CONNECTED_DOMAIN(domain)) { virLibDomainError(NULL, VIR_ERR_INVALID_DOMAIN, __FUNCTION__); @@ -2723,7 +2737,7 @@ virSchedParameterPtr params, int nparams) { virConnectPtr conn; - DEBUG("domain=%p, params=%p, nparams=%d", domain, params, nparams); + DEBUG("%s domain=%p, params=%p, nparams=%d", __FUNCTION__, domain, params, nparams); if (!VIR_IS_CONNECTED_DOMAIN(domain)) { virLibDomainError(NULL, VIR_ERR_INVALID_DOMAIN, __FUNCTION__); @@ -2772,7 +2786,7 @@ { virConnectPtr conn; struct _virDomainBlockStats stats2 = { -1, -1, -1, -1, -1 }; - DEBUG("domain=%p, path=%s, stats=%p, size=%zi", dom, path, stats, size); + DEBUG("%s domain=%p, path=%s, stats=%p, size=%zi", __FUNCTION__, dom, path, stats, size); if (!stats || size > sizeof stats2) { virLibDomainError (dom, VIR_ERR_INVALID_ARG, __FUNCTION__); @@ -2824,7 +2838,7 @@ virConnectPtr conn; struct _virDomainInterfaceStats stats2 = { -1, -1, -1, -1, -1, -1, -1, -1 }; - DEBUG("domain=%p, path=%s, stats=%p, size=%zi", dom, path, stats, size); + DEBUG("%s domain=%p, path=%s, stats=%p, size=%zi", __FUNCTION__, dom, path, stats, size); if (!stats || size > sizeof stats2) { virLibDomainError (dom, VIR_ERR_INVALID_ARG, __FUNCTION__); @@ -2896,7 +2910,7 @@ unsigned int flags) { virConnectPtr conn; - DEBUG("domain=%p, path=%s, offset=%lld, size=%zi, buffer=%p", + DEBUG("%s domain=%p, path=%s, offset=%lld, size=%zi, buffer=%p", __FUNCTION__, dom, path, offset, size, buffer); if (!VIR_IS_CONNECTED_DOMAIN (dom)) { @@ -3042,7 +3056,7 @@ */ virDomainPtr virDomainDefineXML(virConnectPtr conn, const char *xml) { - DEBUG("conn=%p, xml=%s", conn, xml); + DEBUG("%s conn=%p, xml=%s", __FUNCTION__, conn, xml); if (!VIR_IS_CONNECT(conn)) { virLibConnError(NULL, VIR_ERR_INVALID_CONN, __FUNCTION__); @@ -3075,7 +3089,7 @@ int virDomainUndefine(virDomainPtr domain) { virConnectPtr conn; - DEBUG("domain=%p", domain); + DEBUG("%s domain=%p", __FUNCTION__, domain); if (!VIR_IS_CONNECTED_DOMAIN(domain)) { virLibDomainError(NULL, VIR_ERR_INVALID_DOMAIN, __FUNCTION__); @@ -3105,7 +3119,7 @@ int virConnectNumOfDefinedDomains(virConnectPtr conn) { - DEBUG("conn=%p", conn); + DEBUG("%s conn=%p", __FUNCTION__, conn); if (!VIR_IS_CONNECT(conn)) { virLibConnError(NULL, VIR_ERR_INVALID_CONN, __FUNCTION__); @@ -3133,7 +3147,7 @@ int virConnectListDefinedDomains(virConnectPtr conn, char **const names, int maxnames) { - DEBUG("conn=%p, names=%p, maxnames=%d", conn, names, maxnames); + DEBUG("%s conn=%p, names=%p, maxnames=%d", __FUNCTION__, conn, names, maxnames); if (!VIR_IS_CONNECT(conn)) { virLibConnError(NULL, VIR_ERR_INVALID_CONN, __FUNCTION__); @@ -3164,7 +3178,7 @@ int virDomainCreate(virDomainPtr domain) { virConnectPtr conn; - DEBUG("domain=%p", domain); + DEBUG("%s domain=%p", __FUNCTION__, domain); if (domain == NULL) { TODO @@ -3203,7 +3217,7 @@ int *autostart) { virConnectPtr conn; - DEBUG("domain=%p, autostart=%p", domain, autostart); + DEBUG("%s domain=%p, autostart=%p", __FUNCTION__, domain, autostart); if (!VIR_IS_DOMAIN(domain)) { virLibDomainError(NULL, VIR_ERR_INVALID_DOMAIN, __FUNCTION__); @@ -3238,7 +3252,7 @@ int autostart) { virConnectPtr conn; - DEBUG("domain=%p, autostart=%d", domain, autostart); + DEBUG("%s domain=%p, autostart=%d", __FUNCTION__, domain, autostart); if (!VIR_IS_DOMAIN(domain)) { virLibDomainError(NULL, VIR_ERR_INVALID_DOMAIN, __FUNCTION__); @@ -3271,7 +3285,7 @@ virDomainSetVcpus(virDomainPtr domain, unsigned int nvcpus) { virConnectPtr conn; - DEBUG("domain=%p, nvcpus=%u", domain, nvcpus); + DEBUG("%s domain=%p, nvcpus=%u", __FUNCTION__, domain, nvcpus); if (domain == NULL) { TODO @@ -3322,7 +3336,7 @@ unsigned char *cpumap, int maplen) { virConnectPtr conn; - DEBUG("domain=%p, vcpu=%u, cpumap=%p, maplen=%d", domain, vcpu, cpumap, maplen); + DEBUG("%s domain=%p, vcpu=%u, cpumap=%p, maplen=%d", __FUNCTION__, domain, vcpu, cpumap, maplen); if (domain == NULL) { TODO @@ -3377,7 +3391,7 @@ unsigned char *cpumaps, int maplen) { virConnectPtr conn; - DEBUG("domain=%p, info=%p, maxinfo=%d, cpumaps=%p, maplen=%d", domain, info, maxinfo, cpumaps, maplen); + DEBUG("%s domain=%p, info=%p, maxinfo=%d, cpumaps=%p, maplen=%d", __FUNCTION__, domain, info, maxinfo, cpumaps, maplen); if (domain == NULL) { TODO @@ -3422,7 +3436,7 @@ virDomainGetMaxVcpus(virDomainPtr domain) { virConnectPtr conn; - DEBUG("domain=%p", domain); + DEBUG("%s domain=%p", __FUNCTION__, domain); if (!VIR_IS_CONNECTED_DOMAIN(domain)) { virLibDomainError(NULL, VIR_ERR_INVALID_DOMAIN, __FUNCTION__); @@ -3452,7 +3466,7 @@ virDomainAttachDevice(virDomainPtr domain, const char *xml) { virConnectPtr conn; - DEBUG("domain=%p, xml=%s", domain, xml); + DEBUG("%s domain=%p, xml=%s", __FUNCTION__, domain, xml); if (!VIR_IS_CONNECTED_DOMAIN(domain)) { virLibDomainError(NULL, VIR_ERR_INVALID_DOMAIN, __FUNCTION__); @@ -3484,7 +3498,7 @@ virDomainDetachDevice(virDomainPtr domain, const char *xml) { virConnectPtr conn; - DEBUG("domain=%p, xml=%s", domain, xml); + DEBUG("%s domain=%p, xml=%s", __FUNCTION__, domain, xml); if (!VIR_IS_CONNECTED_DOMAIN(domain)) { virLibDomainError(NULL, VIR_ERR_INVALID_DOMAIN, __FUNCTION__); @@ -3525,7 +3539,7 @@ virNodeGetCellsFreeMemory(virConnectPtr conn, unsigned long long *freeMems, int startCell, int maxCells) { - DEBUG("conn=%p, freeMems=%p, startCell=%d, maxCells=%d", + DEBUG("%s conn=%p, freeMems=%p, startCell=%d, maxCells=%d", __FUNCTION__, conn, freeMems, startCell, maxCells); if (!VIR_IS_CONNECT(conn)) { @@ -3562,7 +3576,7 @@ virConnectPtr virNetworkGetConnect (virNetworkPtr net) { - DEBUG("net=%p", net); + DEBUG("%s net=%p", __FUNCTION__, net); if (!VIR_IS_NETWORK (net)) { virLibNetworkError (NULL, VIR_ERR_INVALID_NETWORK, __FUNCTION__); @@ -3582,7 +3596,7 @@ int virConnectNumOfNetworks(virConnectPtr conn) { - DEBUG("conn=%p", conn); + DEBUG("%s conn=%p", __FUNCTION__, conn); if (!VIR_IS_CONNECT(conn)) { virLibConnError(NULL, VIR_ERR_INVALID_CONN, __FUNCTION__); @@ -3609,7 +3623,7 @@ int virConnectListNetworks(virConnectPtr conn, char **const names, int maxnames) { - DEBUG("conn=%p, names=%p, maxnames=%d", conn, names, maxnames); + DEBUG("%s conn=%p, names=%p, maxnames=%d", __FUNCTION__, conn, names, maxnames); if (!VIR_IS_CONNECT(conn)) { virLibConnError(NULL, VIR_ERR_INVALID_CONN, __FUNCTION__); @@ -3639,7 +3653,7 @@ int virConnectNumOfDefinedNetworks(virConnectPtr conn) { - DEBUG("conn=%p", conn); + DEBUG("%s conn=%p", __FUNCTION__, conn); if (!VIR_IS_CONNECT(conn)) { virLibConnError(NULL, VIR_ERR_INVALID_CONN, __FUNCTION__); @@ -3667,7 +3681,7 @@ virConnectListDefinedNetworks(virConnectPtr conn, char **const names, int maxnames) { - DEBUG("conn=%p, names=%p, maxnames=%d", conn, names, maxnames); + DEBUG("%s conn=%p, names=%p, maxnames=%d", __FUNCTION__, conn, names, maxnames); if (!VIR_IS_CONNECT(conn)) { virLibConnError(NULL, VIR_ERR_INVALID_CONN, __FUNCTION__); @@ -3700,7 +3714,7 @@ virNetworkPtr virNetworkLookupByName(virConnectPtr conn, const char *name) { - DEBUG("conn=%p, name=%s", conn, name); + DEBUG("%s conn=%p, name=%s", __FUNCTION__, conn, name); if (!VIR_IS_CONNECT(conn)) { virLibConnError(NULL, VIR_ERR_INVALID_CONN, __FUNCTION__); @@ -3731,7 +3745,7 @@ virNetworkPtr virNetworkLookupByUUID(virConnectPtr conn, const unsigned char *uuid) { - DEBUG("conn=%p, uuid=%s", conn, uuid); + DEBUG("%s conn=%p, uuid=%s", __FUNCTION__, conn, uuid); if (!VIR_IS_CONNECT(conn)) { virLibConnError(NULL, VIR_ERR_INVALID_CONN, __FUNCTION__); @@ -3765,7 +3779,7 @@ int raw[VIR_UUID_BUFLEN], i; unsigned char uuid[VIR_UUID_BUFLEN]; int ret; - DEBUG("conn=%p, uuidstr=%s", conn, uuidstr); + DEBUG("%s conn=%p, uuidstr=%s", __FUNCTION__, conn, uuidstr); if (!VIR_IS_CONNECT(conn)) { virLibConnError(NULL, VIR_ERR_INVALID_CONN, __FUNCTION__); @@ -3813,7 +3827,7 @@ virNetworkPtr virNetworkCreateXML(virConnectPtr conn, const char *xmlDesc) { - DEBUG("conn=%p, xmlDesc=%s", conn, xmlDesc); + DEBUG("%s conn=%p, xmlDesc=%s", __FUNCTION__, conn, xmlDesc); if (!VIR_IS_CONNECT(conn)) { virLibConnError(NULL, VIR_ERR_INVALID_CONN, __FUNCTION__); @@ -3847,7 +3861,7 @@ virNetworkPtr virNetworkDefineXML(virConnectPtr conn, const char *xml) { - DEBUG("conn=%p, xml=%s", conn, xml); + DEBUG("%s conn=%p, xml=%s", __FUNCTION__, conn, xml); if (!VIR_IS_CONNECT(conn)) { virLibConnError(NULL, VIR_ERR_INVALID_CONN, __FUNCTION__); @@ -3880,7 +3894,7 @@ int virNetworkUndefine(virNetworkPtr network) { virConnectPtr conn; - DEBUG("network=%p", network); + DEBUG("%s network=%p", __FUNCTION__, network); if (!VIR_IS_CONNECTED_NETWORK(network)) { virLibNetworkError(NULL, VIR_ERR_INVALID_NETWORK, __FUNCTION__); @@ -3912,7 +3926,7 @@ virNetworkCreate(virNetworkPtr network) { virConnectPtr conn; - DEBUG("network=%p", network); + DEBUG("%s network=%p", __FUNCTION__, network); if (network == NULL) { TODO @@ -3950,7 +3964,7 @@ virNetworkDestroy(virNetworkPtr network) { virConnectPtr conn; - DEBUG("network=%p", network); + DEBUG("%s network=%p", __FUNCTION__, network); if (!VIR_IS_CONNECTED_NETWORK(network)) { virLibNetworkError(NULL, VIR_ERR_INVALID_NETWORK, __FUNCTION__); @@ -3982,7 +3996,7 @@ int virNetworkFree(virNetworkPtr network) { - DEBUG("network=%p", network); + DEBUG("%s network=%p", __FUNCTION__, network); if (!VIR_IS_NETWORK(network)) { virLibNetworkError(NULL, VIR_ERR_INVALID_NETWORK, __FUNCTION__); @@ -4005,7 +4019,7 @@ const char * virNetworkGetName(virNetworkPtr network) { - DEBUG("network=%p", network); + DEBUG("%s network=%p", __FUNCTION__, network); if (!VIR_IS_NETWORK(network)) { virLibNetworkError(NULL, VIR_ERR_INVALID_NETWORK, __FUNCTION__); @@ -4026,7 +4040,7 @@ int virNetworkGetUUID(virNetworkPtr network, unsigned char *uuid) { - DEBUG("network=%p, uuid=%p", network, uuid); + DEBUG("%s network=%p, uuid=%p", __FUNCTION__, network, uuid); if (!VIR_IS_NETWORK(network)) { virLibNetworkError(NULL, VIR_ERR_INVALID_NETWORK, __FUNCTION__); @@ -4056,7 +4070,7 @@ virNetworkGetUUIDString(virNetworkPtr network, char *buf) { unsigned char uuid[VIR_UUID_BUFLEN]; - DEBUG("network=%p, buf=%p", network, buf); + DEBUG("%s network=%p, buf=%p", __FUNCTION__, network, buf); if (!VIR_IS_NETWORK(network)) { virLibNetworkError(NULL, VIR_ERR_INVALID_NETWORK, __FUNCTION__); @@ -4089,7 +4103,7 @@ virNetworkGetXMLDesc(virNetworkPtr network, int flags) { virConnectPtr conn; - DEBUG("network=%p, flags=%d", network, flags); + DEBUG("%s network=%p, flags=%d", __FUNCTION__, network, flags); if (!VIR_IS_NETWORK(network)) { virLibNetworkError(NULL, VIR_ERR_INVALID_NETWORK, __FUNCTION__); @@ -4123,7 +4137,7 @@ virNetworkGetBridgeName(virNetworkPtr network) { virConnectPtr conn; - DEBUG("network=%p", network); + DEBUG("%s network=%p", __FUNCTION__, network); if (!VIR_IS_NETWORK(network)) { virLibNetworkError(NULL, VIR_ERR_INVALID_NETWORK, __FUNCTION__); @@ -4155,7 +4169,7 @@ int *autostart) { virConnectPtr conn; - DEBUG("network=%p, autostart=%p", network, autostart); + DEBUG("%s network=%p, autostart=%p", __FUNCTION__, network, autostart); if (!VIR_IS_NETWORK(network)) { virLibNetworkError(NULL, VIR_ERR_INVALID_NETWORK, __FUNCTION__); @@ -4190,7 +4204,7 @@ int autostart) { virConnectPtr conn; - DEBUG("network=%p, autostart=%d", network, autostart); + DEBUG("%s network=%p, autostart=%d", __FUNCTION__, network, autostart); if (!VIR_IS_NETWORK(network)) { virLibNetworkError(NULL, VIR_ERR_INVALID_NETWORK, __FUNCTION__); @@ -4224,7 +4238,7 @@ virConnectPtr virStoragePoolGetConnect (virStoragePoolPtr pool) { - DEBUG("pool=%p", pool); + DEBUG("%s pool=%p", __FUNCTION__, pool); if (!VIR_IS_STORAGE_POOL (pool)) { virLibStoragePoolError (NULL, VIR_ERR_INVALID_STORAGE_POOL, __FUNCTION__); @@ -4244,7 +4258,7 @@ int virConnectNumOfStoragePools (virConnectPtr conn) { - DEBUG("conn=%p", conn); + DEBUG("%s conn=%p", __FUNCTION__, conn); if (!VIR_IS_CONNECT(conn)) { virLibConnError(NULL, VIR_ERR_INVALID_CONN, __FUNCTION__); @@ -4275,7 +4289,7 @@ char **const names, int maxnames) { - DEBUG("conn=%p, names=%p, maxnames=%d", conn, names, maxnames); + DEBUG("%s conn=%p, names=%p, maxnames=%d", __FUNCTION__, conn, names, maxnames); if (!VIR_IS_CONNECT(conn)) { virLibConnError(NULL, VIR_ERR_INVALID_CONN, __FUNCTION__); @@ -4307,7 +4321,7 @@ int virConnectNumOfDefinedStoragePools(virConnectPtr conn) { - DEBUG("conn=%p", conn); + DEBUG("%s conn=%p", __FUNCTION__, conn); if (!VIR_IS_CONNECT(conn)) { virLibConnError(NULL, VIR_ERR_INVALID_CONN, __FUNCTION__); @@ -4339,7 +4353,7 @@ char **const names, int maxnames) { - DEBUG("conn=%p, names=%p, maxnames=%d", conn, names, maxnames); + DEBUG("%s conn=%p, names=%p, maxnames=%d", __FUNCTION__, conn, names, maxnames); if (!VIR_IS_CONNECT(conn)) { virLibConnError(NULL, VIR_ERR_INVALID_CONN, __FUNCTION__); @@ -4416,7 +4430,7 @@ virStoragePoolLookupByName(virConnectPtr conn, const char *name) { - DEBUG("conn=%p, name=%s", conn, name); + DEBUG("%s conn=%p, name=%s", __FUNCTION__, conn, name); if (!VIR_IS_CONNECT(conn)) { virLibConnError(NULL, VIR_ERR_INVALID_CONN, __FUNCTION__); @@ -4448,7 +4462,7 @@ virStoragePoolLookupByUUID(virConnectPtr conn, const unsigned char *uuid) { - DEBUG("conn=%p, uuid=%s", conn, uuid); + DEBUG("%s conn=%p, uuid=%s", __FUNCTION__, conn, uuid); if (!VIR_IS_CONNECT(conn)) { virLibConnError(NULL, VIR_ERR_INVALID_CONN, __FUNCTION__); @@ -4482,7 +4496,7 @@ const char *uuidstr) { unsigned char uuid[VIR_UUID_BUFLEN]; - DEBUG("conn=%p, uuidstr=%s", conn, uuidstr); + DEBUG("%s conn=%p, uuidstr=%s", __FUNCTION__, conn, uuidstr); if (!VIR_IS_CONNECT(conn)) { virLibConnError(NULL, VIR_ERR_INVALID_CONN, __FUNCTION__); @@ -4513,7 +4527,7 @@ virStoragePoolPtr virStoragePoolLookupByVolume(virStorageVolPtr vol) { - DEBUG("vol=%p", vol); + DEBUG("%s vol=%p", __FUNCTION__, vol); if (!VIR_IS_STORAGE_VOL(vol)) { virLibConnError(NULL, VIR_ERR_INVALID_CONN, __FUNCTION__); @@ -4545,7 +4559,7 @@ const char *xmlDesc, unsigned int flags) { - DEBUG("conn=%p, xmlDesc=%s", conn, xmlDesc); + DEBUG("%s conn=%p, xmlDesc=%s", __FUNCTION__, conn, xmlDesc); if (!VIR_IS_CONNECT(conn)) { virLibConnError(NULL, VIR_ERR_INVALID_CONN, __FUNCTION__); @@ -4583,7 +4597,7 @@ const char *xml, unsigned int flags) { - DEBUG("conn=%p, xml=%s", conn, xml); + DEBUG("%s conn=%p, xml=%s", __FUNCTION__, conn, xml); if (!VIR_IS_CONNECT(conn)) { virLibConnError(NULL, VIR_ERR_INVALID_CONN, __FUNCTION__); @@ -4620,7 +4634,7 @@ unsigned int flags) { virConnectPtr conn; - DEBUG("pool=%p, flags=%u", pool, flags); + DEBUG("%s pool=%p, flags=%u", __FUNCTION__, pool, flags); if (!VIR_IS_CONNECTED_STORAGE_POOL(pool)) { virLibStoragePoolError(NULL, VIR_ERR_INVALID_NETWORK, __FUNCTION__); @@ -4653,7 +4667,7 @@ virStoragePoolUndefine(virStoragePoolPtr pool) { virConnectPtr conn; - DEBUG("pool=%p", pool); + DEBUG("%s pool=%p", __FUNCTION__, pool); if (!VIR_IS_CONNECTED_STORAGE_POOL(pool)) { virLibStoragePoolError(NULL, VIR_ERR_INVALID_NETWORK, __FUNCTION__); @@ -4688,7 +4702,7 @@ unsigned int flags) { virConnectPtr conn; - DEBUG("pool=%p", pool); + DEBUG("%s pool=%p", __FUNCTION__, pool); if (pool == NULL) { TODO; @@ -4729,7 +4743,7 @@ virStoragePoolDestroy(virStoragePoolPtr pool) { virConnectPtr conn; - DEBUG("pool=%p", pool); + DEBUG("%s pool=%p", __FUNCTION__, pool); if (!VIR_IS_CONNECTED_STORAGE_POOL(pool)) { virLibStoragePoolError(NULL, VIR_ERR_INVALID_STORAGE_POOL, __FUNCTION__); @@ -4765,7 +4779,7 @@ unsigned int flags) { virConnectPtr conn; - DEBUG("pool=%p, flags=%u", pool, flags); + DEBUG("%s pool=%p, flags=%u", __FUNCTION__, pool, flags); if (!VIR_IS_CONNECTED_STORAGE_POOL(pool)) { virLibStoragePoolError(NULL, VIR_ERR_INVALID_STORAGE_POOL, __FUNCTION__); @@ -4798,7 +4812,7 @@ int virStoragePoolFree(virStoragePoolPtr pool) { - DEBUG("pool=%p", pool); + DEBUG("%s pool=%p", __FUNCTION__, pool); if (!VIR_IS_STORAGE_POOL(pool)) { virLibStoragePoolError(NULL, VIR_ERR_INVALID_STORAGE_POOL, __FUNCTION__); @@ -4827,7 +4841,7 @@ unsigned int flags) { virConnectPtr conn; - DEBUG("pool=%p flags=%u", pool, flags); + DEBUG("%s pool=%p flags=%u", __FUNCTION__, pool, flags); if (!VIR_IS_CONNECTED_STORAGE_POOL(pool)) { virLibStoragePoolError(NULL, VIR_ERR_INVALID_STORAGE_POOL, __FUNCTION__); @@ -4859,7 +4873,7 @@ const char* virStoragePoolGetName(virStoragePoolPtr pool) { - DEBUG("pool=%p", pool); + DEBUG("%s pool=%p", __FUNCTION__, pool); if (!VIR_IS_STORAGE_POOL(pool)) { virLibStoragePoolError(NULL, VIR_ERR_INVALID_STORAGE_POOL, __FUNCTION__); @@ -4883,7 +4897,7 @@ virStoragePoolGetUUID(virStoragePoolPtr pool, unsigned char *uuid) { - DEBUG("pool=%p, uuid=%p", pool, uuid); + DEBUG("%s pool=%p, uuid=%p", __FUNCTION__, pool, uuid); if (!VIR_IS_STORAGE_POOL(pool)) { virLibStoragePoolError(NULL, VIR_ERR_INVALID_STORAGE_POOL, __FUNCTION__); @@ -4914,7 +4928,7 @@ char *buf) { unsigned char uuid[VIR_UUID_BUFLEN]; - DEBUG("pool=%p, buf=%p", pool, buf); + DEBUG("%s pool=%p, buf=%p", __FUNCTION__, pool, buf); if (!VIR_IS_STORAGE_POOL(pool)) { virLibStoragePoolError(NULL, VIR_ERR_INVALID_STORAGE_POOL, __FUNCTION__); @@ -4949,7 +4963,7 @@ virStoragePoolInfoPtr info) { virConnectPtr conn; - DEBUG("pool=%p, info=%p", pool, info); + DEBUG("%s pool=%p, info=%p", __FUNCTION__, pool, info); if (!VIR_IS_CONNECTED_STORAGE_POOL(pool)) { virLibStoragePoolError(NULL, VIR_ERR_INVALID_STORAGE_POOL, __FUNCTION__); @@ -4989,7 +5003,7 @@ unsigned int flags) { virConnectPtr conn; - DEBUG("pool=%p, flags=%u", pool, flags); + DEBUG("%s pool=%p, flags=%u", __FUNCTION__, pool, flags); if (!VIR_IS_STORAGE_POOL(pool)) { virLibStoragePoolError(NULL, VIR_ERR_INVALID_STORAGE_POOL, __FUNCTION__); @@ -5026,7 +5040,7 @@ int *autostart) { virConnectPtr conn; - DEBUG("pool=%p, autostart=%p", pool, autostart); + DEBUG("%s pool=%p, autostart=%p", __FUNCTION__, pool, autostart); if (!VIR_IS_STORAGE_POOL(pool)) { virLibStoragePoolError(NULL, VIR_ERR_INVALID_STORAGE_POOL, __FUNCTION__); @@ -5061,7 +5075,7 @@ int autostart) { virConnectPtr conn; - DEBUG("pool=%p, autostart=%d", pool, autostart); + DEBUG("%s pool=%p, autostart=%d", __FUNCTION__, pool, autostart); if (!VIR_IS_STORAGE_POOL(pool)) { virLibStoragePoolError(NULL, VIR_ERR_INVALID_STORAGE_POOL, __FUNCTION__); @@ -5089,7 +5103,7 @@ int virStoragePoolNumOfVolumes(virStoragePoolPtr pool) { - DEBUG("pool=%p", pool); + DEBUG("%s pool=%p", __FUNCTION__, pool); if (!VIR_IS_STORAGE_POOL(pool)) { virLibConnError(NULL, VIR_ERR_INVALID_STORAGE_POOL, __FUNCTION__); @@ -5120,7 +5134,7 @@ char **const names, int maxnames) { - DEBUG("pool=%p, names=%p, maxnames=%d", pool, names, maxnames); + DEBUG("%s pool=%p, names=%p, maxnames=%d", __FUNCTION__, pool, names, maxnames); if (!VIR_IS_STORAGE_POOL(pool)) { virLibConnError(NULL, VIR_ERR_INVALID_STORAGE_POOL, __FUNCTION__); @@ -5157,7 +5171,7 @@ virConnectPtr virStorageVolGetConnect (virStorageVolPtr vol) { - DEBUG("vol=%p", vol); + DEBUG("%s vol=%p", __FUNCTION__, vol); if (!VIR_IS_STORAGE_VOL (vol)) { virLibStoragePoolError (NULL, VIR_ERR_INVALID_STORAGE_VOL, __FUNCTION__); @@ -5181,7 +5195,7 @@ virStorageVolLookupByName(virStoragePoolPtr pool, const char *name) { - DEBUG("pool=%p, name=%s", pool, name); + DEBUG("%s pool=%p, name=%s", __FUNCTION__, pool, name); if (!VIR_IS_STORAGE_POOL(pool)) { virLibConnError(NULL, VIR_ERR_INVALID_CONN, __FUNCTION__); @@ -5215,7 +5229,7 @@ virStorageVolLookupByKey(virConnectPtr conn, const char *key) { - DEBUG("conn=%p, key=%s", conn, key); + DEBUG("%s conn=%p, key=%s", __FUNCTION__, conn, key); if (!VIR_IS_CONNECT(conn)) { virLibConnError(NULL, VIR_ERR_INVALID_CONN, __FUNCTION__); @@ -5247,7 +5261,7 @@ virStorageVolLookupByPath(virConnectPtr conn, const char *path) { - DEBUG("conn=%p, path=%s", conn, path); + DEBUG("%s conn=%p, path=%s", __FUNCTION__, conn, path); if (!VIR_IS_CONNECT(conn)) { virLibConnError(NULL, VIR_ERR_INVALID_CONN, __FUNCTION__); @@ -5278,7 +5292,7 @@ const char* virStorageVolGetName(virStorageVolPtr vol) { - DEBUG("vol=%p", vol); + DEBUG("%s vol=%p", __FUNCTION__, vol); if (!VIR_IS_STORAGE_VOL(vol)) { virLibStorageVolError(NULL, VIR_ERR_INVALID_STORAGE_VOL, __FUNCTION__); @@ -5301,7 +5315,7 @@ const char* virStorageVolGetKey(virStorageVolPtr vol) { - DEBUG("vol=%p", vol); + DEBUG("%s vol=%p", __FUNCTION__, vol); if (!VIR_IS_STORAGE_VOL(vol)) { virLibStorageVolError(NULL, VIR_ERR_INVALID_STORAGE_VOL, __FUNCTION__); @@ -5328,7 +5342,7 @@ const char *xmldesc, unsigned int flags) { - DEBUG("pool=%p, flags=%u", pool, flags); + DEBUG("%s pool=%p, flags=%u", __FUNCTION__, pool, flags); if (!VIR_IS_STORAGE_POOL(pool)) { virLibConnError(NULL, VIR_ERR_INVALID_STORAGE_VOL, __FUNCTION__); @@ -5362,7 +5376,7 @@ unsigned int flags) { virConnectPtr conn; - DEBUG("vol=%p, flags=%u", vol, flags); + DEBUG("%s vol=%p, flags=%u", __FUNCTION__, vol, flags); if (!VIR_IS_CONNECTED_STORAGE_VOL(vol)) { virLibStorageVolError(NULL, VIR_ERR_INVALID_STORAGE_VOL, __FUNCTION__); @@ -5395,7 +5409,7 @@ int virStorageVolFree(virStorageVolPtr vol) { - DEBUG("vol=%p", vol); + DEBUG("%s vol=%p", __FUNCTION__, vol); if (!VIR_IS_STORAGE_VOL(vol)) { virLibStorageVolError(NULL, VIR_ERR_INVALID_STORAGE_VOL, __FUNCTION__); @@ -5422,7 +5436,7 @@ virStorageVolInfoPtr info) { virConnectPtr conn; - DEBUG("vol=%p, info=%p", vol, info); + DEBUG("%s vol=%p, info=%p", __FUNCTION__, vol, info); if (!VIR_IS_CONNECTED_STORAGE_VOL(vol)) { virLibStorageVolError(NULL, VIR_ERR_INVALID_STORAGE_VOL, __FUNCTION__); @@ -5460,7 +5474,7 @@ unsigned int flags) { virConnectPtr conn; - DEBUG("vol=%p, flags=%u", vol, flags); + DEBUG("%s vol=%p, flags=%u", __FUNCTION__, vol, flags); if (!VIR_IS_STORAGE_VOL(vol)) { virLibStorageVolError(NULL, VIR_ERR_INVALID_STORAGE_VOL, __FUNCTION__); @@ -5498,7 +5512,7 @@ virStorageVolGetPath(virStorageVolPtr vol) { virConnectPtr conn; - DEBUG("vol=%p", vol); + DEBUG("%s vol=%p", __FUNCTION__, vol); if (!VIR_IS_STORAGE_VOL(vol)) { virLibStorageVolError(NULL, VIR_ERR_INVALID_STORAGE_VOL, __FUNCTION__); @@ -5533,7 +5547,7 @@ int virNodeNumOfDevices(virConnectPtr conn, const char *cap, unsigned int flags) { - DEBUG("conn=%p, cap=%s, flags=%d", conn, cap, flags); + DEBUG("%s conn=%p, cap=%s, flags=%d", __FUNCTION__, conn, cap, flags); if (!VIR_IS_CONNECT(conn)) { virLibConnError(NULL, VIR_ERR_INVALID_CONN, __FUNCTION__); @@ -5573,7 +5587,7 @@ char **const names, int maxnames, unsigned int flags) { - DEBUG("conn=%p, cap=%s, names=%p, maxnames=%d, flags=%d", + DEBUG("%s conn=%p, cap=%s, names=%p, maxnames=%d, flags=%d", __FUNCTION__, conn, cap, names, maxnames, flags); if (!VIR_IS_CONNECT(conn)) { @@ -5604,7 +5618,7 @@ */ virNodeDevicePtr virNodeDeviceLookupByName(virConnectPtr conn, const char *name) { - DEBUG("conn=%p, name=%p", conn, name); + DEBUG("%s conn=%p, name=%p", __FUNCTION__, conn, name); if (!VIR_IS_CONNECT(conn)) { virLibConnError(NULL, VIR_ERR_INVALID_CONN, __FUNCTION__); @@ -5636,7 +5650,7 @@ */ char *virNodeDeviceGetXMLDesc(virNodeDevicePtr dev, unsigned int flags) { - DEBUG("dev=%p, conn=%p", dev, dev ? dev->conn : NULL); + DEBUG("%s dev=%p, conn=%p", __FUNCTION__, dev, dev ? dev->conn : NULL); if (!VIR_IS_CONNECTED_NODE_DEVICE(dev)) { virLibNodeDeviceError(NULL, VIR_ERR_INVALID_NODE_DEVICE, __FUNCTION__); @@ -5661,7 +5675,7 @@ */ const char *virNodeDeviceGetName(virNodeDevicePtr dev) { - DEBUG("dev=%p, conn=%p", dev, dev ? dev->conn : NULL); + DEBUG("%s dev=%p, conn=%p", __FUNCTION__, dev, dev ? dev->conn : NULL); if (!VIR_IS_CONNECTED_NODE_DEVICE(dev)) { virLibNodeDeviceError(NULL, VIR_ERR_INVALID_NODE_DEVICE, __FUNCTION__); @@ -5682,7 +5696,7 @@ */ const char *virNodeDeviceGetParent(virNodeDevicePtr dev) { - DEBUG("dev=%p, conn=%p", dev, dev ? dev->conn : NULL); + DEBUG("%s dev=%p, conn=%p", __FUNCTION__, dev, dev ? dev->conn : NULL); if (!VIR_IS_CONNECTED_NODE_DEVICE(dev)) { virLibNodeDeviceError(NULL, VIR_ERR_INVALID_NODE_DEVICE, __FUNCTION__); @@ -5710,7 +5724,7 @@ */ int virNodeDeviceNumOfCaps(virNodeDevicePtr dev) { - DEBUG("dev=%p, conn=%p", dev, dev ? dev->conn : NULL); + DEBUG("%s dev=%p, conn=%p", __FUNCTION__, dev, dev ? dev->conn : NULL); if (!VIR_IS_CONNECTED_NODE_DEVICE(dev)) { virLibNodeDeviceError(NULL, VIR_ERR_INVALID_NODE_DEVICE, __FUNCTION__); @@ -5738,7 +5752,7 @@ char **const names, int maxnames) { - DEBUG("dev=%p, conn=%p, names=%p, maxnames=%d", + DEBUG("%s dev=%p, conn=%p, names=%p, maxnames=%d", __FUNCTION__, dev, dev ? dev->conn : NULL, names, maxnames); if (!VIR_IS_CONNECTED_NODE_DEVICE(dev)) { @@ -5765,7 +5779,7 @@ */ int virNodeDeviceFree(virNodeDevicePtr dev) { - DEBUG("dev=%p, conn=%p", dev, dev ? dev->conn : NULL); + DEBUG("%s dev=%p, conn=%p", __FUNCTION__, dev, dev ? dev->conn : NULL); if (!VIR_IS_CONNECTED_NODE_DEVICE(dev)) { virLibNodeDeviceError(NULL, VIR_ERR_INVALID_NODE_DEVICE, __FUNCTION__);