checkpatch expects typedefs to be suffixed with _t and has different
rules when typedefs are being used as arguments of a function. This
seems to be a known issue and defining typedefs in a file resolves this
issue.
Signed-off-by: Anas Nashif <anas.nashif@intel.com>