V4L/DVB (9913): tuner-xc2028: allow printing stack trace as debug on sleep code

tuner-xc3028 can be put to sleep to save power. However, if not properly
recovered from sleep, the device won't work. It is noticed that some
devices doesn't recover properly, so let's add a dump_stack() as a debug
option, to allow us to track when this happens.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
diff --git a/drivers/media/common/tuners/tuner-xc2028.c b/drivers/media/common/tuners/tuner-xc2028.c
index 7b7e242..1adce9f 100644
--- a/drivers/media/common/tuners/tuner-xc2028.c
+++ b/drivers/media/common/tuners/tuner-xc2028.c
@@ -1107,6 +1107,10 @@
 		return 0;
 
 	tuner_dbg("Putting xc2028/3028 into poweroff mode.\n");
+	if (debug > 1) {
+		tuner_dbg("Printing sleep stack trace:\n");
+		dump_stack();
+	}
 
 	mutex_lock(&priv->lock);