Why the confusion over the ending?
There are suggestions here that Loki didn't rescue Keller, either because he didn't follow up on the whistle noise or incredibly even that he thought it was better to leave him to die.
Both ideas are ridiculous. Loki is obviously a pitbull, he doesn't let anything go. If he hears an unusual out of place sound at a crime scene like this he's not going to quit until he finds out exactly what it is, and he's clearly focused on the sound at the very end.
Whether he gets to Keller in time or not is irrelevant, there's no way he's shrugging his shoulders and walking away as has been suggested.
As for the idea that he realizes it's Keller and thinks it's best to walk away and let him die in a hole rather than have him face the inevitable prison term, that would be utterly monstrous. Let the guy die in pain, never knowing that his daughter is safe? What kind of asshole would do that?
He clearly finds Keller, the only question is what happens then?
Ideally in my mind he finds him that night shortly after the ending when there is no one else around and helps him get away and into hiding, though that would be much complicated by the fact Keller is seriously wounded.