/**
 * @file smc.s
 * @brief functions to provide smc interface
 * Copyright (c) 2014 Samsung Electronics Co., Ltd.
 *
 * This software is proprietary of Samsung Electronics.
 * No part of this software, either material or conceptual may be copied
 * or distributed, transmitted, transcribed, stored in a retrieval system
 * or translated into any human or computer language in any form by any means,
 * electronic, mechanical, manual or otherwise, or disclosed to third parties
 * without the express written permission of Samsung Electronics.
 */

	export sec_smc

	area text, code, readonly
	preserve8
	arm
sec_smc
	stmfd   sp!, {r4-r11, lr}
	mov     r4, r0
	mov     r5, r1
	mov     r6, r2
	mov     r7, r3
	ldr     r0, [r4]
	ldr     r1, [r5]
	ldr     r2, [r6]
	ldr     r3, [r7]
	stmfd   sp!, {r4-r11}
	dsb
	smc #0
	ldmfd   sp!, {r4-r11}
	str     r0, [r4]
	str     r1, [r5]
	str     r2, [r6]
	str     r3, [r7]
	ldmfd   sp!, {r4-r11, pc}

	END
