On Tue, Nov 24, 2009 at 21:55, Song, Barry wrote: >From: Song, Barry >>From: Mike Frysinger [mailto:[email protected]] >>>On Tue, Nov 24, 2009 at 05:20, <[email protected]> wrote: >>>> +void dma_sync_single_range_for_cpu(struct device *dev, dma_addr_t >>>> dma_handle, >>>> + unsigned long offset, size_t size, enum >>>dma_data_direction direction) >>>> +{ >>>> + BUG_ON(!valid_dma_direction(direction)); >>>> +} >>>> +EXPORT_SYMBOL(dma_sync_single_range_for_cpu); >>>> + >>>> +void dma_sync_sg_for_cpu(struct device *dev, struct >>>scatterlist *sg, int >>>> nelems, >>>> + enum dma_data_direction direction) >>>> +{ >>>> + BUG_ON(!valid_dma_direction(direction)); >>>> +} >>>> +EXPORT_SYMBOL(dma_sync_sg_for_cpu); >>>> + >>>> +/* >>>> + * allow the device to access the mapped streaming DMA buffer again >>>> + */ >>>> +void dma_sync_single_range_for_device(struct device *dev, >>dma_addr_t >>>> dma_handle, >>>> + unsigned long offset, size_t size, enum >>>dma_data_direction direction) >>>> +{ >>>> + __dma_sync(dma_handle + offset, size, direction); >>>> +} >>>> +EXPORT_SYMBOL(dma_sync_single_range_for_device); >>>> + >>>> +void dma_sync_sg_for_device(struct device *dev, struct >>>scatterlist *sg, int >>>> nelems, >>>> + enum dma_data_direction direction) >>>> +{ >>>> + int i; >>>> + >>>> + for (i = 0; i < nelems; i++, sg++) { >>>> + sg->dma_address = (dma_addr_t) sg_virt(sg); >>>> + __dma_sync(sg_dma_address(sg), sg_dma_len(sg), >>>direction); >>>> + } >>>> +} >>>> +EXPORT_SYMBOL(dma_sync_sg_for_device); >>>> + >>>> +void dma_cache_sync(struct device *dev, void *vaddr, size_t size, >>>> + enum dma_data_direction direction) >>>> +{ >>>> + __dma_sync((dma_addr_t)vaddr, size, direction); >>>> +} >>>> +EXPORT_SYMBOL(dma_cache_sync); >>> >>>it doesnt really make sense to uninline these simple stub functions >> >>Ok. Inline is fine. > > I will not inline these since __dma_sync should not be exported to users > in headfile or as symbol.
having the public symbols tail into an internal symbol is fine. we can export __dma_sync both in the api and at the symbol level. -mike _______________________________________________ Linux-kernel-commits mailing list [email protected] https://blackfin.uclinux.org/mailman/listinfo/linux-kernel-commits
