Commit Graph

11 Commits

Author SHA1 Message Date
Daniel Verkamp
b58a5d73ef util: add SPDK_COUNTOF() array size macro
SPDK_COUNTOF works like sizeof, except it returns the number of elements
in an array instead of the number of bytes.

Change-Id: I38ff4dd3485ed9b630cc5660ff84851d0031911f
Signed-off-by: Daniel Verkamp <daniel.verkamp@intel.com>
2017-03-07 12:43:42 -07:00
Tsuyoshi Uchida
5ee4728d0c log: define prioritynames[] (#102) 2017-01-23 16:07:29 -07:00
Tsuyoshi Uchida
950b48de61 log: use facilitynames to set/get log facility (#81)
* log: use facilitynames to set/get log facility

Define our own facilitynames[] instead of defining SYSLOG_NAMES
2017-01-17 11:20:34 -07:00
Daniel Verkamp
c454900960 log: print trace flag names in SPDK_TRACELOG()
Change-Id: I962ee098818f48563e67f9b4214bc3519eee48b4
Signed-off-by: Daniel Verkamp <daniel.verkamp@intel.com>
2016-11-28 13:15:08 -07:00
Daniel Verkamp
d27b24c94b log: split internal TRACELOG macro into new header
The SPDK_TRACELOG macro depends on a CONFIG setting (DEBUG), so it
should not be part of the public API.

Create a new include/spdk_internal directory for headers that should
only be used within SPDK, not exported for public use.

Change-Id: I39b90ce57da3270e735ba32210c4b3a3468c460b
Signed-off-by: Daniel Verkamp <daniel.verkamp@intel.com>
2016-11-16 13:33:51 -07:00
Krzysztof Jakimiak
25749728b6 spdk: tweak tracedump
Increased printed data width, added data offset indices.

Change-Id: I44f81396e33870109c2bece5e152657f8a24a56a
Signed-off-by: Krzysztof Jakimiak <krzysztof.jakimiak@intel.com>
2016-10-05 09:40:21 -07:00
Daniel Verkamp
20bee521a6 log: dynamically generate usage for -t option
Change-Id: I8c709b507c4cb00092d5dc9b1e8ca1c0fe880b02
Signed-off-by: Daniel Verkamp <daniel.verkamp@intel.com>
2016-08-22 16:57:19 -07:00
Daniel Verkamp
0cb9522781 build: include spdk.common.mk in lib Makefiles
Explicitly include spdk.common.mk at the top of all lib Makefiles so
that CONFIG options and other predefined variables are set.

Change-Id: I1e560c294fe8242602e45191a280f4295533ae44
Signed-off-by: Daniel Verkamp <daniel.verkamp@intel.com>
2016-07-18 16:17:40 -07:00
Ben Walker
44d131105e log: Add a lib for integrating the log lib with event framework.
Linking this library into an application makes the log
configurable via RPC. This only works if the rpc subsystem
is also loaded.

Change-Id: If1340cf2a845ef159290232c26f341150c98fb9a
Signed-off-by: Ben Walker <benjamin.walker@intel.com>
2016-07-13 10:13:48 -07:00
Daniel Verkamp
8f4ef2a843 log: allow setting all trace flags at once
Add a special "all" trace flag name to set or clear all registered trace
flags.

Change-Id: Ib579df7c41ce4aca72174e04734df20f2752035c
Signed-off-by: Daniel Verkamp <daniel.verkamp@intel.com>
2016-05-12 09:47:57 -07:00
Daniel Verkamp
aaa533adc7 log: add SPDK logging library
Change-Id: I3d4060b619a3976ffff75c05f86214e3fcd18fb5
Signed-off-by: Daniel Verkamp <daniel.verkamp@intel.com>
2016-05-09 15:54:49 -07:00