IRequest.cs 1.5 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859
  1. using Ryujinx.Common.Logging;
  2. using Ryujinx.HLE.HOS.Ipc;
  3. using System.Collections.Generic;
  4. namespace Ryujinx.HLE.HOS.Services.Mm
  5. {
  6. class IRequest : IpcService
  7. {
  8. private Dictionary<int, ServiceProcessRequest> m_Commands;
  9. public override IReadOnlyDictionary<int, ServiceProcessRequest> Commands => m_Commands;
  10. public IRequest()
  11. {
  12. m_Commands = new Dictionary<int, ServiceProcessRequest>()
  13. {
  14. { 1, InitializeOld },
  15. { 4, Initialize },
  16. { 6, SetAndWait },
  17. { 7, Get }
  18. };
  19. }
  20. // InitializeOld(u32, u32, u32)
  21. public long InitializeOld(ServiceCtx Context)
  22. {
  23. int Unknown0 = Context.RequestData.ReadInt32();
  24. int Unknown1 = Context.RequestData.ReadInt32();
  25. int Unknown2 = Context.RequestData.ReadInt32();
  26. Logger.PrintStub(LogClass.ServiceMm, "Stubbed.");
  27. return 0;
  28. }
  29. public long Initialize(ServiceCtx Context)
  30. {
  31. Logger.PrintStub(LogClass.ServiceMm, "Stubbed.");
  32. return 0;
  33. }
  34. public long SetAndWait(ServiceCtx Context)
  35. {
  36. Logger.PrintStub(LogClass.ServiceMm, "Stubbed.");
  37. return 0;
  38. }
  39. public long Get(ServiceCtx Context)
  40. {
  41. Context.ResponseData.Write(0);
  42. Logger.PrintStub(LogClass.ServiceMm, "Stubbed.");
  43. return 0;
  44. }
  45. }
  46. }