I had to do a hard power off on my Pi, as it had crashed. Now, when I turn it on, I get 3 flashes of the OK LED, which means either loader.bin or start.elf is not found. I have plugged the SD card into my Windows PC to browse the boot partition and neither of those files is present. Is there any way to repair the boot partition and allow the Pi to boot without losing any data on the card? I have important data that hasn't been backed up yet on the card.
I'm afraid you're going to have to fix the installation manually.
You can download the relevant bin and elf files from the Raspberry Pi GitHub repository. Then mount the boot partition of the SD card and copy the files onto it.
If this doesn't work then something more serious has gone wrong and you're going to have to re-flash the entire image.
However, you should be able to save your data if you can mount the SD card as you can simply copy off the files you want. They will be in the directory
I hope this helps, let me know if you have any more trouble.
Backup the card.
Reflash the card with your OS, which would also fix the boot partition.
Copy the files you want back to your card.