blob: 8a5d3a04088fbf5e1db0c230f63dc3ea7a8ed6c6 [file] [log] [blame]
David Brazdilb856be62020-03-25 10:14:55 +00001/*
2 * Copyright 2020 The Hafnium Authors.
3 *
Andrew Walbrane959ec12020-06-17 15:01:09 +01004 * Use of this source code is governed by a BSD-style
5 * license that can be found in the LICENSE file or at
6 * https://opensource.org/licenses/BSD-3-Clause.
David Brazdilb856be62020-03-25 10:14:55 +00007 */
8
9#pragma once
10
11#include "hf/boot_params.h"
12#include "hf/mm.h"
13#include "hf/mpool.h"
14
15/** Apply an update to the FDT. */
16bool fdt_patch(struct mm_stage1_locked stage1_locked, paddr_t fdt_addr,
17 struct boot_params_update *p, struct mpool *ppool);
Fuad Tabba50469e02020-06-30 15:14:28 +010018
19/** Patches a secondary VM's FDT with the location of its memory range. */
20bool fdt_patch_mem(struct mm_stage1_locked stage1_locked, paddr_t fdt_addr,
21 size_t fdt_max_size, paddr_t mem_begin, paddr_t mem_end,
22 struct mpool *ppool);