diff --git a/headers/private/kernel/boot_device.h b/headers/private/kernel/boot_device.h new file mode 100644 index 0000000000..915a08d715 --- /dev/null +++ b/headers/private/kernel/boot_device.h @@ -0,0 +1,15 @@ +/* + * Copyright 2005, Axel Dörfler, axeld@pinc-software.de. All rights reserved. + * Distributed under the terms of the MIT License. + */ +#ifndef _KERNEL_BOOT_DEVICE_H +#define _KERNEL_BOOT_DEVICE_H + + +#include + + +extern dev_t gBootDevice; + // defined in fs/vfs_boot.cpp + +#endif /* _KERNEL_BOOT_DEVICE_H */ diff --git a/src/system/kernel/device_manager/probe.cpp b/src/system/kernel/device_manager/probe.cpp index b8aa8ff5ea..f59e54de62 100644 --- a/src/system/kernel/device_manager/probe.cpp +++ b/src/system/kernel/device_manager/probe.cpp @@ -15,8 +15,7 @@ #include "device_manager_private.h" -#include -#include +#include #include #include #include @@ -24,6 +23,9 @@ #include #include +#include +#include + #include #include #include @@ -70,8 +72,6 @@ static const char *kModulePaths[] = { NULL }; -extern dev_t gBootDevice; - // from fs/vfs.cpp class DirectoryIterator { public: diff --git a/src/system/kernel/fs/devfs.cpp b/src/system/kernel/fs/devfs.cpp index dbe43c29b4..0097a5df7d 100644 --- a/src/system/kernel/fs/devfs.cpp +++ b/src/system/kernel/fs/devfs.cpp @@ -14,6 +14,7 @@ #include #include +#include #include #include #include @@ -136,9 +137,6 @@ static status_t publish_device(struct devfs *fs, const char *path, driver_entry *driver, device_hooks *ops); -// The boot device, if already present -extern dev_t gBootDevice; - /* the one and only allowed devfs instance */ static struct devfs *sDeviceFileSystem = NULL; diff --git a/src/system/kernel/module.c b/src/system/kernel/module.c index 967de4fabc..3d6e9ca4f6 100644 --- a/src/system/kernel/module.c +++ b/src/system/kernel/module.c @@ -11,17 +11,18 @@ */ +#include +#include #include #include -#include -#include #include +#include #include -#include +#include #include #include -#include +#include //#define TRACE_MODULE @@ -160,8 +161,6 @@ static const char * const sModulePaths[] = { static hash_table *sModuleImagesHash; static hash_table *sModulesHash; -extern dev_t gBootDevice; - /** calculates hash for a module using its name */