Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 158044
b: refs/heads/master
c: 99becac
h: refs/heads/master
v: v3
  • Loading branch information
FUJITA Tomonori committed Jul 28, 2009
1 parent 7042141 commit c47b060
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 1 deletion.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 02ca646e73f3cb9be69e339841b94edae675e248
refs/heads/master: 99becaca86d184a4433e9fde879ff97303d7669f
8 changes: 8 additions & 0 deletions trunk/arch/x86/include/asm/dma-mapping.h
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,14 @@ extern int dma_set_mask(struct device *dev, u64 mask);
extern void *dma_generic_alloc_coherent(struct device *dev, size_t size,
dma_addr_t *dma_addr, gfp_t flag);

static inline bool dma_capable(struct device *dev, dma_addr_t addr, size_t size)
{
if (!dev->dma_mask)
return 0;

return addr + size <= *dev->dma_mask;
}

static inline void
dma_cache_sync(struct device *dev, void *vaddr, size_t size,
enum dma_data_direction dir)
Expand Down

0 comments on commit c47b060

Please sign in to comment.