platform/core/system/dlog.git
4 years agoAdd an --sort-by option to dlogutil 77/224577/6
Mateusz Majewski [Tue, 11 Feb 2020 13:28:07 +0000 (14:28 +0100)]
Add an --sort-by option to dlogutil

Change-Id: I9ea6579af9361abd61315a0296f421bc72d7083f

4 years agoDocumentation: make boxes more boxy 03/221803/5
Michal Bloch [Tue, 7 Jan 2020 12:48:39 +0000 (13:48 +0100)]
Documentation: make boxes more boxy

Change-Id: I86765ca0912acee188bab31b5b3c0509066f827b
Signed-off-by: Michal Bloch <m.bloch@samsung.com>
4 years agoOptimise dumping while using the logger backend 06/225106/9
Mateusz Majewski [Tue, 18 Feb 2020 07:01:37 +0000 (08:01 +0100)]
Optimise dumping while using the logger backend

Change-Id: I78ae67e8800bf8aed962a859f7ccd2afdddbf39f

4 years agoRefactor FDI EOF signalisation 37/225237/3
Mateusz Majewski [Tue, 18 Feb 2020 07:22:10 +0000 (08:22 +0100)]
Refactor FDI EOF signalisation

Change-Id: I235a4176a7b0966f2be46c0088cd062ac0239e81

4 years agoMerge "Port old GCC compatibility from Tizen 5.5" into tizen accepted/tizen/unified/20200219.130224 submit/tizen/20200218.060818
Karol Lewandowski [Fri, 14 Feb 2020 14:23:26 +0000 (14:23 +0000)]
Merge "Port old GCC compatibility from Tizen 5.5" into tizen

4 years agoPort old GCC compatibility from Tizen 5.5 14/225014/1
Michal Bloch [Fri, 14 Feb 2020 13:53:11 +0000 (14:53 +0100)]
Port old GCC compatibility from Tizen 5.5

Change-Id: Id3743dffb81bdace9a29746cec8a3c0eb877a939
Signed-off-by: Michal Bloch <m.bloch@samsung.com>
4 years agoAdd permissions information 77/224677/3
Mateusz Majewski [Wed, 12 Feb 2020 07:54:52 +0000 (08:54 +0100)]
Add permissions information

Change-Id: I17defcb9dc262c63596ec4f0f61fb561182d81e4

4 years agoFix compilation for old GCC 85/224985/1 accepted/tizen/5.5/unified/20200218.150017 accepted/tizen/5.5/unified/20200219.130254 submit/tizen_5.5/20200214.105609 submit/tizen_5.5/20200218.060951
Michal Bloch [Fri, 14 Feb 2020 10:51:32 +0000 (11:51 +0100)]
Fix compilation for old GCC

Change-Id: I5936c466cd6e65bda7421ea8f2df045d3610d745
Signed-off-by: Michal Bloch <m.bloch@samsung.com>
4 years agoRelease 5.5.3: sync with Tizen 6.0.7 83/224983/1 submit/tizen_5.5/20200214.104335
Michal Bloch [Fri, 14 Feb 2020 10:28:16 +0000 (11:28 +0100)]
Release 5.5.3: sync with Tizen 6.0.7

Change-Id: I7fff9f2d60d2cf3deee00cd993380c457f013ade
Signed-off-by: Michal Bloch <m.bloch@samsung.com>
4 years agoRelease 6.0.7 76/224876/1 accepted/tizen/unified/20200214.120111 submit/tizen/20200213.173657
Michal Bloch [Thu, 13 Feb 2020 17:06:44 +0000 (18:06 +0100)]
Release 6.0.7

This release adds critical log rotation and a monitoring mode for dlogutil.

Change-Id: I84a428cda7f09d16e2c2e25ac4b09c83aace2593
Signed-off-by: Michal Bloch <m.bloch@samsung.com>
4 years agoFix coverity bugs 75/224875/2
Agnieszka Baumann [Thu, 13 Feb 2020 16:06:50 +0000 (17:06 +0100)]
Fix coverity bugs

Change-Id: I6eebf286936628452962e18a566092448369febb

4 years agoMerge "[lib]dlogutil: add a monitoring mode" into tizen
Karol Lewandowski [Thu, 13 Feb 2020 16:19:09 +0000 (16:19 +0000)]
Merge "[lib]dlogutil: add a monitoring mode" into tizen

4 years agoCritical logs: introduce rotation 37/223537/14
Michal Bloch [Mon, 3 Feb 2020 15:45:05 +0000 (16:45 +0100)]
Critical logs: introduce rotation

Change-Id: I5afff333ef105c8a13142457bef0cbea3c9c319c
Signed-off-by: Michal Bloch <m.bloch@samsung.com>
4 years agoCritical log: lock the file when handling it 86/223886/10
Michal Bloch [Mon, 3 Feb 2020 13:25:06 +0000 (14:25 +0100)]
Critical log: lock the file when handling it

Change-Id: I09452ab1a84447e8d846444c723cb40bed8fed0a
Signed-off-by: Michal Bloch <m.bloch@samsung.com>
4 years agoUse OOP for the critical log writer 85/223885/8
Michal Bloch [Mon, 3 Feb 2020 13:10:51 +0000 (14:10 +0100)]
Use OOP for the critical log writer

Change-Id: I54303cf2fd9f73487cc1be9519c8ec297e9a2878
Signed-off-by: Michal Bloch <m.bloch@samsung.com>
4 years agoCritical logs: move path default to autoconf 87/223887/10
Michal Bloch [Tue, 4 Feb 2020 11:51:43 +0000 (12:51 +0100)]
Critical logs: move path default to autoconf

Change-Id: Ifc7b88efb4ef764a20e47b0e36e1c634de34e4c0
Signed-off-by: Michal Bloch <m.bloch@samsung.com>
4 years agoCompile critical log writer as C++ 84/223884/6
Michal Bloch [Mon, 3 Feb 2020 11:56:51 +0000 (12:56 +0100)]
Compile critical log writer as C++

Change-Id: I45bfd0d5fe616f1a338fc04f0c0ec1f15fb61517
Signed-off-by: Michal Bloch <m.bloch@samsung.com>
4 years agoRelease 6.0.6 39/224739/2 accepted/tizen/unified/20200213.121535 submit/tizen/20200212.164011 submit/tizen/20200213.025348
Michal Bloch [Wed, 12 Feb 2020 16:37:31 +0000 (17:37 +0100)]
Release 6.0.6

This release fixes a common crash and some other minor bugs.

Change-Id: Id0635cb8ddae217079cd7862cb1c99bfa4bcc9bb
Signed-off-by: Michal Bloch <m.bloch@samsung.com>
4 years agoOptimize out a redundant call 60/224560/2
Michal Bloch [Mon, 10 Feb 2020 17:29:07 +0000 (18:29 +0100)]
Optimize out a redundant call

Change-Id: Ibf9a656712b83435466df431a2c5ab1374666a81
Signed-off-by: Michal Bloch <m.bloch@samsung.com>
4 years agoFix a compiler warning 32/224732/1
Michal Bloch [Wed, 12 Feb 2020 12:14:21 +0000 (13:14 +0100)]
Fix a compiler warning

'strncpy' specified bound equals destination size [-Wstringop-truncation]

Change-Id: Ia3729336ca95a750c08eb89bcc2f657627725b26
Signed-off-by: Michal Bloch <m.bloch@samsung.com>
4 years ago[lib]dlogutil: add a monitoring mode 61/220361/9
Michal Bloch [Mon, 16 Dec 2019 13:21:15 +0000 (14:21 +0100)]
[lib]dlogutil: add a monitoring mode

Change-Id: Ifa07a832e32e1f7e0523823c7150e97a35a8f5e6
Signed-off-by: Michal Bloch <m.bloch@samsung.com>
4 years agoGet rid of useless LINE_MAX macro 27/224727/2
Mateusz Majewski [Wed, 12 Feb 2020 11:22:36 +0000 (12:22 +0100)]
Get rid of useless LINE_MAX macro

Change-Id: If0fd4b3db60586d17d512fff75006b010ecff13e

4 years agoApply consistent comment style 55/224455/3
Michal Bloch [Mon, 10 Feb 2020 16:24:52 +0000 (17:24 +0100)]
Apply consistent comment style

Change-Id: I63467afa521c2072a317f63ce2a79427e9bb6d53
Signed-off-by: Michal Bloch <m.bloch@samsung.com>
4 years agoAdd integration test sanity checks 96/224696/1
Mateusz Majewski [Wed, 12 Feb 2020 08:26:06 +0000 (09:26 +0100)]
Add integration test sanity checks

Change-Id: Ide49b5bea792a929b108495698c1cff00b0fbcbf

4 years agoFix "rwtime" unit tests for the timestamp change 58/224558/1 accepted/tizen/5.5/unified/20200212.125501 submit/tizen_5.5/20200211.112353
Michal Bloch [Tue, 11 Feb 2020 11:20:49 +0000 (12:20 +0100)]
Fix "rwtime" unit tests for the timestamp change

Change-Id: Ic8426033d3e34b78869b760d7040165a9af0e5da
Signed-off-by: Michal Bloch <m.bloch@samsung.com>
(cherry picked from commit 602976f0145106f217da7f5e2b80b1c692f3d699)

4 years agoFix "rwtime" unit tests for the timestamp change 57/224557/1
Michal Bloch [Tue, 11 Feb 2020 11:20:49 +0000 (12:20 +0100)]
Fix "rwtime" unit tests for the timestamp change

Change-Id: Ic8426033d3e34b78869b760d7040165a9af0e5da
Signed-off-by: Michal Bloch <m.bloch@samsung.com>
4 years agoRestore kmsg time format as 'rwtime' 56/224556/1
Hyotaek Shim [Tue, 11 Feb 2020 07:04:05 +0000 (16:04 +0900)]
Restore kmsg time format as 'rwtime'

Change-Id: I8d561fdfdf39f79ff5dd49b478b72b1458f402f7
Signed-off-by: Hyotaek Shim <hyotaek.shim@samsung.com>
(cherry picked from commit 3d2673186770d4b50ea8ff33cec7f14284db26f1)

4 years agoFix "rwtime" format to use SENT mono timestamp 55/224555/1
Michal Bloch [Tue, 11 Feb 2020 11:10:40 +0000 (12:10 +0100)]
Fix "rwtime" format to use SENT mono timestamp

Reverts a change introduced in 0652433919dc6018cd7769d33e78bbd20d16138e.

Change-Id: I6dbe9fac4531ffaeba282f5c3271c72884ed8452
Signed-off-by: Michal Bloch <m.bloch@samsung.com>
(cherry picked from commit b32cc43573473f08907751371552ba93a4257fbe)

4 years agoRestore kmsg time format as 'rwtime' 13/224513/4
Hyotaek Shim [Tue, 11 Feb 2020 07:04:05 +0000 (16:04 +0900)]
Restore kmsg time format as 'rwtime'

Change-Id: I8d561fdfdf39f79ff5dd49b478b72b1458f402f7
Signed-off-by: Hyotaek Shim <hyotaek.shim@samsung.com>
4 years agoFix "rwtime" format to use SENT mono timestamp 54/224554/2
Michal Bloch [Tue, 11 Feb 2020 11:10:40 +0000 (12:10 +0100)]
Fix "rwtime" format to use SENT mono timestamp

Reverts a change introduced in 0652433919dc6018cd7769d33e78bbd20d16138e.

Change-Id: I6dbe9fac4531ffaeba282f5c3271c72884ed8452
Signed-off-by: Michal Bloch <m.bloch@samsung.com>
4 years agoFix various SVACE complaints 47/224547/2
Mateusz Majewski [Tue, 11 Feb 2020 10:09:19 +0000 (11:09 +0100)]
Fix various SVACE complaints

Change-Id: I910508371c5c728b00aec5c749fb11c8526a1bfb

4 years agoAdd various log_format tests 48/224548/2
Mateusz Majewski [Tue, 11 Feb 2020 09:35:40 +0000 (10:35 +0100)]
Add various log_format tests

Change-Id: I197addc62f7aec55722f3d44aa1f4a59fc10a730

4 years agoReduce warnings for -pedantic clients 28/224128/2
Michal Bloch [Thu, 6 Feb 2020 10:30:54 +0000 (11:30 +0100)]
Reduce warnings for -pedantic clients

ISO C does not permit named variadic macros

Change-Id: I88c7cbfe094b8f054622ac847240155dfe0cd99c
Signed-off-by: Michal Bloch <m.bloch@samsung.com>
4 years agoMerge "Fix empty message formatting" into tizen
Karol Lewandowski [Mon, 10 Feb 2020 13:23:58 +0000 (13:23 +0000)]
Merge "Fix empty message formatting" into tizen

4 years agoMerge "Document confusing daemon structures" into tizen
Karol Lewandowski [Mon, 10 Feb 2020 13:23:50 +0000 (13:23 +0000)]
Merge "Document confusing daemon structures" into tizen

4 years agoRemove unused variables 10/224410/2
Michal Bloch [Mon, 10 Feb 2020 11:20:58 +0000 (12:20 +0100)]
Remove unused variables

Change-Id: Icec5002e1b1cb1845021bf7d79fa6b9e859938fc

4 years agoUse TEMP_FAILURE_RETRY instead of manual looping 98/224398/2
Mateusz Majewski [Mon, 10 Feb 2020 07:59:43 +0000 (08:59 +0100)]
Use TEMP_FAILURE_RETRY instead of manual looping

Change-Id: I84f1d39a1180c428f5ecbfc8ec959b9db0d60577

4 years agoClarify the a && b || c && d type expression with parens 09/224409/2
Mateusz Majewski [Mon, 10 Feb 2020 08:34:03 +0000 (09:34 +0100)]
Clarify the a && b || c && d type expression with parens

As suggested by -Wall.

Change-Id: Ifd6316a637542cd88aa4f115dcb2b62af38dc36e

4 years agoAdd some libdlogutil negative tests 07/224307/2
Mateusz Majewski [Mon, 27 Jan 2020 13:46:43 +0000 (14:46 +0100)]
Add some libdlogutil negative tests

Change-Id: I7fc0aef2e522ae1a997399fb318b448a55c0a237

4 years agoFail on no buffers passed 85/224385/1
Mateusz Majewski [Mon, 10 Feb 2020 07:03:02 +0000 (08:03 +0100)]
Fail on no buffers passed

Change-Id: I2b7957c620fcd78507a4155de81a34036711009c

4 years agoChange -ENOTSUP to TIZEN_ERROR_NOT_SUPPORTED 06/224306/1
Mateusz Majewski [Fri, 31 Jan 2020 15:11:41 +0000 (16:11 +0100)]
Change -ENOTSUP to TIZEN_ERROR_NOT_SUPPORTED

This is actually a behavior change, since the both values are actually
not equal.

Change-Id: I4239f42ee2553c22095aa9bda02721b0489ff1d6

4 years agoAdd exit code propagation to the integration tests 78/224278/2 accepted/tizen/unified/20200210.131809 submit/tizen/20200207.103010
Mateusz Majewski [Fri, 7 Feb 2020 09:37:49 +0000 (10:37 +0100)]
Add exit code propagation to the integration tests

Now, if any of the tests fails, the dlog_test script will return a
nonzero error code. You can use this, for example, to execute
`dlog_test pipe && dlog_test logger`.

Note that, if you are using SDB, running `sdb shell dlog_test pipe` or a
similar command will NOT pass the exit code to the local shell. This is
because SDB always returns 0 as the exit code, no matter what was the
code of the underlying command; the nonzero exit codes are reserved for,
for example, connection failures.

Change-Id: I935ad63170ce7e02d27b496d1cf62f8c755bc3ab

4 years agoAdd various libdlogutil filterspec tests 70/224270/1
Mateusz Majewski [Fri, 7 Feb 2020 08:24:11 +0000 (09:24 +0100)]
Add various libdlogutil filterspec tests

Change-Id: I12ab4b598142670e4c30fa35063261f41241e13f

4 years agoChange dlog_logger options to increase the size of log backup files 74/224174/4
Hyotaek Shim [Fri, 7 Feb 2020 01:53:23 +0000 (10:53 +0900)]
Change dlog_logger options to increase the size of log backup files

Change-Id: Ib68c769d8edc38a55c9965e8e0b8da74547ca79f
Signed-off-by: Hyotaek Shim <hyotaek.shim@samsung.com>
4 years agoChange dlog_logger options to increase the size of log backup files 93/224193/1 accepted/tizen/5.5/unified/20200210.131633 submit/tizen_5.5/20200207.111014
Hyotaek Shim [Fri, 7 Feb 2020 01:53:23 +0000 (10:53 +0900)]
Change dlog_logger options to increase the size of log backup files

Change-Id: Ib68c769d8edc38a55c9965e8e0b8da74547ca79f
Signed-off-by: Hyotaek Shim <hyotaek.shim@samsung.com>
(cherry picked from commit 7005a42682bab02a332da46e7a1fa28684c290cc)

4 years agoDocument confusing daemon structures 58/224158/2
Michal Bloch [Thu, 6 Feb 2020 15:57:09 +0000 (16:57 +0100)]
Document confusing daemon structures

Change-Id: I48ce2d790538f4228cf362565841e9b10508b588
Signed-off-by: Michal Bloch <m.bloch@samsung.com>
4 years agoFix empty message formatting 29/224029/1
Michal Bloch [Wed, 5 Feb 2020 17:50:49 +0000 (18:50 +0100)]
Fix empty message formatting

Change-Id: I115dd269933435300e1a5bbff8578795fd6b0850
Signed-off-by: Michal Bloch <m.bloch@samsung.com>
4 years agoImprove filter tests 20/224020/1
Mateusz Majewski [Wed, 5 Feb 2020 12:35:24 +0000 (13:35 +0100)]
Improve filter tests

Change-Id: Id8b56bf3db4ceef43a8df61fc54a432912c111b8

4 years agoAdd tests for tag filtering 19/224019/1
Mateusz Majewski [Wed, 5 Feb 2020 12:19:59 +0000 (13:19 +0100)]
Add tests for tag filtering

To make sure I won't break it ever again.

Change-Id: Ie0f9a56d9692bf09ff288975de454060e6d09c33

4 years agoMake the FDI creation check more strict 81/223981/2
Mateusz Majewski [Wed, 5 Feb 2020 07:21:55 +0000 (08:21 +0100)]
Make the FDI creation check more strict

Change-Id: I4d2ca0aaf12e451cb13ce4288046863daa3127ca

4 years agoAdd colorful output integration tests 49/223749/5
Mateusz Majewski [Thu, 16 Jan 2020 07:02:14 +0000 (08:02 +0100)]
Add colorful output integration tests

Change-Id: I40fa224bf367908a3850875d25c2892e9e09ef0e

4 years agoRelease 6.0.5 12/224012/1 submit/tizen/20200205.113321
Karol Lewandowski [Wed, 5 Feb 2020 11:16:06 +0000 (12:16 +0100)]
Release 6.0.5

This release rewrite of dlogutil to use libdlogutil and numerous bugfixes.

Change-Id: I4dca1823a6a3b33b33c7b0825bb727509ee326e3

4 years agoAdd KMSG integration test 45/223745/3
Mateusz Majewski [Mon, 3 Feb 2020 14:43:10 +0000 (15:43 +0100)]
Add KMSG integration test

Change-Id: Id41b5091cc7a9cfa6a74a712e01310e80fcce958

4 years agoFix the handling of KMSG with regard to timestamps 24/223324/2
Michal Bloch [Tue, 28 Jan 2020 17:05:14 +0000 (18:05 +0100)]
Fix the handling of KMSG with regard to timestamps

Change-Id: I62542b352439f4447139fcd4cdd74a3e01da8e8f
Signed-off-by: Michal Bloch <m.bloch@samsung.com>
4 years agoFix libdlogutil tag filtering 02/224002/3
Mateusz Majewski [Wed, 5 Feb 2020 09:22:04 +0000 (10:22 +0100)]
Fix libdlogutil tag filtering

It turns out that it never worked in first place! :(

There was a tiny logical error in translation of dlogutil code into
libdlogutil; namely, dlogutil added the "*:D" at the end if no other
filterspec was added. Obviously I, not knowing how filterspec works,
decided that it would be equivalent to add it at the beginning no matter
if there are any other filterspec. This assumption is hiliarously wrong,
and now needs to be fixed.

Change-Id: I8496e3a4e248bd060d82ab5814e9b439bc2212b7

4 years agoFix log_filter_from_filter 01/224001/2
Mateusz Majewski [Wed, 5 Feb 2020 10:18:55 +0000 (11:18 +0100)]
Fix log_filter_from_filter

Change-Id: I7609bf7d586b66109bcf7f905295f647bcaf5ffe

4 years agoFix the sed command 59/223959/1
Mateusz Majewski [Wed, 5 Feb 2020 07:21:55 +0000 (08:21 +0100)]
Fix the sed command

This command used to be wrong because it contains a star. When shell
sees the star, it expands it, which is very wrong in our case. The test
somehow still passes, but sed spams the error message on the stderr,
which is unhelpful while debugging.

Change-Id: Ief9666698b7163e6b332bb5c7535cc6814abd50e

4 years agoEnable returning TIZEN_ERROR_INVALID_PARAMETERS on invalid params instead of assertin... 09/223209/9
Mateusz Majewski [Mon, 27 Jan 2020 11:26:57 +0000 (12:26 +0100)]
Enable returning TIZEN_ERROR_INVALID_PARAMETERS on invalid params instead of asserting them

Change-Id: I9754699e774b4b3de8a166063bb9b44b52c3bf06

4 years agoCritical logs: move to /var/log/dlog 14/223314/4
Michal Bloch [Tue, 28 Jan 2020 11:30:13 +0000 (12:30 +0100)]
Critical logs: move to /var/log/dlog

The writer binary now has the 'System' smack label to allow this.

Change-Id: I2f8486c02caa2e45cff5594b19d3155919ddd1e9
Signed-off-by: Michal Bloch <m.bloch@samsung.com>
4 years agoCritical logs: avoid leaving zombie processes 52/223652/5
Michal Bloch [Fri, 31 Jan 2020 12:51:45 +0000 (13:51 +0100)]
Critical logs: avoid leaving zombie processes

libdlog doesn't really want to wait for the writer child process,
so now it leaves reaping it to init through the double fork idiom,
where the worker process is actually a grandchild and the immediate
child exists just to die and be reaped immediately.

Change-Id: I7a5c903f55b0ccd0f56824a228ee69f21ed87cac
Signed-off-by: Michal Bloch <m.bloch@samsung.com>
4 years agoCritical logs: less fragile unit tests 58/223658/2
Michal Bloch [Fri, 31 Jan 2020 16:26:01 +0000 (17:26 +0100)]
Critical logs: less fragile unit tests

Change-Id: I826970a7a13c89051ca2dd18689ea001e2722632
Signed-off-by: Michal Bloch <m.bloch@samsung.com>
4 years agoChange time option for dlog_logger (recv_realtime -> threadtime) 36/223736/1 accepted/tizen/5.5/unified/20200205.014428 submit/tizen_5.5/20200204.002631
Hyotaek Shim [Mon, 3 Feb 2020 04:50:20 +0000 (13:50 +0900)]
Change time option for dlog_logger (recv_realtime -> threadtime)

Change-Id: I3ef8c23721cec38a555da5b090af9c6173544b21
Signed-off-by: Hyotaek Shim <hyotaek.shim@samsung.com>
(cherry picked from commit c40fbeb4ffd0dd45f3aef3abb7b4119cba4f0c84)

4 years agoChange time option for dlog_logger (recv_realtime -> threadtime) 81/223681/3 accepted/tizen/unified/20200204.125829 submit/tizen/20200203.104325
Hyotaek Shim [Mon, 3 Feb 2020 04:50:20 +0000 (13:50 +0900)]
Change time option for dlog_logger (recv_realtime -> threadtime)

Change-Id: I3ef8c23721cec38a555da5b090af9c6173544b21
Signed-off-by: Hyotaek Shim <hyotaek.shim@samsung.com>
4 years agokmsg passive logs: use the same timestamp as dmesg 76/223676/1 submit/tizen_5.5/20200131.024742
Michal Bloch [Fri, 31 Jan 2020 10:35:18 +0000 (11:35 +0100)]
kmsg passive logs: use the same timestamp as dmesg

Change-Id: If93482f353f05f3870ff906d96cae9d60edeffee
Signed-off-by: Michal Bloch <m.bloch@samsung.com>
(cherry picked from commit 68eed0d59a96327dfbffe8e845ed8a6cf169db4b)

4 years agoFix the docs a bit 57/223657/1
Mateusz Majewski [Fri, 31 Jan 2020 15:43:28 +0000 (16:43 +0100)]
Fix the docs a bit

Change-Id: Ief7de9cad5383f3d8058771a5630653c0445fd35

4 years agokmsg passive logs: use the same timestamp as dmesg 31/223631/1
Michal Bloch [Fri, 31 Jan 2020 10:35:18 +0000 (11:35 +0100)]
kmsg passive logs: use the same timestamp as dmesg

Change-Id: If93482f353f05f3870ff906d96cae9d60edeffee
Signed-off-by: Michal Bloch <m.bloch@samsung.com>
4 years agoMove non-shared files out of shared/ directory 81/217981/28
Mateusz Majewski [Thu, 19 Dec 2019 08:21:34 +0000 (09:21 +0100)]
Move non-shared files out of shared/ directory

Some files have been moved to the shared directory during the
libdlogutil refactor. But now dlogutil, having been rewritten to use
libdlogutil, doesn't have to use those files anymore. Therefore,
libdlogutil is the only user of those files, and so they belong in the
libdlogutil directory.

Change-Id: If9f2728f33f92b4b25d8380245a0c06d745541d0

4 years agoCheck impossible situations more aggressively 94/222594/5
Michal Bloch [Wed, 15 Jan 2020 16:53:39 +0000 (17:53 +0100)]
Check impossible situations more aggressively

Our locks cannot ever fail so using an assert both
better represents our confidence and improves runtime
performance for release builds.

Expands upon 7b74b02574fbc5065f6a7de31de49e73916044c3

Change-Id: I88a8ee8056d0b5a81b9f99da01bf2376e216d428
Signed-off-by: Michal Bloch <m.bloch@samsung.com>
4 years agotests: exclude arg parsing 07/218807/6
Michal Bloch [Mon, 27 Jan 2020 16:56:29 +0000 (17:56 +0100)]
tests: exclude arg parsing

Belongs to integration tests

Change-Id: I1c26dddd73dbc0434479aa9244110cc63484f062
Signed-off-by: Michal Bloch <m.bloch@samsung.com>
4 years agoRewrite dlogutil in terms of libdlogutil 18/217718/30
Mateusz Majewski [Mon, 20 Jan 2020 12:41:15 +0000 (13:41 +0100)]
Rewrite dlogutil in terms of libdlogutil

Change-Id: I0c089c19bbf0af661a232e1ab0b82f3686ca8838

4 years agolibdlogutil: DLOGUTIL_MODE_FULL_DUMP is not a mode 01/223301/2
Michal Bloch [Mon, 27 Jan 2020 16:32:28 +0000 (17:32 +0100)]
libdlogutil: DLOGUTIL_MODE_FULL_DUMP is not a mode

Change-Id: Ia7bfd8d14b2f742edda14bc58d5eb5bde5163c79
Signed-off-by: Michal Bloch <m.bloch@samsung.com>
4 years agoSlightly refactor EXPORTing the API 13/223213/3
Mateusz Majewski [Mon, 27 Jan 2020 10:46:53 +0000 (11:46 +0100)]
Slightly refactor EXPORTing the API

Change-Id: I6db009bc4a9f526031e8d6b82e83f85c5bb50e21

4 years agologger: separate args parsing from config parsing 06/218806/5
Michal Bloch [Wed, 27 Nov 2019 12:07:05 +0000 (13:07 +0100)]
logger: separate args parsing from config parsing

Change-Id: I3878f696ee702b9c55971392840c4d8eac2f83b1
Signed-off-by: Michal Bloch <m.bloch@samsung.com>
4 years agoAdd JSON integration test 02/222502/4
Mateusz Majewski [Wed, 15 Jan 2020 15:46:27 +0000 (16:46 +0100)]
Add JSON integration test

Change-Id: If510047fad0a1f930a0e1e1617dc1e7db8d4ed0f

4 years agodlogutil: make error message syntax consistent 24/223224/1
Michal Bloch [Mon, 27 Jan 2020 14:34:21 +0000 (15:34 +0100)]
dlogutil: make error message syntax consistent

Change-Id: I03d1b4612db9f665b227c68de5e738b8c2149879
Signed-off-by: Michal Bloch <m.bloch@samsung.com>
4 years agoClarify the manpage reference 18/223218/3
Mateusz Majewski [Mon, 27 Jan 2020 13:29:04 +0000 (14:29 +0100)]
Clarify the manpage reference

Change-Id: I141afafd2260bcb2fa86472ac4e9012ddc437d96

4 years agoClarify TID/PID errors 17/223217/2
Mateusz Majewski [Mon, 27 Jan 2020 13:15:42 +0000 (14:15 +0100)]
Clarify TID/PID errors

Change-Id: I3039ea871f1cdcc0f03c757ee1f94f377530217e

4 years agolibdlogutil: type consistency 12/223212/2
Michal Bloch [Fri, 24 Jan 2020 13:48:17 +0000 (14:48 +0100)]
libdlogutil: type consistency

`unsigned int` is used everywhere else.

Change-Id: I991be1bc16965772dc8d6f2a0b4a4e9f7a885160
Signed-off-by: Michal Bloch <m.bloch@samsung.com>
4 years agoDecrease magic amount 08/223208/1
Mateusz Majewski [Fri, 24 Jan 2020 07:34:14 +0000 (08:34 +0100)]
Decrease magic amount

Change-Id: If4b3942f25080442df372f08f49bd33ac51694c6

4 years agoMinor libdlogutil documentation clarification 71/223171/2
Mateusz Majewski [Fri, 24 Jan 2020 07:21:51 +0000 (08:21 +0100)]
Minor libdlogutil documentation clarification

Change-Id: I4bafb349eff49a6a3e14d980d4887e8e4adc751b

4 years agoRelease 6.0.4 89/223189/1 accepted/tizen/unified/20200129.022642 submit/tizen/20200124.122926
Michal Bloch [Fri, 24 Jan 2020 11:50:11 +0000 (12:50 +0100)]
Release 6.0.4

This release adds the critical logging functionality.

Change-Id: I90b479d53aed2d8dea84ea1c4bcc3a4e554fd57f
Signed-off-by: Michal Bloch <m.bloch@samsung.com>
4 years agotests: solve some coverage regressions 36/222736/3
Michal Bloch [Thu, 16 Jan 2020 10:03:27 +0000 (11:03 +0100)]
tests: solve some coverage regressions

Change-Id: I8dd82a6ba2da72db797db62f1d71d9fdd8c67572
Signed-off-by: Michal Bloch <m.bloch@samsung.com>
4 years agotests: fix scandirat wrapping 88/223188/3
Michal Bloch [Fri, 24 Jan 2020 11:20:31 +0000 (12:20 +0100)]
tests: fix scandirat wrapping

Change-Id: I381d623749ddc90deb2ddad7d828dbbc20c160df
Signed-off-by: Michal Bloch <m.bloch@samsung.com>
4 years agoMerge "Create the critical log file at package install" into tizen
Karol Lewandowski [Fri, 24 Jan 2020 11:26:55 +0000 (11:26 +0000)]
Merge "Create the critical log file at package install" into tizen

4 years agoMerge changes into tizen
Karol Lewandowski [Fri, 24 Jan 2020 11:26:55 +0000 (11:26 +0000)]
Merge changes  into tizen

4 years agoMerge changes from topic "kritzkrieg" into tizen
Karol Lewandowski [Fri, 24 Jan 2020 11:26:55 +0000 (11:26 +0000)]
Merge changes from topic "kritzkrieg" into tizen

* changes:
  Create the critical log writer program
  logsend: add -k option for critical logs

4 years agoCreate the critical log file at package install 63/223163/1
Michal Bloch [Thu, 23 Jan 2020 11:26:30 +0000 (12:26 +0100)]
Create the critical log file at package install

Change-Id: I089dec6c016c924237f550e5e7a01dbea54d9733
Signed-off-by: Michal Bloch <m.bloch@samsung.com>
4 years agoCreate the critical log writer program 41/222841/6
Michal Bloch [Mon, 20 Jan 2020 14:11:46 +0000 (15:11 +0100)]
Create the critical log writer program

Change-Id: I079979b8ca1a369ad24327b7219e2556d819f71d
Signed-off-by: Michal Bloch <m.bloch@samsung.com>
4 years agologsend: add -k option for critical logs 42/222842/5
Michal Bloch [Mon, 20 Jan 2020 14:51:50 +0000 (15:51 +0100)]
logsend: add -k option for critical logs

Change-Id: I4b6a69d73eb14fa17c676aeadad490df83b981a5
Signed-off-by: Michal Bloch <m.bloch@samsung.com>
4 years agolibdlog: add __dlog_critical_print to the API 38/222738/11
Michal Bloch [Fri, 17 Jan 2020 12:08:52 +0000 (13:08 +0100)]
libdlog: add __dlog_critical_print to the API

Still requires the special privileged logging program,
so doesn't yet do anything.

Change-Id: Id1195957592f0fa475cf8f9482b5edd8b2bc04fe
Signed-off-by: Michal Bloch <m.bloch@samsung.com>
4 years agoMake the libdlogutil sorting test actually test something 46/223146/2
Mateusz Majewski [Mon, 20 Jan 2020 13:30:01 +0000 (14:30 +0100)]
Make the libdlogutil sorting test actually test something

-.-

Change-Id: I15b38f7fb41ad950ae75b78cee5666e9820f6d1b

4 years agoImprove some test signatures 40/222840/2
Mateusz Majewski [Mon, 20 Jan 2020 12:41:01 +0000 (13:41 +0100)]
Improve some test signatures

Change-Id: I2ac0b8f6f8848d76ca3e4d5217a26ef6efced9b5

4 years agoMove priority / char mapping to logcommon 39/222739/3
Michal Bloch [Fri, 17 Jan 2020 13:13:45 +0000 (14:13 +0100)]
Move priority / char mapping to logcommon

Change-Id: I65206d11e943f4d4aea02c38ebeccf7a7927eb25
Signed-off-by: Michal Bloch <m.bloch@samsung.com>
4 years agoRelease 6.0.3 40/222740/1 accepted/tizen/unified/20200121.121505 submit/tizen/20200117.161457 submit/tizen/20200120.091007
Karol Lewandowski [Fri, 17 Jan 2020 15:53:44 +0000 (16:53 +0100)]
Release 6.0.3

This release brings addion of libdlogutil - library and API.

Change-Id: I4b7742ffe58b1090f6ee042a58001850d0df8008

4 years agoImplement the first version of the libdlogutil library 97/214497/75
Mateusz Majewski [Fri, 25 Oct 2019 06:24:44 +0000 (08:24 +0200)]
Implement the first version of the libdlogutil library

Change-Id: I2bf179f93df97e157a625c3538d6c9ddefa1e68b

4 years agoMerge "Filterspec get/setters: conform to Tizen API style" into tizen
Michal Bloch [Fri, 17 Jan 2020 10:35:17 +0000 (10:35 +0000)]
Merge "Filterspec get/setters: conform to Tizen API style" into tizen

4 years agoFilterspec get/setters: conform to Tizen API style 05/222305/6
Mateusz Majewski [Mon, 13 Jan 2020 10:10:23 +0000 (11:10 +0100)]
Filterspec get/setters: conform to Tizen API style

Change-Id: I265d5e7b2891b70a6d964f0409b13c18e0154c46

4 years agoEntry getters return error code 99/222299/7
Michal Bloch [Mon, 13 Jan 2020 09:28:04 +0000 (10:28 +0100)]
Entry getters return error code

And return the actual thing through a parameter.
This is the Tizen API style.

Change-Id: Ibf4056a3d3a70c4c27de0b9bf5534c4bb575628c

4 years agoRemove DLOGUTIL_SORT_MAX 98/222298/5
Michal Bloch [Mon, 13 Jan 2020 09:17:48 +0000 (10:17 +0100)]
Remove DLOGUTIL_SORT_MAX

Only used in a test and is unwanted in an API

Change-Id: Ic186c6de6150bc004c5033469a3efe2f44c52901

4 years agoChange some `size_t` to `unsigned int` 96/222296/7
Mateusz Majewski [Mon, 13 Jan 2020 08:54:36 +0000 (09:54 +0100)]
Change some `size_t` to `unsigned int`

Tizen interfaces are fairly consistent in only using `size_t` when the
variable represents the size of some object in bytes. Therefore we're
changing our variables away from `size_t` as they represent the number
of objects.

Change-Id: I7e9b0a66d51ad1ca0114387d8dbc40914f605138