Commit c45f627d authored by Soby Mathew's avatar Soby Mathew
Browse files

Move SIZE_FROM_LOG2_WORDS macro to utils.h

This patch moves the macro SIZE_FROM_LOG2_WORDS() defined in
`arch.h` to `utils.h` as it is utility macro.

Change-Id: Ia8171a226978f053a1ee4037f80142c0a4d21430
parent 12ab697e
...@@ -38,6 +38,7 @@ ...@@ -38,6 +38,7 @@
#include <platform.h> #include <platform.h>
#include <platform_def.h> #include <platform_def.h>
#include <smcc_helpers.h> #include <smcc_helpers.h>
#include <utils.h>
#include "bl1_private.h" #include "bl1_private.h"
#include <uuid.h> #include <uuid.h>
......
/* /*
* Copyright (c) 2013-2015, ARM Limited and Contributors. All rights reserved. * Copyright (c) 2013-2016, ARM Limited and Contributors. All rights reserved.
* *
* Redistribution and use in source and binary forms, with or without * Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met: * modification, are permitted provided that the following conditions are met:
...@@ -334,8 +334,6 @@ ...@@ -334,8 +334,6 @@
#define CTR_IMINLINE_MASK 0xf #define CTR_IMINLINE_MASK 0xf
#define MAX_CACHE_LINE_SIZE 0x800 /* 2KB */ #define MAX_CACHE_LINE_SIZE 0x800 /* 2KB */
#define SIZE_FROM_LOG2_WORDS(n) (4 << (n))
/* Physical timer control register bit fields shifts and masks */ /* Physical timer control register bit fields shifts and masks */
#define CNTP_CTL_ENABLE_SHIFT 0 #define CNTP_CTL_ENABLE_SHIFT 0
......
...@@ -38,6 +38,8 @@ ...@@ -38,6 +38,8 @@
#define IS_POWER_OF_TWO(x) \ #define IS_POWER_OF_TWO(x) \
(((x) & ((x) - 1)) == 0) (((x) & ((x) - 1)) == 0)
#define SIZE_FROM_LOG2_WORDS(n) (4 << (n))
/* /*
* The round_up() macro rounds up a value to the given boundary in a * The round_up() macro rounds up a value to the given boundary in a
* type-agnostic yet type-safe manner. The boundary must be a power of two. * type-agnostic yet type-safe manner. The boundary must be a power of two.
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment