Not all Devil Fruit powers stop working when the user is unconscious.
Luffy was knocked unconscious and nearly drowned during the Arlong arc when he was submerged in Arlong's pool. Despite this his neck was stretched far enough to give him air. This was also seen when he was on Amazon Lily. There... parts... of him were stretched by the tribe while he was unconscious and that is all I'll say on that.
It would appear that if conscious or reflexive control is required to operate the user's power (such as Robin or Crocodile), the power will not work if they are unconscious. If the power causes a permanent change in the physiology of the user, the ability probably still works while they are unconscious.
Sugar is the perfect example of all of this because her fruit also makes her look very young. This is not reversed when she is knocked unconscious because that is not consciously controlled.
However, if it were that simple, Moria (or others) could never sleep. We are forced (whether it makes sense or not) to assume that the limited awareness a person has when asleep keeps some activated powers active. Specifically, ones that generate some conscious minion. In Perona's and Sugar's cases though, this obviously doesn't work if they are knocked unconscious. This makes sense as when someone is unconscious by force or alcohol, they do not dream (until they are mostly recovered) and sometimes lose control of subconsciously controlled faculties (such as bowels or, more seriously, breathing).
All of these rules seem to change fruit to fruit so it is impossible to tell if, say, Law's body switches or Van Decker's marks would revert if they were knocked unconscious.
Please note: Moria did not lose control of his zombies because he was unconscious but because he took all of their shadows into himself at the end of the fight. He did, however, lose control of the shadows when he was knocked unconscious. Most likely though he would have lost control of zombies in this situation anyways. You didn't make this mistake but I did several times while writing this.