firmware: Enable -Wformat and resolve all related compiler warnings

There have been tons of format-string related bugs in our code which
we never discovered due to disabling -Wformat.  Let's fix that.

Change-Id: I5ec466361bcc526fac1f4897673264ee5af3458b
diff --git a/firmware/libcommon/source/card_emu.c b/firmware/libcommon/source/card_emu.c
index af90351..75910c1 100644
--- a/firmware/libcommon/source/card_emu.c
+++ b/firmware/libcommon/source/card_emu.c
@@ -112,7 +112,7 @@
 #define	_P3	4
 
 struct card_handle {
-	uint32_t num;
+	unsigned int num;
 
 	enum iso7816_3_card_state state;