From 556640510d7e15664cb9bf2f70f7519bfedd6c29 Mon Sep 17 00:00:00 2001 From: Stefan Richter Date: Tue, 28 Mar 2006 19:59:42 -0500 Subject: sbp2: check for ARM failure Sbp2 did not check for successful registration of the lower address range when CONFIG_IEEE1394_SBP2_PHYS_DMA was set. If hpsb_register_addrspace failed, a "login timed-out" would occur which is misleading. Now sbp2 logs a sensible error message. Signed-off-by: Stefan Richter Signed-off-by: Jody McIntyre --- drivers/ieee1394/sbp2.c | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) (limited to 'drivers/ieee1394') diff --git a/drivers/ieee1394/sbp2.c b/drivers/ieee1394/sbp2.c index 0b2b0da5b883..ce3b43dd229b 100644 --- a/drivers/ieee1394/sbp2.c +++ b/drivers/ieee1394/sbp2.c @@ -749,9 +749,13 @@ static struct scsi_id_instance_data *sbp2_alloc_device(struct unit_directory *ud #ifdef CONFIG_IEEE1394_SBP2_PHYS_DMA /* Handle data movement if physical dma is not - * enabled/supportedon host controller */ - hpsb_register_addrspace(&sbp2_highlevel, ud->ne->host, &sbp2_physdma_ops, - 0x0ULL, 0xfffffffcULL); + * enabled or not supported on host controller */ + if (!hpsb_register_addrspace(&sbp2_highlevel, ud->ne->host, + &sbp2_physdma_ops, + 0x0ULL, 0xfffffffcULL)) { + SBP2_ERR("failed to register lower 4GB address range"); + goto failed_alloc; + } #endif } -- cgit v1.2.2