mboxd: Fix MBOX_C_GET_FLASH_INFO to return size specified on command line

The MBOX_C_GET_FLASH_INFO command is supposed to return the size of the
file which was specified by the "flash" option on the command line. However
currently the actual size of the flash chip its self is being reported.

Fix the MBOX_C_GET_FLASH_INFO command to correctly return the size of the
file rather than the whole flash size.

Change-Id: Ic7425dde8eca187a85e9bcec4084d5abc501c8da
Signed-off-by: Suraj Jitindar Singh <sjitindarsingh@gmail.com>
diff --git a/mboxd.c b/mboxd.c
index 8fdcc2d..8503b49 100644
--- a/mboxd.c
+++ b/mboxd.c
@@ -224,7 +224,7 @@
 			}
 			break;
 		case MBOX_C_GET_FLASH_INFO:
-			put_u32(&resp.msg.data[0], context->mtd_info.size);
+			put_u32(&resp.msg.data[0], context->flash_size);
 			put_u32(&resp.msg.data[4], context->mtd_info.erasesize);
 			resp.msg.response = MBOX_R_SUCCESS;
 			break;