Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 366199
b: refs/heads/master
c: 4e8f8b3
h: refs/heads/master
i:
  366197: a34c22e
  366195: 008ce0e
  366191: 2e0c2b2
v: v3
  • Loading branch information
John Stultz authored and Thomas Gleixner committed Apr 11, 2013
1 parent 2297225 commit 4ab25db
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 4 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 51fd36f3fad8447c487137ae26b9d0b3ce77bb25
refs/heads/master: 4e8f8b34b92b6514cc070aeb94d317cadd5071d7
10 changes: 7 additions & 3 deletions trunk/kernel/time/timekeeping.c
Original file line number Diff line number Diff line change
Expand Up @@ -607,6 +607,7 @@ void timekeeping_set_tai_offset(s32 tai_offset)
__timekeeping_set_tai_offset(tk, tai_offset);
write_seqcount_end(&timekeeper_seq);
raw_spin_unlock_irqrestore(&timekeeper_lock, flags);
clock_was_set();
}

/**
Expand Down Expand Up @@ -1639,7 +1640,7 @@ int do_adjtimex(struct timex *txc)
struct timekeeper *tk = &timekeeper;
unsigned long flags;
struct timespec ts;
s32 tai;
s32 orig_tai, tai;
int ret;

/* Validate the data before disabling interrupts */
Expand All @@ -1663,10 +1664,13 @@ int do_adjtimex(struct timex *txc)
raw_spin_lock_irqsave(&timekeeper_lock, flags);
write_seqcount_begin(&timekeeper_seq);

tai = tk->tai_offset;
orig_tai = tai = tk->tai_offset;
ret = __do_adjtimex(txc, &ts, &tai);

__timekeeping_set_tai_offset(tk, tai);
if (tai != orig_tai) {
__timekeeping_set_tai_offset(tk, tai);
clock_was_set_delayed();
}
write_seqcount_end(&timekeeper_seq);
raw_spin_unlock_irqrestore(&timekeeper_lock, flags);

Expand Down

0 comments on commit 4ab25db

Please sign in to comment.