It's extremely difficult for the Powertrain Control Module (PCM, also called the main computer, the ECU, the ECM and a few other tems) to control a cold engine within a very narrow rpm band, it gets easier as it warms up. Valvetronic stuff should have nothing to do with loping idle speed, everything is at 'zero' in the mechanism until load or rpm changes.
When a cold engine starts is when the most pollutants occur. More emissions happen during the first five minutes than in the next couple hours. The PCM has to consult the intake air temperature graphs, the intake air density graphs, the engine temperature graphs, the fuel octane and composition (methanol percentage?) graphs, the barometric pressure graphs, the accelerator pedal position graphs, the injector history graphs, the long term fuel trim graphs and whether the driver is drinking coffee graphs. It then tries to come up with an injector pulse which will nail the desired rpm while doing a delicate balancing act with the idle air control bypass system. It ain't easy.
Most often the 'problem' is software related and mfrs. do a recall to tweak the algorithms once they get enough field information. What takes forever is getting the EPA to certify these tweaks before they're released, they want to make sure that the car will still meet emission standards after the new software is installed (often called 'reflashing').