lp:~sforshee/+junk/powerd-worker
- Get this branch:
- bzr branch lp:~sforshee/+junk/powerd-worker
Branch information
- Owner:
- Seth Forshee
- Status:
- Development
Recent revisions
- 33. By Seth Forshee
-
power-request: Remove use of mutex protecting request hash table
Use powerd_
run_mainloop_ sync() to ensure all accesses to the
hash table occur on the main loop, eliminating the need to
protect access to the table with a mutex. - 32. By Seth Forshee
-
Add utility for synchronously running a function on the main loop
In order to reduce the need for locking, we always want to run
certain tasks on the main loop. Sometimes it's necessary to
initiate these tasks from another thread, however we'd still like
to block until the task completes.Add powerd_
run_mainloop_ sync() to assist with doing this action.
This function runs the the requested function on the main loop.
If currently executing on the main loop the function is executed
inline. Otherwise it is scheduled to run on the main loop and
powerd_run_mainloop_ sync() blocks until the operation completes.
A new function power_is_mainloop() is also added to help with
determining if the current function is executing on the main
loop. - 31. By Seth Forshee
-
power-request: Slight efficiency improvement to UUID hashing function
a ^ 0 == a. Therefore, when calculating the UUID hash we can
save a small chunk of time by initializing the hash to the first
element of the data rather than initializing it to 0 and xoring
it with the first element. - 30. By Seth Forshee
-
power-request: Fix use-after-free bug
g_hash_
table_remove( ) frees the memory, so save off the data
we need to use after calling it. - 28. By Seth Forshee
-
Use a hash table rather than a linked list for storing system state requests
This will scale better to larger numbers of requests.
- 27. By Seth Forshee
-
Improve dbus error handling
Fix several problems with dbus error handling. Modify the
internal request functions to no longer take an invocation;
instead, perform all error indication in the dbus callbacks.
Branch metadata
- Branch format:
- Branch format 7
- Repository format:
- Bazaar repository format 2a (needs bzr 1.16 or later)