mirror of
https://github.com/ipxe/ipxe
synced 2026-01-05 03:10:58 +03:00
[efi] Remove raw EFI_HANDLE values from debug messages
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>
This commit is contained in:
@@ -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;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user