I have a photo and I know what RGB coordinates a pixel in that photo should actually have. Based on that information, how do I correct the entire photo?
If you have a pixel in the image with RGB values (x, y, z) and want to bring it to (x', y', z'), simply use the Channel Mixer to apply the difference. It's available in both GIMP and Photoshop (and probably most editors).
There is a good chance though, that you won't be pleased with the outcome as the input information isn't to much to go on.
You aren't going to get it exactly right with a single pixel, though you can certainly get that pixel right and then adjust everything else to be visually pleasing (which is usually close enough).
To get the color more correct, assuming the light is a continuous spectrum (e.g. sunlight or incandescent bulb) you could get pretty close with a known-white pixel and a known black pixel, because the known-white pixel will tell you the color of the lighting and the known-black pixel will tell you how far off your black point is. But to get it exactly right, you would need at least several known non-grey pixels to determine how broad the spectrum is.
For discontinuous spectra (fluorescent lighting, LED lighting, mixed lighting), etc., you would pretty much need to shoot photo of a series of continuous color charts with various brightnesses (i.e. the pink-to-baby-blue chart, the light-red-to-light-blue chart ... the deep red-to-deep-blue chart), because there's no way to predict based on a small number of colors what other colors will look like.
That's not to say you can't get fairly close with a much smaller number of color samples, of course, even with a discontinuous spectrum. You can get reasonably close with a known sample of black, white, (medium) red, and (medium) green (for example). More data points is better (assuming you're willing to take the time to calibrate for all of them).
A couple of articles that explain more: