util: add SPDK_CACHE_LINE_SIZE macro definition
For now we don't provide #ifdef to users, SPDK_CACHE_LINE_SIZE is defined with 64 bytes. Change-Id: I8ddb01a382008a3e333967650200c5aa8b93e09e Signed-off-by: Changpeng Liu <changpeng.liu@intel.com> Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/477385 Tested-by: SPDK CI Jenkins <sys_sgci@intel.com> Community-CI: SPDK CI Jenkins <sys_sgci@intel.com> Reviewed-by: Jim Harris <james.r.harris@intel.com> Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com> Reviewed-by: Ben Walker <benjamin.walker@intel.com> Reviewed-by: Paul Luse <paul.e.luse@intel.com>
This commit is contained in:
parent
1d11ab120d
commit
65506d5116
@ -44,6 +44,8 @@
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#define SPDK_CACHE_LINE_SIZE 64
|
||||
|
||||
#define spdk_min(a,b) (((a)<(b))?(a):(b))
|
||||
#define spdk_max(a,b) (((a)>(b))?(a):(b))
|
||||
|
||||
|
@ -81,7 +81,7 @@ struct spdk_reactor {
|
||||
|
||||
/* The last known rusage values */
|
||||
struct rusage rusage;
|
||||
} __attribute__((aligned(64)));
|
||||
} __attribute__((aligned(SPDK_CACHE_LINE_SIZE)));
|
||||
|
||||
static struct spdk_reactor *g_reactors;
|
||||
static struct spdk_cpuset *g_reactor_core_mask;
|
||||
|
@ -42,11 +42,10 @@
|
||||
#include "spdk_internal/vhost_user.h"
|
||||
#include "spdk_internal/log.h"
|
||||
#include "spdk/event.h"
|
||||
#include "spdk/util.h"
|
||||
#include "spdk/rpc.h"
|
||||
#include "spdk/config.h"
|
||||
|
||||
#define SPDK_CACHE_LINE_SIZE RTE_CACHE_LINE_SIZE
|
||||
|
||||
#define SPDK_VHOST_MAX_VQUEUES 256
|
||||
#define SPDK_VHOST_MAX_VQ_SIZE 1024
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user