The religion can set constraints, but no cyborg would be halal
A religion may set any rules, its narrative serves to make them consistent, not logical. See other answers. This is not a frame challenge: religions are quite often internally inconsistent, so it will be 'realistic' to have such a religion. Also, when the powers that be require cyborgs to exist, religions tend to comply and ease up the rules to accommodate the powers that be.
Paradox
When these rules are carved in stone, I doubt if cyborgs would exist at all. Science and religion both embrace cyborgs, but the religion doesn't allow AI or genetic engineering? This will make it very difficult to create a functioning cyborg! Its brain may remain human, but a cyborg cannot be constructed without AI or genetic engineering in its senses, and to connect limbs extensions to the body. When you want to let a cyborg walk, you'll need to connect sensors to neural pathways, which can only be done properly with the help of genetic analysis. Now suppose your cyborg has both legs replaced by mechanics, you'll need to add servos and electronics for balance, which is driven by learning, a system which needs AI to exist inside the Cyborg, but outside its brain. If it is not allowed, you'll end up with a very clumsy cyborg.
Some notes on AI application in brain-machine connections
I view AI as everyday, current technology. I regard learning (or adjustment) on the side of the artificial limb as needed for the cyborgs physics-brain connection. Maybe when the religion would reject "deep learning" or "machine learning" instead of "AI", the discussion in the comments below could have been avoided, but this extra part would not have been written, so thank you @Pelinore and others for the input!
In the question, it says
Q: "In short then, I am asking: Is there actually any way to have a religion which would both prohibit significant advances in machine learning and totally forbid all genetic engineering but which would, nonetheless, be entirely and undividedly happy with the idea of people casually replacing their limbs and organs with brain-controlled artificial versions?"
When the predominant religion cannot coexist with AI, your people it can't make an advanced, autonomously balancing prosthesis, like this one,
https://daw-usa.com/knee/slk-multi-matrix/
Ok, let's talk medical devices as an example of modern (learning) AI application.
In the early 1980s, there were pioneers in NL working on artificial limbs and even artificial hands, connected to the brain. These systems were based on electrodes and patient learning, not machine learning. That is: the patient had to learn to manipulate the device. Back then, these systems were ineffective an unstable. The reason for that: brain signals were multiple, that is the patient had to invent how activate multiple electrodes to move the device, all parts of it.
When machine learning came in, the number of electrodes could be reduced. The artifical limb would not be "driven" by the brain rather "react" to the brain. As a result, we now have artificial hands, and artificial legs, as well as dancing robots. These artificial limbs "live" for 80% autonomously, behaviour induced by machine learning. By learning, it got used to your brain signals, the level of them.. and the combination connected to certain movements. The patient's learning is still needed, but the device learns too, it adjusts to the patient. Individually.. no system can be copy-pasted from one patient to the other.
The ideal in the end, a real cyborg (like in your title) will be able to move his superior limbs intuitively. It will be able to jump and fight, to perfectly connect the motor system in the brain. We're not there yet, but AI, that is machine learning, is regarded as the key to connect the parts while training the patient (or "terminator" or "cybercop", one day)