lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <59f9a0281bac84fe356ed3d0f54ae371ad1e430d.1398072824.git.viresh.kumar@linaro.org>
Date:	Mon, 21 Apr 2014 15:25:09 +0530
From:	Viresh Kumar <viresh.kumar@...aro.org>
To:	tglx@...utronix.de
Cc:	linaro-kernel@...ts.linaro.org, linaro-networking@...aro.org,
	linux-kernel@...r.kernel.org, fweisbec@...il.com,
	Viresh Kumar <viresh.kumar@...aro.org>
Subject: [PATCH V2 13/19] tick-common: remove local variable 'broadcast' from tick_resume()

'broadcast' is used just once and we can use tick_resume_broadcast() directly
instead. Also it changes the code a bit to get rid of extra indentation level
which was forcing us to break function calls into two lines.

Signed-off-by: Viresh Kumar <viresh.kumar@...aro.org>
---
 kernel/time/tick-common.c | 15 +++++++--------
 1 file changed, 7 insertions(+), 8 deletions(-)

diff --git a/kernel/time/tick-common.c b/kernel/time/tick-common.c
index 85ee9fd..2dc6822 100644
--- a/kernel/time/tick-common.c
+++ b/kernel/time/tick-common.c
@@ -350,17 +350,16 @@ void tick_resume(void)
 {
 	struct tick_device *td = tick_get_cpu_device();
 	struct clock_event_device *dev = td->evtdev;
-	int broadcast = tick_resume_broadcast();
 
 	clockevents_set_mode(dev, CLOCK_EVT_MODE_RESUME);
 
-	if (!broadcast) {
-		if (td->mode == TICKDEV_MODE_PERIODIC)
-			tick_setup_periodic(dev, 0);
-		else
-			tick_setup_oneshot(dev, dev->event_handler,
-					   ktime_get());
-	}
+	if (tick_resume_broadcast())
+		return;
+
+	if (td->mode == TICKDEV_MODE_PERIODIC)
+		tick_setup_periodic(dev, 0);
+	else
+		tick_setup_oneshot(dev, dev->event_handler, ktime_get());
 }
 
 /**
-- 
1.7.12.rc2.18.g61b472e

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ