diff --git a/src/system/boot/platform/openfirmware/Handle.cpp b/src/system/boot/platform/openfirmware/Handle.cpp index 00ff3a2706..1ff0f87d75 100644 --- a/src/system/boot/platform/openfirmware/Handle.cpp +++ b/src/system/boot/platform/openfirmware/Handle.cpp @@ -1,15 +1,16 @@ /* - * Copyright 2003, Axel Dörfler, axeld@pinc-software.de. All rights reserved. - * Distributed under the terms of the MIT License. + * Copyright 2003, Axel Dörfler, axeld@pinc-software.de. + * All rights reserved. Distributed under the terms of the MIT License. */ +#include "Handle.h" + #include + #include #include -#include "Handle.h" - Handle::Handle(int handle, bool takeOwnership) : diff --git a/src/system/boot/platform/openfirmware/arch/ppc/mmu.cpp b/src/system/boot/platform/openfirmware/arch/ppc/mmu.cpp index 259d75c840..f21d91022d 100644 --- a/src/system/boot/platform/openfirmware/arch/ppc/mmu.cpp +++ b/src/system/boot/platform/openfirmware/arch/ppc/mmu.cpp @@ -4,6 +4,8 @@ */ +#include + #include #include #include @@ -15,8 +17,6 @@ #include #include -#include - // set protection to WIMGNPP: -----PP // PP: 00 - no access diff --git a/src/system/boot/platform/openfirmware/console.cpp b/src/system/boot/platform/openfirmware/console.cpp index 95bb65aba7..2ba6422278 100644 --- a/src/system/boot/platform/openfirmware/console.cpp +++ b/src/system/boot/platform/openfirmware/console.cpp @@ -54,7 +54,8 @@ FILE *stdin, *stdout, *stderr; ConsoleHandle::ConsoleHandle() - : Handle() + : + Handle() { } @@ -117,9 +118,10 @@ ConsoleHandle::WriteAt(void */*cookie*/, off_t /*pos*/, const void *buffer, InputConsoleHandle::InputConsoleHandle() - : ConsoleHandle() - , fStart(0) - , fCount(0) + : + ConsoleHandle(), + fStart(0), + fCount(0) { } diff --git a/src/system/boot/platform/openfirmware/devices.cpp b/src/system/boot/platform/openfirmware/devices.cpp index 601ac5059c..9e0f5a5f41 100644 --- a/src/system/boot/platform/openfirmware/devices.cpp +++ b/src/system/boot/platform/openfirmware/devices.cpp @@ -1,10 +1,10 @@ /* - * Copyright 2003-2006, Axel Dörfler, axeld@pinc-software.de. All rights reserved. - * Distributed under the terms of the MIT License. + * Copyright 2003-2006, Axel Dörfler, axeld@pinc-software.de. + * All rights reserved. Distributed under the terms of the MIT License. */ -#include "Handle.h" -#include "machine.h" + +#include #include #include @@ -16,7 +16,8 @@ #include #include -#include +#include "Handle.h" +#include "machine.h" char sBootPath[192]; @@ -175,7 +176,8 @@ platform_add_block_devices(stage2_args *args, NodeList *devicesList) } Handle *device = new(nothrow) Handle(handle); - printf("\t\t(could open device, handle = %p, node = %p)\n", (void *)handle, device); + printf("\t\t(could open device, handle = %p, node = %p)\n", + (void *)handle, device); devicesList->Add(device); } @@ -184,6 +186,7 @@ platform_add_block_devices(stage2_args *args, NodeList *devicesList) return B_OK; } + status_t platform_register_boot_device(Node *device) { diff --git a/src/system/boot/platform/openfirmware/heap.cpp b/src/system/boot/platform/openfirmware/heap.cpp index 706130d683..3ff41ad67d 100644 --- a/src/system/boot/platform/openfirmware/heap.cpp +++ b/src/system/boot/platform/openfirmware/heap.cpp @@ -1,8 +1,9 @@ /* - * Copyright 2003, Axel Dörfler, axeld@pinc-software.de. All rights reserved. - * Distributed under the terms of the MIT License. + * Copyright 2003, Axel Dörfler, axeld@pinc-software.de. + * All rights reserved. Distributed under the terms of the MIT License. */ + #include #include diff --git a/src/system/boot/platform/openfirmware/menu.cpp b/src/system/boot/platform/openfirmware/menu.cpp index c0b06e7c2a..d14c87e435 100644 --- a/src/system/boot/platform/openfirmware/menu.cpp +++ b/src/system/boot/platform/openfirmware/menu.cpp @@ -1,6 +1,6 @@ /* - * Copyright 2004, Axel Dörfler, axeld@pinc-software.de. All rights reserved. - * Distributed under the terms of the MIT License. + * Copyright 2004, Axel Dörfler, axeld@pinc-software.de. + * All rights reserved. Distributed under the terms of the MIT License. */ diff --git a/src/system/boot/platform/openfirmware/mmu.cpp b/src/system/boot/platform/openfirmware/mmu.cpp index e948a98477..b765e8dcb1 100644 --- a/src/system/boot/platform/openfirmware/mmu.cpp +++ b/src/system/boot/platform/openfirmware/mmu.cpp @@ -1,6 +1,6 @@ /* - * Copyright 2003, Axel Dörfler, axeld@pinc-software.de. All rights reserved. - * Distributed under the terms of the MIT License. + * Copyright 2003, Axel Dörfler, axeld@pinc-software.de. + * All rights reserved. Distributed under the terms of the MIT License. */ diff --git a/src/system/boot/platform/openfirmware/real_time_clock.cpp b/src/system/boot/platform/openfirmware/real_time_clock.cpp index bac4960832..a87f851713 100644 --- a/src/system/boot/platform/openfirmware/real_time_clock.cpp +++ b/src/system/boot/platform/openfirmware/real_time_clock.cpp @@ -3,6 +3,7 @@ * All rights reserved. Distributed under the terms of the MIT License. */ + #include "real_time_clock.h" #include @@ -12,6 +13,7 @@ #include #include + status_t init_real_time_clock(void) { diff --git a/src/system/boot/platform/openfirmware/start.cpp b/src/system/boot/platform/openfirmware/start.cpp index ec674abaea..b159023b87 100644 --- a/src/system/boot/platform/openfirmware/start.cpp +++ b/src/system/boot/platform/openfirmware/start.cpp @@ -4,15 +4,16 @@ */ +#include + #include + #include #include #include #include #include -#include - #include "console.h" #include "machine.h" #include "real_time_clock.h" @@ -61,7 +62,8 @@ determine_machine(void) int root = of_finddevice("/"); char buffer[64]; int length; - if ((length = of_getprop(root, "device_type", buffer, sizeof(buffer) - 1)) == OF_FAILED) + if ((length = of_getprop(root, "device_type", buffer, sizeof(buffer) - 1)) + == OF_FAILED) return; buffer[length] = '\0'; @@ -72,7 +74,8 @@ determine_machine(void) else if (!strcasecmp("bootrom", buffer)) gMachine = MACHINE_MAC; - if ((length = of_getprop(root, "model", buffer, sizeof(buffer) - 1)) == OF_FAILED) + if ((length = of_getprop(root, "model", buffer, sizeof(buffer) - 1)) + == OF_FAILED) return; buffer[length] = '\0'; @@ -143,7 +146,8 @@ start(void *openFirmwareEntry) of_init((int (*)(void*))openFirmwareEntry); // check for arguments - if (of_getprop(gChosen, "bootargs", bootargs, sizeof(bootargs)) != OF_FAILED) { + if (of_getprop(gChosen, "bootargs", bootargs, sizeof(bootargs)) + != OF_FAILED) { static const char *sArgs[] = { NULL, NULL }; sArgs[0] = (const char *)bootargs; args.arguments = sArgs; @@ -152,7 +156,7 @@ start(void *openFirmwareEntry) determine_machine(); console_init(); - // Initialize and take over MMU and set the OpenFirmware callbacks - it + // Initialize and take over MMU and set the OpenFirmware callbacks - it // will ask us for memory after that instead of maintaining it itself // (the kernel will need to adjust the callback later on as well) arch_mmu_init(); diff --git a/src/system/boot/platform/openfirmware/support.cpp b/src/system/boot/platform/openfirmware/support.cpp index 965b2e43a1..2333b8eb24 100644 --- a/src/system/boot/platform/openfirmware/support.cpp +++ b/src/system/boot/platform/openfirmware/support.cpp @@ -3,10 +3,12 @@ * All rights reserved. Distributed under the terms of the MIT License. */ + #include #include + bigtime_t system_time(void) {