efi_status_t ret;
efi_uintn_t count;
struct efi_open_protocol_info_entry *entry_buffer;
- efi_guid_t *guid_controller = NULL;
+ struct efi_driver_binding_extended_protocol *bp =
+ (struct efi_driver_binding_extended_protocol *)this;
EFI_ENTRY("%p, %pUl, %zu, %p", this, controller_handle,
number_of_children, child_handle_buffer);
/* Destroy all children */
ret = EFI_CALL(systab.boottime->open_protocol_information(
- controller_handle, guid_controller,
+ controller_handle, bp->ops->protocol,
&entry_buffer, &count));
if (ret != EFI_SUCCESS)
goto out;
/* Detach driver from controller */
ret = EFI_CALL(systab.boottime->close_protocol(
- controller_handle, guid_controller,
+ controller_handle, bp->ops->protocol,
this->driver_binding_handle, controller_handle));
out:
return EFI_EXIT(ret);