This sounds like Star Surgeon (1960) by Alan E. Nourse.
The story you describe is the second excursion of the hospital ship described in the book. They receive a distress call from a planet (31 Brucker VII) that is not contracted to the galactic medical service, but the ship answers a distress call because it sounds so urgent.
Dal, one of the 3 main characters lives with a small shape-shifting symbiotic named Fuzzy:
Fuzzy wriggled down onto his hand, and a tiny mouth appeared just below the shoe-button eyes. Bit by bit Dal fed his friend the biscuit, with squirts of water in between bites. Finally, when the biscuit was gone, Dal squirted the rest of the water into Fuzzy's mouth and rubbed him between the eyes. "Feel better now?" he asked.
The creature seemed to understand; he wriggled in Dal's hand and blinked his eyes sleepily. "All right, then," Dal said. "Off to sleep."
Dal started to tuck him back into his jacket pocket, but Fuzzy abruptly sprouted a pair of forelegs and began struggling fiercely to get out again. Dal grinned and replaced the little creature in the crook of his arm. "Don't like that idea so well, eh? Okay, friend. If you want to watch, that suits me.
As you say the inhabitants had been assessed as non-intelligent:
Following this was a long, detailed and exceedingly dull description of the step-by-step procedure followed by a Confederation exploratory ship making a first landing on a barren planet. There was a description of the atmosphere, the soil surface, the land masses and major water bodies. Physically, the planet was a desert, hot and dry, and barren of vegetation excepting in two or three areas of jungle along the equator. "The planet is inhabited by numerous small unintelligent animal species which seem well-adapted to the semi-arid conditions. Of higher animals and mammals only two species were discovered, and of these the most highly developed was an erect biped with an integrated central nervous system and the intelligence level of a Garvian drachma."
"How small is that?" Jack said.
"Idiot-level," Dal said glumly. "I.Q. of about 20 on the human scale. I guess the explorers weren't much impressed; they didn't even put the planet down for a routine colonization survey."
They find a virus because Fuzzy gets infected by it:
It was a virus, beyond doubt. The electron microscope told them that, now that they had the substance isolated and could examine it. In the culture tubes in the Lancet's incubators, it would begin to grow nicely, and then falter and die, but when guinea pigs were inoculated in the ship's laboratory, the substance proved its virulence. The animals injected with tiny bits of the substance grew sick within hours and very quickly died.
Because Fuzzy had been able partly able to fight off the virus they extract some of his structure to use as an anti-viral agent:
"That's not what I mean," Dal said. "Maybe Fuzzy's body developed antibodies against the virus while he was infected. Remember, he doesn't have a rigid body structure like we do. He's mostly just basic protein, and he can synthesize pretty much anything he wants to or needs to."
Jack blinked. "It's an idea, at least. Is there any way we can get some of his body fluid away from him? Without getting bit, I mean?"
"No problem there," Dal said. "He can regenerate pretty fast if he has enough of the right kind of food. He won't miss an ounce or two of excess tissue."
He took a beaker over to Fuzzy's platform and began squeezing off a little blob of pink material. Fuzzy seemed to sense what Dal wanted; obligingly he thrust out a little pseudopod which Dal pinched off into the beaker. With the addition of a small amount of saline solution, the tissue dissolved into thin, pink suspension.
In the laboratory they found two or three of the guinea pigs in the last stages of the infection, and injected them with a tiny bit of the pink solution. The effect was almost unbelievable. Within twenty minutes all of the injected animals began to perk up, their eyes brighter, nibbling at the food in their cages, while the ones that had not been injected got sicker and sicker.
They prepare injections and test them on 400 of the Bruckians only to find they destroy their intelligence:
The Bruckian spokesman and the others who had not yet been inoculated drew back from them in terror as they stepped to the ground. Before, the people on the field had crowded in eagerly around the ship; now they were standing in silent groups staring at the doctors fearfully and muttering among themselves.
But the doctors could see only the inoculated people in the two roped-off areas. Off to the right among the infected Bruckians who had received the antibody there were no new dead—but there was no change for the better, either. The sick creatures drifted about aimlessly, milling like animals in a cage, their faces blank, their jaws slack, hands wandering foolishly. Not one of them had begun reacting normally, not one showed any sign of recognition or recovery.
But the real horror was on the other side of the field. Here were the healthy ones, the uninfected ones who had received preventative inoculations. A few hours before they had been left standing in quiet, happy groups, talking among themselves, laughing and joking....
But now they weren't talking any more. They stared across at the doctors with slack faces and dazed eyes, their feet shuffling aimlessly in the dust. All were alive, but only half-alive. The intelligence and alertness were gone from their faces; they were like the empty shells of the creatures they had been a few hours before, indistinguishable from the infected creatures in the other compound.
They finally figure out it's the virus that's intelligent:
"As backward as we could get it," Dal said. "We've assumed all along that these flesh-and-blood creatures down there were the ones that were calling us for help because of a virus plague that was attacking and killing them. All right, look at it the other way. Just suppose that the intelligent creature that called us for help was the virus, and that those flesh-and-blood creatures down there with the blank, stupid faces are the real plague we ought to have been fighting all along!"
Fuzzy divides to give the viruses a host:
A moment before, there had been a single three-inch pink creature on his elbow. But now there were two, each just one-half the size of the original. As Dal watched, one of the two drew away from the other, creeping in to snuggle closer to Dal's side, and a pair of shoe-button eyes appeared and blinked up at him trustingly. But the other creature was moving down his arm, straining out toward the Bruckian spokesman....
Dal realized instantly what was happening. He started to draw back, but something stopped him. Deep in his mind he could sense a gentle voice reassuring him, saying, It's all right, there is nothing to fear, no harm will come to me. These creatures need help, and this is the way to help them.
He saw the Bruckian reach out a trembling hand. The tiny pink creature that had separated from Fuzzy seemed almost to leap across to the outstretched hand. And then the spokesman held him close, and the new Fuzzy shivered happily.
The virus-creatures had found a host. Here was the ideal kind of body for their intelligence to work with and mold, a host where antibody-formation could be perfectly controlled. Dal knew now that the problem had almost been solved once before, when the virus-creature had reached Fuzzy on the ship; if they had only waited a little longer they would have seen Fuzzy recover from his illness a different creature entirely than before.
Already the new creature was dividing again, with half going on to the next of the Bruckians. To a submicroscopic virus, the body of the host would not have to be large; soon there would be a sufficient number of hosts to serve the virus-creatures' needs forever. As he started back up the ladder to the ship, Dal knew that the problem on 31 Brucker VII had found a happy and permanent solution.