Commit message (Collapse) | Author | Age | Files | Lines | |
---|---|---|---|---|---|
* | Moved debug.[ch] to utils folder | Tobias Brunner | 2012-10-24 | 2 | -2/+2 |
| | |||||
* | Moved data structures to new collections subfolder | Tobias Brunner | 2012-10-24 | 2 | -2/+2 |
| | |||||
* | Make rescheduling a job more predictable | Tobias Brunner | 2012-06-25 | 2 | -37/+85 |
| | | | | | | | | | | | | | This avoids race conditions between calls to cancel() and jobs that like to be rescheduled. If jobs were able to reschedule themselves it would theoretically be possible that two worker threads have the same job assigned (the one currently executing the job and the one executing the same but rescheduled job if it already is time to execute it), this means that cancel() could be called twice for that job. Creating a new job based on the current one and reschedule that is also OK, but rescheduling itself is more efficient for jobs that need to be executed often. | ||||
* | Centralized thread cancellation in processor_t | Tobias Brunner | 2012-06-25 | 6 | -206/+124 |
| | | | | | | | | | | This ensures that no threads are active when plugins and the rest of the daemon are unloaded. callback_job_t was simplified a lot in the process as its main functionality is now contained in processor_t. The parent-child relationships were abandoned as these were only needed to simplify job cancellation. | ||||
* | Give processor_t more control over the lifecycle of a job | Tobias Brunner | 2012-06-25 | 6 | -105/+176 |
| | | | | | | | | | | | Jobs are now destroyed by the processor, but they are allowed to reschedule themselves. That is, parts of the reschedule functionality already provided by callback_job_t is moved to the processor. Not yet fully supported is JOB_REQUEUE_DIRECT and canceling jobs. Note: job_t.destroy() is now called not only for queued jobs but also after execution or cancellation of jobs. job_t.status can be used to decide what to do in said method. | ||||
* | Use wrapped semaphore in callback_job_t. | Tobias Brunner | 2012-05-02 | 1 | -12/+9 |
| | |||||
* | Log worker thread ID with two digits. | Tobias Brunner | 2011-12-16 | 1 | -2/+2 |
| | |||||
* | Fixed compiler warnings regarding enum comparison. | Tobias Brunner | 2011-11-25 | 1 | -1/+1 |
| | | | | | | | | | Warnings like comparison of unsigned expression < 0 is always false are reported with -Wextra when enum types that are compiled to an unsigned type (which is up to the compiler) are checked for negativity. | ||||
* | Fixed common misspellings. | Tobias Brunner | 2011-07-20 | 2 | -2/+2 |
| | | | | Mostly found by 'codespell'. | ||||
* | Prevent deadlock while shutting down thread pool. | Tobias Brunner | 2011-06-08 | 1 | -2/+2 |
| | | | | | | | | | During destruction the main thread locks the mutex in processor_t and waits on a condvar for threads to have terminated. Because the mutex has also to be locked to decrement the thread count the condvar cannot be signaled before doing that as otherwise the main thread might already be waiting to join the threads while locking the mutex and thus causing a deadlock. | ||||
* | Update working thread count without allocation. | Tobias Brunner | 2011-05-16 | 1 | -22/+15 |
| | |||||
* | Make sure working thread count is correctly updated | Tobias Brunner | 2011-05-16 | 1 | -4/+23 |
| | |||||
* | Use CRITICAL job priority class for long running dispatcher jobs | Martin Willi | 2011-05-16 | 1 | -1/+2 |
| | |||||
* | Introduce a highest priority job for critical thread services | Martin Willi | 2011-05-16 | 2 | -2/+5 |
| | |||||
* | Added a callback_job constructor supporting custom priorities | Martin Willi | 2011-05-16 | 2 | -4/+36 |
| | |||||
* | Count number of threads active in each class, and reserve threads only if ↵ | Martin Willi | 2011-05-16 | 2 | -17/+66 |
| | | | | none active | ||||
* | Reserve threads for job priority classes based on strongswan.conf options | Martin Willi | 2011-05-16 | 1 | -1/+17 |
| | |||||
* | Added job priority enum names | Martin Willi | 2011-05-16 | 2 | -0/+27 |
| | |||||
* | Processor job scheduling respects job priority classes | Martin Willi | 2011-05-16 | 2 | -13/+47 |
| | |||||
* | Introduce priority classes for jobs | Martin Willi | 2011-05-16 | 2 | -2/+30 |
| | |||||
* | Migrated scheduler_t to INIT/METHOD macros | Martin Willi | 2011-05-05 | 1 | -33/+24 |
| | |||||
* | Migrated callback_job to INIT/METHOD macros | Martin Willi | 2011-05-05 | 2 | -38/+38 |
| | |||||
* | Migrated processor to INIT/METHOD macros | Martin Willi | 2011-05-05 | 1 | -42/+35 |
| | |||||
* | Do not invoke processor restart() if not required | Martin Willi | 2011-03-15 | 1 | -1/+2 |
| | | | | | Doing so might result in a deadlock during shutdown if a delayed restart is locked on the bus during the debug statement. | ||||
* | Remove obsolete pool_size argument in processor_create() | Martin Willi | 2010-11-16 | 1 | -1/+1 |
| | |||||
* | Refer to scheduler and processor via lib and not hydra. | Tobias Brunner | 2010-09-02 | 2 | -6/+4 |
| | |||||
* | Moved scheduler and thread pool to libstrongswan. | Tobias Brunner | 2010-09-02 | 7 | -0/+1298 |