diff options
author | Marvin Borner | 2020-03-18 17:32:50 +0100 |
---|---|---|
committer | Marvin Borner | 2020-03-18 17:32:50 +0100 |
commit | f495cc1e93710c233292a503720ec235a61b685c (patch) | |
tree | 23b0b4b82b6d80001c1ffdb15f00b93cbdc65722 /src/kernel/sound/frequency.c | |
parent | c6657aac0c5d5ecf347bc082cb6df38e1174d297 (diff) |
Applied official linux kernel code style guidelines
Due to my change to vim and the clang-format plugin this was needed!
Diffstat (limited to 'src/kernel/sound/frequency.c')
-rw-r--r-- | src/kernel/sound/frequency.c | 30 |
1 files changed, 15 insertions, 15 deletions
diff --git a/src/kernel/sound/frequency.c b/src/kernel/sound/frequency.c index 5c45c60..772df10 100644 --- a/src/kernel/sound/frequency.c +++ b/src/kernel/sound/frequency.c @@ -4,31 +4,31 @@ void play_sound(uint32_t frequency) { - uint32_t divided; - uint8_t tmp; + uint32_t divided; + uint8_t tmp; - divided = 1193180 / frequency; - outb(0x43, 0xb6); - outb(0x42, (uint8_t) (divided)); - outb(0x42, (uint8_t) (divided >> 8)); + divided = 1193180 / frequency; + outb(0x43, 0xb6); + outb(0x42, (uint8_t)(divided)); + outb(0x42, (uint8_t)(divided >> 8)); - tmp = inb(0x61); - if (tmp != (tmp | 3)) { - outb(0x61, (uint8_t) (tmp | 3)); - } + tmp = inb(0x61); + if (tmp != (tmp | 3)) { + outb(0x61, (uint8_t)(tmp | 3)); + } } static void shut_up() { - uint8_t tmp = (uint8_t) (inb(0x61) & 0xFC); + uint8_t tmp = (uint8_t)(inb(0x61) & 0xFC); - outb(0x61, tmp); + outb(0x61, tmp); } // Make a beep void beep(uint32_t frequency, uint32_t ticks) { - play_sound(frequency); - timer_wait((int) ticks); - shut_up(); + play_sound(frequency); + timer_wait((int)ticks); + shut_up(); }
\ No newline at end of file |