1249967Sneel/*-
2249967Sneel * Copyright (c) 2013 Anish Gupta (akgupt3@gmail.com)
3249967Sneel * All rights reserved.
4249967Sneel *
5249967Sneel * Redistribution and use in source and binary forms, with or without
6249967Sneel * modification, are permitted provided that the following conditions
7249967Sneel * are met:
8249967Sneel * 1. Redistributions of source code must retain the above copyright
9249967Sneel *    notice unmodified, this list of conditions, and the following
10249967Sneel *    disclaimer.
11249967Sneel * 2. Redistributions in binary form must reproduce the above copyright
12249967Sneel *    notice, this list of conditions and the following disclaimer in the
13249967Sneel *    documentation and/or other materials provided with the distribution.
14249967Sneel *
15249967Sneel * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
16249967Sneel * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
17249967Sneel * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
18249967Sneel * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
19249967Sneel * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
20249967Sneel * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
21249967Sneel * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
22249967Sneel * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
23249967Sneel * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
24249967Sneel * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
25249967Sneel */
26249967Sneel
27249967Sneel#include <sys/cdefs.h>
28249967Sneel__FBSDID("$FreeBSD: releng/10.3/sys/amd64/vmm/amd/svm_genassym.c 285015 2015-07-01 19:46:57Z neel $");
29249967Sneel
30249967Sneel#include <sys/param.h>
31249967Sneel#include <sys/assym.h>
32285015Sneel#include <x86/specialreg.h>
33249967Sneel
34249967Sneel#include "svm.h"
35249967Sneel
36249967SneelASSYM(SCTX_RBX, offsetof(struct svm_regctx, sctx_rbx));
37249967SneelASSYM(SCTX_RCX, offsetof(struct svm_regctx, sctx_rcx));
38249967SneelASSYM(SCTX_RBP, offsetof(struct svm_regctx, sctx_rbp));
39272195SneelASSYM(SCTX_RDX, offsetof(struct svm_regctx, sctx_rdx));
40272195SneelASSYM(SCTX_RDI, offsetof(struct svm_regctx, sctx_rdi));
41272195SneelASSYM(SCTX_RSI, offsetof(struct svm_regctx, sctx_rsi));
42249967SneelASSYM(SCTX_R8,  offsetof(struct svm_regctx, sctx_r8));
43249967SneelASSYM(SCTX_R9,  offsetof(struct svm_regctx, sctx_r9));
44249967SneelASSYM(SCTX_R10, offsetof(struct svm_regctx, sctx_r10));
45249967SneelASSYM(SCTX_R11, offsetof(struct svm_regctx, sctx_r11));
46249967SneelASSYM(SCTX_R12, offsetof(struct svm_regctx, sctx_r12));
47249967SneelASSYM(SCTX_R13, offsetof(struct svm_regctx, sctx_r13));
48249967SneelASSYM(SCTX_R14, offsetof(struct svm_regctx, sctx_r14));
49249967SneelASSYM(SCTX_R15, offsetof(struct svm_regctx, sctx_r15));
50285015SneelASSYM(MSR_GSBASE, MSR_GSBASE);
51