“A computer process is a running instance of a program, including all variables and other states, or simply it’s defined as a program in execution. Now we will see how this task or process is implemented in Linux kernel. The description of the characteristics of a process is given in the structure task_struct.”
Very short article, not even an introduction really. This may be newsworthy at episode 4 or 5. Or never.
use http://tldp.org/ to gather some real information about linux (internal datastructures for example).
and why the hell would you want to “While modifying this structure”?
i dont see the value of this 2 page article on osweekly
I have to agree – this “article” was terrible. No detail on what the structure is designed for, no detail on how you use it, and…
This access is not made, as it is usually in C language, via the names of the components, but is made via their offsets relative to start of the structure
Why on *earth* would you want to play with something as critical to system operation as this, by using address offsets?!!?!??!!? That’s a recipe for disaster.
PipoDeClown — thanks for the tldp.org pointer – much more useful.
For those who would mess with a task structure – please rtfm (tldp.org is a good place to start) before using, and be very, very careful to make sure that you only ever use the designated interfaces for making changes or reading from these structs. Your kernel stability matters!
Edited 2006-04-10 07:23
Why on *earth* would you want to play with something as critical to system operation as this, by using address offsets?!
because…
“The first few data members are accessed from assembler routines”
Gas doesn’t have any access to C structure.
This is how the GNU tools was designed in 70s.