I am trying to write a program that issues one SMC call. After searching the previous questions, it is my understanding that there is no real API within the Linux kernel for implementing ARM SMC? I am working on a prototype based on msm8974, and want to know what is the best way to do it.
I am still learning about section magic and how the linker maps assembly export 'tag'? Macros? ( Not sure what they are called ) to the C procedures. Please tell me if I really need to read through the GNU linker document to understand how that happens.
@Ross Ridge- Thanks. SMC, Secure Monitor Call, is an instruction to interface with the ARM Trust Zone service. My question is how to implement this call. Most of the posts and the answers here imply that such interface is not available on the Linux kernel tree yet. So, I know I have to write it in assembly. @Notlikethat - Hey man. I am using the different platfrom. What is involved at a highlevel to implement these other implementations for my platform, which is Qualcomm Snapdragon?
@Notlikethat - Here is what I see under /arch/arm/kerel:
sansari@ubuntu:~/WORKING_DIRECTORY/arch/arm/kernel$ ls
arch_timer.c entry-common.S kprobes-arm.c perf_event_v6.c suspend.c
armksyms.c entry-header.S kprobes.c perf_event_v7.c swp_emulate.c
arthur.c etm.c kprobes-common.c perf_event_xscale.c sys_arm.c
asm-offsets.c fiqasm.S kprobes.h pj4-cp0.c sys_oabi-compat.c
atags.c fiq.c kprobes-test-arm.c pmu.c tcm.c
atags.h ftrace.c kprobes-test.c process.c tcm.h
bios32.c head-common.S kprobes-test.h ptrace.c thumbee.c
calls.S head-nommu.S kprobes-test-thumb.c relocate_kernel.S time.c
compat.c head.S kprobes-thumb.c return_address.c topology.c
compat.h hw_breakpoint.c leds.c sched_clock.c traps.c
cpuidle.c init_task.c machine_kexec.c setup.c unwind.c
crash_dump.c insn.c Makefile signal.c update_vsyscall_arm.c
debug.S insn.h module.c signal.h update_vsyscall_arm.h
devtree.c io.c opcodes.c sleep.S user_accessible_timer.c
dma.c irq.c patch.c smp.c vmlinux.lds.S
dma-isa.c isa.c patch.h smp_scu.c xscale-cp0.c
early_printk.c iwmmxt.S perf_event.c smp_tlb.c
elf.c jump_label.c perf_event_msm.c smp_twd.c
entry-armv.S kgdb.c perf_event_msm_krait.c stacktrace.c
I need an updated kernel perhaps?
@Notlikethat - Would you please point me to the documentation on the implementations you mentioned EXINOS and ...?
@all- Thank you for your help and explanation. Arun - this definitely helps.