[includes] remove lk/utils.h which seem to be unused on anything in mainline
Was a bit of a hodgepodge of defines. If any of these are needed we can add them back somewhere a bit more appropriate. ARRAY_SIZE can use countof() defined in compiler.h KB/MB/GB are generally duplicately defined in architecture specific files, but not generically. I couldn't think off the top of my head of a better place to generically put these, especially since they're used in asm files, so just deleted it for now. The other stuff seemed to be just unused anywhere.
This commit is contained in:
@@ -1,21 +0,0 @@
|
||||
/*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
* Copyright (C) 2020-2023 Google LLC.
|
||||
*/
|
||||
|
||||
#pragma once
|
||||
|
||||
#define ARRAY_SIZE(_a) (sizeof(_a) / sizeof(*(_a)))
|
||||
|
||||
#define KB (1024UL)
|
||||
#define MB (1024UL * 1024UL)
|
||||
#define GB (1024UL * 1024UL * 1024UL)
|
||||
|
||||
#define RETURN_IF_ERROR(expr) \
|
||||
do { \
|
||||
status_t err_ = (expr); \
|
||||
if (err_ != NO_ERROR) { \
|
||||
return err_; \
|
||||
} \
|
||||
} while (0)
|
||||
Reference in New Issue
Block a user