From: Wei Liu <wei.liu2@citrix.com>
To: Xen-devel <xen-devel@lists.xenproject.org>
Cc: Andrew Cooper <andrew.cooper3@citrix.com>,
Wei Liu <wei.liu2@citrix.com>, Jan Beulich <JBeulich@suse.com>
Subject: [PATCH 02/18] x86/apic.c: use plain bool
Date: Fri, 30 Jun 2017 18:01:10 +0100 [thread overview]
Message-ID: <20170630170126.4148-3-wei.liu2@citrix.com> (raw)
In-Reply-To: <20170630170126.4148-1-wei.liu2@citrix.com>
Signed-off-by: Wei Liu <wei.liu2@citrix.com>
---
xen/arch/x86/apic.c | 30 +++++++++++++++---------------
xen/include/asm-x86/apic.h | 4 ++--
2 files changed, 17 insertions(+), 17 deletions(-)
diff --git a/xen/arch/x86/apic.c b/xen/arch/x86/apic.c
index 8c6c2f5819..28a1ef8a58 100644
--- a/xen/arch/x86/apic.c
+++ b/xen/arch/x86/apic.c
@@ -37,8 +37,8 @@
#include <io_ports.h>
#include <xen/kexec.h>
-static bool_t tdt_enabled __read_mostly;
-static bool_t tdt_enable __initdata = 1;
+static bool tdt_enabled __read_mostly;
+static bool tdt_enable __initdata = true;
boolean_param("tdt", tdt_enable);
static struct {
@@ -70,7 +70,7 @@ static s8 __initdata enable_local_apic; /* -1=force-disable, +1=force-enable */
*/
u8 __read_mostly apic_verbosity;
-static bool_t __initdata opt_x2apic = 1;
+static bool __initdata opt_x2apic = true;
boolean_param("x2apic", opt_x2apic);
/*
@@ -79,8 +79,8 @@ boolean_param("x2apic", opt_x2apic);
*/
static enum apic_mode apic_boot_mode = APIC_MODE_INVALID;
-bool_t __read_mostly x2apic_enabled = 0;
-bool_t __read_mostly directed_eoi_enabled = 0;
+bool __read_mostly x2apic_enabled = false;
+bool __read_mostly directed_eoi_enabled = false;
static int modern_apic(void)
{
@@ -130,9 +130,9 @@ void __init apic_intr_init(void)
}
/* Using APIC to generate smp_local_timer_interrupt? */
-static bool_t __read_mostly using_apic_timer;
+static bool __read_mostly using_apic_timer;
-static bool_t __read_mostly enabled_via_apicbase;
+static bool __read_mostly enabled_via_apicbase;
int get_physical_broadcast(void)
{
@@ -387,7 +387,7 @@ int __init verify_local_APIC(void)
else
{
ioapic_ack_new = 0;
- directed_eoi_enabled = 1;
+ directed_eoi_enabled = true;
printk("Enabled directed EOI with ioapic_ack_old on!\n");
}
}
@@ -839,7 +839,7 @@ static int __init detect_init_APIC (void)
msr_content &= ~MSR_IA32_APICBASE_BASE;
msr_content |= MSR_IA32_APICBASE_ENABLE | APIC_DEFAULT_PHYS_BASE;
wrmsrl(MSR_IA32_APICBASE, msr_content);
- enabled_via_apicbase = 1;
+ enabled_via_apicbase = true;
}
}
/*
@@ -945,7 +945,7 @@ void __init x2apic_bsp_setup(void)
if ( !x2apic_enabled )
{
- x2apic_enabled = 1;
+ x2apic_enabled = true;
__enable_x2apic();
}
@@ -1176,7 +1176,7 @@ void __init setup_boot_APIC_clock(void)
{
unsigned long flags;
apic_printk(APIC_VERBOSE, "Using local APIC timer interrupts.\n");
- using_apic_timer = 1;
+ using_apic_timer = true;
local_irq_save(flags);
@@ -1185,7 +1185,7 @@ void __init setup_boot_APIC_clock(void)
if ( tdt_enable && boot_cpu_has(X86_FEATURE_TSC_DEADLINE) )
{
printk(KERN_DEBUG "TSC deadline timer enabled\n");
- tdt_enabled = 1;
+ tdt_enabled = true;
}
setup_APIC_timer();
@@ -1258,12 +1258,12 @@ void apic_timer_interrupt(struct cpu_user_regs * regs)
raise_softirq(TIMER_SOFTIRQ);
}
-static DEFINE_PER_CPU(bool_t, state_dump_pending);
+static DEFINE_PER_CPU(bool, state_dump_pending);
void smp_send_state_dump(unsigned int cpu)
{
/* We overload the spurious interrupt handler to handle the dump. */
- per_cpu(state_dump_pending, cpu) = 1;
+ per_cpu(state_dump_pending, cpu) = true;
send_IPI_mask(cpumask_of(cpu), SPURIOUS_APIC_VECTOR);
}
@@ -1280,7 +1280,7 @@ void spurious_interrupt(struct cpu_user_regs *regs)
if (apic_isr_read(SPURIOUS_APIC_VECTOR)) {
ack_APIC_irq();
if (this_cpu(state_dump_pending)) {
- this_cpu(state_dump_pending) = 0;
+ this_cpu(state_dump_pending) = false;
dump_execstate(regs);
goto out;
}
diff --git a/xen/include/asm-x86/apic.h b/xen/include/asm-x86/apic.h
index ea675b7f0a..9d7ec93042 100644
--- a/xen/include/asm-x86/apic.h
+++ b/xen/include/asm-x86/apic.h
@@ -29,8 +29,8 @@ enum apic_mode {
};
extern u8 apic_verbosity;
-extern bool_t x2apic_enabled;
-extern bool_t directed_eoi_enabled;
+extern bool x2apic_enabled;
+extern bool directed_eoi_enabled;
void check_x2apic_preenabled(void);
void x2apic_bsp_setup(void);
--
2.11.0
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
https://lists.xen.org/xen-devel
next prev parent reply other threads:[~2017-06-30 17:01 UTC|newest]
Thread overview: 30+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-06-30 17:01 [PATCH 00/18] x86: more bool_t to bool cleanup Wei Liu
2017-06-30 17:01 ` [PATCH 01/18] x86/acpi: use plain bool Wei Liu
2017-06-30 17:01 ` Wei Liu [this message]
2017-06-30 17:26 ` [PATCH 02/18] x86/apic.c: " Andrew Cooper
2017-06-30 17:01 ` [PATCH 03/18] x86/debug.c: " Wei Liu
2017-06-30 17:28 ` Andrew Cooper
2017-06-30 17:01 ` [PATCH 04/18] x86/dmi.c: " Wei Liu
2017-06-30 17:01 ` [PATCH 05/18] x86/domctl: " Wei Liu
2017-06-30 17:01 ` [PATCH 06/18] x86/hpet.c: " Wei Liu
2017-06-30 17:01 ` [PATCH 07/18] x86/e820.c: use plan bool Wei Liu
2017-06-30 17:01 ` [PATCH 08/18] x86/i387.c: use plain bool Wei Liu
2017-06-30 17:01 ` [PATCH 09/18] x86/i8259.c: " Wei Liu
2017-06-30 17:01 ` [PATCH 10/18] x86/monitor.c: " Wei Liu
2017-06-30 17:45 ` Andrew Cooper
2017-06-30 18:30 ` Razvan Cojocaru
2017-06-30 17:01 ` [PATCH 11/18] x86/xstate.c: " Wei Liu
2017-06-30 17:01 ` [PATCH 12/18] x86/srat.c: " Wei Liu
2017-06-30 17:01 ` [PATCH 13/18] x86/smpboot.c: " Wei Liu
2017-06-30 17:01 ` [PATCH 14/18] x86/io_apic.c: " Wei Liu
2017-06-30 17:53 ` Andrew Cooper
2017-06-30 17:01 ` [PATCH 15/18] x86/mpparse.c: " Wei Liu
2017-06-30 17:54 ` Andrew Cooper
2017-06-30 17:01 ` [PATCH 16/18] x86/numa.c: " Wei Liu
2017-06-30 17:01 ` [PATCH 17/18] x86/msi.c: " Wei Liu
2017-06-30 17:01 ` [PATCH 18/18] x86/psr.c: " Wei Liu
2017-06-30 18:00 ` [PATCH 00/18] x86: more bool_t to bool cleanup Andrew Cooper
2017-07-03 8:10 ` Jan Beulich
2017-07-03 12:54 ` Wei Liu
2017-07-03 13:19 ` Jan Beulich
2017-07-04 10:43 ` Wei Liu
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20170630170126.4148-3-wei.liu2@citrix.com \
--to=wei.liu2@citrix.com \
--cc=JBeulich@suse.com \
--cc=andrew.cooper3@citrix.com \
--cc=xen-devel@lists.xenproject.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).