blob: e78b0af8ceac18c1a60cd7e1cc3d9f49cbc5231d [file] [log] [blame]
Aaron Durbin5add4352014-09-17 11:43:20 -05001/*
2 * This file is part of the coreboot project.
3 *
4 * Copyright 2014 Google Inc.
5 *
6 * This program is free software; you can redistribute it and/or modify
7 * it under the terms of the GNU General Public License as published by
8 * the Free Software Foundation; version 2 of the License.
9 *
10 * This program is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 * GNU General Public License for more details.
14 *
15 * You should have received a copy of the GNU General Public License
16 * along with this program; if not, write to the Free Software
Patrick Georgib890a122015-03-26 15:17:45 +010017 * Foundation, Inc.
Aaron Durbin5add4352014-09-17 11:43:20 -050018 */
19
20#include <arch/asm.h>
21
22ENTRY(__wait_for_spin_table_request)
23 /* Entry here is in EL2 with the magic address in x0. */
24 mov x28, x0
251:
26 ldr x27, [x28]
27 cmp x27, xzr
28 b.ne 2f
29 wfe
30 b 1b
312:
32 /* Entry into the kernel. */
33 mov x0, xzr
34 mov x1, xzr
35 mov x2, xzr
36 mov x3, xzr
37 br x27
38ENDPROC(__wait_for_spin_table_request)