Skip to content

Commit

Permalink
include: arch: move addr_types to common location
Browse files Browse the repository at this point in the history
All architectures declare those variables the same way, no need to
define them per arch, instead put them in common. If someone deviates,
they can create their own header.

Signed-off-by: Anas Nashif <anas.nashif@intel.com>
  • Loading branch information
nashif committed Jun 4, 2019
1 parent b01568c commit d647751
Show file tree
Hide file tree
Showing 9 changed files with 7 additions and 55 deletions.
2 changes: 1 addition & 1 deletion include/arch/arc/arch.h
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
#include <arch/arc/v2/aux_regs.h>
#include <arch/arc/v2/arcv2_irq_unit.h>
#include <arch/arc/v2/asm_inline.h>
#include <arch/arc/v2/addr_types.h>
#include <arch/common/addr_types.h>
#include "v2/sys_io.h"
#endif

Expand Down
17 changes: 0 additions & 17 deletions include/arch/arc/v2/addr_types.h

This file was deleted.

2 changes: 1 addition & 1 deletion include/arch/arm/arch.h
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,8 @@
#include <arch/arm/cortex_m/misc.h>
#include <arch/arm/cortex_m/memory_map.h>
#include <arch/arm/cortex_m/asm_inline.h>
#include <arch/arm/cortex_m/addr_types.h>
#include <arch/common/sys_io.h>
#include <arch/common/addr_types.h>
#include <arch/common/ffs.h>
#include <arch/arm/cortex_m/nmi.h>
#endif
Expand Down
17 changes: 0 additions & 17 deletions include/arch/arm/cortex_m/addr_types.h

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,9 @@
#ifndef ZEPHYR_INCLUDE_ARCH_X86_ADDR_TYPES_H_
#define ZEPHYR_INCLUDE_ARCH_X86_ADDR_TYPES_H_

#ifndef _ASMLANGUAGE
typedef unsigned int paddr_t;
typedef unsigned int vaddr_t;
#endif

#endif /* ZEPHYR_INCLUDE_ARCH_X86_ADDR_TYPES_H_ */
4 changes: 1 addition & 3 deletions include/arch/nios2/arch.h
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@

#include <system.h>
#include <arch/nios2/asm_inline.h>
#include <arch/common/addr_types.h>
#include <generated_dts_board.h>
#include "nios2.h"
#include <arch/common/sys_io.h>
Expand All @@ -39,9 +40,6 @@ extern "C" {
#include <irq.h>
#include <sw_isr_table.h>

/* physical/virtual address types required by the kernel */
typedef unsigned int paddr_t;
typedef unsigned int vaddr_t;

/**
* Configure a static interrupt.
Expand Down
2 changes: 1 addition & 1 deletion include/arch/x86/arch.h
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@

#ifndef _ASMLANGUAGE
#include <arch/x86/asm_inline.h>
#include <arch/x86/addr_types.h>
#include <arch/common/addr_types.h>
#include <arch/x86/segmentation.h>
#endif

Expand Down
15 changes: 0 additions & 15 deletions include/arch/xtensa/addr_types.h

This file was deleted.

1 change: 1 addition & 0 deletions include/arch/xtensa/arch.h
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ extern "C" {
#include <sw_isr_table.h>
#include <arch/xtensa/xtensa_irq.h>
#include <xtensa/config/core.h>
#include <arch/common/addr_types.h>

#define STACK_ALIGN 16

Expand Down

0 comments on commit d647751

Please sign in to comment.