Peios Learn
Documentation

Peios

Peios Peios Kernel Universal Directory Project

Developer Tools

Trail Acta Provium clackatoo CAF GCSL Pekit

Applications

Framewright

Standards and Conventions

Standards and Conventions Peios Specifications
Peios Kernel

ARC

Single-page view · as markdown

ARC architecture

Peios Kernel / Hardware and drivers / Processor architectures / ARC

  • Linux kernel for ARC processors
  • features

Linux kernel for ARC processors

Peios Kernel / Hardware and drivers / Processor architectures / ARC

Other sources of information #

Below are some resources where more information can be found on ARC processors and relevant open source projects.

  • https://embarc.org - Community portal for open source on ARC. Good place to start to find relevant FOSS projects, toolchain releases, news items and more.

  • https://github.com/foss-for-synopsys-dwc-arc-processors - Home for all development activities regarding open source projects for ARC processors. Some of the projects are forks of various upstream projects, where "work in progress" is hosted prior to submission to upstream projects. Other projects are developed by Synopsys and made available to community as open source for use on ARC Processors.

  • Official Synopsys ARC Processors website - location, with access to some IP documentation (Programmer's Reference Manual, AKA PRM for ARC HS processors) and free versions of some commercial tools (Free nSIM and MetaWare Light Edition). Please note though, registration is required to access both the documentation and the tools.

Important note on ARC processors configurability #

ARC processors are highly configurable and several configurable options are supported in Linux. Some options are transparent to software (i.e cache geometries, some can be detected at runtime and configured and used accordingly, while some need to be explicitly selected or configured in the kernel's configuration utility (AKA "make menuconfig").

However not all configurable options are supported when an ARC processor is to run Linux. SoC design teams should refer to "Appendix E: Configuration for ARC Linux" in the ARC HS Databook for configurability guidelines.

Following these guidelines and selecting valid configuration options up front is critical to help prevent any unwanted issues during SoC bringup and software development in general.

Building the Linux kernel for ARC processors #

The process of kernel building for ARC processors is the same as for any other architecture and could be done in 2 ways:

  • Cross-compilation: process of compiling for ARC targets on a development host with a different processor architecture (generally x86_64/amd64).

  • Native compilation: process of compiling for ARC on a ARC platform (hardware board or a simulator like QEMU) with complete development environment (GNU toolchain, dtc, make etc) installed on the platform.

In both cases, up-to-date GNU toolchain for ARC for the host is needed. Synopsys offers prebuilt toolchain releases which can be used for this purpose, available from:

  • Synopsys GNU toolchain releases: https://github.com/foss-for-synopsys-dwc-arc-processors/toolchain/releases

  • Linux kernel compilers collection: https://mirrors.edge.kernel.org/pub/tools/crosstool

  • Bootlin's toolchain collection: https://toolchains.bootlin.com

Once the toolchain is installed in the system, make sure its "bin" folder is added in your PATH environment variable. Then set ARCH=arc & CROSS_COMPILE=arc-linux (or whatever matches installed ARC toolchain prefix) and then as usual make defconfig && make.

This will produce "vmlinux" file in the root of the kernel source tree usable for loading on the target system via JTAG. If you need to get an image usable with U-Boot bootloader, type make uImage and uImage will be produced in arch/arc/boot folder.

Feature status on arc architecture

Peios Kernel / Hardware and drivers / Processor architectures / ARC

SubsystemFeatureKconfigStatusDescription
corecBPF-JITHAVE_CBPF_JITTODOarch supports cBPF JIT optimizations
coreeBPF-JITHAVE_EBPF_JITokarch supports eBPF JIT optimizations
coregeneric-idle-threadGENERIC_SMP_IDLE_THREADokarch makes use of the generic SMP idle thread facility
corejump-labelsHAVE_ARCH_JUMP_LABELokarch supports live patched, high efficiency branches
coremseal-system-mappingsARCH_SUPPORTS_MSEAL_SYSTEM_MAPPINGSN/Aarch supports mseal system mappings
corethread-info-in-taskTHREAD_INFO_IN_TASKTODOarch makes use of the core kernel facility to embed thread_info in task_struct
coretracehookHAVE_ARCH_TRACEHOOKokarch supports tracehook (ptrace) register handling APIs
debugdebug-vm-pgtableARCH_HAS_DEBUG_VM_PGTABLEokarch supports pgtable tests for semantics compliance
debuggcov-profile-allARCH_HAS_GCOV_PROFILE_ALLTODOarch supports whole-kernel GCOV code coverage profiling
debugKASANHAVE_ARCH_KASANTODOarch supports the KASAN runtime memory checker
debugkcovARCH_HAS_KCOVTODOarch supports kcov for coverage-guided fuzzing
debugkgdbHAVE_ARCH_KGDBokarch supports the kGDB kernel debugger
debugkmemleakHAVE_DEBUG_KMEMLEAKokarch supports the kernel memory leak detector
debugkprobesHAVE_KPROBESokarch supports live patched kernel probe
debugkprobes-on-ftraceHAVE_KPROBES_ON_FTRACETODOarch supports combined kprobes and ftrace live patching
debugkretprobesHAVE_KRETPROBESokarch supports kernel function-return probes
debugoptprobesHAVE_OPTPROBESTODOarch supports live patched optprobes
debugstackprotectorHAVE_STACKPROTECTORTODOarch supports compiler driven stack overflow protection
debuguprobesARCH_SUPPORTS_UPROBESTODOarch supports live patched user probes
debuguser-ret-profilerHAVE_USER_RETURN_NOTIFIERTODOarch supports user-space return from system call profiler
iodma-contiguousHAVE_DMA_CONTIGUOUSTODOarch supports the DMA CMA (continuous memory allocator)
lockingcmpxchg-localHAVE_CMPXCHG_LOCALTODOarch supports the this_cpu_cmpxchg() API
lockinglockdepLOCKDEP_SUPPORTokarch supports the runtime locking correctness debug facility
lockingqueued-rwlocksARCH_USE_QUEUED_RWLOCKSTODOarch supports queued rwlocks
lockingqueued-spinlocksARCH_USE_QUEUED_SPINLOCKSTODOarch supports queued spinlocks
perfkprobes-eventHAVE_REGS_AND_STACK_ACCESS_APIokarch supports kprobes with perf events
perfperf-regsHAVE_PERF_REGSTODOarch supports perf events register access
perfperf-stackdumpHAVE_PERF_USER_STACK_DUMPTODOarch supports perf events stack dumps
schedmembarrier-sync-coreARCH_HAS_MEMBARRIER_SYNC_CORETODOarch supports core serializing membarrier
schednuma-balancingARCH_SUPPORTS_NUMA_BALANCINGNot compatiblearch supports NUMA balancing
seccompseccomp-filterHAVE_ARCH_SECCOMP_FILTERTODOarch supports seccomp filters
timearch-tick-broadcastARCH_HAS_TICK_BROADCASTTODOarch provides tick_broadcast()
timeclockevents!LEGACY_TIMER_TICKokarch support generic clock events
timeirq-time-acctHAVE_IRQ_TIME_ACCOUNTINGTODOarch supports precise IRQ time accounting
timeuser-context-trackingHAVE_CONTEXT_TRACKING_USERTODOarch supports user context tracking for NO_HZ_FULL
timevirt-cpuacctHAVE_VIRT_CPU_ACCOUNTINGTODOarch supports precise virtual CPU time accounting
vmbatch-unmap-tlb-flushARCH_WANT_BATCHED_UNMAP_TLB_FLUSHTODOarch supports deferral of TLB flush until multiple pages are unmapped
vmELF-ASLRARCH_WANT_DEFAULT_TOPDOWN_MMAP_LAYOUTTODOarch randomizes the stack, heap and binary images of ELF binaries
vmhuge-vmapHAVE_ARCH_HUGE_VMAPTODOarch supports the arch_vmap_pud_supported() and arch_vmap_pmd_supported() VM APIs
vmioremap_protHAVE_IOREMAP_PROTokarch has ioremap_prot()
vmpte_specialARCH_HAS_PTE_SPECIALokarch supports the pte_special()/pte_mkspecial() VM APIs
vmTHPHAVE_ARCH_TRANSPARENT_HUGEPAGEokarch supports transparent hugepages

Peios Learn — documentation for Peios software.

Built with Trail.