mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-28 02:32:09 -04:00
rapidio: add query_mport operation
Add mport query operation to report master port RapidIO capabilities and run time configuration to upper level drivers. Signed-off-by: Alexandre Bounine <[email protected]> Cc: Matt Porter <[email protected]> Cc: Aurelien Jacquiot <[email protected]> Cc: Andre van Herk <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
This commit is contained in:
parent
d2a321f37e
commit
8b189fdbc5
3 changed files with 69 additions and 0 deletions
|
|
@ -67,6 +67,23 @@ u16 rio_local_get_device_id(struct rio_mport *port)
|
|||
return (RIO_GET_DID(port->sys_size, result));
|
||||
}
|
||||
|
||||
/**
|
||||
* rio_query_mport - Query mport device attributes
|
||||
* @port: mport device to query
|
||||
* @mport_attr: mport attributes data structure
|
||||
*
|
||||
* Returns attributes of specified mport through the
|
||||
* pointer to attributes data structure.
|
||||
*/
|
||||
int rio_query_mport(struct rio_mport *port,
|
||||
struct rio_mport_attr *mport_attr)
|
||||
{
|
||||
if (!port->ops->query_mport)
|
||||
return -ENODATA;
|
||||
return port->ops->query_mport(port, mport_attr);
|
||||
}
|
||||
EXPORT_SYMBOL(rio_query_mport);
|
||||
|
||||
/**
|
||||
* rio_add_device- Adds a RIO device to the device model
|
||||
* @rdev: RIO device
|
||||
|
|
|
|||
Loading…
Reference in a new issue