aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorStefan Richter <stefanr@s5r6.in-berlin.de>2009-01-04 10:23:29 -0500
committerStefan Richter <stefanr@s5r6.in-berlin.de>2009-03-24 15:56:44 -0400
commit33580a3ef5ba3bc0ee1b520df82a24bb37ce28f0 (patch)
tree3bd567d8c5244a049eef32147f4fb84f6a19a184 /include
parent1ec3c0269d7196118cc7c403654ca5f19ef4d584 (diff)
firewire: cdev: add ioctl to query maximum transmission speed
While the speed of asynchronous transactions is automatically chosen by the kernel, the speed of isochronous streams has to be chosen by the initiating client. In case of 1394a bus topologies, the maximum possible speed could be figured out with some effort by evaluation of the remote node's link speed field in the config ROM, the local node's link speed field, and the PHY speeds and topologic information in the local node's or IRM's topology map CSR. However, this does not work in case of 1394b buses. Hence add an ioctl to export the maximum speed which the kernel already determined. Signed-off-by: Stefan Richter <stefanr@s5r6.in-berlin.de>
Diffstat (limited to 'include')
-rw-r--r--include/linux/firewire-cdev.h10
1 files changed, 10 insertions, 0 deletions
diff --git a/include/linux/firewire-cdev.h b/include/linux/firewire-cdev.h
index 08ca838a727b..f819c1026958 100644
--- a/include/linux/firewire-cdev.h
+++ b/include/linux/firewire-cdev.h
@@ -229,6 +229,7 @@ union fw_cdev_event {
229#define FW_CDEV_IOC_DEALLOCATE_ISO_RESOURCE _IOW('#', 0x0e, struct fw_cdev_deallocate) 229#define FW_CDEV_IOC_DEALLOCATE_ISO_RESOURCE _IOW('#', 0x0e, struct fw_cdev_deallocate)
230#define FW_CDEV_IOC_ALLOCATE_ISO_RESOURCE_ONCE _IOW('#', 0x0f, struct fw_cdev_allocate_iso_resource) 230#define FW_CDEV_IOC_ALLOCATE_ISO_RESOURCE_ONCE _IOW('#', 0x0f, struct fw_cdev_allocate_iso_resource)
231#define FW_CDEV_IOC_DEALLOCATE_ISO_RESOURCE_ONCE _IOW('#', 0x10, struct fw_cdev_allocate_iso_resource) 231#define FW_CDEV_IOC_DEALLOCATE_ISO_RESOURCE_ONCE _IOW('#', 0x10, struct fw_cdev_allocate_iso_resource)
232#define FW_CDEV_IOC_GET_SPEED _IOR('#', 0x11, struct fw_cdev_get_speed)
232 233
233/* FW_CDEV_VERSION History 234/* FW_CDEV_VERSION History
234 * 235 *
@@ -575,4 +576,13 @@ struct fw_cdev_allocate_iso_resource {
575 __u32 handle; 576 __u32 handle;
576}; 577};
577 578
579/**
580 * struct fw_cdev_get_speed - Query maximum speed to or from this device
581 * @max_speed: Speed code; minimum of the device's link speed, the local node's
582 * link speed, and all PHY port speeds between the two links
583 */
584struct fw_cdev_get_speed {
585 __u32 max_speed;
586};
587
578#endif /* _LINUX_FIREWIRE_CDEV_H */ 588#endif /* _LINUX_FIREWIRE_CDEV_H */