menu: Update bootmenu_loop() to return the code