Changeset 542e819 in mainline for uspace


Ignore:
Timestamp:
2012-08-12T09:03:30Z (13 years ago)
Author:
Martin Decky <martin@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
b08e7970
Parents:
bd29f9c9 (diff), 371cb6c (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.
Message:

merge mainline changes

Location:
uspace
Files:
18 edited

Legend:

Unmodified
Added
Removed
  • uspace/lib/c/arch/abs32le/_link.ld.in

    rbd29f9c9 r542e819  
    2222        . = 0x1000 + SIZEOF_HEADERS;
    2323#endif
     24       
     25        /* Make sure the code is aligned reasonably */
     26        . = ALIGN(., 16);
    2427       
    2528        .text : {
  • uspace/lib/c/arch/amd64/_link.ld.in

    rbd29f9c9 r542e819  
    2323        . = 0x1000 + SIZEOF_HEADERS;
    2424#endif
     25       
     26        /* Make sure the code is aligned reasonably */
     27        . = ALIGN(., 16);
    2528       
    2629        .init : {
  • uspace/lib/c/arch/amd64/include/elf_linux.h

    rbd29f9c9 r542e819  
    6666        uint64_t rsp;
    6767        uint64_t ss;
     68
     69        /*
     70         * The following registers need to be part of elf_regs_t.
     71         * Unfortunately, we don't have any information about them in our
     72         * istate_t.
     73         */
     74        uint64_t unused_fs_base;
     75        uint64_t unused_gs_base;
     76        uint64_t unused_ds;
     77        uint64_t unused_es;
     78        uint64_t unused_fs;
     79        uint64_t unused_gs;
    6880} elf_regs_t;
    6981
     
    91103        elf_regs->rsp = istate->rsp;
    92104        elf_regs->ss = istate->ss;
     105
     106        /*
     107         * Reset the registers for which there is not enough info in istate_t.
     108         */
     109        elf_regs->unused_fs_base = 0;
     110        elf_regs->unused_gs_base = 0;
     111        elf_regs->unused_ds = 0;
     112        elf_regs->unused_es = 0;
     113        elf_regs->unused_fs = 0;
     114        elf_regs->unused_gs = 0;
    93115}
    94116
  • uspace/lib/c/arch/arm32/_link.ld.in

    rbd29f9c9 r542e819  
    2222        . = 0x1000 + SIZEOF_HEADERS;
    2323#endif
     24       
     25        /* Make sure the code is aligned reasonably */
     26        . = ALIGN(., 8);
    2427       
    2528        .init : {
  • uspace/lib/c/arch/arm32/src/fibril.S

    rbd29f9c9 r542e819  
    3535        stmia r0!, {sp, lr}
    3636        stmia r0!, {r4-r11}
    37 
     37       
    3838        # return 1
    3939        mov r0, #1
     
    4343        ldmia r0!, {sp, lr}
    4444        ldmia r0!, {r4-r11}
    45 
    46         #return 0
     45       
     46        # return 0
    4747        mov r0, #0
    4848        mov pc, lr
  • uspace/lib/c/arch/arm32/src/stacktrace_asm.S

    rbd29f9c9 r542e819  
    4141
    4242stacktrace_pc_get:
    43         mov r0, lr 
     43        mov r0, lr
    4444        mov pc, lr
  • uspace/lib/c/arch/arm32/src/thread_entry.s

    rbd29f9c9 r542e819  
    4242        push {fp, ip, lr, pc}
    4343        sub fp, ip, #4
    44 
    45         b __thread_main
     44       
     45        b __thread_main
  • uspace/lib/c/arch/ia32/_link.ld.in

    rbd29f9c9 r542e819  
    3131#endif
    3232       
     33        /* Make sure the code is aligned reasonably */
     34        . = ALIGN(., 16);
     35       
    3336        .init : {
    3437                *(.init);
     
    3942                *(.rodata .rodata.*);
    4043        } :text
    41 
     44       
    4245#if defined(SHLIB) || defined(DLEXE)
    4346        .rel.plt : {
     
    8285#if defined(SHLIB) || defined(DLEXE)
    8386        .data.rel : {
    84                 *(.data.rel .data.rel.*);
     87                *(.data.rel .data.rel.*);
    8588        } :data
    86 
     89       
    8790        .got : {
    88                 *(.got);
     91                *(.got);
    8992        } :data
     93       
    9094        .got.plt : {
    91                 *(.got.plt);
     95                *(.got.plt);
    9296        } :data
    9397#endif
  • uspace/lib/c/arch/ia64/_link.ld.in

    rbd29f9c9 r542e819  
    2323#endif
    2424       
    25         /*
    26          * XXX This is just a work around. Problem: .init section does not
    27          * have the proper alignment.
    28          */
     25        /* Make sure the code is aligned reasonably */
    2926        . = ALIGN(., 16);
    3027       
  • uspace/lib/c/arch/mips32/Makefile.common

    rbd29f9c9 r542e819  
    2727#
    2828
    29 GCC_CFLAGS += -mips3 -mabi=32
     29GCC_CFLAGS += -msoft-float -mips3 -mabi=32
    3030
    3131ENDIANESS = LE
  • uspace/lib/c/arch/mips32/_link.ld.in

    rbd29f9c9 r542e819  
    2222        . = 0x4000 + SIZEOF_HEADERS;
    2323#endif
     24       
     25        /* Make sure the code is aligned reasonably */
     26        . = ALIGN(., 16);
    2427       
    2528        .init : {
  • uspace/lib/c/arch/mips32eb/Makefile.common

    rbd29f9c9 r542e819  
    2727#
    2828
    29 GCC_CFLAGS += -mips3 -mabi=32
     29GCC_CFLAGS += -msoft-float -mips3 -mabi=32
    3030
    3131ENDIANESS = BE
  • uspace/lib/c/arch/mips64/Makefile.common

    rbd29f9c9 r542e819  
    2727#
    2828
    29 GCC_CFLAGS += -mips3 -mabi=64
     29GCC_CFLAGS += -msoft-float -mips3 -mabi=64
    3030AFLAGS = -64
    3131
  • uspace/lib/c/arch/mips64/_link.ld.in

    rbd29f9c9 r542e819  
    2323        . = 0x4000 + SIZEOF_HEADERS;
    2424#endif
     25       
     26        /* Make sure the code is aligned reasonably */
     27        . = ALIGN(., 16);
    2528       
    2629        .init : {
  • uspace/lib/c/arch/ppc32/_link.ld.in

    rbd29f9c9 r542e819  
    2323        . = 0x1000 + SIZEOF_HEADERS;
    2424#endif
     25       
     26        /* Make sure the code is aligned reasonably */
     27        . = ALIGN(., 4);
    2528       
    2629        .init : {
  • uspace/lib/c/arch/sparc64/_link.ld.in

    rbd29f9c9 r542e819  
    2222        . = 0x4000 + SIZEOF_HEADERS;
    2323#endif
     24       
     25        /* Make sure the code is aligned reasonably */
     26        . = ALIGN(., 16);
    2427       
    2528        .init : {
  • uspace/lib/c/generic/str.c

    rbd29f9c9 r542e819  
    431431 * and both strings consist of the same sequence of characters.
    432432 *
    433  * A string is smaller than another string iff it is shorter or
    434  * has a character with lower value at the first position where
    435  * the strings differ.
     433 * A string S1 is less than another string S2 if it has a character with
     434 * lower value at the first character position where the strings differ.
     435 * If the strings differ in length, the shorter one is treated as if
     436 * padded by characters with a value of zero.
    436437 *
    437438 * @param s1 First string to compare.
    438439 * @param s2 Second string to compare.
    439440 *
    440  * @return 0 if the strings are equal, -1 if first is smaller,
    441  *         1 if second smaller.
     441 * @return 0 if the strings are equal, -1 if the first is less than the second,
     442 *         1 if the second is less than the first.
    442443 *
    443444 */
     
    475476 * up to max_len characters.
    476477 *
    477  * A string is smaller than another string iff it is shorter or
    478  * has a character with lower value at the first position where
    479  * the strings differ, considering only first max_len characters.
     478 * A string S1 is less than another string S2 if it has a character with
     479 * lower value at the first character position where the strings differ.
     480 * If the strings differ in length, the shorter one is treated as if
     481 * padded by characters with a value of zero. Only the first max_len
     482 * characters are considered.
    480483 *
    481484 * @param s1      First string to compare.
     
    483486 * @param max_len Maximum number of characters to consider.
    484487 *
    485  * @return 0 if the strings are equal, -1 if first is smaller,
    486  *         1 if second smaller.
     488 * @return 0 if the strings are equal, -1 if the first is less than the second,
     489 *         1 if the second is less than the first.
    487490 *
    488491 */
  • uspace/srv/net/tcp/sock.c

    rbd29f9c9 r542e819  
    779779        }
    780780
     781        /* Grab recv_buffer_lock because of CV wait in tcp_sock_recv_fibril() */
     782        fibril_mutex_lock(&socket->recv_buffer_lock);
     783        socket->sock_core = NULL;
     784        fibril_mutex_unlock(&socket->recv_buffer_lock);
     785
    781786        rc = socket_destroy(NULL, socket_id, &client->sockets, &gsock,
    782787            tcp_free_sock_data);
     
    839844        log_msg(LVL_DEBUG, "tcp_sock_recv_fibril()");
    840845
     846        fibril_mutex_lock(&sock->recv_buffer_lock);
     847
    841848        while (true) {
    842849                log_msg(LVL_DEBUG, "call tcp_uc_receive()");
    843                 fibril_mutex_lock(&sock->recv_buffer_lock);
    844                 while (sock->recv_buffer_used != 0)
     850                while (sock->recv_buffer_used != 0 && sock->sock_core != NULL)
    845851                        fibril_condvar_wait(&sock->recv_buffer_cv,
    846852                            &sock->recv_buffer_lock);
     
    852858                        sock->recv_error = trc;
    853859                        fibril_condvar_broadcast(&sock->recv_buffer_cv);
    854                         fibril_mutex_unlock(&sock->recv_buffer_lock);
    855                         tcp_sock_notify_data(sock->sock_core);
     860                        if (sock->sock_core != NULL)
     861                                tcp_sock_notify_data(sock->sock_core);
    856862                        break;
    857863                }
     
    861867                sock->recv_buffer_used = data_len;
    862868                fibril_condvar_broadcast(&sock->recv_buffer_cv);
    863                 fibril_mutex_unlock(&sock->recv_buffer_lock);
    864                 tcp_sock_notify_data(sock->sock_core);
    865         }
     869                if (sock->sock_core != NULL)
     870                        tcp_sock_notify_data(sock->sock_core);
     871        }
     872
     873        fibril_mutex_unlock(&sock->recv_buffer_lock);
    866874
    867875        tcp_uc_delete(sock->conn);
Note: See TracChangeset for help on using the changeset viewer.