Well, it looks like you have quite a list.
P0172- Fuel trim upper limit
P1008- Throttle system Warning- Signal low
P1017- ECM internal failure
P1027- Throttle unit internal faliure
P1620- Is an ECM (computer) problem, dash problem or wiring in between the two
Any one of these could explain the surging idle. Look for any vacum leaks, cracked or broken hoses. This one you may want to find a good Volvo shop, it looks like the throttle control may be bad, but it could have hurt the ECM given the internal ECM code.
February, 6, 2010 AT 6:44 PM
Start off by having the the throttle cleaned. It would be better if you remove it so that you can clean it out good. Also check your postive battery cable. Do a voltage drog across the cable to make sure it is ok. And also look at the positive cable going to the realy box. Look inside the relay box for the cable. Check for oxidation or cable being burnt. If it is, then replace the cable. It is called the 30+ cable if you order it from Volvo. If all that is done or it is good, then you will need to have the throttle replaced, but you will need software reloaded to it as well for it to function properly. Also have you had campaign 155 done? If you are not sure, call Volvo to make sure it was done. If not they will do it at no charge to you.