diff options
author | Leif Delgass <ldelgass@users.sourceforge.net> | 2002-04-27 04:46:17 +0000 |
---|---|---|
committer | Leif Delgass <ldelgass@users.sourceforge.net> | 2002-04-27 04:46:17 +0000 |
commit | 45a5c02888a9f7d0ab36d8cb2f9dce58524cda8d (patch) | |
tree | d4d26ed7b3a6b1c9bdd28d032afed5ee410996b1 | |
parent | edac61a944b5fce4eeaa439a5f35999beec7b03a (diff) |
use virt_to_bus instead of virt_to_phys to get DMA buffer address, which
should work on non-x86 architecures.
-rw-r--r-- | linux/mach64_state.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/linux/mach64_state.c b/linux/mach64_state.c index a726a12e..f222d1ff 100644 --- a/linux/mach64_state.c +++ b/linux/mach64_state.c @@ -438,7 +438,7 @@ static void mach64_dma_dispatch_vertex( drm_device_t *dev, u32 *p; if (dev_priv->is_pci) { - address = (u32) virt_to_phys((void *)buf->address); + address = (u32) virt_to_bus((void *)buf->address); p = (u32 *) buf->address; } else { address = (u32) buf->bus_address; @@ -474,7 +474,7 @@ static void mach64_dma_dispatch_vertex( drm_device_t *dev, tableDwords += 4; #if MACH64_VERBOSE - DRM_INFO( "%s: %d bytes, buffer addr: 0x%08x\n", __FUNCTION__, size, address); + DRM_INFO( "%d bytes, buffer addr: 0x%08x\n", size, address); table_ptr = (u32 *) dev_priv->cpu_addr_table; for ( i = 0 ; i < tableDwords / 4 ; i++ ) { DRM_INFO( " entry: %x addr: %p cmd: 0x%x\n", i, |