| 867 | } |
| 868 | |
| 869 | static void cbForStateBusy(u32 intType) |
| 870 | { |
| 871 | DVDCommandBlock* finished; |
| 872 | |
| 873 | if (intType == 16) |
| 874 | { |
| 875 | executing->state = -1; |
| 876 | stateTimeout(); |
| 877 | return; |
| 878 | } |
| 879 | |
| 880 | if ((CurrCommand == 3) || (CurrCommand == 15)) |
| 881 | { |
| 882 | if (intType & 2) |
| 883 | { |
| 884 | executing->state = -1; |
| 885 | stateError(0x1234567); |
| 886 | return; |
| 887 | } |
| 888 | |
| 889 | NumInternalRetry = 0; |
| 890 | |
| 891 | if (CurrCommand == 15) |
| 892 | { |
| 893 | ResetRequired = TRUE; |
| 894 | } |
| 895 | |
| 896 | if (CheckCancel(7)) |
| 897 | { |
| 898 | return; |
| 899 | } |
| 900 | |
| 901 | executing->state = 7; |
| 902 | stateMotorStopped(); |
| 903 | return; |
| 904 | } |
| 905 | |
| 906 | if (IsDmaCommand(CurrCommand)) |
| 907 | { |
| 908 | executing->transferredSize += executing->currTransferSize - __DIRegs[6]; |
| 909 | } |
| 910 | |
| 911 | if (intType & 8) |
| 912 | { |
| 913 | Canceling = FALSE; |
| 914 | finished = executing; |
| 915 | executing = &DummyCommandBlock; |
| 916 | |
| 917 | finished->state = 10; |
| 918 | if (finished->callback) |
| 919 | (*finished->callback)(-3, finished); |
| 920 | if (CancelCallback) |
| 921 | (CancelCallback)(0, finished); |
| 922 | stateReady(); |
| 923 | |
| 924 | return; |
| 925 | } |
| 926 |
nothing calls this directly
no test coverage detected