Changeset f9d0a86 in mainline for boot


Ignore:
Timestamp:
2017-11-14T12:24:42Z (8 years ago)
Author:
Aearsis <Hlavaty.Ondrej@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
6cad776
Parents:
887c9de (diff), d2d142a (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the (diff) links above to see all the changes relative to each parent.
git-author:
Aearsis <Hlavaty.Ondrej@…> (2017-11-14 01:04:19)
git-committer:
Aearsis <Hlavaty.Ondrej@…> (2017-11-14 12:24:42)
Message:

Merge tag '0.7.1'

The merge wasn't clean, because of changes in build system. The most
significant change was partial revert of usbhc callback refactoring,
which now does not take usb transfer batch, but few named fields again.

Location:
boot
Files:
1 added
1 deleted
14 edited
39 moved

Legend:

Unmodified
Added
Removed
  • boot/Makefile

    r887c9de rf9d0a86  
    128128        rm -f $(POST_OUTPUT) $(BOOT_OUTPUT) arch/*/include/common.h
    129129        find generic/src/ arch/*/src/ genarch/src/ -name '*.o' -follow -exec rm \{\} \;
    130         find generic/src/ arch/*/src/ genarch/src/ -name '*.d' -follow -exec rm \{\} \;
     130        find . -name '*.d' -follow -exec rm \{\} \;
    131131
    132132clean_dist:
  • boot/Makefile.build

    r887c9de rf9d0a86  
    3131include Makefile.common
    3232
    33 INCLUDES = -Igeneric/include -I$(ROOT_PATH)/abi/include
     33INCLUDES = -Igeneric/include -Iarch/$(KARCH)/include -Igenarch/include -I$(ROOT_PATH)/abi/include
    3434OPTIMIZATION = 3
    3535
    3636DEFS = -DBOOT -DRELEASE=$(RELEASE) "-DCOPYRIGHT=$(COPYRIGHT)" "-DNAME=$(NAME)" -D__$(BITS)_BITS__ -D__$(ENDIANESS)__
    3737
    38 AFLAGS =
    39 LFLAGS = --fatal-warnings
    40 
    41 # FIXME: This condition is a workaround for issue #693.
    42 ifneq ($(BARCH),mips32)
    43         AFLAGS += --fatal-warnings
    44 endif
     38AFLAGS = --fatal-warnings
     39LFLAGS = --fatal-warnings --warn-common
    4540
    4641COMMON_CFLAGS = $(INCLUDES) -O$(OPTIMIZATION) -imacros $(CONFIG_HEADER) \
    4742        -ffreestanding -fno-builtin -nostdlib -nostdinc \
    48         -fexec-charset=UTF-8 -finput-charset=UTF-8
     43        -fexec-charset=UTF-8 -finput-charset=UTF-8 -fno-common \
     44        -fdebug-prefix-map=$(realpath $(ROOT_PATH))=.
    4945
    5046GCC_CFLAGS = -Wall -Wextra -Wno-unused-parameter -Wmissing-prototypes \
     
    7672
    7773clean:
    78         rm -f $(RAW) $(MAP) $(ARCH_INCLUDE) $(GENARCH_INCLUDE)
     74        rm -f $(RAW) $(MAP)
    7975
    8076-include $(DEPENDS)
     
    9187        $(CC) $(DEFS) $(CFLAGS) -D__ASM__ -D__LINKER__ -E -x c $(LINK).in | grep -v "^\#" > $(LINK)
    9288
     89%.o: %.s | depend
     90        $(CC_JOB) -c -MD -MP $(DEFS) $(CFLAGS) $(AS_CFLAGS) -D__ASM__
     91
    9392%.o: %.S | depend
    94         $(CC) -MD $(DEFS) $(CFLAGS) $(AS_CFLAGS) -D__ASM__ -c $< -o $@
    95 ifeq ($(PRECHECK),y)
    96         $(JOBFILE) $(JOB) $< $@ as asm/preproc $(DEFS) $(CFLAGS) -D__ASM__
    97 endif
     93        $(CC_JOB) -c -MD -MP $(DEFS) $(CFLAGS) $(AS_CFLAGS) -D__ASM__
    9894
    9995%.o: %.c | depend
    100         $(CC) -MD $(DEFS) $(CFLAGS) -c $< -o $@
    101 ifeq ($(PRECHECK),y)
    102         $(JOBFILE) $(JOB) $< $@ cc core $(DEFS) $(CFLAGS)
    103 endif
     96        $(CC_JOB) -c -MD -MP $(DEFS) $(CFLAGS)
    10497
    105 %.o: %.s | depend
    106         $(CC) -MD $(DEFS) $(CFLAGS) $(AS_CFLAGS) -D__ASM__ -c $< -o $@
    107 ifeq ($(PRECHECK),y)
    108         $(JOBFILE) $(JOB) $< $@ as asm
    109 endif
    110 
    111 depend: $(ARCH_INCLUDE) $(GENARCH_INCLUDE) $(COMMON_HEADER_ARCH) $(PRE_DEPEND)
     98depend: $(PRE_DEPEND)
    11299
    113100$(COMPS).s: $(COMPS).zip
     
    128115include Makefile.initrd
    129116
    130 $(ARCH_INCLUDE): arch/$(KARCH)/include/
    131         ln -sfn ../../$< $@
    132 
    133 $(GENARCH_INCLUDE): genarch/include/
    134         ln -sfn ../../$< $@
    135 
    136 $(COMMON_HEADER_ARCH): $(COMMON_HEADER)
    137         ln -sfn ../../../$< $@
  • boot/Makefile.common

    r887c9de rf9d0a86  
    3636COMMON_MAKEFILE = $(ROOT_PATH)/Makefile.common
    3737COMMON_HEADER = $(ROOT_PATH)/common.h
    38 COMMON_HEADER_ARCH = arch/$(BARCH)/include/common.h
    3938
    4039CONFIG_MAKEFILE = $(ROOT_PATH)/Makefile.config
     
    5857MKUIMAGE = $(TOOLS_PATH)/mkuimage.py
    5958
    60 JOBFILE = $(ROOT_PATH)/tools/jobfile.py
    61 
    62 ARCH_INCLUDE = generic/include/arch
    63 GENARCH_INCLUDE = generic/include/genarch
     59ifeq ($(PRECHECK),y)
     60        JOBFILE = $(TOOLS_PATH)/jobfile.py
     61        # XXX: Do not change the order of arguments.
     62        CC_JOB = $(JOBFILE) $(JOB) $(CC) $< -o $@
     63else
     64        CC_JOB = $(CC) $< -o $@
     65endif
    6466
    6567DISTROOT = distroot
  • boot/arch/amd64/Makefile.inc

    r887c9de rf9d0a86  
    3939        audio/sb16 \
    4040        char/i8042 \
    41         char/ps2mouse \
    42         char/xtkbd
     41        hid/ps2mouse \
     42        hid/xtkbd
    4343
    4444RD_DRVS_NON_ESSENTIAL += \
     
    5151        bus/usb/usbflbk \
    5252        bus/usb/usbhub \
    53         bus/usb/usbhid \
    54         bus/usb/usbmast \
    5553        bus/usb/usbmid \
    5654        bus/usb/vhc \
    57         bus/usb/xhci
     55        bus/usb/xhci \
     56        block/usbmast \
     57        hid/usbhid
    5858
    5959RD_DRV_CFG += \
  • boot/arch/arm32/Makefile.inc

    r887c9de rf9d0a86  
    7474        RD_DRVS_ESSENTIAL += \
    7575                char/pl050 \
    76                 char/atkbd \
    77                 char/ps2mouse \
     76                hid/atkbd \
     77                hid/ps2mouse \
    7878                intctl/icp-ic \
    7979                platform/icp
     
    8585        bus/usb/usbflbk \
    8686        bus/usb/usbhub \
    87         bus/usb/usbhid \
    88         bus/usb/usbmast \
    89         bus/usb/usbmid
     87        bus/usb/usbmid \
     88        block/usbmast \
     89        hid/usbhid
    9090
    9191SOURCES = \
  • boot/arch/arm32/include/arch/types.h

    r887c9de rf9d0a86  
    3737#define BOOT_arm32_TYPES_H
    3838
    39 #include <arch/common.h>
     39#include <_bits/all.h>
    4040
    4141#define TASKMAP_MAX_RECORDS        32
    4242#define BOOTINFO_TASK_NAME_BUFLEN  32
    43 
    44 typedef uint32_t size_t;
    45 typedef uint32_t uintptr_t;
    46 
    47 typedef uint32_t pfn_t;
    48 
    49 typedef int32_t ptrdiff_t;
    5043
    5144typedef struct {
  • boot/arch/ia64/Makefile.inc

    r887c9de rf9d0a86  
    6666endif
    6767
     68ifeq ($(MACHINE),i460GX)
    6869RD_DRVS_ESSENTIAL += \
    6970        platform/pc \
     
    7172        bus/isa \
    7273        char/i8042 \
    73         char/xtkbd
     74        hid/xtkbd
    7475
    7576RD_DRVS_NON_ESSENTIAL += \
     
    8182        bus/usb/usbflbk \
    8283        bus/usb/usbhub \
    83         bus/usb/usbhid \
    84         bus/usb/usbmast \
    8584        bus/usb/usbmid \
    86         bus/usb/vhc
     85        bus/usb/vhc \
     86        block/usbmast \
     87        hid/usbhid
    8788
    8889RD_DRV_CFG += \
    8990        bus/isa
     91endif
     92
     93ifeq ($(MACHINE),ski)
     94RD_DRVS_ESSENTIAL += \
     95        char/ski-con \
     96        platform/ski
     97endif
    9098
    9199PRE_DEPEND = $(COMPS).s $(COMPS).h $(COMPS)_desc.c $(COMPONENTS_DEFLATE)
  • boot/arch/ia64/include/arch/types.h

    r887c9de rf9d0a86  
    3030#define BOOT_ia64_TYPES_H_
    3131
    32 #include <arch/common.h>
     32#include <_bits/all.h>
    3333
    3434#define TASKMAP_MAX_RECORDS             32
    3535#define BOOTINFO_TASK_NAME_BUFLEN       32
    3636#define MEMMAP_ITEMS                    128
    37 
    38 typedef uint64_t size_t;
    39 typedef uint64_t sysarg_t;
    40 typedef uint64_t uintptr_t;
    41 
    42 typedef int64_t ptrdiff_t;
    4337
    4438typedef struct {
  • boot/arch/mips32/Makefile.inc

    r887c9de rf9d0a86  
    5858                bus/isa \
    5959                char/i8042 \
    60                 char/ps2mouse \
    61                 char/xtkbd
     60                hid/ps2mouse \
     61                hid/xtkbd
    6262
    6363        RD_DRV_CFG += \
     
    6868        RD_DRVS_ESSENTIAL += \
    6969                platform/msim \
    70                 block/ddisk
     70                block/ddisk \
     71                char/msim-con
    7172endif
    7273
  • boot/arch/mips32/include/arch/types.h

    r887c9de rf9d0a86  
    3030#define BOOT_mips32_TYPES_H_
    3131
    32 #include <arch/common.h>
     32#include <_bits/all.h>
    3333
    3434#define TASKMAP_MAX_RECORDS        32
    3535#define CPUMAP_MAX_RECORDS         32
    3636#define BOOTINFO_TASK_NAME_BUFLEN  32
    37 
    38 typedef uint32_t size_t;
    39 typedef uint32_t uintptr_t;
    40 
    41 typedef int32_t ptrdiff_t;
    4237
    4338typedef struct {
  • boot/arch/mips32/src/asm.S

    r887c9de rf9d0a86  
    3333.set noat
    3434.set noreorder
    35 .set nomacro
    3635
    3736.section BOOTSTRAP
  • boot/arch/ppc32/Makefile.inc

    r887c9de rf9d0a86  
    4949        bus/usb/usbflbk \
    5050        bus/usb/usbhub \
    51         bus/usb/usbhid \
    52         bus/usb/usbmast \
    5351        bus/usb/usbmid \
    54         bus/usb/vhc
     52        bus/usb/vhc \
     53        block/usbmast \
     54        hid/usbhid
    5555
    5656SOURCES = \
  • boot/arch/ppc32/include/arch/types.h

    r887c9de rf9d0a86  
    3030#define BOOT_ppc32_TYPES_H_
    3131
    32 #include <arch/common.h>
     32#include <_bits/all.h>
    3333
    3434#define TASKMAP_MAX_RECORDS        32
    3535#define BOOTINFO_TASK_NAME_BUFLEN  32
    36 
    37 typedef uint32_t size_t;
    38 typedef uint32_t uintptr_t;
    39 typedef uint32_t sysarg_t;
    40 typedef int32_t native_t;
    41 
    42 typedef int32_t ptrdiff_t;
    4336
    4437typedef struct {
  • boot/arch/riscv64/include/arch/types.h

    r887c9de rf9d0a86  
    3030#define BOOT_riscv64_TYPES_H_
    3131
    32 #include <arch/common.h>
     32#include <_bits/all.h>
    3333
    3434#define MEMMAP_MAX_RECORDS         32
    3535#define TASKMAP_MAX_RECORDS        32
    3636#define BOOTINFO_TASK_NAME_BUFLEN  32
    37 
    38 typedef uint64_t size_t;
    39 typedef uint64_t uintptr_t;
    40 
    41 typedef int64_t ptrdiff_t;
    4237
    4338typedef struct {
  • boot/arch/sparc64/Makefile.inc

    r887c9de rf9d0a86  
    3939EXTRA_CFLAGS = -mcpu=ultrasparc -m64 -mno-fpu -mcmodel=medlow
    4040
     41ifeq ($(PROCESSOR), sun4v)
     42RD_DRVS_ESSENTIAL += \
     43        platform/sun4v \
     44        char/sun4v-con
     45else
    4146RD_DRVS_ESSENTIAL += \
    4247        platform/sun4u \
    4348        bus/pci/pciintel \
    4449        bus/isa \
     50        intctl/obio \
    4551        char/ns8250
    4652
    4753RD_DRV_CFG += \
    4854        bus/isa
    49 
    50 RD_SRVS_NON_ESSENTIAL +=
    51 
    52 RD_SRVS_ESSENTIAL += \
    53         $(USPACE_PATH)/srv/hw/irc/obio/obio
     55endif
    5456
    5557SOURCES = \
  • boot/arch/sparc64/include/arch/types.h

    r887c9de rf9d0a86  
    3030#define BOOT_sparc64_TYPES_H_
    3131
    32 #include <arch/common.h>
     32#include <_bits/all.h>
    3333
    3434#define TASKMAP_MAX_RECORDS        32
    3535#define BOOTINFO_TASK_NAME_BUFLEN  32
    36 
    37 typedef uint64_t size_t;
    38 typedef uint64_t uintptr_t;
    39 typedef uint64_t sysarg_t;
    40 typedef int64_t native_t;
    41 
    42 typedef int64_t ptrdiff_t;
    4336
    4437typedef struct {
  • boot/generic/include/stddef.h

    r887c9de rf9d0a86  
    3333#define BOOT_STDDEF_H_
    3434
    35 #include <arch/common.h>
    3635#include <arch/types.h>
    3736
    38 #define NULL  ((void *) 0)
     37#include <_bits/NULL.h>
    3938
    4039#endif
  • boot/generic/include/stdint.h

    r887c9de rf9d0a86  
    3333#define BOOT_STDINT_H_
    3434
    35 #include <arch/common.h>
    3635#include <arch/types.h>
    37 
    38 #define INT8_MIN  INT8_C(0x80)
    39 #define INT8_MAX  INT8_C(0x7F)
    40 
    41 #define UINT8_MIN  UINT8_C(0)
    42 #define UINT8_MAX  UINT8_C(0xFF)
    43 
    44 #define INT16_MIN  INT16_C(0x8000)
    45 #define INT16_MAX  INT16_C(0x7FFF)
    46 
    47 #define UINT16_MIN  UINT16_C(0)
    48 #define UINT16_MAX  UINT16_C(0xFFFF)
    49 
    50 #define INT32_MIN  INT32_C(0x80000000)
    51 #define INT32_MAX  INT32_C(0x7FFFFFFF)
    52 
    53 #define UINT32_MIN  UINT32_C(0)
    54 #define UINT32_MAX  UINT32_C(0xFFFFFFFF)
    55 
    56 #define INT64_MIN  INT64_C(0x8000000000000000)
    57 #define INT64_MAX  INT64_C(0x7FFFFFFFFFFFFFFF)
    58 
    59 #define UINT64_MIN  UINT64_C(0)
    60 #define UINT64_MAX  UINT64_C(0xFFFFFFFFFFFFFFFF)
    6136
    6237#endif
  • boot/generic/src/printf_core.c

    r887c9de rf9d0a86  
    101101        PrintfQualifierLongLong,
    102102        PrintfQualifierPointer,
    103         PrintfQualifierSize
     103        PrintfQualifierSize,
     104        PrintfQualifierMax
    104105} qualifier_t;
    105106
     
    643644                                uc = str_decode(fmt, &nxt, STR_NO_LIMIT);
    644645                                break;
     646                        case 'j':
     647                                qualifier = PrintfQualifierMax;
     648                                i = nxt;
     649                                uc = str_decode(fmt, &nxt, STR_NO_LIMIT);
     650                                break;
    645651                        default:
    646652                                /* Default type */
     
    759765                                number = (uint64_t) va_arg(ap, size_t);
    760766                                break;
     767                        case PrintfQualifierMax:
     768                                size = sizeof(uintmax_t);
     769                                number = (uint64_t) va_arg(ap, uintmax_t);
     770                                break;
    761771                        default:
    762772                                /* Unknown qualifier */
  • boot/generic/src/str.c

    r887c9de rf9d0a86  
    104104
    105105/** Check the condition if wchar_t is signed */
    106 #ifdef WCHAR_IS_UNSIGNED
     106#ifdef __WCHAR_UNSIGNED__
    107107        #define WCHAR_SIGNED_CHECK(cond)  (true)
    108108#else
Note: See TracChangeset for help on using the changeset viewer.