diff options
author | Masao Uebayashi <uebayasi@cvs.openbsd.org> | 2014-07-21 17:25:48 +0000 |
---|---|---|
committer | Masao Uebayashi <uebayasi@cvs.openbsd.org> | 2014-07-21 17:25:48 +0000 |
commit | f17753593c3ba9fb7226c8026ec2c748f4be658f (patch) | |
tree | 7c55c9f49619a73b65928f60411827d5a181f907 /sys/arch/hppa | |
parent | 353e4422b301ecf3fe6c2a5b8219f3c9f5183425 (diff) |
boot(9): Reduce annoying style diffs
- Always use either: ((x & RB_XXX) != 0) or ((x & RB_XXX) == 0) in boolean
context (mostly if (x), or x ? y : z)
- prom_halt() in alpha is confirmed to take int as boolean
Converted by coccinelle. No functional change intended.
Diffstat (limited to 'sys/arch/hppa')
-rw-r--r-- | sys/arch/hppa/hppa/machdep.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/sys/arch/hppa/hppa/machdep.c b/sys/arch/hppa/hppa/machdep.c index 0a149c0283b..a9bc5cb41e7 100644 --- a/sys/arch/hppa/hppa/machdep.c +++ b/sys/arch/hppa/hppa/machdep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: machdep.c,v 1.231 2014/07/13 22:53:38 uebayasi Exp $ */ +/* $OpenBSD: machdep.c,v 1.232 2014/07/21 17:25:47 uebayasi Exp $ */ /* * Copyright (c) 1999-2003 Michael Shalayeff @@ -908,7 +908,7 @@ boot(int howto) boothowto = howto | (boothowto & RB_HALT); - if (!(howto & RB_NOSYNC)) { + if ((howto & RB_NOSYNC) == 0) { waittime = 0; vfs_shutdown(); @@ -924,7 +924,7 @@ boot(int howto) splhigh(); cold = 1; - if (howto & RB_DUMP) + if ((howto & RB_DUMP) != 0) dumpsys(); haltsys: @@ -941,8 +941,8 @@ haltsys: if (cold_hook) (*cold_hook)(HPPA_COLD_COLD); - if (howto & RB_HALT) { - if (howto & RB_POWERDOWN && cold_hook) { + if ((howto & RB_HALT) != 0) { + if ((howto & RB_POWERDOWN) != 0 && cold_hook) { printf("Powering off..."); DELAY(2000000); (*cold_hook)(HPPA_COLD_OFF); |