mirror of
https://github.com/RPCS3/rpcs3.git
synced 2025-07-09 00:11:24 +12:00
Fix cellPadSetPortSetting (#3980)
* Don't skip setting port settings when no controller is connected * DS4: fix error message
This commit is contained in:
parent
8a3759f479
commit
fc2ef5529d
2 changed files with 4 additions and 3 deletions
|
@ -524,12 +524,13 @@ s32 cellPadSetPortSetting(u32 port_no, u32 port_setting)
|
||||||
|
|
||||||
if (port_no >= rinfo.max_connect)
|
if (port_no >= rinfo.max_connect)
|
||||||
return CELL_PAD_ERROR_INVALID_PARAMETER;
|
return CELL_PAD_ERROR_INVALID_PARAMETER;
|
||||||
if (port_no >= rinfo.now_connect)
|
|
||||||
return CELL_PAD_ERROR_NO_DEVICE;
|
|
||||||
|
|
||||||
auto& pads = handler->GetPads();
|
auto& pads = handler->GetPads();
|
||||||
pads[port_no]->m_port_setting = port_setting;
|
pads[port_no]->m_port_setting = port_setting;
|
||||||
|
|
||||||
|
if (port_no >= rinfo.now_connect)
|
||||||
|
return CELL_PAD_ERROR_NO_DEVICE;
|
||||||
|
|
||||||
return CELL_OK;
|
return CELL_OK;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -723,7 +723,7 @@ bool ds4_pad_handler::Init()
|
||||||
if (dev)
|
if (dev)
|
||||||
CheckAddDevice(dev, devInfo);
|
CheckAddDevice(dev, devInfo);
|
||||||
else
|
else
|
||||||
LOG_ERROR(HLE, "[DS4] hid_open_path failed! Reason: %S", hid_error(dev));
|
LOG_ERROR(HLE, "[DS4] hid_open_path failed! Reason: %s", hid_error(dev));
|
||||||
devInfo = devInfo->next;
|
devInfo = devInfo->next;
|
||||||
}
|
}
|
||||||
hid_free_enumeration(head);
|
hid_free_enumeration(head);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue