diff options
author | Martyn Welch <martyn.welch@gefanuc.com> | 2010-02-18 15:12:58 +0000 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2010-03-03 16:43:00 -0800 |
commit | 4f723df45d3952c485ee0125fb6797ad615901c3 (patch) | |
tree | 3db9d8a00c01c0ffa4d3d66630abf4e72e4771ed /drivers/staging/vme/vme_api.txt | |
parent | Staging: vme: Renaming following split of GE Fanuc joint venture (diff) | |
download | linux-dev-4f723df45d3952c485ee0125fb6797ad615901c3.tar.xz linux-dev-4f723df45d3952c485ee0125fb6797ad615901c3.zip |
Staging: vme: Attribute Testing For Dma Request
Check the directions in which the DMA controller is expected to operate
before giving control of a resource.
Signed-off-by: Martyn Welch <martyn.welch@gefanuc.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/staging/vme/vme_api.txt')
-rw-r--r-- | drivers/staging/vme/vme_api.txt | 27 |
1 files changed, 19 insertions, 8 deletions
diff --git a/drivers/staging/vme/vme_api.txt b/drivers/staging/vme/vme_api.txt index a5c1b1cd5fcc..a910a0c4388b 100644 --- a/drivers/staging/vme/vme_api.txt +++ b/drivers/staging/vme/vme_api.txt @@ -77,16 +77,21 @@ driver in question: struct vme_resource * vme_slave_request(struct device *dev, vme_address_t aspace, vme_cycle_t cycle); - struct vme_resource *vme_dma_request(struct device *dev); + struct vme_resource *vme_dma_request(struct device *dev, + vme_dma_route_t route); For slave windows these attributes are split into those of type 'vme_address_t' -and 'vme_cycle_t'. Master windows add a further set of attributes 'vme_cycle_t'. -These attributes are defined as bitmasks and as such any combination of the -attributes can be requested for a single window, the core will assign a window -that meets the requirements, returning a pointer of type vme_resource that -should be used to identify the allocated resource when it is used. If an -unallocated window fitting the requirements can not be found a NULL pointer will -be returned. +and 'vme_cycle_t'. Master windows add a further set of attributes +'vme_cycle_t'. These attributes are defined as bitmasks and as such any +combination of the attributes can be requested for a single window, the core +will assign a window that meets the requirements, returning a pointer of type +vme_resource that should be used to identify the allocated resource when it is +used. For DMA controllers, the request function requires the potential +direction of any transfers to be provided in the route attributes. This is +typically VME-to-MEM and/or MEM-to-VME, though some hardware can support +VME-to-VME and MEM-to-MEM transfers as well as test pattern generation. If an +unallocated window fitting the requirements can not be found a NULL pointer +will be returned. Functions are also provided to free window allocations once they are no longer required. These functions should be passed the pointer to the resource provided @@ -237,6 +242,12 @@ covered under "Transfer Attributes"): struct vme_dma_attr *src, struct vme_dma_attr *dest, size_t count); +NOTE: The detailed attributes of the transfers source and destination + are not checked until an entry is added to a DMA list, the request + for a DMA channel purely checks the directions in which the + controller is expected to transfer data. As a result it is + possible for this call to return an error, for example if the + source or destination is in an unsupported VME address space. Transfer Attributes ------------------- |