LCOV - code coverage report
Current view: top level - include/linux/sched - xacct.h (source / functions) Hit Total Coverage
Test: fstests of 6.5.0-rc4-xfsx @ Mon Jul 31 20:08:34 PDT 2023 Lines: 6 6 100.0 %
Date: 2023-07-31 20:08:34 Functions: 0 0 -

          Line data    Source code
       1             : /* SPDX-License-Identifier: GPL-2.0 */
       2             : #ifndef _LINUX_SCHED_XACCT_H
       3             : #define _LINUX_SCHED_XACCT_H
       4             : 
       5             : /*
       6             :  * Extended task accounting methods:
       7             :  */
       8             : 
       9             : #include <linux/sched.h>
      10             : 
      11             : #ifdef CONFIG_TASK_XACCT
      12             : static inline void add_rchar(struct task_struct *tsk, ssize_t amt)
      13             : {
      14     9506941 :         tsk->ioac.rchar += amt;
      15  5533601007 : }
      16             : 
      17             : static inline void add_wchar(struct task_struct *tsk, ssize_t amt)
      18             : {
      19          13 :         tsk->ioac.wchar += amt;
      20   836401662 : }
      21             : 
      22             : static inline void inc_syscr(struct task_struct *tsk)
      23             : {
      24  6270769915 :         tsk->ioac.syscr++;
      25             : }
      26             : 
      27             : static inline void inc_syscw(struct task_struct *tsk)
      28             : {
      29   831507972 :         tsk->ioac.syscw++;
      30             : }
      31             : #else
      32             : static inline void add_rchar(struct task_struct *tsk, ssize_t amt)
      33             : {
      34             : }
      35             : 
      36             : static inline void add_wchar(struct task_struct *tsk, ssize_t amt)
      37             : {
      38             : }
      39             : 
      40             : static inline void inc_syscr(struct task_struct *tsk)
      41             : {
      42             : }
      43             : 
      44             : static inline void inc_syscw(struct task_struct *tsk)
      45             : {
      46             : }
      47             : #endif
      48             : 
      49             : #endif /* _LINUX_SCHED_XACCT_H */

Generated by: LCOV version 1.14