]> git.ipfire.org Git - thirdparty/ipxe.git/commitdiff
[efi] Remove raw EFI_HANDLE values from debug messages
authorMichael Brown <mcb30@ipxe.org>
Thu, 27 Aug 2015 09:08:00 +0000 (10:08 +0100)
committerMichael Brown <mcb30@ipxe.org>
Thu, 27 Aug 2015 14:40:44 +0000 (15:40 +0100)
The raw EFI_HANDLE value is almost never useful to know, and simply
adds noise to the already verbose debug messages.  Improve the
legibility of debug messages by using only the name generated by
efi_handle_name().

Signed-off-by: Michael Brown <mcb30@ipxe.org>
src/drivers/net/efi/nii.c
src/drivers/net/efi/snp.c
src/drivers/net/efi/snpnet.c
src/drivers/net/efi/snponly.c
src/interface/efi/efi_bofm.c
src/interface/efi/efi_debug.c
src/interface/efi/efi_driver.c
src/interface/efi/efi_pci.c
src/interface/efi/efi_snp.c
src/interface/efi/efi_utils.c
src/interface/efi/efi_wrap.c

index b91848f5c0a23eda5aa5c6ff35037aba63f599f1..d68b36cc3dc3db402789b1fd0365234bafde2da7 100644 (file)
@@ -1125,8 +1125,8 @@ int nii_start ( struct efi_device *efidev ) {
        /* Register network device */
        if ( ( rc = register_netdev ( netdev ) ) != 0 )
                goto err_register_netdev;
-       DBGC ( nii, "NII %s registered as %s for %p %s\n", nii->dev.name,
-              netdev->name, device, efi_handle_name ( device ) );
+       DBGC ( nii, "NII %s registered as %s for %s\n", nii->dev.name,
+              netdev->name, efi_handle_name ( device ) );
 
        /* Set initial link state (if media detection is not supported) */
        if ( ! nii->media )
index acfcfba9fd57321991322d14c9e1287133454033..fbd60690203dfb73c7f7c51cddaace9b143206e5 100644 (file)
@@ -48,8 +48,8 @@ static int snp_supported ( EFI_HANDLE device ) {
 
        /* Check that this is not a device we are providing ourselves */
        if ( find_snpdev ( device ) != NULL ) {
-               DBGCP ( device, "SNP %p %s is provided by this binary\n",
-                       device, efi_handle_name ( device ) );
+               DBGCP ( device, "SNP %s is provided by this binary\n",
+                       efi_handle_name ( device ) );
                return -ENOTTY;
        }
 
@@ -58,12 +58,12 @@ static int snp_supported ( EFI_HANDLE device ) {
                                          &efi_simple_network_protocol_guid,
                                          NULL, efi_image_handle, device,
                                          EFI_OPEN_PROTOCOL_TEST_PROTOCOL))!=0){
-               DBGCP ( device, "SNP %p %s is not an SNP device\n",
-                       device, efi_handle_name ( device ) );
+               DBGCP ( device, "SNP %s is not an SNP device\n",
+                       efi_handle_name ( device ) );
                return -EEFI ( efirc );
        }
-       DBGC ( device, "SNP %p %s is an SNP device\n",
-              device, efi_handle_name ( device ) );
+       DBGC ( device, "SNP %s is an SNP device\n",
+              efi_handle_name ( device ) );
 
        return 0;
 }
@@ -80,8 +80,8 @@ static int nii_supported ( EFI_HANDLE device ) {
 
        /* Check that this is not a device we are providing ourselves */
        if ( find_snpdev ( device ) != NULL ) {
-               DBGCP ( device, "NII %p %s is provided by this binary\n",
-                       device, efi_handle_name ( device ) );
+               DBGCP ( device, "NII %s is provided by this binary\n",
+                       efi_handle_name ( device ) );
                return -ENOTTY;
        }
 
@@ -90,12 +90,12 @@ static int nii_supported ( EFI_HANDLE device ) {
                                          &efi_nii31_protocol_guid,
                                          NULL, efi_image_handle, device,
                                          EFI_OPEN_PROTOCOL_TEST_PROTOCOL))!=0){
-               DBGCP ( device, "NII %p %s is not an NII device\n",
-                       device, efi_handle_name ( device ) );
+               DBGCP ( device, "NII %s is not an NII device\n",
+                       efi_handle_name ( device ) );
                return -EEFI ( efirc );
        }
-       DBGC ( device, "NII %p %s is an NII device\n",
-              device, efi_handle_name ( device ) );
+       DBGC ( device, "NII %s is an NII device\n",
+              efi_handle_name ( device ) );
 
        return 0;
 }
index 96642c4cafddee8874d60114c09fd32e0e1c100b..0d876b636544248cedd4d19b90267515e0d3ab3d 100644 (file)
@@ -431,8 +431,8 @@ int snpnet_start ( struct efi_device *efidev ) {
                                          ( EFI_OPEN_PROTOCOL_BY_DRIVER |
                                            EFI_OPEN_PROTOCOL_EXCLUSIVE )))!=0){
                rc = -EEFI ( efirc );
-               DBGC ( device, "SNP %p %s cannot open SNP protocol: %s\n",
-                      device, efi_handle_name ( device ), strerror ( rc ) );
+               DBGC ( device, "SNP %s cannot open SNP protocol: %s\n",
+                      efi_handle_name ( device ), strerror ( rc ) );
                DBGC_EFI_OPENERS ( device, device,
                                   &efi_simple_network_protocol_guid );
                goto err_open_protocol;
@@ -463,32 +463,30 @@ int snpnet_start ( struct efi_device *efidev ) {
        if ( ( mode->State == EfiSimpleNetworkStopped ) &&
             ( ( efirc = snp->snp->Start ( snp->snp ) ) != 0 ) ) {
                rc = -EEFI ( efirc );
-               DBGC ( device, "SNP %p %s could not start: %s\n", device,
+               DBGC ( device, "SNP %s could not start: %s\n",
                       efi_handle_name ( device ), strerror ( rc ) );
                goto err_start;
        }
        if ( ( mode->State == EfiSimpleNetworkInitialized ) &&
             ( ( efirc = snp->snp->Shutdown ( snp->snp ) ) != 0 ) ) {
                rc = -EEFI ( efirc );
-               DBGC ( device, "SNP %p %s could not shut down: %s\n", device,
+               DBGC ( device, "SNP %s could not shut down: %s\n",
                       efi_handle_name ( device ), strerror ( rc ) );
                goto err_shutdown;
        }
 
        /* Populate network device parameters */
        if ( mode->HwAddressSize != netdev->ll_protocol->hw_addr_len ) {
-               DBGC ( device, "SNP %p %s has invalid hardware address "
-                      "length %d\n", device, efi_handle_name ( device ),
-                      mode->HwAddressSize );
+               DBGC ( device, "SNP %s has invalid hardware address length "
+                      "%d\n", efi_handle_name ( device ), mode->HwAddressSize);
                rc = -ENOTSUP;
                goto err_hw_addr_len;
        }
        memcpy ( netdev->hw_addr, &mode->PermanentAddress,
                 netdev->ll_protocol->hw_addr_len );
        if ( mode->HwAddressSize != netdev->ll_protocol->ll_addr_len ) {
-               DBGC ( device, "SNP %p %s has invalid link-layer address "
-                      "length %d\n", device, efi_handle_name ( device ),
-                      mode->HwAddressSize );
+               DBGC ( device, "SNP %s has invalid link-layer address length "
+                      "%d\n", efi_handle_name ( device ), mode->HwAddressSize);
                rc = -ENOTSUP;
                goto err_ll_addr_len;
        }
@@ -500,8 +498,8 @@ int snpnet_start ( struct efi_device *efidev ) {
        /* Register network device */
        if ( ( rc = register_netdev ( netdev ) ) != 0 )
                goto err_register_netdev;
-       DBGC ( device, "SNP %p %s registered as %s\n",
-              device, efi_handle_name ( device ), netdev->name );
+       DBGC ( device, "SNP %s registered as %s\n",
+              efi_handle_name ( device ), netdev->name );
 
        /* Set initial link state */
        if ( snp->snp->Mode->MediaPresentSupported ) {
@@ -547,7 +545,7 @@ void snpnet_stop ( struct efi_device *efidev ) {
        /* Stop SNP protocol */
        if ( ( efirc = snp->snp->Stop ( snp->snp ) ) != 0 ) {
                rc = -EEFI ( efirc );
-               DBGC ( device, "SNP %p %s could not stop: %s\n", device,
+               DBGC ( device, "SNP %s could not stop: %s\n",
                       efi_handle_name ( device ), strerror ( rc ) );
                /* Nothing we can do about this */
        }
index 73abfdbf42b3cddd5dc751909da9d029fafb339b..cb7ea1bbc26e23b87c0507c9c617c6b619592912 100644 (file)
@@ -81,14 +81,14 @@ static int chained_locate ( struct chained_protocol *chained ) {
        /* Locate handle supporting this protocol */
        if ( ( rc = efi_locate_device ( device, chained->protocol,
                                        &parent ) ) != 0 ) {
-               DBGC ( device, "CHAINED %p %s does not support %s: %s\n",
-                      device, efi_handle_name ( device ),
+               DBGC ( device, "CHAINED %s does not support %s: %s\n",
+                      efi_handle_name ( device ),
                       efi_guid_ntoa ( chained->protocol ), strerror ( rc ) );
                goto err_locate_device;
        }
-       DBGC ( device, "CHAINED %p %s found %s on ", device,
-              efi_handle_name ( device ), efi_guid_ntoa ( chained->protocol ));
-       DBGC ( device, "%p %s\n", parent, efi_handle_name ( parent ) );
+       DBGC ( device, "CHAINED %s found %s on ", efi_handle_name ( device ),
+              efi_guid_ntoa ( chained->protocol ) );
+       DBGC ( device, "%s\n", efi_handle_name ( parent ) );
 
        /* Get protocol instance */
        if ( ( efirc = bs->OpenProtocol ( parent, chained->protocol,
@@ -96,11 +96,11 @@ static int chained_locate ( struct chained_protocol *chained ) {
                                          device,
                                          EFI_OPEN_PROTOCOL_GET_PROTOCOL ))!=0){
                rc = -EEFI ( efirc );
-               DBGC ( device, "CHAINED %p %s could not open %s on ",
-                      device, efi_handle_name ( device ),
+               DBGC ( device, "CHAINED %s could not open %s on ",
+                      efi_handle_name ( device ),
                       efi_guid_ntoa ( chained->protocol ) );
-               DBGC ( device, "%p %s: %s\n",
-                      parent, efi_handle_name ( parent ), strerror ( rc ) );
+               DBGC ( device, "%s: %s\n",
+                      efi_handle_name ( parent ), strerror ( rc ) );
                goto err_open_protocol;
        }
 
@@ -130,25 +130,25 @@ static int chained_supported ( EFI_HANDLE device,
                                          efi_image_handle, device,
                                          EFI_OPEN_PROTOCOL_GET_PROTOCOL ))!=0){
                rc = -EEFI ( efirc );
-               DBGCP ( device, "CHAINED %p %s is not a %s device\n",
-                       device, efi_handle_name ( device ),
+               DBGCP ( device, "CHAINED %s is not a %s device\n",
+                       efi_handle_name ( device ),
                        efi_guid_ntoa ( chained->protocol ) );
                goto err_open_protocol;
        }
 
        /* Test for a match against the chainloading device */
        if ( interface != chained->interface ) {
-               DBGC ( device, "CHAINED %p %s %p is not the chainloaded "
-                      "%s\n", device, efi_handle_name ( device ),
-                      interface, efi_guid_ntoa ( chained->protocol ) );
+               DBGC ( device, "CHAINED %s %p is not the chainloaded %s\n",
+                      efi_handle_name ( device ), interface,
+                      efi_guid_ntoa ( chained->protocol ) );
                rc = -ENOTTY;
                goto err_no_match;
        }
 
        /* Success */
        rc = 0;
-       DBGC ( device, "CHAINED %p %s %p is the chainloaded %s\n",
-              device, efi_handle_name ( device ), interface,
+       DBGC ( device, "CHAINED %s %p is the chainloaded %s\n",
+              efi_handle_name ( device ), interface,
               efi_guid_ntoa ( chained->protocol ) );
 
  err_no_match:
index ea0e15f7f54ad21ffc42d4e2927433f65db2e3fc..00f6a1d5c09fdc8ca16990bd09721915c1cd7c3c 100644 (file)
@@ -178,8 +178,8 @@ static int efi_bofm_supported ( EFI_HANDLE device ) {
 
        /* Look for a BOFM driver */
        if ( ( rc = bofm_find_driver ( &pci ) ) != 0 ) {
-               DBGCP ( device, "EFIBOFM %p %s has no driver\n",
-                       device, efi_handle_name ( device ) );
+               DBGCP ( device, "EFIBOFM %s has no driver\n",
+                       efi_handle_name ( device ) );
                return rc;
        }
 
@@ -187,8 +187,8 @@ static int efi_bofm_supported ( EFI_HANDLE device ) {
        if ( ( efirc = bs->LocateProtocol ( &bofm1_protocol_guid, NULL,
                                            &bofm1.interface ) ) != 0 ) {
                rc = -EEFI ( efirc );
-               DBGC ( device, "EFIBOFM %p %s cannot find BOFM protocol\n",
-                      device, efi_handle_name ( device ) );
+               DBGC ( device, "EFIBOFM %s cannot find BOFM protocol\n",
+                      efi_handle_name ( device ) );
                return rc;
        }
 
@@ -198,13 +198,13 @@ static int efi_bofm_supported ( EFI_HANDLE device ) {
                                                      0x00 /* No iSCSI */,
                                                      0x02 /* Version */ ))!=0){
                rc = -EEFI ( efirc );
-               DBGC ( device, "EFIBOFM %p %s could not register support: %s\n",
-                      device, efi_handle_name ( device ), strerror ( rc ) );
+               DBGC ( device, "EFIBOFM %s could not register support: %s\n",
+                      efi_handle_name ( device ), strerror ( rc ) );
                return rc;
        }
 
-       DBGC ( device, "EFIBOFM %p %s has driver \"%s\"\n",
-              device, efi_handle_name ( device ), pci.id->name );
+       DBGC ( device, "EFIBOFM %s has driver \"%s\"\n",
+              efi_handle_name ( device ), pci.id->name );
        return 0;
 }
 
@@ -241,49 +241,48 @@ static int efi_bofm_start ( struct efi_device *efidev ) {
        if ( ( efirc = bs->LocateProtocol ( &bofm1_protocol_guid, NULL,
                                            &bofm1.interface ) ) != 0 ) {
                rc = -EEFI ( efirc );
-               DBGC ( device, "EFIBOFM %p %s cannot find BOFM protocol\n",
-                      device, efi_handle_name ( device ) );
+               DBGC ( device, "EFIBOFM %s cannot find BOFM protocol\n",
+                      efi_handle_name ( device ) );
                goto err_locate_bofm;
        }
        bofmtab = &bofm1.bofm1->BofmTable;
-       DBGC ( device, "EFIBOFM %p %s found version 1 BOFM table at %p+%04x\n",
-              device, efi_handle_name ( device ), bofmtab,
-              bofmtab->Parameters.Length );
+       DBGC ( device, "EFIBOFM %s found version 1 BOFM table at %p+%04x\n",
+              efi_handle_name ( device ), bofmtab, bofmtab->Parameters.Length);
 
        /* Locate BOFM2 protocol, if available */
        if ( ( efirc = bs->LocateProtocol ( &bofm2_protocol_guid, NULL,
                                            &bofm2.interface ) ) == 0 ) {
                bofmtab2 = &bofm2.bofm2->BofmTable;
-               DBGC ( device, "EFIBOFM %p %s found version 2 BOFM table at "
-                      "%p+%04x\n", device, efi_handle_name ( device ),
-                      bofmtab2, bofmtab2->Parameters.Length );
+               DBGC ( device, "EFIBOFM %s found version 2 BOFM table at "
+                      "%p+%04x\n", efi_handle_name ( device ), bofmtab2,
+                      bofmtab2->Parameters.Length );
                assert ( bofm2.bofm2->RegisterSupport ==
                         bofm1.bofm1->RegisterSupport );
        } else {
-               DBGC ( device, "EFIBOFM %p %s cannot find BOFM2 protocol\n",
-                      device, efi_handle_name ( device ) );
+               DBGC ( device, "EFIBOFM %s cannot find BOFM2 protocol\n",
+                      efi_handle_name ( device ) );
                /* Not a fatal error; may be a BOFM1-only system */
                bofmtab2 = NULL;
        }
 
        /* Process BOFM table */
-       DBGC2 ( device, "EFIBOFM %p %s version 1 before processing:\n",
-               device, efi_handle_name ( device ) );
+       DBGC2 ( device, "EFIBOFM %s version 1 before processing:\n",
+               efi_handle_name ( device ) );
        DBGC2_HD ( device, bofmtab, bofmtab->Parameters.Length );
        if ( bofmtab2 ) {
-               DBGC2 ( device, "EFIBOFM %p %s version 2 before processing:\n",
-                       device, efi_handle_name ( device ) );
+               DBGC2 ( device, "EFIBOFM %s version 2 before processing:\n",
+                       efi_handle_name ( device ) );
                DBGC2_HD ( device, bofmtab2, bofmtab2->Parameters.Length );
        }
        bofmrc = bofm ( virt_to_user ( bofmtab2 ? bofmtab2 : bofmtab ), &pci );
-       DBGC ( device, "EFIBOFM %p %s status %08x\n",
-              device, efi_handle_name ( device ), bofmrc );
-       DBGC2 ( device, "EFIBOFM %p %s version 1 after processing:\n",
-               device, efi_handle_name ( device ) );
+       DBGC ( device, "EFIBOFM %s status %08x\n",
+              efi_handle_name ( device ), bofmrc );
+       DBGC2 ( device, "EFIBOFM %s version 1 after processing:\n",
+               efi_handle_name ( device ) );
        DBGC2_HD ( device, bofmtab, bofmtab->Parameters.Length );
        if ( bofmtab2 ) {
-               DBGC2 ( device, "EFIBOFM %p %s version 2 after processing:\n",
-                       device, efi_handle_name ( device ) );
+               DBGC2 ( device, "EFIBOFM %s version 2 after processing:\n",
+                       efi_handle_name ( device ) );
                DBGC2_HD ( device, bofmtab2, bofmtab2->Parameters.Length );
        }
 
@@ -292,18 +291,18 @@ static int efi_bofm_start ( struct efi_device *efidev ) {
                if ( ( efirc = bofm2.bofm2->SetStatus ( bofm2.bofm2, device,
                                                        FALSE, bofmrc ) ) != 0){
                        rc = -EEFI ( efirc );
-                       DBGC ( device, "EFIBOFM %p %s could not set BOFM2 "
-                              "status: %s\n", device,
-                              efi_handle_name ( device ), strerror ( rc ) );
+                       DBGC ( device, "EFIBOFM %s could not set BOFM2 "
+                              "status: %s\n", efi_handle_name ( device ),
+                              strerror ( rc ) );
                        goto err_set_status;
                }
        } else {
                if ( ( efirc = bofm1.bofm1->SetStatus ( bofm1.bofm1, device,
                                                        FALSE, bofmrc ) ) != 0){
                        rc = -EEFI ( efirc );
-                       DBGC ( device, "EFIBOFM %p %s could not set BOFM "
-                              "status: %s\n", device,
-                              efi_handle_name ( device ), strerror ( rc ) );
+                       DBGC ( device, "EFIBOFM %s could not set BOFM "
+                              "status: %s\n", efi_handle_name ( device ),
+                              strerror ( rc ) );
                        goto err_set_status;
                }
        }
index 607e628f30acac7714e66c6f2109c2ab267240fe..b48a2c6fd1039c4315f20a927faa574b2279de1d 100644 (file)
@@ -231,8 +231,9 @@ void dbg_efi_openers ( EFI_HANDLE handle, EFI_GUID *protocol ) {
 
        /* Sanity check */
        if ( ( ! handle ) || ( ! protocol ) ) {
-               printf ( "EFI could not retrieve openers for %s on %p\n",
-                        efi_guid_ntoa ( protocol ), handle );
+               printf ( "HANDLE %s could not retrieve openers for %s\n",
+                        efi_handle_name ( handle ),
+                        efi_guid_ntoa ( protocol ) );
                return;
        }
 
@@ -240,24 +241,24 @@ void dbg_efi_openers ( EFI_HANDLE handle, EFI_GUID *protocol ) {
        if ( ( efirc = bs->OpenProtocolInformation ( handle, protocol, &openers,
                                                     &count ) ) != 0 ) {
                rc = -EEFI ( efirc );
-               printf ( "EFI could not retrieve openers for %s on %p: %s\n",
-                        efi_guid_ntoa ( protocol ), handle, strerror ( rc ) );
+               printf ( "HANDLE %s could not retrieve openers for %s: %s\n",
+                        efi_handle_name ( handle ),
+                        efi_guid_ntoa ( protocol ), strerror ( rc ) );
                return;
        }
 
        /* Dump list of openers */
        for ( i = 0 ; i < count ; i++ ) {
                opener = &openers[i];
-               printf ( "HANDLE %p %s %s opened %dx (%s)",
-                        handle, efi_handle_name ( handle ),
+               printf ( "HANDLE %s %s opened %dx (%s)",
+                        efi_handle_name ( handle ),
                         efi_guid_ntoa ( protocol ), opener->OpenCount,
                         efi_open_attributes_name ( opener->Attributes ) );
-               printf ( " by %p %s", opener->AgentHandle,
-                        efi_handle_name ( opener->AgentHandle ) );
+               printf ( " by %s", efi_handle_name ( opener->AgentHandle ) );
                if ( opener->ControllerHandle == handle ) {
                        printf ( "\n" );
                } else {
-                       printf ( " for %p %s\n", opener->ControllerHandle,
+                       printf ( " for %s\n",
                                 efi_handle_name ( opener->ControllerHandle ) );
                }
        }
@@ -282,7 +283,8 @@ void dbg_efi_protocols ( EFI_HANDLE handle ) {
 
        /* Sanity check */
        if ( ! handle ) {
-               printf ( "EFI could not retrieve protocols for %p\n", handle );
+               printf ( "HANDLE %s could not retrieve protocols\n",
+                        efi_handle_name ( handle ) );
                return;
        }
 
@@ -290,16 +292,15 @@ void dbg_efi_protocols ( EFI_HANDLE handle ) {
        if ( ( efirc = bs->ProtocolsPerHandle ( handle, &protocols,
                                                &count ) ) != 0 ) {
                rc = -EEFI ( efirc );
-               printf ( "EFI could not retrieve protocols for %p: %s\n",
-                        handle, strerror ( rc ) );
+               printf ( "HANDLE %s could not retrieve protocols: %s\n",
+                        efi_handle_name ( handle ), strerror ( rc ) );
                return;
        }
 
        /* Dump list of protocols */
        for ( i = 0 ; i < count ; i++ ) {
                protocol = protocols[i];
-               printf ( "HANDLE %p %s %s supported\n",
-                        handle, efi_handle_name ( handle ),
+               printf ( "HANDLE %s %s supported\n", efi_handle_name ( handle ),
                         efi_guid_ntoa ( protocol ) );
                dbg_efi_openers ( handle, protocol );
        }
@@ -631,6 +632,7 @@ static struct efi_handle_name_type efi_handle_name_types[] = {
 const __attribute__ (( pure )) char * efi_handle_name ( EFI_HANDLE handle ) {
        EFI_BOOT_SERVICES *bs = efi_systab->BootServices;
        struct efi_handle_name_type *type;
+       static char buf[32];
        unsigned int i;
        void *interface;
        const char *name;
@@ -670,5 +672,7 @@ const __attribute__ (( pure )) char * efi_handle_name ( EFI_HANDLE handle ) {
                        return name;
        }
 
-       return "UNKNOWN";
+       /* Use raw handle value if no name found */
+       snprintf ( buf, sizeof ( buf ), "UNKNOWN<%p>", handle );
+       return buf;
 }
index ba7784cd7752141c78a3a615093c46b51e1104b3..2a59257b868b53b235d21e5c351a645a00a55110 100644 (file)
@@ -96,30 +96,29 @@ efi_driver_supported ( EFI_DRIVER_BINDING_PROTOCOL *driver __unused,
        struct efi_driver *efidrv;
        int rc;
 
-       DBGCP ( device, "EFIDRV %p %s DRIVER_SUPPORTED",
-               device, efi_handle_name ( device ) );
+       DBGCP ( device, "EFIDRV %s DRIVER_SUPPORTED",
+               efi_handle_name ( device ) );
        if ( child )
                DBGCP ( device, " (child %s)", efi_devpath_text ( child ) );
        DBGCP ( device, "\n" );
 
        /* Do nothing if we are already driving this device */
        if ( efidev_find ( device ) != NULL ) {
-               DBGCP ( device, "EFIDRV %p %s is already started\n",
-                       device, efi_handle_name ( device ) );
+               DBGCP ( device, "EFIDRV %s is already started\n",
+                       efi_handle_name ( device ) );
                return EFI_ALREADY_STARTED;
        }
 
        /* Look for a driver claiming to support this device */
        for_each_table_entry ( efidrv, EFI_DRIVERS ) {
                if ( ( rc = efidrv->supported ( device ) ) == 0 ) {
-                       DBGC ( device, "EFIDRV %p %s has driver \"%s\"\n",
-                              device, efi_handle_name ( device ),
-                              efidrv->name );
+                       DBGC ( device, "EFIDRV %s has driver \"%s\"\n",
+                              efi_handle_name ( device ), efidrv->name );
                        return 0;
                }
        }
-       DBGCP ( device, "EFIDRV %p %s has no driver\n",
-               device, efi_handle_name ( device ) );
+       DBGCP ( device, "EFIDRV %s has no driver\n",
+               efi_handle_name ( device ) );
 
        return EFI_UNSUPPORTED;
 }
@@ -140,8 +139,7 @@ efi_driver_start ( EFI_DRIVER_BINDING_PROTOCOL *driver __unused,
        EFI_STATUS efirc;
        int rc;
 
-       DBGC ( device, "EFIDRV %p %s DRIVER_START",
-              device, efi_handle_name ( device ) );
+       DBGC ( device, "EFIDRV %s DRIVER_START", efi_handle_name ( device ) );
        if ( child )
                DBGC ( device, " (child %s)", efi_devpath_text ( child ) );
        DBGC ( device, "\n" );
@@ -149,8 +147,8 @@ efi_driver_start ( EFI_DRIVER_BINDING_PROTOCOL *driver __unused,
        /* Do nothing if we are already driving this device */
        efidev = efidev_find ( device );
        if ( efidev ) {
-               DBGCP ( device, "EFIDRV %p %s is already started\n",
-                       device, efi_handle_name ( device ) );
+               DBGCP ( device, "EFIDRV %s is already started\n",
+                       efi_handle_name ( device ) );
                efirc = EFI_ALREADY_STARTED;
                goto err_already_started;
        }
@@ -169,22 +167,22 @@ efi_driver_start ( EFI_DRIVER_BINDING_PROTOCOL *driver __unused,
        /* Try to start this device */
        for_each_table_entry ( efidrv, EFI_DRIVERS ) {
                if ( ( rc = efidrv->supported ( device ) ) != 0 ) {
-                       DBGC ( device, "EFIDRV %p %s is not supported by "
-                              "driver \"%s\": %s\n", device,
-                              efi_handle_name ( device ), efidrv->name,
+                       DBGC ( device, "EFIDRV %s is not supported by driver "
+                              "\"%s\": %s\n", efi_handle_name ( device ),
+                              efidrv->name,
                               strerror ( rc ) );
                        continue;
                }
                if ( ( rc = efidrv->start ( efidev ) ) == 0 ) {
                        efidev->driver = efidrv;
-                       DBGC ( device, "EFIDRV %p %s using driver \"%s\"\n",
-                              device, efi_handle_name ( device ),
+                       DBGC ( device, "EFIDRV %s using driver \"%s\"\n",
+                              efi_handle_name ( device ),
                               efidev->driver->name );
                        return 0;
                }
-               DBGC ( device, "EFIDRV %p %s could not start driver \"%s\": "
-                      "%s\n", device, efi_handle_name ( device ),
-                      efidrv->name, strerror ( rc ) );
+               DBGC ( device, "EFIDRV %s could not start driver \"%s\": %s\n",
+                      efi_handle_name ( device ), efidrv->name,
+                      strerror ( rc ) );
        }
        efirc = EFI_UNSUPPORTED;
 
@@ -213,19 +211,18 @@ efi_driver_stop ( EFI_DRIVER_BINDING_PROTOCOL *driver __unused,
        struct efi_device *efidev;
        UINTN i;
 
-       DBGC ( device, "EFIDRV %p %s DRIVER_STOP",
-              device, efi_handle_name ( device ) );
+       DBGC ( device, "EFIDRV %s DRIVER_STOP", efi_handle_name ( device ) );
        for ( i = 0 ; i < num_children ; i++ ) {
-               DBGC ( device, "%s%p %s", ( i ? ", " : " child " ),
-                      children[i], efi_handle_name ( children[i] ) );
+               DBGC ( device, "%s%s", ( i ? ", " : " child " ),
+                      efi_handle_name ( children[i] ) );
        }
        DBGC ( device, "\n" );
 
        /* Do nothing unless we are driving this device */
        efidev = efidev_find ( device );
        if ( ! efidev ) {
-               DBGCP ( device, "EFIDRV %p %s is not started\n",
-                       device, efi_handle_name ( device ) );
+               DBGCP ( device, "EFIDRV %s is not started\n",
+                       efi_handle_name ( device ) );
                return 0;
        }
 
@@ -378,36 +375,35 @@ static int efi_driver_connect ( EFI_HANDLE device ) {
        }
 
        /* Disconnect any existing drivers */
-       DBGC2 ( device, "EFIDRV %p %s before disconnecting:\n",
-               device, efi_handle_name ( device ) );
+       DBGC2 ( device, "EFIDRV %s before disconnecting:\n",
+               efi_handle_name ( device ) );
        DBGC2_EFI_PROTOCOLS ( device, device );
-       DBGC ( device, "EFIDRV %p %s disconnecting existing drivers\n",
-              device, efi_handle_name ( device ) );
+       DBGC ( device, "EFIDRV %s disconnecting existing drivers\n",
+              efi_handle_name ( device ) );
        if ( ( efirc = bs->DisconnectController ( device, NULL,
                                                  NULL ) ) != 0 ) {
                rc = -EEFI ( efirc );
-               DBGC ( device, "EFIDRV %p %s could not disconnect existing "
-                      "drivers: %s\n", device, efi_handle_name ( device ),
+               DBGC ( device, "EFIDRV %s could not disconnect existing "
+                      "drivers: %s\n", efi_handle_name ( device ),
                       strerror ( rc ) );
                /* Ignore the error and attempt to connect our drivers */
        }
-       DBGC2 ( device, "EFIDRV %p %s after disconnecting:\n",
-               device, efi_handle_name ( device ) );
+       DBGC2 ( device, "EFIDRV %s after disconnecting:\n",
+               efi_handle_name ( device ) );
        DBGC2_EFI_PROTOCOLS ( device, device );
 
        /* Connect our driver */
-       DBGC ( device, "EFIDRV %p %s connecting new drivers\n",
-              device, efi_handle_name ( device ) );
+       DBGC ( device, "EFIDRV %s connecting new drivers\n",
+              efi_handle_name ( device ) );
        if ( ( efirc = bs->ConnectController ( device, drivers, NULL,
                                               FALSE ) ) != 0 ) {
                rc = -EEFI ( efirc );
-               DBGC ( device, "EFIDRV %p %s could not connect new drivers: "
-                      "%s\n", device, efi_handle_name ( device ),
-                      strerror ( rc ) );
+               DBGC ( device, "EFIDRV %s could not connect new drivers: "
+                      "%s\n", efi_handle_name ( device ), strerror ( rc ) );
                return rc;
        }
-       DBGC2 ( device, "EFIDRV %p %s after connecting:\n",
-               device, efi_handle_name ( device ) );
+       DBGC2 ( device, "EFIDRV %s after connecting:\n",
+               efi_handle_name ( device ) );
        DBGC2_EFI_PROTOCOLS ( device, device );
 
        return 0;
index 97ea72bb955433c786b165c7e321fbb2a1af1600..be305ba6cef6cd1a1fcf2efe8deaed12aae43968 100644 (file)
@@ -154,8 +154,8 @@ int efipci_open ( EFI_HANDLE device, UINT32 attributes,
                                          &pci_io.interface, efi_image_handle,
                                          device, attributes ) ) != 0 ) {
                rc = -EEFI_PCI ( efirc );
-               DBGCP ( device, "EFIPCI %p %s cannot open PCI protocols: %s\n",
-                       device, efi_handle_name ( device ), strerror ( rc ) );
+               DBGCP ( device, "EFIPCI %s cannot open PCI protocols: %s\n",
+                       efi_handle_name ( device ), strerror ( rc ) );
                goto err_open_protocol;
        }
 
@@ -164,11 +164,11 @@ int efipci_open ( EFI_HANDLE device, UINT32 attributes,
                                                    &pci_bus, &pci_dev,
                                                    &pci_fn ) ) != 0 ) {
                rc = -EEFI ( efirc );
-               DBGC ( device, "EFIPCI %p %s could not get PCI location: %s\n",
-                      device, efi_handle_name ( device ), strerror ( rc ) );
+               DBGC ( device, "EFIPCI %s could not get PCI location: %s\n",
+                      efi_handle_name ( device ), strerror ( rc ) );
                goto err_get_location;
        }
-       DBGC2 ( device, "EFIPCI %p %s is PCI %04lx:%02lx:%02lx.%lx\n", device,
+       DBGC2 ( device, "EFIPCI %s is PCI %04lx:%02lx:%02lx.%lx\n",
                efi_handle_name ( device ), ( ( unsigned long ) pci_segment ),
                ( ( unsigned long ) pci_bus ), ( ( unsigned long ) pci_dev ),
                ( ( unsigned long ) pci_fn ) );
@@ -192,9 +192,8 @@ int efipci_open ( EFI_HANDLE device, UINT32 attributes,
        /* Populate PCI device */
        pci_init ( pci, PCI_BUSDEVFN ( pci_bus, pci_dev, pci_fn ) );
        if ( ( rc = pci_read_config ( pci ) ) != 0 ) {
-               DBGC ( device, "EFIPCI %p %s cannot read PCI configuration: "
-                      "%s\n", device, efi_handle_name ( device ),
-                      strerror ( rc ) );
+               DBGC ( device, "EFIPCI %s cannot read PCI configuration: %s\n",
+                      efi_handle_name ( device ), strerror ( rc ) );
                goto err_pci_read_config;
        }
 
@@ -264,12 +263,12 @@ static int efipci_supported ( EFI_HANDLE device ) {
 
        /* Look for a driver */
        if ( ( rc = pci_find_driver ( &pci ) ) != 0 ) {
-               DBGCP ( device, "EFIPCI %p %s has no driver\n",
-                       device, efi_handle_name ( device ) );
+               DBGCP ( device, "EFIPCI %s has no driver\n",
+                       efi_handle_name ( device ) );
                return rc;
        }
-       DBGC ( device, "EFIPCI %p %s has driver \"%s\"\n",
-              device, efi_handle_name ( device ), pci.id->name );
+       DBGC ( device, "EFIPCI %s has driver \"%s\"\n",
+              efi_handle_name ( device ), pci.id->name );
 
        return 0;
 }
@@ -296,16 +295,16 @@ static int efipci_start ( struct efi_device *efidev ) {
        if ( ( rc = efipci_open ( device, ( EFI_OPEN_PROTOCOL_BY_DRIVER |
                                            EFI_OPEN_PROTOCOL_EXCLUSIVE ),
                                  pci ) ) != 0 ) {
-               DBGC ( device, "EFIPCI %p %s could not open PCI device: %s\n",
-                      device, efi_handle_name ( device ), strerror ( rc ) );
+               DBGC ( device, "EFIPCI %s could not open PCI device: %s\n",
+                      efi_handle_name ( device ), strerror ( rc ) );
                DBGC_EFI_OPENERS ( device, device, &efi_pci_io_protocol_guid );
                goto err_open;
        }
 
        /* Find driver */
        if ( ( rc = pci_find_driver ( pci ) ) != 0 ) {
-               DBGC ( device, "EFIPCI %p %s has no driver\n",
-                      device, efi_handle_name ( device ) );
+               DBGC ( device, "EFIPCI %s has no driver\n",
+                      efi_handle_name ( device ) );
                goto err_find_driver;
        }
 
@@ -315,13 +314,13 @@ static int efipci_start ( struct efi_device *efidev ) {
 
        /* Probe driver */
        if ( ( rc = pci_probe ( pci ) ) != 0 ) {
-               DBGC ( device, "EFIPCI %p %s could not probe driver \"%s\": "
-                      "%s\n", device, efi_handle_name ( device ),
-                      pci->id->name, strerror ( rc ) );
+               DBGC ( device, "EFIPCI %s could not probe driver \"%s\": %s\n",
+                      efi_handle_name ( device ), pci->id->name,
+                      strerror ( rc ) );
                goto err_probe;
        }
-       DBGC ( device, "EFIPCI %p %s using driver \"%s\"\n",
-              device, efi_handle_name ( device ), pci->id->name );
+       DBGC ( device, "EFIPCI %s using driver \"%s\"\n",
+              efi_handle_name ( device ), pci->id->name );
 
        efidev_set_drvdata ( efidev, pci );
        return 0;
index 3dfcc5e168da7628ee4871f84eee2985697ed042..c2604580fab25947a1824d2aa91e9cc6e2dd4c78 100644 (file)
@@ -1024,9 +1024,9 @@ static int efi_snp_probe ( struct net_device *netdev ) {
                                          efidev->device,
                                          EFI_OPEN_PROTOCOL_GET_PROTOCOL ))!=0){
                rc = -EEFI ( efirc );
-               DBGC ( snpdev, "SNPDEV %p cannot get %p %s device path: %s\n",
-                      snpdev, efidev->device,
-                      efi_handle_name ( efidev->device ), strerror ( rc ) );
+               DBGC ( snpdev, "SNPDEV %p cannot get %s device path: %s\n",
+                      snpdev, efi_handle_name ( efidev->device ),
+                      strerror ( rc ) );
                goto err_open_device_path;
        }
 
@@ -1067,16 +1067,16 @@ static int efi_snp_probe ( struct net_device *netdev ) {
                        &efi_load_file_protocol_guid, &snpdev->load_file,
                        NULL ) ) != 0 ) {
                rc = -EEFI ( efirc );
-               DBGC ( snpdev, "SNPDEV %p could not install protocols: "
-                      "%s\n", snpdev, strerror ( rc ) );
+               DBGC ( snpdev, "SNPDEV %p could not install protocols: %s\n",
+                      snpdev, strerror ( rc ) );
                goto err_install_protocol_interface;
        }
 
        /* Add as child of EFI parent device */
        if ( ( rc = efi_child_add ( efidev->device, snpdev->handle ) ) != 0 ) {
-               DBGC ( snpdev, "SNPDEV %p could not become child of %p %s: "
-                      "%s\n", snpdev, efidev->device,
-                      efi_handle_name ( efidev->device ), strerror ( rc ) );
+               DBGC ( snpdev, "SNPDEV %p could not become child of %s: %s\n",
+                      snpdev, efi_handle_name ( efidev->device ),
+                      strerror ( rc ) );
                goto err_efi_child_add;
        }
 
@@ -1097,9 +1097,8 @@ static int efi_snp_probe ( struct net_device *netdev ) {
        bs->CloseProtocol ( efidev->device, &efi_device_path_protocol_guid,
                            efi_image_handle, efidev->device );
 
-       DBGC ( snpdev, "SNPDEV %p installed for %s as device %p %s\n",
-              snpdev, netdev->name, snpdev->handle,
-              efi_handle_name ( snpdev->handle ) );
+       DBGC ( snpdev, "SNPDEV %p installed for %s as device %s\n",
+              snpdev, netdev->name, efi_handle_name ( snpdev->handle ) );
        return 0;
 
        if ( snpdev->package_list )
index 936ad48ece9617862e17d505df4b2ce3c83899c2..1bebaa56d1625ef9c5528c5166c3ed04d738d0f9 100644 (file)
@@ -76,8 +76,8 @@ int efi_locate_device ( EFI_HANDLE device, EFI_GUID *protocol,
                                          efi_image_handle, device,
                                          EFI_OPEN_PROTOCOL_GET_PROTOCOL ))!=0){
                rc = -EEFI ( efirc );
-               DBGC ( device, "EFIDEV %p %s cannot open device path: %s\n",
-                      device, efi_handle_name ( device ), strerror ( rc ) );
+               DBGC ( device, "EFIDEV %s cannot open device path: %s\n",
+                      efi_handle_name ( device ), strerror ( rc ) );
                goto err_open_device_path;
        }
        devpath = path.path;
@@ -86,8 +86,8 @@ int efi_locate_device ( EFI_HANDLE device, EFI_GUID *protocol,
        if ( ( efirc = bs->LocateDevicePath ( protocol, &devpath,
                                              parent ) ) != 0 ) {
                rc = -EEFI ( efirc );
-               DBGC ( device, "EFIDEV %p %s has no parent supporting %s: %s\n",
-                      device, efi_handle_name ( device ),
+               DBGC ( device, "EFIDEV %s has no parent supporting %s: %s\n",
+                      efi_handle_name ( device ),
                       efi_guid_ntoa ( protocol ), strerror ( rc ) );
                goto err_locate_protocol;
        }
@@ -123,18 +123,17 @@ int efi_child_add ( EFI_HANDLE parent, EFI_HANDLE child ) {
                                          EFI_OPEN_PROTOCOL_BY_CHILD_CONTROLLER
                                          ) ) != 0 ) {
                rc = -EEFI ( efirc );
-               DBGC ( parent, "EFIDEV %p %s could not add child",
-                      parent, efi_handle_name ( parent ) );
-               DBGC ( parent, " %p %s: %s\n", child,
+               DBGC ( parent, "EFIDEV %s could not add child",
+                      efi_handle_name ( parent ) );
+               DBGC ( parent, " %s: %s\n",
                       efi_handle_name ( child ), strerror ( rc ) );
                DBGC_EFI_OPENERS ( parent, parent,
                                   &efi_device_path_protocol_guid );
                return rc;
        }
 
-       DBGC2 ( parent, "EFIDEV %p %s added child",
-               parent, efi_handle_name ( parent ) );
-       DBGC2 ( parent, " %p %s\n", child, efi_handle_name ( child ) );
+       DBGC2 ( parent, "EFIDEV %s added child", efi_handle_name ( parent ) );
+       DBGC2 ( parent, " %s\n", efi_handle_name ( child ) );
        return 0;
 }
 
@@ -149,10 +148,8 @@ void efi_child_del ( EFI_HANDLE parent, EFI_HANDLE child ) {
 
        bs->CloseProtocol ( parent, &efi_device_path_protocol_guid,
                            efi_image_handle, child );
-       DBGC2 ( parent, "EFIDEV %p %s removed child",
-               parent, efi_handle_name ( parent ) );
-       DBGC2 ( parent, " %p %s\n",
-               child, efi_handle_name ( child ) );
+       DBGC2 ( parent, "EFIDEV %s removed child", efi_handle_name ( parent ) );
+       DBGC2 ( parent, " %s\n", efi_handle_name ( child ) );
 }
 
 /**
@@ -172,16 +169,15 @@ static int efi_pci_info ( EFI_HANDLE device, const char *prefix,
        /* Find parent PCI device */
        if ( ( rc = efi_locate_device ( device, &efi_pci_io_protocol_guid,
                                        &pci_device ) ) != 0 ) {
-               DBGC ( device, "EFIDEV %p %s is not a PCI device: %s\n",
-                      device, efi_handle_name ( device ), strerror ( rc ) );
+               DBGC ( device, "EFIDEV %s is not a PCI device: %s\n",
+                      efi_handle_name ( device ), strerror ( rc ) );
                return rc;
        }
 
        /* Get PCI device information */
        if ( ( rc = efipci_info ( pci_device, &pci ) ) != 0 ) {
-               DBGC ( device, "EFIDEV %p %s could not get PCI information: "
-                      "%s\n", device, efi_handle_name ( device ),
-                      strerror ( rc ) );
+               DBGC ( device, "EFIDEV %s could not get PCI information: %s\n",
+                      efi_handle_name ( device ), strerror ( rc ) );
                return rc;
        }
 
@@ -211,8 +207,8 @@ void efi_device_info ( EFI_HANDLE device, const char *prefix,
        /* If we cannot get any underlying device information, fall
         * back to providing information about the EFI handle.
         */
-       DBGC ( device, "EFIDEV %p %s could not get underlying device "
-              "information\n", device, efi_handle_name ( device ) );
+       DBGC ( device, "EFIDEV %s could not get underlying device "
+              "information\n", efi_handle_name ( device ) );
        dev->desc.bus_type = BUS_TYPE_EFI;
        snprintf ( dev->name, sizeof ( dev->name ), "%s-%p", prefix, device );
 }
index 2ea184e97d40184ec2849e419826d914ab10b8cf..e94e8d9fc7eede87007de779c56a6d3adb6fdf35 100644 (file)
@@ -111,7 +111,7 @@ efi_handle_protocol_wrapper ( EFI_HANDLE handle, EFI_GUID *protocol,
        void *retaddr = __builtin_return_address ( 0 );
        EFI_STATUS efirc;
 
-       DBGC ( colour, "HandleProtocol ( %p %s, %s, ... ) ", handle,
+       DBGC ( colour, "HandleProtocol ( %s, %s, ... ) ",
               efi_handle_name ( handle ), efi_guid_ntoa ( protocol ) );
        efirc = bs->HandleProtocol ( handle, protocol, interface );
        DBGC ( colour, "= %s ( %p ) -> %p\n",
@@ -155,10 +155,9 @@ efi_locate_device_path_wrapper ( EFI_GUID *protocol,
        DBGC ( colour, "LocateDevicePath ( %s, %s, ... ) ",
               efi_guid_ntoa ( protocol ), efi_devpath_text ( *device_path ) );
        efirc = bs->LocateDevicePath ( protocol, device_path, device );
-       DBGC ( colour, "= %s ( %p, ",
+       DBGC ( colour, "= %s ( %s, ",
               efi_status ( efirc ), efi_devpath_text ( *device_path ) );
-       DBGC ( colour, "%p %s ) -> %p\n",
-              *device, efi_handle_name ( *device ), retaddr );
+       DBGC ( colour, "%s ) -> %p\n", efi_handle_name ( *device ), retaddr );
        return efirc;
 }
 
@@ -175,18 +174,16 @@ efi_load_image_wrapper ( BOOLEAN boot_policy, EFI_HANDLE parent_image_handle,
        void *retaddr = __builtin_return_address ( 0 );
        EFI_STATUS efirc;
 
-       DBGC ( colour, "LoadImage ( %d, %p %s, ", boot_policy,
-              parent_image_handle, efi_handle_name ( parent_image_handle ) );
+       DBGC ( colour, "LoadImage ( %d, %s, ", boot_policy,
+              efi_handle_name ( parent_image_handle ) );
        DBGC ( colour, "%s, %p, %#llx, ... ) ",
               efi_devpath_text ( device_path ), source_buffer,
               ( ( unsigned long long ) source_size ) );
        efirc = bs->LoadImage ( boot_policy, parent_image_handle, device_path,
                                source_buffer, source_size, image_handle );
        DBGC ( colour, "= %s ( ", efi_status ( efirc ) );
-       if ( efirc == 0 ) {
-               DBGC ( colour, "%p %s ", *image_handle,
-                      efi_handle_name ( *image_handle ) );
-       }
+       if ( efirc == 0 )
+               DBGC ( colour, "%s ", efi_handle_name ( *image_handle ) );
        DBGC ( colour, ") -> %p\n", retaddr );
 
        /* Wrap the new image */
@@ -206,8 +203,8 @@ efi_exit_boot_services_wrapper ( EFI_HANDLE image_handle, UINTN map_key ) {
        void *retaddr = __builtin_return_address ( 0 );
        EFI_STATUS efirc;
 
-       DBGC ( colour, "ExitBootServices ( %p %s, %#llx ) ",
-              image_handle, efi_handle_name ( image_handle ),
+       DBGC ( colour, "ExitBootServices ( %s, %#llx ) ",
+              efi_handle_name ( image_handle ),
               ( ( unsigned long long ) map_key ) );
        efirc = bs->ExitBootServices ( image_handle, map_key );
        DBGC ( colour, "= %s -> %p\n", efi_status ( efirc ), retaddr );
@@ -226,11 +223,10 @@ efi_open_protocol_wrapper ( EFI_HANDLE handle, EFI_GUID *protocol,
        void *retaddr = __builtin_return_address ( 0 );
        EFI_STATUS efirc;
 
-       DBGC ( colour, "OpenProtocol ( %p %s, %s, ..., ", handle,
+       DBGC ( colour, "OpenProtocol ( %s, %s, ..., ",
               efi_handle_name ( handle ), efi_guid_ntoa ( protocol ) );
-       DBGC ( colour, "%p %s, ", agent_handle,
-              efi_handle_name ( agent_handle ) );
-       DBGC ( colour, "%p %s, %#x ) ", controller_handle,
+       DBGC ( colour, "%s, ", efi_handle_name ( agent_handle ) );
+       DBGC ( colour, "%s, %#x ) ",
               efi_handle_name ( controller_handle ), attributes );
        efirc = bs->OpenProtocol ( handle, protocol, interface, agent_handle,
                                   controller_handle, attributes );
@@ -295,23 +291,22 @@ efi_locate_protocol_wrapper ( EFI_GUID *protocol, VOID *registration,
                                          &loaded.intf, efi_image_handle, NULL,
                                          EFI_OPEN_PROTOCOL_GET_PROTOCOL ))!=0){
                rc = -EEFI ( efirc );
-               DBGC ( colour, "Could not get loaded image protocol for %p %s: "
-                      "%s\n", handle, efi_handle_name ( handle ),
-                      strerror ( rc ) );
+               DBGC ( colour, "WRAP %s could not get loaded image protocol: "
+                      "%s\n", efi_handle_name ( handle ), strerror ( rc ) );
                return;
        }
 
        /* Provide system table wrapper to image */
        loaded.image->SystemTable = &efi_systab_wrapper;
-       DBGC ( colour, "Wrapped image %p %s at base %p has protocols:\n",
-              handle, efi_handle_name ( handle ), loaded.image->ImageBase );
+       DBGC ( colour, "WRAP %s at base %p has protocols:\n",
+              efi_handle_name ( handle ), loaded.image->ImageBase );
        DBGC_EFI_PROTOCOLS ( colour, handle );
-       DBGC ( colour, "Parent image %p %s\n", loaded.image->ParentHandle,
-              efi_handle_name ( loaded.image->ParentHandle ) );
-       DBGC ( colour, "Device %p %s ", loaded.image->DeviceHandle,
-              efi_handle_name ( loaded.image->DeviceHandle ) );
-       DBGC ( colour, "file %p %s\n", loaded.image->FilePath,
-              efi_devpath_text ( loaded.image->FilePath ) );
+       DBGC ( colour, "WRAP %s parent", efi_handle_name ( handle ) );
+       DBGC ( colour, " %s\n", efi_handle_name ( loaded.image->ParentHandle ));
+       DBGC ( colour, "WRAP %s device", efi_handle_name ( handle ) );
+       DBGC ( colour, " %s\n", efi_handle_name ( loaded.image->DeviceHandle ));
+       DBGC ( colour, "WRAP %s file", efi_handle_name ( handle ) );
+       DBGC ( colour, " %s\n", efi_devpath_text ( loaded.image->FilePath ) );
 
        /* Close loaded image protocol */
        bs->CloseProtocol ( handle, &efi_loaded_image_protocol_guid,