Changeset c501a76 for patches


Ignore:
Timestamp:
Sep 16, 2006, 1:38:41 PM (18 years ago)
Author:
Jim Gifford <clfs@…>
Branches:
clfs-1.2, clfs-2.1, clfs-3.0.0-systemd, clfs-3.0.0-sysvinit, master, systemd, sysvinit
Children:
59bc7cb
Parents:
0c3999a
Message:

Updated Linux MIPS patches

Location:
patches
Files:
1 added
1 deleted
1 moved

Legend:

Unmodified
Added
Removed
  • patches/linux-2.6.17.13-mips_fixes-2.patch

    r0c3999a rc501a76  
    11Submitted By: Jim Gifford (patches at jg555 dot com)
    2 Date: 2006-08-14
    3 Initial Package Version: 2.6.17.4
     2Date: 2006-09-16
     3Initial Package Version: 2.6.17.13
    44Origin: Linux-MIPS Mailing List
    55Upstream Status: Not Applied
     
    3535 lib-y += ashldi3.o ashrdi3.o lshrdi3.o
    3636 
    37 diff -Naur linux-2.6.17.8.orig/arch/mips/lib/ashldi3.c linux-2.6.17.8/arch/mips/lib/ashldi3.c
    38 --- linux-2.6.17.8.orig/arch/mips/lib/ashldi3.c 1969-12-31 16:00:00.000000000 -0800
    39 +++ linux-2.6.17.8/arch/mips/lib/ashldi3.c      2006-08-14 08:05:27.786793056 -0700
    40 @@ -0,0 +1,29 @@
    41 +#include <linux/module.h>
    42 +
    43 +#include "libgcc.h"
    44 +
    45 +long long __ashldi3(long long u, word_type b)
    46 +{
    47 +       DWunion uu, w;
    48 +       word_type bm;
    49 +
    50 +       if (b == 0)
    51 +               return u;
    52 +
    53 +       uu.ll = u;
    54 +       bm = 32 - b;
    55 +
    56 +       if (bm <= 0) {
    57 +               w.s.low = 0;
    58 +               w.s.high = (unsigned int) uu.s.low << -bm;
    59 +       } else {
    60 +               const unsigned int carries = (unsigned int) uu.s.low >> bm;
    61 +
    62 +               w.s.low = (unsigned int) uu.s.low << b;
    63 +               w.s.high = ((unsigned int) uu.s.high << b) | carries;
    64 +       }
    65 +
    66 +       return w.ll;
    67 +}
    68 +
    69 +EXPORT_SYMBOL(__ashldi3);
    70 diff -Naur linux-2.6.17.8.orig/arch/mips/lib/ashrdi3.c linux-2.6.17.8/arch/mips/lib/ashrdi3.c
    71 --- linux-2.6.17.8.orig/arch/mips/lib/ashrdi3.c 1969-12-31 16:00:00.000000000 -0800
    72 +++ linux-2.6.17.8/arch/mips/lib/ashrdi3.c      2006-08-14 08:05:27.786793056 -0700
    73 @@ -0,0 +1,31 @@
    74 +#include <linux/module.h>
    75 +
    76 +#include "libgcc.h"
    77 +
    78 +long long __ashrdi3(long long u, word_type b)
    79 +{
    80 +       DWunion uu, w;
    81 +       word_type bm;
    82 +
    83 +       if (b == 0)
    84 +               return u;
    85 +
    86 +       uu.ll = u;
    87 +       bm = 32 - b;
    88 +
    89 +       if (bm <= 0) {
    90 +               /* w.s.high = 1..1 or 0..0 */
    91 +               w.s.high =
    92 +                   uu.s.high >> 31;
    93 +               w.s.low = uu.s.high >> -bm;
    94 +       } else {
    95 +               const unsigned int carries = (unsigned int) uu.s.high << bm;
    96 +
    97 +               w.s.high = uu.s.high >> b;
    98 +               w.s.low = ((unsigned int) uu.s.low >> b) | carries;
    99 +       }
    100 +
    101 +       return w.ll;
    102 +}
    103 +
    104 +EXPORT_SYMBOL(__ashrdi3);
    10537diff -Naur linux-2.6.17.8.orig/arch/mips/lib/iomap.c linux-2.6.17.8/arch/mips/lib/iomap.c
    10638--- linux-2.6.17.8.orig/arch/mips/lib/iomap.c   1969-12-31 16:00:00.000000000 -0800
     
    185117+EXPORT_SYMBOL(pci_iomap);
    186118+EXPORT_SYMBOL(pci_iounmap);
    187 diff -Naur linux-2.6.17.8.orig/arch/mips/lib/libgcc.h linux-2.6.17.8/arch/mips/lib/libgcc.h
    188 --- linux-2.6.17.8.orig/arch/mips/lib/libgcc.h  1969-12-31 16:00:00.000000000 -0800
    189 +++ linux-2.6.17.8/arch/mips/lib/libgcc.h       2006-08-14 08:05:27.786793056 -0700
    190 @@ -0,0 +1,26 @@
    191 +#ifndef __ASM_LIBGCC_H
    192 +#define __ASM_LIBGCC_H
    193 +
    194 +#include <asm/byteorder.h>
    195 +
    196 +typedef int word_type __attribute__ ((mode (__word__)));
    197 +
    198 +#ifdef __BIG_ENDIAN
    199 +struct DWstruct {
    200 +       int high, low;
    201 +};
    202 +#elif defined(__LITTLE_ENDIAN)
    203 +struct DWstruct {
    204 +       int low, high;
    205 +};
    206 +#else
    207 +#error I feel sick.
    208 +#endif
    209 +
    210 +typedef union
    211 +{
    212 +       struct DWstruct s;
    213 +       long long ll;
    214 +} DWunion;
    215 +
    216 +#endif /* __ASM_LIBGCC_H */
    217 diff -Naur linux-2.6.17.8.orig/arch/mips/lib/lshrdi3.c linux-2.6.17.8/arch/mips/lib/lshrdi3.c
    218 --- linux-2.6.17.8.orig/arch/mips/lib/lshrdi3.c 1969-12-31 16:00:00.000000000 -0800
    219 +++ linux-2.6.17.8/arch/mips/lib/lshrdi3.c      2006-08-14 08:05:27.786793056 -0700
    220 @@ -0,0 +1,29 @@
    221 +#include <linux/module.h>
    222 +
    223 +#include "libgcc.h"
    224 +
    225 +long long __lshrdi3(long long u, word_type b)
    226 +{
    227 +       DWunion uu, w;
    228 +       word_type bm;
    229 +
    230 +       if (b == 0)
    231 +               return u;
    232 +
    233 +       uu.ll = u;
    234 +       bm = 32 - b;
    235 +
    236 +       if (bm <= 0) {
    237 +               w.s.high = 0;
    238 +               w.s.low = (unsigned int) uu.s.high >> -bm;
    239 +       } else {
    240 +               const unsigned int carries = (unsigned int) uu.s.high << bm;
    241 +
    242 +               w.s.high = (unsigned int) uu.s.high >> b;
    243 +               w.s.low = ((unsigned int) uu.s.low >> b) | carries;
    244 +       }
    245 +
    246 +       return w.ll;
    247 +}
    248 +
    249 +EXPORT_SYMBOL(__lshrdi3);
    250119diff -Naur linux-2.6.17.8.orig/include/asm-mips/io.h linux-2.6.17.8/include/asm-mips/io.h
    251120--- linux-2.6.17.8.orig/include/asm-mips/io.h   2006-08-14 08:05:04.311410340 -0700
Note: See TracChangeset for help on using the changeset viewer.