chromium/gin/thread_isolation.cc

// Copyright 2023 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

#include "gin/thread_isolation.h"

#if PA_BUILDFLAG(ENABLE_THREAD_ISOLATION)

#include <sys/mman.h>
#include <sys/utsname.h>

#include <cstddef>

#include "base/check.h"
#include "base/check_op.h"
#include "base/memory/page_size.h"
#include "base/metrics/histogram_functions.h"
#include "base/no_destructor.h"
#include "partition_alloc/thread_isolation/alignment.h"
#include "third_party/abseil-cpp/absl/base/attributes.h"

extern int pkey_alloc(unsigned int flags,
                      unsigned int access_rights) ABSL_ATTRIBUTE_WEAK;

namespace {

bool KernelHasPkruFix() {}

int PkeyAlloc(int access_rights) {}

uint32_t Rdpkru() {}

void Wrpkru(uint32_t pkru) {}

static constexpr uint32_t kBitsPerPkey =;

void PkeyDisableWriteAccess(int pkey) {}

}  // namespace

namespace gin {

void ThreadIsolationData::InitializeBeforeThreadCreation() {}

bool ThreadIsolationData::Initialized() const {}

ThreadIsolationData& GetThreadIsolationData() {}

}  // namespace gin

#endif  // PA_BUILDFLAG(ENABLE_THREAD_ISOLATION)