Kichan Kwon [Thu, 29 Dec 2016 02:44:59 +0000 (11:44 +0900)]
Replace strerror_r() to '%m'.
- strerror_r() always need additional buffer
- We don't have to declare buffer by using '%m'
Change-Id: I326a306d15b1d74360b4264ff99024b5b7a6fb43
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Fri, 13 Jan 2017 02:05:52 +0000 (11:05 +0900)]
Merge branch 'tizen_3.0' into tizen
Change-Id: I6fcfd62968c45276ba202605f73f000c685af1a3
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Thu, 5 Jan 2017 06:27:45 +0000 (15:27 +0900)]
heart : fix argument
Change-Id: Ib8a342468847a5a9ff412cfcd98fcd94a18a8a04
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Wed, 4 Jan 2017 05:27:51 +0000 (14:27 +0900)]
heart : sync thread no more reply D-Bus message
- D-Bus methods using same path are not thread-safe
- Sync thread will invoke main thread to finish its work by using pipe
Change-Id: I81f917a7abc905aa483b19e465564012744f4e5d
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Thu, 29 Dec 2016 04:25:14 +0000 (13:25 +0900)]
Merge branch 'tizen_3.0' into tizen
Change-Id: I9c66ded00e187a68b52c13334dc6c1732d1b0933
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Tue, 27 Dec 2016 01:05:57 +0000 (10:05 +0900)]
heart : pull out DB size checking statement
Change-Id: I0e420c64c14bbcb8864d6509bf6172ab3c04b4f5
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Wed, 21 Dec 2016 08:25:20 +0000 (17:25 +0900)]
Fix timing issues
- No more use constructor for userinfo-list
- When resourced starts, gumd may not be ready
- No more create user DB after initialization
- There is no scenario about new user
- Unify update and data threads
- These threads can access DB simultaneously
Change-Id: I119c33b138cfb62c30f03b9ecc5b9e7538842a83
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Wed, 21 Dec 2016 08:10:31 +0000 (17:10 +0900)]
heart : add dbus method about HEART-CPU sync
- org.tizen.resourced.logging.SyncCpuData
- It will update cache and write into the DB
- Return value : 0(success), -1(fail), TID(running)
Change-Id: Ic7fc4b8f3dc86a4b6ccd38ee1db7e2789b8e9589
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Tue, 20 Dec 2016 06:35:17 +0000 (15:35 +0900)]
Check memory allocation failure
- In addition, repeated error code is removed
Change-Id: I34a21445a5cffe07c1a44c83b457c47b614f9de0
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Fri, 16 Dec 2016 04:45:09 +0000 (13:45 +0900)]
proc-stat : create app info only if both appid and pkgid are existed
- Each app should have appid and pkgid
Change-Id: Ibc3ba0b9a30ae184d373ee5c7bdba6783e28d68d
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Wed, 14 Dec 2016 06:25:03 +0000 (15:25 +0900)]
Improve stability
- No more update user list when it is needed
- In current, there is no scenario about adding new users
- Wait data thread for writing before storing to HEART DB
- Remove program list of subordinated app
- Check array size before remove it
Change-Id: If08ad5b55faf1103f20c2f2d379b5d7dc53d9f98
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kunhoon Baik [Wed, 14 Dec 2016 14:26:33 +0000 (23:26 +0900)]
Allow ProcExclude signal without privilege
- To allow the request of Minicontroller
Rollback to original Mr.Kwon's patch : https://review.tizen.org/gerrit/#/c/103884/1
Change-Id: I1d6043c8388c14bdf636157288922dc6df2a3a24
Kunhoon Baik [Wed, 14 Dec 2016 13:59:44 +0000 (05:59 -0800)]
Merge "Revert "Allow ProcExclude signal without privilege"" into tizen_3.0
Kunhoon Baik [Wed, 14 Dec 2016 13:57:00 +0000 (05:57 -0800)]
Revert "Allow ProcExclude signal without privilege"
This reverts commit
73b906e4714db967fa6438260c3fa020e67d71a7.
Change-Id: I92b71689d87c4541aa4933aaecb19ed2f14d1255
Kichan Kwon [Wed, 7 Dec 2016 11:20:05 +0000 (20:20 +0900)]
Fix memory leak and invalid access
Change-Id: I8561972e584233fd417d84a8850293e6c666f306
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Tue, 13 Dec 2016 02:13:56 +0000 (11:13 +0900)]
proc-stat : fix invalid unlock
- If proc_app_list is closed without open, lock issue will occurred
- To prevent this situation, checking code is included
Change-Id: I63950ec05350ad74e03acdf398c5901e4fe9c8bc
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Thu, 8 Dec 2016 06:47:04 +0000 (15:47 +0900)]
common : userinfo-list refactoring
- At a time, only one user_list is existed
- Each module using this no more have to worry about memory leak
- Replace from hash table to array because few user is existed in current
Change-Id: I152915072025afd9ecb898a8077bd99f5f281cfc
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Sat, 10 Dec 2016 06:10:02 +0000 (15:10 +0900)]
Replace strerror to strerror_r
- strerror is not thread-safe
- Size of buffer is decided to usually used
Change-Id: Icef5a5605e4347d65a634a0088445e07721b23d8
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Thu, 24 Nov 2016 08:00:31 +0000 (17:00 +0900)]
common : clean up DBusError
- Define cleanup function
- Remove unused variable
Change-Id: I11ff0af7ffd55d47f3b0eccdbde652ec243493fe
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Thu, 24 Nov 2016 07:30:04 +0000 (16:30 +0900)]
proc-stat : improve stability about controlling proc_app_list.
- Add handle for prelaunch app
- Rename child pid handling api properly
- Do not overwrite flags and categories of app_info
Change-Id: I43ccf642d5f5e07e50c04edbfee08f45045c4599
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Wed, 23 Nov 2016 10:59:00 +0000 (19:59 +0900)]
Simplify CMakefile
- Remove unnecessary resourced-cpucgroup.service
- Use GLOB instead of declaring all files
- Exclude swap source file when swap module is disabled
Change-Id: I8388b866f1337af462a32ccfc54d64c210526e46
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Mon, 21 Nov 2016 05:41:19 +0000 (14:41 +0900)]
common : separate cgroup integer function with uint and int
- Some numbers like pid should be written to unsigned int
Change-Id: Id34e1395974afd7526e1d92bb2dcfef4a2fd4f84
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Sat, 10 Dec 2016 04:58:48 +0000 (13:58 +0900)]
Allow ProcExclude signal without privilege
- To allow the request of Minicontroller
Change-Id: Iebaf678f2069b65216aeed3f311efbbfd5781b96
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Wed, 7 Dec 2016 00:44:47 +0000 (09:44 +0900)]
heart : remove heart-appopt
- No longer used
- In addition, from now, all HEART sub-modules will be listed in the HEART conf file
Change-Id: Ibc8c252c8d2359084261cc7abe6e89a8e0faa266
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Tue, 6 Dec 2016 07:43:19 +0000 (16:43 +0900)]
heart : fix wrong battery indexing
- When current index is 0, then temp index should be INDEX_WINDOW_SIZE - 1
- However, temp is set to 0, so we have to fix it
- Meanwhile, some comments and logs are modified
Change-Id: Iefe85b2f3b4987cb4dec9d034b16a626d70f0a58
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Mon, 5 Dec 2016 11:00:53 +0000 (20:00 +0900)]
heart : detach async DB updating
- LevelDB is not thread-safe
Change-Id: I845246c7041a120c8e710ce52c9c554732c0e012
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Fri, 25 Nov 2016 05:50:35 +0000 (14:50 +0900)]
heart : upgrade HEART-battery
1) Stability
- Use enum for charger status instead of integer
- Fix memory leak
- Asynchronous (level)DB updating
2) New function
- Discharge rate : HIGH(1.2x~), LOW(~0.8x), compare with predicted rate
- New logic for battery remaining time estimation
- Calculate SOE(State Of Energy) decreasing rate
- SOE is considered to the integral of OCP(Open-Circuit Potential)
- To use new logic, vendor have to support battery capacity and OCV coefficients
Change-Id: Ic80073028d8fde16980a53d8cb550023b56cb8b8
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Mon, 5 Dec 2016 04:57:00 +0000 (13:57 +0900)]
heart : fix minor issues
- Fix memory leak
- Remove unreachable code
- Fix cache searching condition
Change-Id: Ia91f07461afa7a759899533276717ec2c175dfc0
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Mon, 28 Nov 2016 00:57:20 +0000 (09:57 +0900)]
Fix minor issues
- Check memory allocation
- Initialize variables
Change-Id: I733751b3efd7042de73c6f8656421a1a4d0c4971
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Sunmin Lee [Fri, 2 Dec 2016 08:53:54 +0000 (17:53 +0900)]
Upgrade: set RW update script number
Change-Id: I77e66fb8cfd9cf19111af2e2dad91e5868fc313e
[Rebase]
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Sunmin Lee [Wed, 30 Nov 2016 06:08:10 +0000 (15:08 +0900)]
Upgrade: omit RO update commands in upgrade script
The change of RO partition is dealt with in different way.
There is no need to make change of RO in RW update script.
Change-Id: Icefcec01219c59e65cf954438290bffe529e8304
Signed-off-by: taeyoung <ty317.kim@samsung.com>
[Remove exclude list file from upgrade path]
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
lokilee73 [Mon, 21 Nov 2016 14:02:49 +0000 (23:02 +0900)]
proc-stat : fix about ANR popup signal
- Fix signal name and dbus format
Change-Id: I297eef44a45823631041be17e6e27f18e17e2af0
Signed-off-by: lokilee73 <changjoo.lee@samsung.com>
[Modify comment]
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kunhoon Baik [Mon, 14 Nov 2016 13:08:29 +0000 (22:08 +0900)]
Bug Fix & Minor code changes
- Bug Fix from Mr.Kim of MCD
- Close object at the appropriate time
Change-Id: Ie9331dbedf0ffa69507c99fda00bd8314c3cefb9
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Mon, 21 Nov 2016 05:36:34 +0000 (14:36 +0900)]
Merge branch 'tizen' into tizen_3.0
Change-Id: I24c32bc9ccf3e0ac85f5b84c26b57d2ded02c909
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Tue, 8 Nov 2016 10:48:19 +0000 (19:48 +0900)]
Fix memory issues
Change-Id: If6b6aec2f11454c796b2f54615d99921926ff4f0
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Fri, 11 Nov 2016 09:07:25 +0000 (18:07 +0900)]
Make rules about controlling cgroup
- All definitions will not have "/"
- Exception : root path ("/"sys/~), intermediate path (/sys"/"fs/~)
- Instead, "/" will be included in the function like snprintf
Change-Id: I3be94a7f357a9aa4d2db3ce0019c40d6269e96b0
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Fri, 11 Nov 2016 08:15:42 +0000 (17:15 +0900)]
proc-stat : use glib for monitoring exclude list
- For removing ecore-file dependency
Change-Id: I2fb208e60c7bdd23d151eb6a3ab3ec93a629964f
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Tue, 8 Nov 2016 10:48:19 +0000 (19:48 +0900)]
Fix memory issues
Change-Id: If6b6aec2f11454c796b2f54615d99921926ff4f0
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Mon, 7 Nov 2016 07:05:36 +0000 (16:05 +0900)]
Remove deprecated resourced.socket
Change-Id: Id264986beb0d20a97303b666a9fa3bdc6c385908
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
MyungJoo Ham [Wed, 2 Nov 2016 02:44:29 +0000 (11:44 +0900)]
Code Clean: spec file has dead code.
CAUTION: %pre section had not been active and will be
active from now on.
The whole %pre section was dead (and now alive),
so you should be careful on the behavior of that
"systemctl stop"
Change-Id: I6875b3a1e6a9f45bec6fe5c8efc07bec0685ea4b
Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
Kichan Kwon [Sat, 5 Nov 2016 08:55:57 +0000 (17:55 +0900)]
proc-stat : create critical section for proc_app_list
- System-freezer will link proc_app_list functions to use it
Change-Id: I57acaba1bee806e98e7f42bdf4529a892cdb7dae
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Sat, 5 Nov 2016 07:44:05 +0000 (16:44 +0900)]
Fix minor issues
Change-Id: I129b4fd3dc0284223c419d930bb3c16356234c5e
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Sat, 5 Nov 2016 07:35:24 +0000 (16:35 +0900)]
common : remove not used systemd-util
Change-Id: I90368bebe65f9390feff539c20655c943b811506
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Sat, 5 Nov 2016 06:01:39 +0000 (15:01 +0900)]
common : add cgroup control functions
- Getting pid
- Getting information about memory.stat
- In addition, all cgroup functions will unify prefix
Change-Id: I305ba00c5baa8e7962340d03c133cdc75faa3949
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Fri, 4 Nov 2016 06:15:21 +0000 (15:15 +0900)]
proc-stat : remove duplicated macro
- Size converting macro is supported by resourced util
Change-Id: I56365f759de498894c914e0b1f2943a83a9532a6
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Fri, 4 Nov 2016 05:09:23 +0000 (14:09 +0900)]
common : combine lowmem-common with memory-common
Change-Id: I848de5426f563997be73e551d248796fed0335dc
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Thu, 3 Nov 2016 10:59:26 +0000 (19:59 +0900)]
common : improve per-app memory usage calculation
1) New functions provide per-process memory usage
- pss, uss : use totmaps(if supported) or smaps(else)
- zram usage
- memory usage : pss + vmswap
2) proc_get_mem_usage is modified
- VmSize, VmRSS -> VmSwap, VmRSS
3) Other modules use these functions above
- vmpressure no more uses HEART-memory to get uss
- Signal handlers providing memory usage reply not rss but (pss + vmswap)
Change-Id: If8e2ff575b8d666ae82317228ff821c157c5cfc2
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Thu, 3 Nov 2016 08:46:10 +0000 (17:46 +0900)]
proc-stat : improve per-app CPU usage calculation
- Existed calculation is too strange
- Usage percentage = used time / elapsed time
- To get elapsed time, starttime and uptime are needed
Change-Id: I1834a550ae32603c66af780de72d57c0bcedcbb2
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Tue, 1 Nov 2016 07:11:14 +0000 (16:11 +0900)]
proc-stat : write appinfo into the file and exploit for restoring
- Current app information will be stored to /run/resourced/appinfo
- In there, each app has their own directory and store current state
- When resourced is restarted, proc module will read it and restore app information
Change-Id: I71b5a814615b928fd97194ebdae00cb15e902e65
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Tue, 1 Nov 2016 05:30:29 +0000 (14:30 +0900)]
common : each module can restore when resourced is restarted
- After restarting, all information are erased though other apps aren't exited
- Therefore, if each module needs, they can run restore function
- In addition, when restarted, BOOTING_DONE notifier will be broadcasted
Change-Id: I205993417565bc0505c4762b7da0c09e4b85a3a2
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Tue, 1 Nov 2016 04:47:37 +0000 (13:47 +0900)]
common : improve module structure
- Check whether sub-module is successfully loaded or not
- Re-establish module priority : LATE(default), NORMAL, EARLY, HIGH
Change-Id: Ife26e883af2578f449f65fa253b5026ea5e4ba81
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Mon, 31 Oct 2016 02:23:04 +0000 (11:23 +0900)]
cpu : move cgroup along with children.
Change-Id: Id177abb4510935da9396a72355c779ca81a91c4d
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Mon, 31 Oct 2016 08:12:51 +0000 (17:12 +0900)]
proc-stat : no more wrap structure around child pid
- We don't have to allocate and free for one-variable structure
Change-Id: Ic17e5a1c5dbb59adb4b38351ce5f72df19c3519c
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Thu, 3 Nov 2016 02:26:07 +0000 (11:26 +0900)]
common : directly read user information
Change-Id: I94a9d393236d73b44262ebc5631619eadd711284
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Tue, 25 Oct 2016 01:24:25 +0000 (10:24 +0900)]
Remove meaningless format specifier
Change-Id: Ib06118f5f7f49e7d01dc55b04d1d172ee20ec9b8
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Thu, 6 Oct 2016 08:45:51 +0000 (17:45 +0900)]
Version up
Change-Id: I0b9d4b361d0f69bea4e2bbfac0dfb49b65419660
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Thu, 6 Oct 2016 05:35:20 +0000 (22:35 -0700)]
Merge "Add path variable in the script file" into tizen
Chang Hyeon Chae [Tue, 4 Oct 2016 03:59:05 +0000 (12:59 +0900)]
Make static global variable used in only one file
Change-Id: Ida84dd5b4ef5334ea6c264c7697052962ed222c0
Signed-off-by: Chang Hyeon Chae <ckid.chae@samsung.com>
Kichan Kwon [Tue, 4 Oct 2016 01:45:13 +0000 (10:45 +0900)]
Add path variable in the script file
- For security issue
Change-Id: Ia71a2197a1aeaff02b4b3ba651745c9d504a413d
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Thu, 29 Sep 2016 01:10:17 +0000 (10:10 +0900)]
Fix security issues
- Prevent making not intended file
- Use %q instead of %s for preventing SQL injection
Change-Id: I778a2d3ff8af26112bca346b62b19322e094a01d
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Tue, 27 Sep 2016 05:15:18 +0000 (14:15 +0900)]
No more include not used file in the package
Change-Id: Iab23c338f23930dc4e8081be8e5f144e87fcae9f
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Mon, 19 Sep 2016 07:21:29 +0000 (16:21 +0900)]
cpu : don't assert with variable not used in the function
Change-Id: Ie38023814ae4d4ff7977db882fc1acae713954e3
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Mon, 19 Sep 2016 01:37:54 +0000 (10:37 +0900)]
common : remove hard coding path about internal root directory
- Instead, we will use Tizen platform configuration
Change-Id: I04d9963d0e4adb94c7ff8d2e647e1af7dbd1d784
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Mon, 12 Sep 2016 10:12:08 +0000 (19:12 +0900)]
Fix ENOENT issues
- No more access gumd user file directly
- Make HEART-battery dat file when it doesn't exist
Change-Id: I17ca884340c482a1ccb6efcb3a59091a88e6f97e
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Tue, 6 Sep 2016 10:22:24 +0000 (19:22 +0900)]
Modify upgrade script
- Use Tizen 3.0 RO exclude list and move RW exclude list
(For readbility, modify macros about exclude list)
- Remove output of sluggish module
- Use macro provided by tizen-platform-config
Change-Id: I00915cd79a86ec95e3f4587227b535fb5f3e5371
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Thu, 8 Sep 2016 01:26:38 +0000 (10:26 +0900)]
heart : fix memory leak.
Change-Id: Idaf09623ef8d50a3bc041eadc3a4a58f1dcdc78a
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Tue, 30 Aug 2016 02:14:08 +0000 (11:14 +0900)]
common : remove related to config_parse_new
- It can be replaced with config_parse and util functions
Change-Id: I1a77c006dfedd2dbd0d25ca6b42f1ed79b410cff
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Fri, 26 Aug 2016 07:19:51 +0000 (16:19 +0900)]
proc-stat : thaw process before setting state
- Until now, all processes are thawed after setting state to foreground
- However, System-freezer doesn't thaw foreground service bound with UI app
Change-Id: I502e80e7a197875c0b82882fb4478158f75773ef
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Fri, 26 Aug 2016 06:40:10 +0000 (15:40 +0900)]
proc-stat : do whole background process though app is directly come from initial state
- Until now, to apply whole background processes, app should be come from foreground
- However, from Tizen 3.0, app can be launched at the background without going to foreground
Change-Id: I0096779f75e200b97aaaddf0d5ff4ad26e62aa8b
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Mon, 22 Aug 2016 04:42:46 +0000 (13:42 +0900)]
Remove dependency on wm_ready
- Resourced doesn't need this dependency any more
Change-Id: I51408234053080ee2635b3d4d53816b5891773d4
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Fri, 12 Aug 2016 04:13:02 +0000 (13:13 +0900)]
common : use strncmp to compare string
- strstr can return false positive if first string is the prefix of second string
Change-Id: I3e2c733e5319c95ecac9235fad7478d212d87b5c
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Thu, 11 Aug 2016 09:27:51 +0000 (18:27 +0900)]
Remove needless things
- Unused definitions
- Documents about libresourced
- Headers about libproc-stat
Change-Id: Ica5a8654bab3795b3d9cbb97475c86a791505ec4
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Mon, 29 Aug 2016 05:58:22 +0000 (14:58 +0900)]
heart : multi-user logging : use old user list when updating user list is failed
- gumd can return fail if other package locks user list
- If resourced doesn't have existing user list, return fail
Change-Id: I0cf7529e531da716bfd2eee9cf8786d74797f430
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Tue, 16 Aug 2016 07:55:35 +0000 (16:55 +0900)]
heart : multi-user logging : implement per-user dat file of HEART-CPU
- Similar to DB, dat cache is composed of hash table (key=uid, value=cache)
- To distinguish destination, some HEART-CPU dbus methods ask uid
Change-Id: I9f703cf054436cf4272d5c2bac5fb95f0803e9fd
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Thu, 11 Aug 2016 09:57:06 +0000 (18:57 +0900)]
heart : multi-user logging : attach free function
Change-Id: I60b61b9087798ae067ae9cd3cc5141b2719bbf96
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Thu, 11 Aug 2016 02:42:35 +0000 (11:42 +0900)]
heart : multi-user logging : modify sub-modules and key of db_list
Appopt : disable (not used in now, this sub-module will be modified to unify with other modules)
Memory : use user default DB (memory usage can be changed by user's app usage)
Storage : set WAL journal mode (for backward compatibility)
Key : SYSTEM_X DB uses key (0; uid of root)
Change-Id: Ic02e04a04b4b2c2b6f8cf34c337d3c0fbcb6bf55
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Tue, 9 Aug 2016 13:33:05 +0000 (22:33 +0900)]
Create script for upgrade (Tizen 2.4 -> 3.0)
- Move HEART DB and dat files
Change-Id: I59eb63c0772178633ca00bbf46b2354c0ddcc556
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Fri, 5 Aug 2016 07:44:51 +0000 (16:44 +0900)]
heart : multi-user logging : implement per-user DB
- USER_DEFAULT and USER_OWN are similar as SYSTEM_X
- Difference is that only DB owner's logs are written in the user DB
- To manage all user's DB, each sub-module has DB hash table (key=uid, value=DB)
Change-Id: I6737f02f0c48c1fe2718144262e464a7c666967f
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Wed, 3 Aug 2016 07:47:13 +0000 (16:47 +0900)]
heart : multi-user logging : add uid in the logging table
- To write log in the cache,
1) Each sub-module send pid
2) Before writing to cache, pid is converted to uid
3) uid will be used to find destination (don't stored in the DB)
Change-Id: I71f52cc1908b43f24c45d7f774f58bf0210b5e02
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Fri, 22 Jul 2016 07:12:49 +0000 (16:12 +0900)]
heart : multi-user logging : classify sub-modules with DB type.
- SYSTEM_DEFAULT : use default SQLite3 DB
- SYSTEM_OWN : use their own DB
- USER_DEFAULT and USER_OWN will be implemented
Change-Id: I172b677bf01ebb9a8bf88c3c673f1b2638e03d95
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Tue, 9 Aug 2016 07:51:45 +0000 (16:51 +0900)]
proc-stat : use freezer function only if freezer module is loaded
Change-Id: I6fc420d8ba6e8c1518d59851ef1ff4eb5c3137b3
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Tue, 9 Aug 2016 06:30:59 +0000 (15:30 +0900)]
proc-stat : remove libproc-stat
- libproc-stat.so(socket communication) is alternated with dbus communication
- In addition, libresourced rpm package is removed because of absence of library in this package
Change-Id: I729a5edc0c4e2d188e0b62608f21997bd7930916
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Mon, 8 Aug 2016 01:15:58 +0000 (10:15 +0900)]
freezer : remove library and configuration files
- To use freezer module, you should install system-freezer plugin
Change-Id: I716e81a324a6d64083126ce67c031c229854ba99
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Mon, 13 Jun 2016 11:23:29 +0000 (20:23 +0900)]
proc-stat : apply LRU state at the favorite apps.
- Favorite apps have their own LRU state
Change-Id: I398d9ec0d100a6788eff5edd94fe8c8ab75f0608
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Thu, 28 Jul 2016 01:55:00 +0000 (10:55 +0900)]
Set existent user and group name
- User and group name "app" no longer exist
Change-Id: I44d31dd115544f1f4bf2fe77d36454ce239d41c3
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Mon, 25 Jul 2016 06:51:07 +0000 (15:51 +0900)]
common : remove proc_status.appid.
- This variable is overlapped with proc_status.pai->appid
Change-Id: Icd36586ab27891eb3692807b1e943b251d7e0e6d
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Thu, 21 Jul 2016 04:52:22 +0000 (13:52 +0900)]
Remove unused code
Change-Id: Ie8da88ab74a52c6b47cd7aecb56f0756083829dc
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Yunjin Lee [Wed, 20 Jul 2016 11:26:55 +0000 (20:26 +0900)]
Set SmackProcessLabel to System::Privileged
Change-Id: I802fe9becb1aad996f742efc86d2e6e2e84f2696
Signed-off-by: Yunjin Lee <yunjin-.lee@samsung.com>
Kichan Kwon [Wed, 20 Jul 2016 04:55:49 +0000 (13:55 +0900)]
memory : remove memps_log
- It isn't utilized in the platform image
Change-Id: I2f67d624e5f53a6f7c5d987b7ff5b3a8680ca234
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Wed, 13 Jul 2016 08:06:57 +0000 (17:06 +0900)]
Apply Tizen coding rule
Change-Id: I5988977501cce67899c0e0044886865d1bd8bfe9
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Wed, 13 Jul 2016 04:10:54 +0000 (13:10 +0900)]
sluggish : remove sluggish module
- In current, nobody call sluggish method
- Its role is overlapped with crash-worker
Change-Id: I432739fae74c981287e4880f3ca047199a45f0ea
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Fri, 8 Jul 2016 07:49:11 +0000 (16:49 +0900)]
common : close directory stream after using
Change-Id: I653c883a244ba2256e5e876a2477a97d8eb969ef
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Fri, 8 Jul 2016 06:17:30 +0000 (15:17 +0900)]
memory : use HEART-MEMORY data only if HEART-MEMORY module is enabled
Change-Id: Ifde1a811b4b133a88e31a22974c84aa22bd93dd7
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Fri, 8 Jul 2016 06:13:13 +0000 (15:13 +0900)]
Change some pathes
- HEART log files can be regarded to user data
- Therefore, these files may be located at user data area
Change-Id: I90c5896f5be53d67db719052d84681291715e16a
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Wed, 6 Jul 2016 05:07:24 +0000 (14:07 +0900)]
freezer : start vital mode only if suspend mode is enabled
Change-Id: I34a3c2a8e993cbb446b126a0c0056a0389dd3acd
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Wed, 6 Jul 2016 03:11:03 +0000 (12:11 +0900)]
timer-slack : set declaration with definition
Change-Id: I2997cb478734f8910f408a40b5e7c695eff4059b
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Wed, 6 Jul 2016 03:08:04 +0000 (12:08 +0900)]
Remove traces about network module
- test, DB, IPC, ...
Change-Id: I7e013120565791f3f887871425d2f78b4e86c7c6
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Mon, 13 Jun 2016 01:48:43 +0000 (10:48 +0900)]
cpu : tidy up configuration
- Remove unused config keys
- X_CPU_SHARE : absolute -> relative cpu share of root
- QUOTA_MAX_BANDWIDTH : max relative cpu time
Change-Id: I9221eed483b1a55c6e703793071b6e241c309d74
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Mon, 4 Jul 2016 06:30:57 +0000 (15:30 +0900)]
common : fix memory leak when Runtime-info requests information
- e_dbus_message_send internally use dbus_connection_send_with_reply
- However, edbus_message_send is used for replying, so resourced can't receive anything
- Therefore, we should use dbus_connection_send to reply
- In addition, edbus_init is modified to use dbus_conn
Change-Id: I5f00463ab3c434ff442889d60bb947baca86c206
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>
Kichan Kwon [Mon, 4 Jul 2016 10:07:05 +0000 (19:07 +0900)]
common : fix abnormal retry counter
Change-Id: I34c923452834943112065ad483577397c9f45328
Signed-off-by: Kichan Kwon <k_c.kwon@samsung.com>