Skip to content

Commit

Permalink
kcov: move t->kcov_sequence assignment
Browse files Browse the repository at this point in the history
Move t->kcov_sequence assignment before assigning t->kcov_mode for
consistency.

Signed-off-by: Andrey Konovalov <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Reviewed-by: Dmitry Vyukov <[email protected]>
Cc: Alan Stern <[email protected]>
Cc: Alexander Potapenko <[email protected]>
Cc: Greg Kroah-Hartman <[email protected]>
Cc: Marco Elver <[email protected]>
Cc: Andrey Konovalov <[email protected]>
Link: http://lkml.kernel.org/r/5889efe35e0b300e69dba97216b1288d9c2428a8.1585233617.git.andreyknvl@google.com
Link: http://lkml.kernel.org/r/f0283c676bab3335cb48bfe12d375a3da4719f59.1584655448.git.andreyknvl@google.com
Signed-off-by: Linus Torvalds <[email protected]>
  • Loading branch information
xairy authored and torvalds committed Jun 5, 2020
1 parent 76484b1 commit eeb91f9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion kernel/kcov.c
Original file line number Diff line number Diff line change
Expand Up @@ -318,10 +318,10 @@ static void kcov_start(struct task_struct *t, struct kcov *kcov,
/* Cache in task struct for performance. */
t->kcov_size = size;
t->kcov_area = area;
t->kcov_sequence = sequence;
/* See comment in check_kcov_mode(). */
barrier();
WRITE_ONCE(t->kcov_mode, mode);
t->kcov_sequence = sequence;
}

static void kcov_stop(struct task_struct *t)
Expand Down

0 comments on commit eeb91f9

Please sign in to comment.