diff options
| author | Amlal El Mahrouss <amlal@el-mahrouss-logic.com> | 2024-05-19 19:13:03 +0200 |
|---|---|---|
| committer | Amlal El Mahrouss <amlal@el-mahrouss-logic.com> | 2024-05-19 19:13:03 +0200 |
| commit | aad2c069563a3e7318b575216db6deb313445f2c (patch) | |
| tree | 2ba42b767473bebdca9d2538d120f0b4d82194e4 /Boot | |
| parent | c0428f8e5feba9573e572a1a1b3c66cfa1f29108 (diff) | |
MHR-23: Fix run_format.sh, inl files needs to be formated as well.
Signed-off-by: Amlal El Mahrouss <amlal@el-mahrouss-logic.com>
Diffstat (limited to 'Boot')
| -rw-r--r-- | Boot/BootKit/BitManip.hxx | 2 | ||||
| -rw-r--r-- | Boot/BootKit/BootKit.hxx | 2 | ||||
| -rw-r--r-- | Boot/BootKit/Device.hxx | 2 | ||||
| -rw-r--r-- | Boot/BootKit/EPM.hxx | 2 | ||||
| -rw-r--r-- | Boot/BootKit/HW/ATA.hxx | 2 | ||||
| -rw-r--r-- | Boot/BootKit/HW/SATA.hxx | 2 | ||||
| -rw-r--r-- | Boot/BootKit/Platform.hxx | 6 | ||||
| -rw-r--r-- | Boot/BootKit/Protocol.hxx | 2 | ||||
| -rw-r--r-- | Boot/BootKit/Vendor/Shared/base.h | 12 | ||||
| -rw-r--r-- | Boot/BootKit/Vendor/Shared/bit.h | 218 | ||||
| -rw-r--r-- | Boot/BootKit/Vendor/Support.hxx | 20 | ||||
| -rw-r--r-- | Boot/Source/HEL/AMD64/BootAHCI.cxx | 2 | ||||
| -rw-r--r-- | Boot/Source/HEL/AMD64/BootATA.cxx | 16 | ||||
| -rw-r--r-- | Boot/Source/HEL/AMD64/BootFileReader.cxx | 14 | ||||
| -rw-r--r-- | Boot/Source/HEL/AMD64/BootMain.cxx | 4 | ||||
| -rw-r--r-- | Boot/Source/HEL/AMD64/BootPlatform.cxx | 2 | ||||
| -rw-r--r-- | Boot/Source/HEL/AMD64/BootString.cxx | 8 | ||||
| -rw-r--r-- | Boot/Source/HEL/AMD64/BootTextWriter.cxx | 8 | ||||
| -rw-r--r-- | Boot/Source/HEL/AMD64/New+Delete.cxx | 2 | ||||
| -rw-r--r-- | Boot/Source/HEL/AMD64/Support.cxx | 2 |
20 files changed, 164 insertions, 164 deletions
diff --git a/Boot/BootKit/BitManip.hxx b/Boot/BootKit/BitManip.hxx index bf46e75c..cef6c875 100644 --- a/Boot/BootKit/BitManip.hxx +++ b/Boot/BootKit/BitManip.hxx @@ -1,6 +1,6 @@ /* ------------------------------------------- - Copyright SoftwareLabs + Copyright SoftwareLabs ------------------------------------------- */ diff --git a/Boot/BootKit/BootKit.hxx b/Boot/BootKit/BootKit.hxx index 6ddecca1..961137ca 100644 --- a/Boot/BootKit/BootKit.hxx +++ b/Boot/BootKit/BootKit.hxx @@ -1,6 +1,6 @@ /* ------------------------------------------- - Copyright SoftwareLabs + Copyright SoftwareLabs ------------------------------------------- */ diff --git a/Boot/BootKit/Device.hxx b/Boot/BootKit/Device.hxx index 3bdc2829..215c10b6 100644 --- a/Boot/BootKit/Device.hxx +++ b/Boot/BootKit/Device.hxx @@ -1,6 +1,6 @@ /* ------------------------------------------- - Copyright SoftwareLabs + Copyright SoftwareLabs ------------------------------------------- */ diff --git a/Boot/BootKit/EPM.hxx b/Boot/BootKit/EPM.hxx index 0df86724..0cefad5d 100644 --- a/Boot/BootKit/EPM.hxx +++ b/Boot/BootKit/EPM.hxx @@ -1,6 +1,6 @@ /* ------------------------------------------- - Copyright SoftwareLabs + Copyright SoftwareLabs ------------------------------------------- */ diff --git a/Boot/BootKit/HW/ATA.hxx b/Boot/BootKit/HW/ATA.hxx index 8f06739b..d9b251f5 100644 --- a/Boot/BootKit/HW/ATA.hxx +++ b/Boot/BootKit/HW/ATA.hxx @@ -1,6 +1,6 @@ /* ------------------------------------------- - Copyright SoftwareLabs + Copyright SoftwareLabs ------------------------------------------- */ diff --git a/Boot/BootKit/HW/SATA.hxx b/Boot/BootKit/HW/SATA.hxx index 1ad87493..bbb65ec0 100644 --- a/Boot/BootKit/HW/SATA.hxx +++ b/Boot/BootKit/HW/SATA.hxx @@ -1,6 +1,6 @@ /* ------------------------------------------- - Copyright SoftwareLabs + Copyright SoftwareLabs ------------------------------------------- */ diff --git a/Boot/BootKit/Platform.hxx b/Boot/BootKit/Platform.hxx index 972430ce..14a1fa54 100644 --- a/Boot/BootKit/Platform.hxx +++ b/Boot/BootKit/Platform.hxx @@ -1,14 +1,14 @@ /* ------------------------------------------- - Copyright SoftwareLabs + Copyright SoftwareLabs ------------------------------------------- */ #pragma once /** - @file Processor.hxx - @brief Processor specific code. + @file Processor.hxx + @brief Processor specific code. */ #ifdef __x86_64__ diff --git a/Boot/BootKit/Protocol.hxx b/Boot/BootKit/Protocol.hxx index 95a5ca6f..3d9fd9f8 100644 --- a/Boot/BootKit/Protocol.hxx +++ b/Boot/BootKit/Protocol.hxx @@ -1,6 +1,6 @@ /* ------------------------------------------- - Copyright SoftwareLabs + Copyright SoftwareLabs ------------------------------------------- */ diff --git a/Boot/BootKit/Vendor/Shared/base.h b/Boot/BootKit/Vendor/Shared/base.h index a98ae4f0..d1c028d7 100644 --- a/Boot/BootKit/Vendor/Shared/base.h +++ b/Boot/BootKit/Vendor/Shared/base.h @@ -9,12 +9,12 @@ namespace utl { /** - * @brief Helper to get number of elements in array. - * - * @tparam T Auto-deduced element type - * @tparam N Auto-deduced number of elements - * @return Array size - */ + * @brief Helper to get number of elements in array. + * + * @tparam T Auto-deduced element type + * @tparam N Auto-deduced number of elements + * @return Array size + */ template <class T, size_t N> constexpr size_t countof(T (&)[N]) { diff --git a/Boot/BootKit/Vendor/Shared/bit.h b/Boot/BootKit/Vendor/Shared/bit.h index 94ab0bf2..6923e94a 100644 --- a/Boot/BootKit/Vendor/Shared/bit.h +++ b/Boot/BootKit/Vendor/Shared/bit.h @@ -7,11 +7,11 @@ namespace utl { /** - * @brief Size of object in terms of bits. - * - * @tparam T Object type - * @return Number of bits - */ + * @brief Size of object in terms of bits. + * + * @tparam T Object type + * @return Number of bits + */ template <class T> constexpr auto bit_size() { @@ -19,11 +19,11 @@ namespace utl } /** - * @brief Integer with all bits set to 1. - * - * @tparam T Integer type - * @return All set integer - */ + * @brief Integer with all bits set to 1. + * + * @tparam T Integer type + * @return All set integer + */ template <class T> constexpr T bit_full() { @@ -31,15 +31,15 @@ namespace utl } /** - * @brief Wrap around mask for power of two number of bits - * within given integer type. For example: - * [ bit_wrap<uint8_t> = 8 - 1 = 0b111 ] - * [ bit_wrap<uint16_t> = 16 - 1 = 0b1111 ] - * [ bit_wrap<uint32_t> = 32 - 1 = 0b11111 ] - * - * @tparam T Integer type - * @return Wrap around mask for number of bits - */ + * @brief Wrap around mask for power of two number of bits + * within given integer type. For example: + * [ bit_wrap<uint8_t> = 8 - 1 = 0b111 ] + * [ bit_wrap<uint16_t> = 16 - 1 = 0b1111 ] + * [ bit_wrap<uint32_t> = 32 - 1 = 0b11111 ] + * + * @tparam T Integer type + * @return Wrap around mask for number of bits + */ template <class T> constexpr T bit_wrap() { @@ -47,15 +47,15 @@ namespace utl } /** - * @brief Number of bits to fit bit_wrap<T> result, in other words - * bit width of (sizeof(T) * 8 - 1). For example: - * [ bit_shft<uint8_t> = bit_width(0b111) = 3 ] - * [ bit_shft<uint16_t> = bit_width(0b1111) = 4 ] - * [ bit_shft<uint32_t> = bit_width(0b11111) = 5 ] - * - * @tparam T Integer type - * @return Number of bits to shift to divide by sizeof(T) * 8 - */ + * @brief Number of bits to fit bit_wrap<T> result, in other words + * bit width of (sizeof(T) * 8 - 1). For example: + * [ bit_shft<uint8_t> = bit_width(0b111) = 3 ] + * [ bit_shft<uint16_t> = bit_width(0b1111) = 4 ] + * [ bit_shft<uint32_t> = bit_width(0b11111) = 5 ] + * + * @tparam T Integer type + * @return Number of bits to shift to divide by sizeof(T) * 8 + */ template <class T> constexpr auto bit_shft() { @@ -63,13 +63,13 @@ namespace utl } /** - * @brief Round up division by number of bits within given integer type, - * which sizeof(T) * 8 is power of two. - * - * @tparam T Inetegr type - * @param x Dividend - * @return Quotient - */ + * @brief Round up division by number of bits within given integer type, + * which sizeof(T) * 8 is power of two. + * + * @tparam T Inetegr type + * @param x Dividend + * @return Quotient + */ template <class T> constexpr auto bit_ceil(auto x) { @@ -77,11 +77,11 @@ namespace utl } /** - * @brief Count leading zeros. - * - * @param x Unsigned integer argument - * @return Number of leading zeros - */ + * @brief Count leading zeros. + * + * @param x Unsigned integer argument + * @return Number of leading zeros + */ constexpr unsigned cntlz(auto x) { if constexpr (std::is_same_v<decltype(x), int>) @@ -91,11 +91,11 @@ namespace utl } /** - * @brief Count trailing zeros. - * - * @param x Unsigned integer argument - * @return Number of trailing zeros - */ + * @brief Count trailing zeros. + * + * @param x Unsigned integer argument + * @return Number of trailing zeros + */ constexpr unsigned cnttz(auto x) { if constexpr (std::is_same_v<decltype(x), int>) @@ -105,12 +105,12 @@ namespace utl } /** - * @brief Get number of words (integers) required to store N bits. - * - * @tparam T Word integer type - * @param n Number of bits to store - * @return Number of words - */ + * @brief Get number of words (integers) required to store N bits. + * + * @tparam T Word integer type + * @param n Number of bits to store + * @return Number of words + */ template <class T> constexpr size_t words_in_bits(size_t n) { @@ -118,23 +118,23 @@ namespace utl } /** - * @brief Get number of bytes required to store N bits. - * - * @param n Number of bits to store - * @return Number of bytes - */ + * @brief Get number of bytes required to store N bits. + * + * @param n Number of bits to store + * @return Number of bytes + */ constexpr size_t bytes_in_bits(size_t n) { return words_in_bits<uint8_t>(n); } /** - * @brief Make integer with bit at given position. - * - * @tparam T Inetegr type - * @param n Bit position - * @return Integer with set bit - */ + * @brief Make integer with bit at given position. + * + * @tparam T Inetegr type + * @param n Bit position + * @return Integer with set bit + */ template <class T = unsigned> constexpr T bit(int n) { @@ -142,13 +142,13 @@ namespace utl } /** - * @brief Get n-th bit of an integer. - * - * @tparam T Integer type - * @param x Integer - * @param n Bit position from LSB - * @return true if set - */ + * @brief Get n-th bit of an integer. + * + * @tparam T Integer type + * @param x Integer + * @param n Bit position from LSB + * @return true if set + */ template <class T> constexpr bool get_bit(T x, int n) { @@ -156,12 +156,12 @@ namespace utl } /** - * @brief Set n-th bit of an integer. - * - * @tparam T Integer type - * @param x Integer - * @param n Bit position from LSB - */ + * @brief Set n-th bit of an integer. + * + * @tparam T Integer type + * @param x Integer + * @param n Bit position from LSB + */ template <class T> constexpr void set_bit(T& x, int n) { @@ -169,12 +169,12 @@ namespace utl } /** - * @brief Clear n-th bit of an integer. - * - * @tparam T Integer type - * @param x Integer - * @param n Bit position from LSB - */ + * @brief Clear n-th bit of an integer. + * + * @tparam T Integer type + * @param x Integer + * @param n Bit position from LSB + */ template <class T> constexpr void clr_bit(T& x, int n) { @@ -182,13 +182,13 @@ namespace utl } /** - * @brief Get n-th bit in array of words (starting from LSB). - * - * @tparam T Word type - * @param p Array of words - * @param n Index of bit to get - * @return true if set - */ + * @brief Get n-th bit in array of words (starting from LSB). + * + * @tparam T Word type + * @param p Array of words + * @param n Index of bit to get + * @return true if set + */ template <class T> constexpr bool get_arr_bit(const T* p, unsigned n) { @@ -196,12 +196,12 @@ namespace utl } /** - * @brief Set n-th bit in array of words (starting from LSB). - * - * @tparam T Word type - * @param p Array of words - * @param n Index of bit to set - */ + * @brief Set n-th bit in array of words (starting from LSB). + * + * @tparam T Word type + * @param p Array of words + * @param n Index of bit to set + */ template <class T> constexpr void set_arr_bit(T* p, unsigned n) { @@ -209,12 +209,12 @@ namespace utl } /** - * @brief Clear n-th bit in array of words (starting from LSB). - * - * @tparam T Word type - * @param p Array of words - * @param n Index of bit to clear - */ + * @brief Clear n-th bit in array of words (starting from LSB). + * + * @tparam T Word type + * @param p Array of words + * @param n Index of bit to clear + */ template <class T> constexpr void clr_arr_bit(T* p, unsigned n) { @@ -222,15 +222,15 @@ namespace utl } /** - * @brief Shift bits left in array of integer elements from least significant bit - * and considering 0-th byte as the right most. - * uint16_t example: 0b10000000'11100001 ==> 0b00000001'11000010. - * - * @tparam T Integer type - * @tparam L Length of array - * @param x Array of integers, nullptr not acceptable! - * @param len Number of elements - */ + * @brief Shift bits left in array of integer elements from least significant bit + * and considering 0-th byte as the right most. + * uint16_t example: 0b10000000'11100001 ==> 0b00000001'11000010. + * + * @tparam T Integer type + * @tparam L Length of array + * @param x Array of integers, nullptr not acceptable! + * @param len Number of elements + */ template <class T, size_t L> constexpr void shift_left(T (&x)[L]) { diff --git a/Boot/BootKit/Vendor/Support.hxx b/Boot/BootKit/Vendor/Support.hxx index a2c2af65..6a480779 100644 --- a/Boot/BootKit/Vendor/Support.hxx +++ b/Boot/BootKit/Vendor/Support.hxx @@ -1,6 +1,6 @@ /* ------------------------------------------- - Copyright SoftwareLabs + Copyright SoftwareLabs ------------------------------------------- */ @@ -32,17 +32,17 @@ inline long StringToLong(const char* nptr, char** endptr, int base) /* Need unsigned so (-cLongMin) can fit in these: */ unsigned long n = 0UL, cutoff; int cutlim; - + if (base < 0 || base == 1 || base > 36) { return 0L; } - + endp = nptr; - + while (IsSpace(*p)) p++; - + if (*p == '+') { p++; @@ -55,8 +55,8 @@ inline long StringToLong(const char* nptr, char** endptr, int base) { p++; /* For strtol(" 0xZ", &endptr, 16), endptr should point to 'x'; - * pointing to ' ' or '0' is non-compliant. - * (Many implementations do this wrong.) */ + * pointing to ' ' or '0' is non-compliant. + * (Many implementations do this wrong.) */ endp = p; if (base == 16 && (*p == 'X' || *p == 'x')) { @@ -87,10 +87,10 @@ inline long StringToLong(const char* nptr, char** endptr, int base) { base = 10; } - + cutoff = (is_neg) ? -(cLongMin / base) : cLongMax / base; cutlim = (is_neg) ? -(cLongMin % base) : cLongMax % base; - + while (1) { int c; @@ -106,7 +106,7 @@ inline long StringToLong(const char* nptr, char** endptr, int base) if (overflow) { /* endptr should go forward and point to the non-digit character - * (of the given base); required by ANSI standard. */ + * (of the given base); required by ANSI standard. */ if (endptr) continue; break; diff --git a/Boot/Source/HEL/AMD64/BootAHCI.cxx b/Boot/Source/HEL/AMD64/BootAHCI.cxx index 6676f660..d60b91fd 100644 --- a/Boot/Source/HEL/AMD64/BootAHCI.cxx +++ b/Boot/Source/HEL/AMD64/BootAHCI.cxx @@ -1,6 +1,6 @@ /* ------------------------------------------- - Copyright SoftwareLabs + Copyright SoftwareLabs ------------------------------------------- */ diff --git a/Boot/Source/HEL/AMD64/BootATA.cxx b/Boot/Source/HEL/AMD64/BootATA.cxx index 499596ca..c82cb2ea 100644 --- a/Boot/Source/HEL/AMD64/BootATA.cxx +++ b/Boot/Source/HEL/AMD64/BootATA.cxx @@ -1,6 +1,6 @@ /* ------------------------------------------- - Copyright SoftwareLabs + Copyright SoftwareLabs ------------------------------------------- */ @@ -202,9 +202,9 @@ BootDeviceATA::operator bool() } /** - @brief Read Buf from disk - @param Sz Sector size - @param Buf buffer + @brief Read Buf from disk + @param Sz Sector size + @param Buf buffer */ BootDeviceATA& BootDeviceATA::Read(CharacterTypeUTF8* Buf, const SizeT& SectorSz) { @@ -228,9 +228,9 @@ BootDeviceATA& BootDeviceATA::Read(CharacterTypeUTF8* Buf, const SizeT& SectorSz } /** - @brief Write Buf into disk - @param Sz Sector size - @param Buf buffer + @brief Write Buf into disk + @param Sz Sector size + @param Buf buffer */ BootDeviceATA& BootDeviceATA::Write(CharacterTypeUTF8* Buf, const SizeT& SectorSz) { @@ -263,7 +263,7 @@ BootDeviceATA::ATATrait& BootDeviceATA::Leak() } /*** - @brief Getter, gets the number of sectors inside the drive. + @brief Getter, gets the number of sectors inside the drive. */ SizeT BootDeviceATA::GetSectorsCount() noexcept { diff --git a/Boot/Source/HEL/AMD64/BootFileReader.cxx b/Boot/Source/HEL/AMD64/BootFileReader.cxx index 61adc4f3..7ec6b7ab 100644 --- a/Boot/Source/HEL/AMD64/BootFileReader.cxx +++ b/Boot/Source/HEL/AMD64/BootFileReader.cxx @@ -1,10 +1,10 @@ /* ------------------------------------------- - Copyright SoftwareLabs + Copyright SoftwareLabs - File: FileReader.cxx - Purpose: New Boot FileReader, - Read complete file and store it in a buffer. + File: FileReader.cxx + Purpose: New Boot FileReader, + Read complete file and store it in a buffer. ------------------------------------------- */ @@ -29,7 +29,7 @@ //////////////////////////////////////////////////////////////////////////////////////////////////// /*** - @brief File Reader constructor. + @brief File Reader constructor. */ BFileReader::BFileReader(const CharacterTypeUTF16* path, EfiHandlePtr ImageHandle) @@ -111,8 +111,8 @@ BFileReader::~BFileReader() } /** - @brief this reads all of the buffer. - @param until read until size is reached. + @brief this reads all of the buffer. + @param until read until size is reached. */ Void BFileReader::ReadAll(SizeT until, SizeT chunk) { diff --git a/Boot/Source/HEL/AMD64/BootMain.cxx b/Boot/Source/HEL/AMD64/BootMain.cxx index 649596b4..f58709be 100644 --- a/Boot/Source/HEL/AMD64/BootMain.cxx +++ b/Boot/Source/HEL/AMD64/BootMain.cxx @@ -1,6 +1,6 @@ /* ------------------------------------------- - Copyright SoftwareLabs + Copyright SoftwareLabs ------------------------------------------- */ @@ -31,7 +31,7 @@ STATIC EfiGUID kGopGuid; EXTERN_C Void hal_init_platform(HEL::HandoverInformationHeader* HIH); /** - @brief Finds and stores the GOP. + @brief Finds and stores the GOP. */ STATIC Void CheckAndFindFramebuffer() noexcept diff --git a/Boot/Source/HEL/AMD64/BootPlatform.cxx b/Boot/Source/HEL/AMD64/BootPlatform.cxx index 9d125ec6..866c4839 100644 --- a/Boot/Source/HEL/AMD64/BootPlatform.cxx +++ b/Boot/Source/HEL/AMD64/BootPlatform.cxx @@ -1,6 +1,6 @@ /* ------------------------------------------- - Copyright SoftwareLabs + Copyright SoftwareLabs ------------------------------------------- */ diff --git a/Boot/Source/HEL/AMD64/BootString.cxx b/Boot/Source/HEL/AMD64/BootString.cxx index a93943cf..54ab2c64 100644 --- a/Boot/Source/HEL/AMD64/BootString.cxx +++ b/Boot/Source/HEL/AMD64/BootString.cxx @@ -1,11 +1,11 @@ /* ------------------------------------------- - Copyright SoftwareLabs + Copyright SoftwareLabs - File: String.cxx - Purpose: NewBoot string library + File: String.cxx + Purpose: NewBoot string library - Revision History: + Revision History: diff --git a/Boot/Source/HEL/AMD64/BootTextWriter.cxx b/Boot/Source/HEL/AMD64/BootTextWriter.cxx index 30c328ad..90d12f3d 100644 --- a/Boot/Source/HEL/AMD64/BootTextWriter.cxx +++ b/Boot/Source/HEL/AMD64/BootTextWriter.cxx @@ -1,11 +1,11 @@ /* ------------------------------------------- - Copyright SoftwareLabs + Copyright SoftwareLabs - File: String.cxx - Purpose: NewBoot string library + File: String.cxx + Purpose: NewBoot string library - Revision History: + Revision History: diff --git a/Boot/Source/HEL/AMD64/New+Delete.cxx b/Boot/Source/HEL/AMD64/New+Delete.cxx index 3316ac1d..6c025646 100644 --- a/Boot/Source/HEL/AMD64/New+Delete.cxx +++ b/Boot/Source/HEL/AMD64/New+Delete.cxx @@ -1,6 +1,6 @@ /* ------------------------------------------- - Copyright SoftwareLabs + Copyright SoftwareLabs ------------------------------------------- */ diff --git a/Boot/Source/HEL/AMD64/Support.cxx b/Boot/Source/HEL/AMD64/Support.cxx index 12c136f8..22b01280 100644 --- a/Boot/Source/HEL/AMD64/Support.cxx +++ b/Boot/Source/HEL/AMD64/Support.cxx @@ -1,6 +1,6 @@ /* ------------------------------------------- - Copyright SoftwareLabs + Copyright SoftwareLabs ------------------------------------------- */ |
