From bbe787a0afd51307cdac2c023895c19df31519ca Mon Sep 17 00:00:00 2001 From: Linus Groh Date: Wed, 30 Dec 2020 22:44:54 +0100 Subject: Everywhere: Re-format with clang-format-11 Compared to version 10 this fixes a bunch of formatting issues, mostly around structs/classes with attributes like [[gnu::packed]], and incorrect insertion of spaces in parameter types ("T &"/"T &&"). I also removed a bunch of // clang-format off/on and FIXME comments that are no longer relevant - on the other hand it tried to destroy a couple of neatly formatted comments, so I had to add some as well. --- Kernel/Interrupts/IOAPIC.h | 3 +-- Kernel/Interrupts/PIC.cpp | 2 ++ 2 files changed, 3 insertions(+), 2 deletions(-) (limited to 'Kernel/Interrupts') diff --git a/Kernel/Interrupts/IOAPIC.h b/Kernel/Interrupts/IOAPIC.h index 4642df5a23..c5085b313f 100644 --- a/Kernel/Interrupts/IOAPIC.h +++ b/Kernel/Interrupts/IOAPIC.h @@ -30,8 +30,7 @@ #include namespace Kernel { -struct [[gnu::packed]] ioapic_mmio_regs -{ +struct [[gnu::packed]] ioapic_mmio_regs { volatile u32 select; u32 reserved[3]; volatile u32 window; diff --git a/Kernel/Interrupts/PIC.cpp b/Kernel/Interrupts/PIC.cpp index 29bb7e4590..891dee0130 100644 --- a/Kernel/Interrupts/PIC.cpp +++ b/Kernel/Interrupts/PIC.cpp @@ -42,6 +42,7 @@ namespace Kernel { #define PIC1_CTL 0xA0 #define PIC1_CMD 0xA1 +// clang-format off #define ICW1_ICW4 0x01 /* ICW4 (not) needed */ #define ICW1_SINGLE 0x02 /* Single (cascade) mode */ #define ICW1_INTERVAL4 0x04 /* Call address interval 4 (8) */ @@ -53,6 +54,7 @@ namespace Kernel { #define ICW4_BUF_SLAVE 0x08 /* Buffered mode/slave */ #define ICW4_BUF_MASTER 0x0C /* Buffered mode/master */ #define ICW4_SFNM 0x10 /* Special fully nested (not) */ +// clang-format on bool inline static is_all_masked(u16 reg) { -- cgit v1.2.3