Pain is perception of damage, but we aren't talking about what treats the damage, only about what alters the perception.
Err.... No, not really. Pain is a signal that comes down a nerve. It can mean damage, or it can mean no damage at all. Not all pain receptors respond to cells dying. In fact some have nothing at all to do with that.
As a trivial example, your thermal pain receptors (nociceptors) are literally responding not just to the death of any cells around, but also to temperature. And your threshold is probably around 44–45 °C in the upper direction if you're an average human, which is well below the level where cells are dying right now. It's more to prevent actual damage than to actually measure damage. But anyway, you can feel that kind of pain without ANY actual damage happening.
They're even "misused" as taste receptors in your mouth. E.g., capsacin literally binds to the the temperature receptors.
Other nociceptors respond literally to pressure. Even if no cell around has actually died, above a certain pressure level, you'll get a pain signal.
Yet other nociceptors (the "silent nociceptors") are only activated when there is an inflammation (including due to cell death) or being stimulated too often or such. Unless the proteins associated with an inflammation are there to activate the receptors that need an inflammation, they just don't trigger. Joints for example contain a LOT of these. So for example the same pressure in the joint might hurt like heck if it's inflamed, but not hurt at all if it's healthy. Again, the reason seems to be more to prevent further damage, than respond to actual damage happening right now.
Yet others respond to chemicals in the tissue, so they work kinda like the taste receptors in the tongue. A lot of those chemicals is how the ones that respond to tissue damage do so (and in fact, there are several receptors for several of these chemicals released when repairing tissue damage) but some respond to specific substances like lactic acid (think: muscle sores) or just to the PH being above or below a limit. Tissue damage may or may not be involved, but sometimes it's more about keeping you from getting to the level that actually destroys tissue, than recording existing tissue death. The lactic acid receptors are the prime example for that: they actually respond to lesser concentrations than would actually kill the muscle cell, to keep you from getting to that level.
Etc.
So essentially the objection that 'yeah, but pain doesn't just mean injury', yeah, that's nothing new.
It's still a signal that comes up a nerve, and gets processed SOMEHOW before becoming a subjective sensation that you have to compare to another subjective sensation. No different from any other, like sound, temperature or whatever. If there are effects skewing the comparisons done for the others, I want to know if they're taken into account for this one too.
Also, yes, I know about the inhibition mechanisms but even those aren't as clear cut mood-over-matter as you seem to think. A LOT of it happens entirely in the spinal cord and really has nothing to do with your mood or stress level, because those nerves don't know anything about that. Yes, some of the suppressive signal comes from above in the form of serotonin, norepinepherine and dopamine, but a lot of it is entirely local in the spinal cord and has nothing to do with those or your mood or stress level.
And even those three have more to do with what you're doing at the moment, rather than what you think about the pill you took three hours ago.
E.g., dopamine has more to do with
motivational salience, i.e., more of a "yeah, do that" or most often a "keep doing that" signal, as in whatever you were doing at the moment, than having anything to do with what you think about the pill you took three hours ago. Or really with ANYTHING you were doing three hours ago. As I was saying, it's about regulating what you're doing right now.
So it explains things like that you might notice less pain when you're focused on, say, a computer game, but buggerall to do with whether you think the pills you took this morning are working or not
But anyway, yeah, sure, some processing is involved between a pressure receptor firing in your hip and your brain getting a pain value. But it still gets A value at the end of the day. Is it any better at comparing it with the value from yesterday than for any other signal? Is it compensating for all the other variables involved? Having more variables along the way just means more room for subjective confirmation, rather than making it objective.