0

I've recently started reading about workqueues and the code involved to create workqueues in the Linux Kernel.

Workqueues are basically scheduling work on multiple CPUs to concurrently execute a series of tasks based on the queue.

We have create_*workqueue() which is now depracated and is being replaced by alloc_*workqueue()

There are a couple of flags which are given in the documentation on workqueues here. These flags are used in alloc_*workqueue Though I read the documentation provided by the Linux Kernel, I'm still a little unclear on how WQ_MEM_RECLAIM flag works.

What is queue_delayed_work(), __cancel_delayed_work() and mod_delayed_work() and how are they related or different from create/alloc_*workqueue

Note: I'm new to the linux kernel and have limited knowledge of operating systems, so please bear with me and explain in as simplified version as possible.

musicakc
  • 488
  • 1
  • 4
  • 15
  • Too many questions in one post. And many of them are **subjective**, e.g. `how do you determine which flags are to be set for a particular case?` or `how do you make the decision of using alloc_workqueue or alloc_ordered_workqueue`. This choice is mainly dependent from the situation. Try to write your own code for the kernel, then you will have more concrete questions. – Tsyvarev Feb 06 '16 at 15:20
  • @musicakc **Welcome to StackOverflow.** :-) Did you try googling the workqueue flags you mentioned. Can you try searching for posts with the `WQ_UNBOUND` or `workqueue` keywords here on StackOverflow? You will find [**this**](http://stackoverflow.com/a/18071394/319204) and [**this**](http://stackoverflow.com/q/14275113/319204). *Some doubts cleared? Good! New doubts in mind now? Even better!!* Check if the new questions are already answered. Still have some doubts, **then** post new questions here on StackOverflow (one at a time). Good Luck... – TheCodeArtist Feb 08 '16 at 17:48
  • I read your answers already @TheCodeArtist before posting, still had doubts though I'll edit this question with fewer questions as suggested by both you and Tsyvarev – musicakc Feb 09 '16 at 18:16

0 Answers0