]> git.proxmox.com Git - mirror_ubuntu-zesty-kernel.git/commit
scsi: hisi_sas: set dma mask before allocate DMA memory
authorJohn Garry <john.garry@huawei.com>
Tue, 6 Sep 2016 15:36:19 +0000 (23:36 +0800)
committerMartin K. Petersen <martin.petersen@oracle.com>
Wed, 14 Sep 2016 16:54:18 +0000 (12:54 -0400)
commita6f2c7fff90a6fe7a31e764a21b65a809fafa765
tree6867b78c86a632969ce1b5cb2dc74df0809deb11
parent09fe9ecb18a7add9b05928151998692d96338e41
scsi: hisi_sas: set dma mask before allocate DMA memory

The device DMA mask was being set after the bulk of the DMA allocations
in the driver init, so potentially DMA allocates fail.  To resolve,
relocate before allocating the DMA memory when initialising the driver.

Signed-off-by: Xiang Chen <chenxiang66@hisilicon.com>
Signed-off-by: John Garry <john.garry@huawei.com>
Reviewed-by: Hannes Reinecke <hare@suse.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
drivers/scsi/hisi_sas/hisi_sas_main.c