m5op_arm.S (9687:22e9258c06bb) | m5op_arm.S (9949:7890c22dad25) |
---|---|
1/* 2 * Copyright (c) 2010 ARM Limited 3 * All rights reserved 4 * 5 * The license below extends only to copyright in the software and shall 6 * not be construed as granting a license to any other intellectual 7 * property including but not limited to intellectual property relating 8 * to a hardware implementation of the functionality of the software --- 41 unchanged lines hidden (view full) --- 50#include "m5ops.h" 51 52.text 53 54.macro simple_op name, func, subfunc 55 .align 2 56 .globl \name 57\name: | 1/* 2 * Copyright (c) 2010 ARM Limited 3 * All rights reserved 4 * 5 * The license below extends only to copyright in the software and shall 6 * not be construed as granting a license to any other intellectual 7 * property including but not limited to intellectual property relating 8 * to a hardware implementation of the functionality of the software --- 41 unchanged lines hidden (view full) --- 50#include "m5ops.h" 51 52.text 53 54.macro simple_op name, func, subfunc 55 .align 2 56 .globl \name 57\name: |
58 /* First, try to trap into m5 using the m5-kvm hypercall 59 * hack. The bxj will become a branch to the fallback code 60 * if it is executed in the normal m5 environment. 61 */ 62 push {lr} | |
63#ifdef __thumb__ | 58#ifdef __thumb__ |
64 adr lr, 1f+1 65#else 66 adr lr, 1f 67#endif 68 ldr ip, =((((\func) & 0xFF) << 8) | ((\subfunc) & 0xFF)) 69 bxj lr 70 pop {pc} 71 72 /* Old-style m5 pseudo instruction using CP1 accesses */ 731: 74#ifdef __thumb__ | |
75 .short 0xEE00 | \func 76 .short 0x0110 | (\subfunc << 12) 77#else | 59 .short 0xEE00 | \func 60 .short 0x0110 | (\subfunc << 12) 61#else |
78 .long (0xEE000110 | (\func << 16) | (\subfunc << 12)) | 62 .long 0xEE000110 | (\func << 16) | (\subfunc << 12) |
79#endif | 63#endif |
80 pop {pc} | 64 mov pc,lr |
81.endm 82 83#define SIMPLE_OP(name, func, subfunc) simple_op name, func, subfunc 84 85SIMPLE_OP(arm, arm_func, 0) 86SIMPLE_OP(quiesce, quiesce_func, 0) 87SIMPLE_OP(quiesceNs, quiescens_func, 0) 88SIMPLE_OP(quiesceCycle, quiescecycle_func, 0) --- 36 unchanged lines hidden --- | 65.endm 66 67#define SIMPLE_OP(name, func, subfunc) simple_op name, func, subfunc 68 69SIMPLE_OP(arm, arm_func, 0) 70SIMPLE_OP(quiesce, quiesce_func, 0) 71SIMPLE_OP(quiesceNs, quiescens_func, 0) 72SIMPLE_OP(quiesceCycle, quiescecycle_func, 0) --- 36 unchanged lines hidden --- |