Various dictionaries have different things to say.
What price [fame/success/victory etc.]?
something that you say which means it is possible that the fame, success etc. that has been achieved was not worth all the suffering it has caused
What price victory when so many people have died to make it possible?
(Cambridge Idioms Dictionary, 2nd ed.)
price [...]
what price (something)? what are the chances of (something) happening now?
(Collins English Dictionary – Complete and Unabridged)
What price something?
What is the value of something?; What good is something? (Said when the value of the thing referred to is being diminished or ignored.)
Jane's best friend told us all about Jane's personal problems. What price friendship? Jack simply declared himself president of the political society. What price democracy?
(McGraw-Hill Dictionary of American Idioms and Phrasal Verbs)
what price ——? used to ask what has become of something or to suggest that something has or would become worthless : what price justice if he were allowed to go free?
(New Oxford American Dictionary 2nd edition, from OS X)
Apart from Collins's strange definition, it seems that the general meaning of "what price X?" is "what's the value of X?" (not "what's the price of X", in the modern sense of price).
As for how it came to be, my wild speculation of the day is that it could have been used grammatically in an anaphoric expression, eg What price is freedom to us if we tolerate this tyranny? What price justice? etc.
You need to differentiate the noun from the verb, then investigate the verb for your answer.
The noun doesn't help much here.
root n.: the part of a plant, usually below the ground, that lacks nodes, shoots, and leaves, holds the plant in position, draws water and nourishment from the soil, and stores food
Origin: Middle English rote from Late Old English from Old Norse rot, akin to Old English wyrt, German wurzel from Indo-European base an unverified form wrād-, twig, root from source Glassical Greek rhiza, Classical Latin radix, root, ramus, branch
root vi.: to give audible encouragement or applause to a contestant or team; cheer. See Synonyms at applaud; to lend support to someone or something.
Origin: possibly alteration of rout. A second source also mentioned rout as the possible origin. root:Possibly an alteration of rout (“to make a loud noise”), influenced by hoot
rout to bellow, used of cattle. (First Known Use: 14th century): 14th century (Middle English rowten, from Old Norse rauta; akin to Old English rēotan to weep, Latin rudere to roar)
Best Answer
The earliest Google Books search result I could find for "put [someone] up" in the sense of "provide temporary sleeping accommodations for [someone]" is from 1903, but other idiomatic meanings of "put [someone or something] up" go back at least to 1640. I'll address the usage specifically cited in the OP's question first, and then look at some of the earlier meanings of the phrase.
The earliest Google Search match is from Henry James, The Ambassadors (1903):
From Margaret Good, "Search for Fresh Buttermilk and Happiness by an Unmarried Woman," in Farm Journal (March 1909):
From The Michigan Alumnus, volume 28 (January 19, 1922):
I suspect that this idiomatic usage arose out of the earlier usage of to "put up" in the sense of "set up, establish, pack, store, or provide," as exemplified by testimony from Isaiah Look, in Investigation into the Charges of Mismanagement and Cruelty at the Soldiers' and Sailors' Home, Bath, New York" (1883):
The notion of temporary storage (in this case of vegetables in a wagon) prefigures temporary accommodation of people in a dwelling.
The two earliest meanings of "put [pronoun] up" that a Google Books search finds are the senses "nominate or present [a person for political office]" and "store or make ready [a thing for future use]." The "put [a person] up for office" sense appears first in "The Trial Between Sir William Pritchard and Thomas Papillon Esq" (November 6, 1684), in A Complete Collection of State-Trials and Proceedings for High Treason, and Other Crimes and Misdemeanours, volume 3 (1730):
A similar use involved casting someone in a stage role. From "Faithful Copies of Letters between Hopkins and Wild, Prompters to the Monopolizers," in Fugitive Pieces in Prose and Verse (1795):
And yet another early meaning was to flush from cover (as a game bird or other animal). Thus from Charles Shadwell, "Irish Hospitality: Or, Virtue Rewarded," in Five New Plays (1720), we have this exchange between Sir Jowler Kennel (a "Country Baronet") and Morose (a "blunt honest Fellow"):
The "store or make ready [a thing for future use]" appears first in John Parkinson, "Styrax arbor. The sweete Storax tree," in Theatrum Botanicum (1640):
One especially common form of the phrase in the early to middle eighteenth century was to "put [something] up for use" in cookery, as in John Nott, The Cooks and Confectioners Dictionary (1723):
In the nineteenth century, the phrase "put [something] up" could mean both "offer for sale at auction" and "render or offer," as we see in this excerpt from Samuel Lover, "Knocked Up and Knocked Down," in National Proverbs (by 1868), which plays on the phrase: