]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - include/linux/sched.h
[PATCH] non lazy "sleazy" fpu implementation
[linux-2.6-omap-h63xx.git] / include / linux / sched.h
index 6674fc1e51bf3dfe0677633e489231a91c271dac..807556c5bcd26e1ce74471e931a63e3ad915be91 100644 (file)
@@ -865,6 +865,15 @@ struct task_struct {
        struct key *thread_keyring;     /* keyring private to this thread */
        unsigned char jit_keyring;      /* default keyring to attach requested keys to */
 #endif
+       /*
+        * fpu_counter contains the number of consecutive context switches
+        * that the FPU is used. If this is over a threshold, the lazy fpu
+        * saving becomes unlazy to save the trap. This is an unsigned char
+        * so that after 256 times the counter wraps and the behavior turns
+        * lazy again; this to deal with bursty apps that only use FPU for
+        * a short time
+        */
+       unsigned char fpu_counter;
        int oomkilladj; /* OOM kill score adjustment (bit shift). */
        char comm[TASK_COMM_LEN]; /* executable name excluding path
                                     - access with [gs]et_task_comm (which lock
@@ -994,7 +1003,6 @@ struct task_struct {
         */
        struct pipe_inode_info *splice_pipe;
 #ifdef CONFIG_TASK_DELAY_ACCT
-       spinlock_t delays_lock;
        struct task_delay_info *delays;
 #endif
 };