Loading

Paste #p0zdu08pg

  1. fragment z mejch linuxovejch maker, reboot syscall
  2.  
  3. ;--------------------------------------------------------------------------------------------------------------------------
  4. ; reboot syscall magic numbers, see reboot.asm tool for detail use
  5. ; (4) r10 <- 0?
  6. ; (3) rdx:
  7. %assign Linux.REBOOT_CMD_RESTART        0x01234567      ; Performs a restart, weak waiting for sync
  8. %assign Linux.REBOOT_CMD_HALT           0xcdef0123      ; Halt the system
  9. %assign Linux.REBOOT_ENABLE_CAD         0x89abcdef      ; Enable reboot using Ctrl-Alt-Delete keystroke
  10. %assign Linux.REBOOT_DISABLE_CAD        0               ; Disable reboot using Ctrl-Alt-Delete keystroke
  11. %assign Linux.REBOOT_POWER_OFF          0x4321fedc      ; Stop system and switch power off if possible
  12. ; (2) rsi:
  13. %assign Linux.REBOOT_MAGIC2             672274793       ; Magic 2, hex 28121969, perhaps a Linus's birthday?
  14. ; (1) rdi:
  15. %assign Linux.REBOOT_MAGIC1             0xfee1dead      ; Magic 1
  16.  
  17.