Quantcast
Channel: Active questions tagged gcc - Stack Overflow
Viewing all articles
Browse latest Browse all 22153

use of -mcmodel=kernel flag in x86 platform

$
0
0

I am trying to cross compile a device driver built for x86 architecture to arm platform. It got compiled without any errors, but I dont think whole features are available. So I checked the makefile and found this particular part.

ifeq ($(ARCH),x86_64)    EXTRA_CFLAGS += -mcmodel=kernel -mno-red-zone

This is the only part that depends on architecture it seems. After some time on google, I found that -mcmodel=kernel is for kernel code model and -mno-red-zone is to avoid using red zone in memory and both them were for x86_64. But its not clear to me, what impact does it make setting cmodel to kernel?

(Any insight into the problem with arm is also greatly appreciated.)


Viewing all articles
Browse latest Browse all 22153

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>