Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit bb1d8605 authored by Jim Houston's avatar Jim Houston Committed by Linus Torvalds
Browse files

[PATCH] time_adjust cleared before use



I notice that the code which implements adjtime clears the time_adjust
value before using it.  The attached patch makes the obvious fix.

Acked-by: default avatarRoman Zippel <zippel@linux-m68k.org>
Signed-off-by: default avatarJim Houston <jim.houston@ccur.com>
Cc: John Stultz <johnstul@us.ibm.com>
Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
parent eba6cd67
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -161,9 +161,9 @@ void second_overflow(void)
			time_adjust += MAX_TICKADJ;
			tick_length -= MAX_TICKADJ_SCALED;
		} else {
			time_adjust = 0;
			tick_length += (s64)(time_adjust * NSEC_PER_USEC /
					     HZ) << TICK_LENGTH_SHIFT;
			time_adjust = 0;
		}
	}
}