]> git.baikalelectronics.ru Git - kernel.git/commit
powerpc/vio: Fix a dma_mask issue of vio
authorLi Zhong <zhong@linux.vnet.ibm.com>
Tue, 19 Nov 2013 08:11:37 +0000 (16:11 +0800)
committerBenjamin Herrenschmidt <benh@kernel.crashing.org>
Wed, 20 Nov 2013 23:33:43 +0000 (10:33 +1100)
commitfdb8345cc8353373247669122ec15ef5a7efc910
tree55a2ace670f91db06363faee93a1f5b8409dbc1f
parentd784790a747f564e7efa20d5490e9b2fb8edc4dd
powerpc/vio: Fix a dma_mask issue of vio

I encountered following issue:
[    0.283035] ibmvscsi 30000015: couldn't initialize event pool
[    5.688822] ibmvscsi: probe of 30000015 failed with error -1

which prevents the storage from being recognized, and the machine from
booting.

After some digging, it seems that it is caused by commit bd1b630a5f

as dma_mask pointer in viodev->dev is not set, so in
dma_set_mask_and_coherent(), dma_set_coherent_mask() is not called
because dma_set_mask(), which is dma_set_mask_pSeriesLP() returned EIO.
While before the commit, dma_set_coherent_mask() is always called.

I tried to replace dma_set_mask_and_coherent() with
dma_coerce_mask_and_coherent(), and the machine could boot again.

Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
arch/powerpc/kernel/vio.c