summaryrefslogtreecommitdiffstats
path: root/drivers/misc/mei/client.h
diff options
context:
space:
mode:
authorAlexander Usyskin <alexander.usyskin@intel.com>2013-09-15 18:11:07 +0300
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2013-09-26 08:39:27 -0700
commitc0abffbd982ccf9460187206a074e52cb23e8be3 (patch)
tree131fcbc33f58ce635bf8e4cf5160d8d14c26bb6c /drivers/misc/mei/client.h
parenta9c8a17aea8ced19598b388db618e9094f3c1245 (diff)
mei: prefix client log messages with client me and host ids
define cl_dbg and cl_err macros that add me and host id prefix for debug and error log messages so we can track for the client context of the flow. Signed-off-by: Alexander Usyskin <alexander.usyskin@intel.com> Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/misc/mei/client.h')
-rw-r--r--drivers/misc/mei/client.h9
1 files changed, 9 insertions, 0 deletions
diff --git a/drivers/misc/mei/client.h b/drivers/misc/mei/client.h
index 9eb031e9207..6374ed99e23 100644
--- a/drivers/misc/mei/client.h
+++ b/drivers/misc/mei/client.h
@@ -109,4 +109,13 @@ void mei_cl_all_disconnect(struct mei_device *dev);
void mei_cl_all_wakeup(struct mei_device *dev);
void mei_cl_all_write_clear(struct mei_device *dev);
+#define MEI_CL_FMT "cl:host=%02d me=%02d "
+#define MEI_CL_PRM(cl) (cl)->host_client_id, (cl)->me_client_id
+
+#define cl_dbg(dev, cl, format, arg...) \
+ dev_dbg(&(dev)->pdev->dev, MEI_CL_FMT format, MEI_CL_PRM(cl), ##arg)
+
+#define cl_err(dev, cl, format, arg...) \
+ dev_err(&(dev)->pdev->dev, MEI_CL_FMT format, MEI_CL_PRM(cl), ##arg)
+
#endif /* _MEI_CLIENT_H_ */