Skip to content

Commit

Permalink
POWERPC: Set dma_data correctly for direct_ops on pasemi
Browse files Browse the repository at this point in the history
More late-caught fallout from the mainline merge.  Commit
35e4a6e ("[POWERPC] Use
archdata.dma_data in dma_direct_ops and add the offset") claimed

  "Now that all platforms using dma_direct_offset setup the
   archdata.dma_data correctly, ..."

..but nope -- the pasemi iommu setup code that disables translation on
the DMA pci device didn't set dma_data correctly.

This fixes it.

Signed-off-by: Olof Johansson <olof@lixom.net>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
  • Loading branch information
Olof Johansson authored and Linus Torvalds committed Jan 31, 2008
1 parent 8af03e7 commit 24af8cb
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion arch/powerpc/platforms/pasemi/iommu.c
Original file line number Diff line number Diff line change
Expand Up @@ -182,8 +182,10 @@ static void pci_dma_dev_setup_pasemi(struct pci_dev *dev)
* CONFIG_PPC_PASEMI_IOMMU_DMA_FORCE at build time.
*/
if (dev->vendor == 0x1959 && dev->device == 0xa007 &&
!firmware_has_feature(FW_FEATURE_LPAR))
!firmware_has_feature(FW_FEATURE_LPAR)) {
dev->dev.archdata.dma_ops = &dma_direct_ops;
dev->dev.archdata.dma_data = 0;
}
#endif

dev->dev.archdata.dma_data = &iommu_table_iobmap;
Expand Down

0 comments on commit 24af8cb

Please sign in to comment.