Changeset 73301a0 in mainline for uspace/lib/usbvirt/device.h


Ignore:
Timestamp:
2010-10-15T12:57:35Z (13 years ago)
Author:
Vojtech Horky <vojtechhorky@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
47e3a8e
Parents:
cbc00a4d
Message:

Virtual USB keyboard sends its report

Also, the virtual USB framework now handles the standard requests
differently. First, all requests has standalone callbacks and the
user callbacks are always called first. If they return EFORWARD,
the framework will try to satisfy the request by itself.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/lib/usbvirt/device.h

    rcbc00a4d r73301a0  
    4646        uint8_t *data);
    4747
     48/** Callbacks for standard device requests.
     49 * When these functions are NULL or return EFORWARD, this
     50 * framework will try to satisfy the request by itself.
     51 */
     52typedef struct {
     53        usbvirt_on_device_request_t on_get_status;
     54        usbvirt_on_device_request_t on_clear_feature;
     55        usbvirt_on_device_request_t on_set_feature;
     56        usbvirt_on_device_request_t on_set_address;
     57        usbvirt_on_device_request_t on_get_descriptor;
     58        usbvirt_on_device_request_t on_set_descriptor;
     59        usbvirt_on_device_request_t on_get_configuration;
     60        usbvirt_on_device_request_t on_set_configuration;
     61        usbvirt_on_device_request_t on_get_interface;
     62        usbvirt_on_device_request_t on_set_interface;
     63        usbvirt_on_device_request_t on_synch_frame;
     64} usbvirt_standard_device_request_ops_t;
     65
    4866/** Device operations. */
    4967typedef struct {
    50         /** Callback for standard USB request.
    51          * Called only when the request could not be handled by this
    52          * framework.
    53          */
    54         usbvirt_on_device_request_t on_devreq_std;
     68        /** Callbacks for standard deivce requests. */
     69        usbvirt_standard_device_request_ops_t *standard_request_ops;
    5570        /** Callback for class-specific USB request. */
    56         usbvirt_on_device_request_t on_devreq_class;
     71        usbvirt_on_device_request_t on_class_device_request;
    5772        /** Callback for all other incoming data. */
    5873        int (*on_data)(struct usbvirt_device *dev,
Note: See TracChangeset for help on using the changeset viewer.