summaryrefslogtreecommitdiff
path: root/src/device/device_util.c
diff options
context:
space:
mode:
authorLubomir Rintel <lkundrak@v3.sk>2018-04-26 00:00:22 +0200
committerPatrick Georgi <pgeorgi@google.com>2018-04-30 06:22:13 +0000
commit9ba8f7c28e23c4064e09a40c383f2713ad955c25 (patch)
treebb0b22fb8cd6a0f01f4564b6042d6af62eb342f9 /src/device/device_util.c
parentecef322bf4a1d2033286c10970f09663a1214ebb (diff)
downloadcoreboot-9ba8f7c28e23c4064e09a40c383f2713ad955c25.tar.xz
device: constify some variables
Change-Id: I6830a65bc9cea2907f4209bb97a53ccebcbf248d Signed-off-by: Lubomir Rintel <lkundrak@v3.sk> Reviewed-on: https://review.coreboot.org/25873 Reviewed-by: Aaron Durbin <adurbin@chromium.org> Reviewed-by: Paul Menzel <paulepanter@users.sourceforge.net> Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Diffstat (limited to 'src/device/device_util.c')
-rw-r--r--src/device/device_util.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/device/device_util.c b/src/device/device_util.c
index 6bc2730143..3d7f5a154a 100644
--- a/src/device/device_util.c
+++ b/src/device/device_util.c
@@ -269,7 +269,7 @@ u32 dev_path_encode(struct device *dev)
* Warning: This function uses a static buffer. Don't call it more than once
* from the same print statement!
*/
-const char *dev_path(struct device *dev)
+const char *dev_path(const struct device *dev)
{
static char buffer[DEVICE_PATH_MAX];
@@ -814,7 +814,7 @@ bool dev_is_active_bridge(struct device *dev)
return 0;
}
-static void resource_tree(struct device *root, int debug_level, int depth)
+static void resource_tree(const struct device *root, int debug_level, int depth)
{
int i = 0;
struct device *child;
@@ -846,7 +846,7 @@ static void resource_tree(struct device *root, int debug_level, int depth)
}
}
-void print_resource_tree(struct device *root, int debug_level, const char *msg)
+void print_resource_tree(const struct device *root, int debug_level, const char *msg)
{
/* Bail if root is null. */
if (!root) {
@@ -862,7 +862,7 @@ void print_resource_tree(struct device *root, int debug_level, const char *msg)
resource_tree(root, debug_level, 0);
}
-void show_devs_tree(struct device *dev, int debug_level, int depth)
+void show_devs_tree(const struct device *dev, int debug_level, int depth)
{
char depth_str[20];
int i;