mirror of
https://github.com/switchbrew/libnx.git
synced 2025-06-21 12:32:40 +02:00
usbds: Fixed usbDsInterface_AppendConfigurationData for 11.0.0.
This commit is contained in:
parent
0f38ec8a3d
commit
49d7fe81b8
@ -657,12 +657,21 @@ Result usbDsInterface_AppendConfigurationData(UsbDsInterface* interface, UsbDevi
|
|||||||
if (hosversionBefore(5,0,0))
|
if (hosversionBefore(5,0,0))
|
||||||
return MAKERESULT(Module_Libnx, LibnxError_IncompatSysVer);
|
return MAKERESULT(Module_Libnx, LibnxError_IncompatSysVer);
|
||||||
|
|
||||||
const struct {
|
if (hosversionBefore(11,0,0)) {
|
||||||
u8 intf_num;
|
const struct {
|
||||||
u32 speed;
|
u8 intf_num;
|
||||||
} in = { interface->interface_index, speed };
|
u8 pad[3];
|
||||||
|
u32 speed;
|
||||||
|
} in = { interface->interface_index, {0}, speed };
|
||||||
|
|
||||||
return serviceDispatchIn(&interface->s, hosversionAtLeast(11,0,0) ? 10 : 12, in,
|
return serviceDispatchIn(&interface->s, 12, in,
|
||||||
|
.buffer_attrs = { SfBufferAttr_HipcMapAlias | SfBufferAttr_In },
|
||||||
|
.buffers = { { buffer, size } },
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
|
u32 in = speed;
|
||||||
|
return serviceDispatchIn(&interface->s, 10, in,
|
||||||
.buffer_attrs = { SfBufferAttr_HipcMapAlias | SfBufferAttr_In },
|
.buffer_attrs = { SfBufferAttr_HipcMapAlias | SfBufferAttr_In },
|
||||||
.buffers = { { buffer, size } },
|
.buffers = { { buffer, size } },
|
||||||
);
|
);
|
||||||
|
Loading…
Reference in New Issue
Block a user