fix Linaro compiler warnings/error issues

Change-Id: I8c9a1fb3f433e481ad1f48336379c94c4d3f334e