Changes in / [3451129:c6b601b] in mainline


Ignore:
Files:
21 added
25 deleted
12 edited

Legend:

Unmodified
Added
Removed
  • defaults/amd64/Makefile.config

    r3451129 rc6b601b  
    5454
    5555# Default framebuffer mode
    56 CONFIG_BFB_MODE = 1024x768
     56CONFIG_BFB_MODE = 800x600
    5757
    5858# Default framebuffer depth
  • defaults/ia32/Makefile.config

    r3451129 rc6b601b  
    6060
    6161# Default framebuffer mode
    62 CONFIG_BFB_MODE = 1024x768
     62CONFIG_BFB_MODE = 800x600
    6363
    6464# Default framebuffer depth
  • kernel/arch/arm32/Makefile.inc

    r3451129 rc6b601b  
    3333ATSIGN = %
    3434
    35 GCC_CFLAGS += -fno-omit-frame-pointer -mapcs-frame -march=$(subst _,-,$(PROCESSOR))
     35GCC_CFLAGS += -march=$(subst _,-,$(PROCESSOR))
    3636
    3737BITS = 32
  • kernel/arch/arm32/include/istate.h

    r3451129 rc6b601b  
    4949/** Struct representing CPU state saved when an exception occurs. */
    5050typedef struct istate {
    51         uint32_t dummy;
    5251        uint32_t spsr;
    5352        uint32_t sp;
  • kernel/arch/arm32/src/exc_handler.S

    r3451129 rc6b601b  
    130130        stmfd r13!, {r2}
    1311312:
    132         sub sp, sp, #4
    133132.endm
    134133
    135134.macro LOAD_REGS_FROM_STACK
    136         add sp, sp, #4
    137135        ldmfd r13!, {r0}
    138136        msr spsr, r0
  • kernel/arch/arm32/src/mm/page_fault.c

    r3451129 rc6b601b  
    8888}
    8989
     90/** Decides whether the instruction is load/store or not.
     91 *
     92 * @param instr Instruction
     93 *
     94 * @return true when instruction is load/store, false otherwise
     95 *
     96 */
     97static inline bool is_load_store_instruction(instruction_t instr)
     98{
     99        /* load store immediate offset */
     100        if (instr.type == 0x2)
     101                return true;
     102       
     103        /* load store register offset */
     104        if ((instr.type == 0x3) && (instr.bit4 == 0))
     105                return true;
     106       
     107        /* load store multiple */
     108        if (instr.type == 0x4)
     109                return true;
     110       
     111        /* oprocessor load/store */
     112        if (instr.type == 0x6)
     113                return true;
     114       
     115        return false;
     116}
     117
     118/** Decides whether the instruction is swap or not.
     119 *
     120 * @param instr Instruction
     121 *
     122 * @return true when instruction is swap, false otherwise
     123 */
     124static inline bool is_swap_instruction(instruction_t instr)
     125{
     126        /* swap, swapb instruction */
     127        if ((instr.type == 0x0) &&
     128            ((instr.opcode == 0x8) || (instr.opcode == 0xa)) &&
     129            (instr.access == 0x0) && (instr.bits567 == 0x4) && (instr.bit4 == 1))
     130                return true;
     131       
     132        return false;
     133}
     134
    90135#if defined(PROCESSOR_armv4) | defined(PROCESSOR_armv5)
    91136/** Decides whether read or write into memory is requested.
     
    95140 *
    96141 * @return Type of access into memory, PF_ACCESS_EXEC if no memory access is
    97  *         requested.
     142 *         requested.
    98143 */
    99144static pf_access_t get_memory_access_type(uint32_t instr_addr,
     
    113158        }
    114159
    115         /* See ARM Architecture reference manual ARMv7-A and ARMV7-R edition
    116          * A5.3 (PDF p. 206) */
    117         static const struct {
    118                 uint32_t mask;
    119                 uint32_t value;
    120                 pf_access_t access;
    121         } ls_inst[] = {
    122                 /* Store word/byte */
    123                 { 0x0e100000, 0x04000000, PF_ACCESS_WRITE }, /*STR(B) imm*/
    124                 { 0x0e100010, 0x06000000, PF_ACCESS_WRITE }, /*STR(B) reg*/
    125                 /* Load word/byte */
    126                 { 0x0e100000, 0x04100000, PF_ACCESS_READ }, /*LDR(B) imm*/
    127                 { 0x0e100010, 0x06100000, PF_ACCESS_READ }, /*LDR(B) reg*/
    128                 /* Store half-word/dual  A5.2.8 */
    129                 { 0x0e1000b0, 0x000000b0, PF_ACCESS_WRITE }, /*STRH imm reg*/
    130                 /* Load half-word/dual A5.2.8 */
    131                 { 0x0e0000f0, 0x000000d0, PF_ACCESS_READ }, /*LDRH imm reg*/
    132                 { 0x0e1000b0, 0x001000b0, PF_ACCESS_READ }, /*LDRH imm reg*/
    133                 /* Block data transfer, Store */
    134                 { 0x0e100000, 0x08000000, PF_ACCESS_WRITE }, /* STM variants */
    135                 { 0x0e100000, 0x08100000, PF_ACCESS_READ },  /* LDM variants */
    136                 /* Swap */
    137                 { 0x0fb00000, 0x01000000, PF_ACCESS_WRITE },
    138         };
    139         const uint32_t inst = *(uint32_t*)instr_addr;
    140         for (unsigned i = 0; i < sizeof(ls_inst) / sizeof(ls_inst[0]); ++i) {
    141                 if ((inst & ls_inst[i].mask) == ls_inst[i].value) {
    142                         return ls_inst[i].access;
     160        /* load store instructions */
     161        if (is_load_store_instruction(instr)) {
     162                if (instr.access == 1) {
     163                        return PF_ACCESS_READ;
     164                } else {
     165                        return PF_ACCESS_WRITE;
    143166                }
     167        }
     168
     169        /* swap, swpb instruction */
     170        if (is_swap_instruction(instr)) {
     171                return PF_ACCESS_WRITE;
    144172        }
    145173
    146174        panic("page_fault - instruction doesn't access memory "
    147175            "(instr_code: %#0" PRIx32 ", badvaddr:%p).",
    148             inst, (void *) badvaddr);
     176            *(uint32_t*)instr_union.instr, (void *) badvaddr);
     177
     178        return PF_ACCESS_EXEC;
    149179}
    150180#endif
  • uspace/app/tester/Makefile

    r3451129 rc6b601b  
    2929
    3030USPACE_PREFIX = ../..
    31 LIBS = $(LIBEXT2_PREFIX)/libext2.a $(LIBBLOCK_PREFIX)/libblock.a $(LIBSOFTFLOAT_PREFIX)/libsoftfloat.a
    32 EXTRA_CFLAGS = -I$(LIBBLOCK_PREFIX) -I$(LIBEXT2_PREFIX) -I$(LIBSOFTFLOAT_PREFIX)
     31LIBS = $(LIBEXT2_PREFIX)/libext2.a $(LIBBLOCK_PREFIX)/libblock.a
     32EXTRA_CFLAGS = -I$(LIBBLOCK_PREFIX) -I$(LIBEXT2_PREFIX)
    3333BINARY = tester
    3434
     
    4848        fault/fault2.c \
    4949        fault/fault3.c \
    50         float/float1.c \
    51         float/softfloat1.c \
    5250        vfs/vfs1.c \
    5351        ipc/ping_pong.c \
     
    6159        hw/misc/virtchar1.c \
    6260        hw/serial/serial1.c \
    63         ext2/ext2_1.c
     61        libext2/libext2_1.c
    6462
    6563include $(USPACE_PREFIX)/Makefile.common
  • uspace/app/tester/tester.c

    r3451129 rc6b601b  
    5858#include "fault/fault2.def"
    5959#include "fault/fault3.def"
    60 #include "float/float1.def"
    61 #include "float/softfloat1.def"
    6260#include "vfs/vfs1.def"
    6361#include "ipc/ping_pong.def"
     
    7068#include "hw/serial/serial1.def"
    7169#include "hw/misc/virtchar1.def"
    72 #include "ext2/ext2_1.def"
     70#include "libext2/libext2_1.def"
    7371        {NULL, NULL, NULL, false}
    7472};
  • uspace/app/tester/tester.h

    r3451129 rc6b601b  
    9191extern const char *test_fault2(void);
    9292extern const char *test_fault3(void);
    93 extern const char *test_float1(void);
    94 extern const char *test_softfloat1(void);
    9593extern const char *test_vfs1(void);
    9694extern const char *test_ping_pong(void);
     
    103101extern const char *test_serial1(void);
    104102extern const char *test_virtchar1(void);
    105 extern const char *test_ext2_1(void);
     103extern const char *test_libext2_1(void);
    106104extern const char *test_devman1(void);
    107105extern const char *test_devman2(void);
  • uspace/lib/c/arch/arm32/Makefile.common

    r3451129 rc6b601b  
    2828#
    2929
    30 GCC_CFLAGS += -ffixed-r9 -mtp=soft -fno-omit-frame-pointer -mapcs-frame -march=$(subst _,-,$(PROCESSOR))
     30GCC_CFLAGS += -ffixed-r9 -mtp=soft -fno-omit-frame-pointer -march=$(subst _,-,$(PROCESSOR))
    3131
    3232ENDIANESS = LE
  • uspace/lib/fs/libfs.c

    r3451129 rc6b601b  
    631631                                                async_answer_0(rid, rc);
    632632                                        } else {
    633                                                 (void) ops->node_put(cur);
    634                                                 cur = fn;
    635                                                 goto out_with_answer;
     633                                                aoff64_t size = ops->size_get(fn);
     634                                                async_answer_5(rid, fs_handle,
     635                                                    service_id,
     636                                                    ops->index_get(fn),
     637                                                    LOWER32(size),
     638                                                    UPPER32(size),
     639                                                    ops->lnkcnt_get(fn));
     640                                                (void) ops->node_put(fn);
    636641                                        }
    637642                                } else
     
    710715                                        async_answer_0(rid, rc);
    711716                                } else {
    712                                         (void) ops->node_put(cur);
    713                                         cur = fn;
    714                                         goto out_with_answer;
     717                                        aoff64_t size = ops->size_get(fn);
     718                                        async_answer_5(rid, fs_handle,
     719                                            service_id,
     720                                            ops->index_get(fn),
     721                                            LOWER32(size),
     722                                            UPPER32(size),
     723                                            ops->lnkcnt_get(fn));
     724                                        (void) ops->node_put(fn);
    715725                                }
    716726                        } else
  • uspace/lib/softfloat/Makefile

    r3451129 rc6b601b  
    2929
    3030USPACE_PREFIX = ../..
     31EXTRA_CFLAGS = -Iinclude
    3132LIBRARY = libsoftfloat
    3233
    3334SOURCES = \
    34         softfloat.c \
    35         common.c \
    36         add.c \
    37         sub.c \
    38         div.c \
    39         mul.c \
    40         comparison.c \
    41         conversion.c \
    42         other.c
     35        generic/add.c \
     36        generic/common.c \
     37        generic/comparison.c \
     38        generic/conversion.c \
     39        generic/div.c \
     40        generic/mul.c \
     41        generic/other.c \
     42        generic/softfloat.c \
     43        generic/sub.c
    4344
    4445include $(USPACE_PREFIX)/Makefile.common
Note: See TracChangeset for help on using the changeset viewer.