mirror of
https://github.com/genodelabs/genode.git
synced 2025-06-23 17:17:38 +00:00
dde_linux: usb support extra data and zero config
- Vendor devices add addtional data to the config descriptor, read and added to the usb session - allow '0' configuration within the usb session issue #3822
This commit is contained in:
committed by
Norman Feske
parent
537472e9af
commit
36eeab6df2
@ -80,10 +80,16 @@ class Usb::Session_client : public Genode::Rpc_client<Session>
|
||||
call<Rpc_iface_descr>(index, alt_setting, interface_descr);
|
||||
}
|
||||
|
||||
bool interface_extra(unsigned index, unsigned alt_setting,
|
||||
Interface_extra *interface_data) override
|
||||
{
|
||||
return call<Rpc_iface_extra>(index, alt_setting, interface_data);
|
||||
}
|
||||
|
||||
void endpoint_descriptor(unsigned interface_num,
|
||||
unsigned alt_setting,
|
||||
unsigned endpoint_num,
|
||||
Endpoint_descriptor *endpoint_descr) override
|
||||
unsigned alt_setting,
|
||||
unsigned endpoint_num,
|
||||
Endpoint_descriptor *endpoint_descr) override
|
||||
{
|
||||
call<Rpc_ep_descr>(interface_num, alt_setting, endpoint_num, endpoint_descr);
|
||||
}
|
||||
|
@ -182,6 +182,9 @@ struct Usb::Session : public Genode::Session
|
||||
virtual void interface_descriptor(unsigned index, unsigned alt_setting,
|
||||
Interface_descriptor *interface_descr) = 0;
|
||||
|
||||
virtual bool interface_extra(unsigned index, unsigned alt_setting,
|
||||
Interface_extra *interface_data) = 0;
|
||||
|
||||
/**
|
||||
* Return endpoint for interface index/alternate setting tuple
|
||||
*/
|
||||
@ -208,6 +211,8 @@ struct Usb::Session : public Genode::Session
|
||||
GENODE_RPC(Rpc_alt_settings, unsigned, alt_settings, unsigned);
|
||||
GENODE_RPC_THROW(Rpc_iface_descr, void, interface_descriptor, GENODE_TYPE_LIST(Device_not_found,
|
||||
Interface_not_found), unsigned, unsigned, Interface_descriptor *);
|
||||
GENODE_RPC_THROW(Rpc_iface_extra, bool, interface_extra, GENODE_TYPE_LIST(Device_not_found,
|
||||
Interface_not_found), unsigned, unsigned, Interface_extra *);
|
||||
GENODE_RPC_THROW(Rpc_ep_descr, void, endpoint_descriptor, GENODE_TYPE_LIST(Device_not_found,
|
||||
Interface_not_found), unsigned, unsigned, unsigned, Endpoint_descriptor *);
|
||||
GENODE_RPC_THROW(Rpc_claim_interface, void, claim_interface, GENODE_TYPE_LIST(Interface_not_found,
|
||||
@ -215,8 +220,8 @@ struct Usb::Session : public Genode::Session
|
||||
GENODE_RPC_THROW(Rpc_release_interface, void, release_interface, GENODE_TYPE_LIST(Interface_not_found),
|
||||
unsigned);
|
||||
GENODE_RPC_INTERFACE(Rpc_plugged, Rpc_sigh_state_change, Rpc_tx_cap, Rpc_config_descr,
|
||||
Rpc_iface_descr, Rpc_ep_descr, Rpc_alt_settings, Rpc_claim_interface,
|
||||
Rpc_release_interface);
|
||||
Rpc_iface_descr, Rpc_iface_extra, Rpc_ep_descr, Rpc_alt_settings,
|
||||
Rpc_claim_interface, Rpc_release_interface);
|
||||
};
|
||||
|
||||
#endif /* _INCLUDE__USB_SESSION__USB_SESSION_H_ */
|
||||
|
Reference in New Issue
Block a user