Howdy.
Using the mode button and select/ set-reset toggle, cycle through the dash menu until you find 'system check'. Press up (pretty sure) once on the toggle. It'll say 'No Faults'. Press up and hold the toggle until the screen changes, it may take a few seconds. History faults should pop up. Press up on the toggle to cycle through them. Write them down. Do not clear them (it won't help you). Just press the mode button again to exit the menu.
What are the history codes?
Hopefully it's P0087/P0088 (low/high rail pressure). That's gonna be the least expensive scenario. If it's P0087, put a fuel filter on it and cross your fingers. If it's P0088, stop and get some contact cleaner, unplug the connector on the shiny, round, 1"x2" cylinder looking thing on the high pressure fuel pump, and hose out both ends. Cross your fingers.
While you're in there poking around, grab a can of some sort of penetrating lubricant and spray the linkage of the VNT controller. It's under/behind the turbo, and part of the linkage is hidden. Stand on the right front tire, look down at the turbo, and you'll see the upper link in the center of the turbo. Hose down that whole general area. It's gonna smoke when you fire it back up, but that's ok.
Was it doing a regen when it was losing power? If you watch the DPR indicator on the dash, as soon as it hits 3 bars it will start to regen. If this is the case, take off the big hose between the intercooler and the intake. Look in the intake. There's a throttle butterfly in there. Grab the plate and wiggle it. Is it tight? Does it have three hand-drilled holes in the bottom of the plate? If no, then you have a little work to do.
I'll wait for the history codes before going any further.