Revert "alpha: move exports to actual definitions"
authorBen Hutchings <ben@decadent.org.uk>
Thu, 1 Dec 2016 23:14:46 +0000 (23:14 +0000)
committerYves-Alexis Perez <corsac@debian.org>
Wed, 21 Feb 2018 15:29:03 +0000 (15:29 +0000)
This reverts commit 00fc0e0dda6286407f3854cd71a125f519a5689c because
symbols exported from assembly don't automatically get modversions (ABI
hashes).

Gbp-Pq: Topic bugfix/alpha
Gbp-Pq: Name revert-alpha-move-exports-to-actual-definitions.patch

41 files changed:
arch/alpha/include/asm/Kbuild
arch/alpha/kernel/Makefile
arch/alpha/kernel/alpha_ksyms.c [new file with mode: 0644]
arch/alpha/kernel/machvec_impl.h
arch/alpha/kernel/setup.c
arch/alpha/lib/callback_srm.S
arch/alpha/lib/checksum.c
arch/alpha/lib/clear_page.S
arch/alpha/lib/clear_user.S
arch/alpha/lib/copy_page.S
arch/alpha/lib/copy_user.S
arch/alpha/lib/csum_ipv6_magic.S
arch/alpha/lib/csum_partial_copy.c
arch/alpha/lib/dec_and_lock.c
arch/alpha/lib/divide.S
arch/alpha/lib/ev6-clear_page.S
arch/alpha/lib/ev6-clear_user.S
arch/alpha/lib/ev6-copy_page.S
arch/alpha/lib/ev6-copy_user.S
arch/alpha/lib/ev6-csum_ipv6_magic.S
arch/alpha/lib/ev6-divide.S
arch/alpha/lib/ev6-memchr.S
arch/alpha/lib/ev6-memcpy.S
arch/alpha/lib/ev6-memset.S
arch/alpha/lib/ev67-strcat.S
arch/alpha/lib/ev67-strchr.S
arch/alpha/lib/ev67-strlen.S
arch/alpha/lib/ev67-strncat.S
arch/alpha/lib/ev67-strrchr.S
arch/alpha/lib/fpreg.c
arch/alpha/lib/memchr.S
arch/alpha/lib/memcpy.c
arch/alpha/lib/memmove.S
arch/alpha/lib/memset.S
arch/alpha/lib/strcat.S
arch/alpha/lib/strchr.S
arch/alpha/lib/strcpy.S
arch/alpha/lib/strlen.S
arch/alpha/lib/strncat.S
arch/alpha/lib/strncpy.S
arch/alpha/lib/strrchr.S

index bf8475ce85ee2ab37a5e69faf86f7acd22ac59dc..ffd9cf5ec8c407c4686c519de89b3e827f1656a2 100644 (file)
@@ -3,7 +3,6 @@
 generic-y += clkdev.h
 generic-y += cputime.h
 generic-y += exec.h
-generic-y += export.h
 generic-y += irq_work.h
 generic-y += mcs_spinlock.h
 generic-y += mm-arch-hooks.h
index 8ce13d7a2ad389cb26d356b2954e7034326203ac..3ecac0106c8a1aa1e2fb85b5b868cf9e73eb1091 100644 (file)
@@ -8,7 +8,7 @@ ccflags-y       := -Wno-sign-compare
 
 obj-y    := entry.o traps.o process.o osf_sys.o irq.o \
            irq_alpha.o signal.o setup.o ptrace.o time.o \
-           systbls.o err_common.o io.o
+           alpha_ksyms.o systbls.o err_common.o io.o
 
 obj-$(CONFIG_VGA_HOSE) += console.o
 obj-$(CONFIG_SMP)      += smp.o
diff --git a/arch/alpha/kernel/alpha_ksyms.c b/arch/alpha/kernel/alpha_ksyms.c
new file mode 100644 (file)
index 0000000..f4c7ab6
--- /dev/null
@@ -0,0 +1,102 @@
+/*
+ * linux/arch/alpha/kernel/alpha_ksyms.c
+ *
+ * Export the alpha-specific functions that are needed for loadable
+ * modules.
+ */
+
+#include <linux/module.h>
+#include <asm/console.h>
+#include <asm/uaccess.h>
+#include <asm/checksum.h>
+#include <asm/fpu.h>
+#include <asm/machvec.h>
+
+#include <linux/syscalls.h>
+
+/* these are C runtime functions with special calling conventions: */
+extern void __divl (void);
+extern void __reml (void);
+extern void __divq (void);
+extern void __remq (void);
+extern void __divlu (void);
+extern void __remlu (void);
+extern void __divqu (void);
+extern void __remqu (void);
+
+EXPORT_SYMBOL(alpha_mv);
+EXPORT_SYMBOL(callback_getenv);
+EXPORT_SYMBOL(callback_setenv);
+EXPORT_SYMBOL(callback_save_env);
+
+/* platform dependent support */
+EXPORT_SYMBOL(strcat);
+EXPORT_SYMBOL(strcpy);
+EXPORT_SYMBOL(strlen);
+EXPORT_SYMBOL(strncpy);
+EXPORT_SYMBOL(strncat);
+EXPORT_SYMBOL(strchr);
+EXPORT_SYMBOL(strrchr);
+EXPORT_SYMBOL(memmove);
+EXPORT_SYMBOL(__memcpy);
+EXPORT_SYMBOL(__memset);
+EXPORT_SYMBOL(___memset);
+EXPORT_SYMBOL(__memsetw);
+EXPORT_SYMBOL(__constant_c_memset);
+EXPORT_SYMBOL(copy_page);
+EXPORT_SYMBOL(clear_page);
+
+EXPORT_SYMBOL(alpha_read_fp_reg);
+EXPORT_SYMBOL(alpha_read_fp_reg_s);
+EXPORT_SYMBOL(alpha_write_fp_reg);
+EXPORT_SYMBOL(alpha_write_fp_reg_s);
+
+/* Networking helper routines. */
+EXPORT_SYMBOL(csum_tcpudp_magic);
+EXPORT_SYMBOL(ip_compute_csum);
+EXPORT_SYMBOL(ip_fast_csum);
+EXPORT_SYMBOL(csum_partial_copy_nocheck);
+EXPORT_SYMBOL(csum_partial_copy_from_user);
+EXPORT_SYMBOL(csum_ipv6_magic);
+
+#ifdef CONFIG_MATHEMU_MODULE
+extern long (*alpha_fp_emul_imprecise)(struct pt_regs *, unsigned long);
+extern long (*alpha_fp_emul) (unsigned long pc);
+EXPORT_SYMBOL(alpha_fp_emul_imprecise);
+EXPORT_SYMBOL(alpha_fp_emul);
+#endif
+
+/*
+ * The following are specially called from the uaccess assembly stubs.
+ */
+EXPORT_SYMBOL(__copy_user);
+EXPORT_SYMBOL(__do_clear_user);
+
+/* 
+ * SMP-specific symbols.
+ */
+
+#ifdef CONFIG_SMP
+EXPORT_SYMBOL(_atomic_dec_and_lock);
+#endif /* CONFIG_SMP */
+
+/*
+ * The following are special because they're not called
+ * explicitly (the C compiler or assembler generates them in
+ * response to division operations).  Fortunately, their
+ * interface isn't gonna change any time soon now, so it's OK
+ * to leave it out of version control.
+ */
+# undef memcpy
+# undef memset
+EXPORT_SYMBOL(__divl);
+EXPORT_SYMBOL(__divlu);
+EXPORT_SYMBOL(__divq);
+EXPORT_SYMBOL(__divqu);
+EXPORT_SYMBOL(__reml);
+EXPORT_SYMBOL(__remlu);
+EXPORT_SYMBOL(__remq);
+EXPORT_SYMBOL(__remqu);
+EXPORT_SYMBOL(memcpy);
+EXPORT_SYMBOL(memset);
+EXPORT_SYMBOL(memchr);
index b7d69604b6d2e522b8aabc0e904c0ab78b0e637a..d3398f6ab74c2d0b80c538a1181d03f47fbed501 100644 (file)
    else beforehand.  Fine.  We'll do it ourselves.  */
 #if 0
 #define ALIAS_MV(system) \
-  struct alpha_machine_vector alpha_mv __attribute__((alias(#system "_mv"))); \
-  EXPORT_SYMBOL(alpha_mv);
+  struct alpha_machine_vector alpha_mv __attribute__((alias(#system "_mv")));
 #else
 #define ALIAS_MV(system) \
-  asm(".global alpha_mv\nalpha_mv = " #system "_mv"); \
-  EXPORT_SYMBOL(alpha_mv);
+  asm(".global alpha_mv\nalpha_mv = " #system "_mv");
 #endif
 #endif /* GENERIC */
index 4811e54069fcfbb733185d4004e24efa814b9165..b20af76f12c1dbf548a27210fdbb196a2c77496d 100644 (file)
@@ -115,7 +115,6 @@ unsigned long alpha_agpgart_size = DEFAULT_AGP_APER_SIZE;
 
 #ifdef CONFIG_ALPHA_GENERIC
 struct alpha_machine_vector alpha_mv;
-EXPORT_SYMBOL(alpha_mv);
 #endif
 
 #ifndef alpha_using_srm
index 6093addc931a5bf3dec4d7c13f6cf84c88417e39..8804bec2c6448e15e5f34be99b25e9bef8518a15 100644 (file)
@@ -3,7 +3,6 @@
  */
 
 #include <asm/console.h>
-#include <asm/export.h>
 
 .text
 #define HWRPB_CRB_OFFSET 0xc0
@@ -93,10 +92,6 @@ CALLBACK(reset_env, CCB_RESET_ENV, 4)
 CALLBACK(save_env, CCB_SAVE_ENV, 1)
 CALLBACK(pswitch, CCB_PSWITCH, 3)
 CALLBACK(bios_emul, CCB_BIOS_EMUL, 5)
-
-EXPORT_SYMBOL(callback_getenv)
-EXPORT_SYMBOL(callback_setenv)
-EXPORT_SYMBOL(callback_save_env)
        
 .data
 __alpha_using_srm:             # For use by bootpheader
index b57f8007db14f78565200134f6f519165d3970ea..377f9e34eb9709631e50aa20ce87417ebdeac3a8 100644 (file)
@@ -48,7 +48,6 @@ __sum16 csum_tcpudp_magic(__be32 saddr, __be32 daddr,
                (__force u64)saddr + (__force u64)daddr +
                (__force u64)sum + ((len + proto) << 8));
 }
-EXPORT_SYMBOL(csum_tcpudp_magic);
 
 __wsum csum_tcpudp_nofold(__be32 saddr, __be32 daddr,
                          __u32 len, __u8 proto, __wsum sum)
@@ -145,7 +144,6 @@ __sum16 ip_fast_csum(const void *iph, unsigned int ihl)
 {
        return (__force __sum16)~do_csum(iph,ihl*4);
 }
-EXPORT_SYMBOL(ip_fast_csum);
 
 /*
  * computes the checksum of a memory block at buff, length len,
@@ -180,4 +178,3 @@ __sum16 ip_compute_csum(const void *buff, int len)
 {
        return (__force __sum16)~from64to16(do_csum(buff,len));
 }
-EXPORT_SYMBOL(ip_compute_csum);
index 263d7393c0e7a83fd15e570bb171bc726b55afbc..a221ae266e29098ab55cd72fb42ede2ff11588bf 100644 (file)
@@ -3,7 +3,7 @@
  *
  * Zero an entire page.
  */
-#include <asm/export.h>
+
        .text
        .align 4
        .global clear_page
@@ -37,4 +37,3 @@ clear_page:
        nop
 
        .end clear_page
-       EXPORT_SYMBOL(clear_page)
index bf5b931866ba1ed069758cfa95f01f35e18b6b02..8860316c195769ebdf907d590aee0c19555ac956 100644 (file)
@@ -24,7 +24,6 @@
  * Clobbers:
  *     $1,$2,$3,$4,$5,$6
  */
-#include <asm/export.h>
 
 /* Allow an exception for an insn; exit if we get one.  */
 #define EX(x,y...)                     \
@@ -112,4 +111,3 @@ $exception:
        ret     $31, ($28), 1   # .. e1 :
 
        .end __do_clear_user
-       EXPORT_SYMBOL(__do_clear_user)
index 2ee0bd0508c5943aa8eb64e074b6f5bb86de3920..9f3b97459cc64fb5eb70ec7b15ded1a1e97a0245 100644 (file)
@@ -3,7 +3,7 @@
  *
  * Copy an entire page.
  */
-#include <asm/export.h>
+
        .text
        .align 4
        .global copy_page
@@ -47,4 +47,3 @@ copy_page:
        nop
 
        .end copy_page
-       EXPORT_SYMBOL(copy_page)
index 509f62b6531102b539e61f11519ac4d49da02fe9..ac9c3766ba8cb21528497d8d880425faddaa27d6 100644 (file)
@@ -26,8 +26,6 @@
  *     $1,$2,$3,$4,$5,$6,$7
  */
 
-#include <asm/export.h>
-
 /* Allow an exception for an insn; exit if we get one.  */
 #define EXI(x,y...)                    \
        99: x,##y;                      \
@@ -131,4 +129,3 @@ $exitout:
        ret $31,($28),1
 
        .end __copy_user
-EXPORT_SYMBOL(__copy_user)
index e74b4544b0cce0962dd9715f063224a89ed066d4..2c2acb96deb682de173c0a0b3983f92977d3ef8f 100644 (file)
@@ -12,7 +12,6 @@
  * added by Ivan Kokshaysky <ink@jurassic.park.msu.ru>
  */
 
-#include <asm/export.h>
        .globl csum_ipv6_magic
        .align 4
        .ent csum_ipv6_magic
@@ -114,4 +113,3 @@ csum_ipv6_magic:
        ret                     # .. e1 :
 
        .end csum_ipv6_magic
-       EXPORT_SYMBOL(csum_ipv6_magic)
index b4ff3b683bcd57802c8c422708c3c712098c4cc7..5675dca8dbb1412e0b2fcea1c748ec9d757a3e8c 100644 (file)
@@ -374,7 +374,6 @@ csum_partial_copy_from_user(const void __user *src, void *dst, int len,
        }
        return (__force __wsum)checksum;
 }
-EXPORT_SYMBOL(csum_partial_copy_from_user);
 
 __wsum
 csum_partial_copy_nocheck(const void *src, void *dst, int len, __wsum sum)
@@ -387,4 +386,3 @@ csum_partial_copy_nocheck(const void *src, void *dst, int len, __wsum sum)
        set_fs(oldfs);
        return checksum;
 }
-EXPORT_SYMBOL(csum_partial_copy_nocheck);
index 4221b40167eed5b85284e6d9bc831cdc31094666..f9f5fe830e9f9c8912daaf830c4a4b54454ea43c 100644 (file)
@@ -7,7 +7,6 @@
 
 #include <linux/spinlock.h>
 #include <linux/atomic.h>
-#include <linux/export.h>
 
   asm (".text                                  \n\
        .global _atomic_dec_and_lock            \n\
@@ -40,4 +39,3 @@ static int __used atomic_dec_and_lock_1(atomic_t *atomic, spinlock_t *lock)
        spin_unlock(lock);
        return 0;
 }
-EXPORT_SYMBOL(_atomic_dec_and_lock);
index 1e33bd1276213493b44c37acb877de57870cb445..2d1a0484a99e009e3e198f47f77b06194b50006d 100644 (file)
@@ -45,7 +45,6 @@
  *     $28 - compare status
  */
 
-#include <asm/export.h>
 #define halt .long 0
 
 /*
@@ -152,7 +151,6 @@ ufunction:
        addq    $30,STACK,$30
        ret     $31,($23),1
        .end    ufunction
-EXPORT_SYMBOL(ufunction)
 
 /*
  * Uhh.. Ugly signed division. I'd rather not have it at all, but
@@ -195,4 +193,3 @@ sfunction:
        addq    $30,STACK,$30
        ret     $31,($23),1
        .end    sfunction
-EXPORT_SYMBOL(sfunction)
index abe99e69a1945a2bac7ce4062bd43a7503c52907..adf4f7be0e2b6d6792e420e3b40af21ff8f449ca 100644 (file)
@@ -3,7 +3,7 @@
  *
  * Zero an entire page.
  */
-#include <asm/export.h>
+
         .text
         .align 4
         .global clear_page
@@ -52,4 +52,3 @@ clear_page:
        nop
 
        .end clear_page
-       EXPORT_SYMBOL(clear_page)
index 05bef6b505984465699627db5aeec012714893f4..4f42a16b7f53d18cfc08f076d540011ad6ca5215 100644 (file)
@@ -43,7 +43,6 @@
  *     want to leave a hole (and we also want to avoid repeating lots of work)
  */
 
-#include <asm/export.h>
 /* Allow an exception for an insn; exit if we get one.  */
 #define EX(x,y...)                     \
        99: x,##y;                      \
@@ -223,4 +222,4 @@ $exception:                 # Destination for exception recovery(?)
        nop                     # .. E  .. ..   :
        ret     $31, ($28), 1   # L0 .. .. ..   : L U L U
        .end __do_clear_user
-       EXPORT_SYMBOL(__do_clear_user)
+
index 77935061bddbb652c746938de8e8875239330cab..b789db19275443d092494ea80a41be772dedb96a 100644 (file)
@@ -56,7 +56,7 @@
    destination pages are in the dcache, but it is my guess that this is
    less important than the dcache miss case.  */
 
-#include <asm/export.h>
+
        .text
        .align 4
        .global copy_page
@@ -201,4 +201,3 @@ copy_page:
        nop
 
        .end copy_page
-       EXPORT_SYMBOL(copy_page)
index be720b518af9e6500ce7545887a6bf6a9cb715d3..c4d0689c3d26e7dae898f7addfa21bab28b4aa0b 100644 (file)
@@ -37,7 +37,6 @@
  *     L       - lower subcluster; L0 - subcluster L0; L1 - subcluster L1
  */
 
-#include <asm/export.h>
 /* Allow an exception for an insn; exit if we get one.  */
 #define EXI(x,y...)                    \
        99: x,##y;                      \
@@ -236,4 +235,4 @@ $exitout:                   # Destination for exception recovery(?)
        ret $31,($28),1         # L0 .. .. ..   : L U L U
 
        .end __copy_user
-       EXPORT_SYMBOL(__copy_user)
+
index de62627ac4fe1dce24f68cf94df29afb9099a35d..fc0bc399f872db671313f07e78ac8d20f5ff6637 100644 (file)
@@ -52,7 +52,6 @@
  * may cause additional delay in rare cases (load-load replay traps).
  */
 
-#include <asm/export.h>
        .globl csum_ipv6_magic
        .align 4
        .ent csum_ipv6_magic
@@ -149,4 +148,3 @@ csum_ipv6_magic:
        ret                     # L0 : L U L U
 
        .end csum_ipv6_magic
-       EXPORT_SYMBOL(csum_ipv6_magic)
index d18dc0e96e3d7987f0d2b977406a36ef4889b8d7..2a82b9be93fa290fdb6e859019db24839a55af18 100644 (file)
@@ -55,7 +55,6 @@
  * Try not to change the actual algorithm if possible for consistency.
  */
 
-#include <asm/export.h>
 #define halt .long 0
 
 /*
@@ -206,7 +205,6 @@ ufunction:
        addq    $30,STACK,$30           # E :
        ret     $31,($23),1             # L0 : L U U L
        .end    ufunction
-EXPORT_SYMBOL(ufunction)
 
 /*
  * Uhh.. Ugly signed division. I'd rather not have it at all, but
@@ -259,4 +257,3 @@ sfunction:
        addq    $30,STACK,$30           # E :
        ret     $31,($23),1             # L0 : L U U L
        .end    sfunction
-EXPORT_SYMBOL(sfunction)
index 419adc53ccb4e599217aedd3bdb9a6af43bab400..1a5f71b9d8b10286f324b2e13e9be79ddb1d4abb 100644 (file)
@@ -27,7 +27,7 @@
  *     L       - lower subcluster; L0 - subcluster L0; L1 - subcluster L1
  * Try not to change the actual algorithm if possible for consistency.
  */
-#include <asm/export.h>
+
         .set noreorder
         .set noat
 
@@ -189,4 +189,3 @@ $not_found:
        ret                     # L0 :
 
         .end memchr
-       EXPORT_SYMBOL(memchr)
index b19798b2efc09a30fce801eda1587e817fcb434b..52b37b0f2af5152177cd4a58fa815491070a4afc 100644 (file)
@@ -19,7 +19,7 @@
  * Temp usage notes:
  *     $1,$2,          - scratch
  */
-#include <asm/export.h>
+
        .set noreorder
        .set noat
 
@@ -242,7 +242,6 @@ $nomoredata:
        nop                             # E :
 
        .end memcpy
-       EXPORT_SYMBOL(memcpy)
 
 /* For backwards module compatibility.  */
 __memcpy = memcpy
index fed21c6893e8e7c295fcaeac56d0b70bb6051133..356bb2fdd70567721023b8e0a3fc1d59f2f5d981 100644 (file)
@@ -26,7 +26,7 @@
  * as fixes will need to be made in multiple places.  The performance gain
  * is worth it.
  */
-#include <asm/export.h>
+
        .set noat
        .set noreorder
 .text
@@ -229,7 +229,6 @@ end_b:
        nop
        ret $31,($26),1         # L0 :
        .end ___memset
-       EXPORT_SYMBOL(___memset)
 
        /*
         * This is the original body of code, prior to replication and
@@ -407,7 +406,6 @@ end:
        nop
        ret $31,($26),1         # L0 :
        .end __constant_c_memset
-       EXPORT_SYMBOL(__constant_c_memset)
 
        /*
         * This is a replicant of the __constant_c_memset code, rescheduled
@@ -596,9 +594,6 @@ end_w:
        ret $31,($26),1         # L0 :
 
        .end __memsetw
-       EXPORT_SYMBOL(__memsetw)
 
 memset = ___memset
 __memset = ___memset
-       EXPORT_SYMBOL(memset)
-       EXPORT_SYMBOL(__memset)
index b69f60419be1bc940c81dac67fdd78b1932c8fb9..c426fe3ed72f4e193a6f7d8b7ec78831c64af203 100644 (file)
@@ -19,7 +19,7 @@
  * string once.
  */
 
-#include <asm/export.h>
+
        .text
 
        .align 4
@@ -52,4 +52,3 @@ $found:       cttz    $2, $3          # U0 :
        br      __stxcpy        # L0 :
 
        .end strcat
-       EXPORT_SYMBOL(strcat)
index ea8f2f35db9cef2487524b93038885ed9b71ce94..fbb7b4ffade9e596272c1c4ede40689d7bf73a92 100644 (file)
@@ -15,7 +15,7 @@
  *     L       - lower subcluster; L0 - subcluster L0; L1 - subcluster L1
  * Try not to change the actual algorithm if possible for consistency.
  */
-#include <asm/export.h>
+
 #include <asm/regdef.h>
 
        .set noreorder
@@ -86,4 +86,3 @@ $found:       negq    t0, t1          # E : clear all but least set bit
        ret                     # L0 :
 
        .end strchr
-       EXPORT_SYMBOL(strchr)
index 736fd41884a8c11ba44b5b057f23c46e4908c521..503928072523e745b3b62934e52301b1fee2d327 100644 (file)
@@ -17,7 +17,7 @@
  *     U       - upper subcluster; U0 - subcluster U0; U1 - subcluster U1
  *     L       - lower subcluster; L0 - subcluster L0; L1 - subcluster L1
  */
-#include <asm/export.h>
+
        .set noreorder
        .set noat
 
@@ -47,4 +47,3 @@ $found:
        ret     $31, ($26)      # L0 :
 
        .end    strlen
-       EXPORT_SYMBOL(strlen)
index cd35cbade73ae8f46fcf7efff8763646e92efbf4..4ae716cd2bfbf8e8f6c8b194531efac50f88ec7c 100644 (file)
@@ -20,7 +20,7 @@
  * Try not to change the actual algorithm if possible for consistency.
  */
 
-#include <asm/export.h>
+
        .text
 
        .align 4
@@ -92,4 +92,3 @@ $zerocount:
        ret                     # L0 :
 
        .end strncat
-       EXPORT_SYMBOL(strncat)
index 747455f0328cf35bfaeac86ac56101d70e841016..dd0d8c6b9f59ffdf92d8a0bfe40aa3fdd0bbe29d 100644 (file)
@@ -18,7 +18,7 @@
  *     L       - lower subcluster; L0 - subcluster L0; L1 - subcluster L1
  */
 
-#include <asm/export.h>
+
 #include <asm/regdef.h>
 
        .set noreorder
@@ -107,4 +107,3 @@ $eos:
        nop
 
        .end strrchr
-       EXPORT_SYMBOL(strrchr)
index 4aa6dbfa14eecce36fcafcf800e79c4f0a93ee84..05017ba34c3cc40e22a97b4de62bdc0f363901de 100644 (file)
@@ -4,9 +4,6 @@
  * (C) Copyright 1998 Linus Torvalds
  */
 
-#include <linux/compiler.h>
-#include <linux/export.h>
-
 #if defined(CONFIG_ALPHA_EV6) || defined(CONFIG_ALPHA_EV67)
 #define STT(reg,val)  asm volatile ("ftoit $f"#reg",%0" : "=r"(val));
 #else
@@ -55,7 +52,6 @@ alpha_read_fp_reg (unsigned long reg)
        }
        return val;
 }
-EXPORT_SYMBOL(alpha_read_fp_reg);
 
 #if defined(CONFIG_ALPHA_EV6) || defined(CONFIG_ALPHA_EV67)
 #define LDT(reg,val)  asm volatile ("itoft %0,$f"#reg : : "r"(val));
@@ -101,7 +97,6 @@ alpha_write_fp_reg (unsigned long reg, unsigned long val)
              case 31: LDT(31, val); break;
        }
 }
-EXPORT_SYMBOL(alpha_write_fp_reg);
 
 #if defined(CONFIG_ALPHA_EV6) || defined(CONFIG_ALPHA_EV67)
 #define STS(reg,val)  asm volatile ("ftois $f"#reg",%0" : "=r"(val));
@@ -151,7 +146,6 @@ alpha_read_fp_reg_s (unsigned long reg)
        }
        return val;
 }
-EXPORT_SYMBOL(alpha_read_fp_reg_s);
 
 #if defined(CONFIG_ALPHA_EV6) || defined(CONFIG_ALPHA_EV67)
 #define LDS(reg,val)  asm volatile ("itofs %0,$f"#reg : : "r"(val));
@@ -197,4 +191,3 @@ alpha_write_fp_reg_s (unsigned long reg, unsigned long val)
              case 31: LDS(31, val); break;
        }
 }
-EXPORT_SYMBOL(alpha_write_fp_reg_s);
index c13d3eca2e0592736dd17112ff836dcac5c0b7cb..14427eeb555e6d8f80bc863e6e5f50c6c7024a87 100644 (file)
@@ -31,7 +31,7 @@ For correctness consider that:
       - only minimum number of quadwords may be accessed
       - the third argument is an unsigned long
 */
-#include <asm/export.h>
+
         .set noreorder
         .set noat
 
@@ -162,4 +162,3 @@ $not_found:
        ret                     # .. e1 :
 
         .end memchr
-       EXPORT_SYMBOL(memchr)
index 57d9291ad172c6a2660104a6af6d4392efac1efb..64083fc732389419aa55e499532a278af4f8adab 100644 (file)
@@ -16,7 +16,6 @@
  */
 
 #include <linux/types.h>
-#include <linux/export.h>
 
 /*
  * This should be done in one go with ldq_u*2/mask/stq_u. Do it
@@ -159,4 +158,6 @@ void * memcpy(void * dest, const void *src, size_t n)
        __memcpy_unaligned_up ((unsigned long) dest, (unsigned long) src, n);
        return dest;
 }
-EXPORT_SYMBOL(memcpy);
+
+/* For backward modules compatibility, define __memcpy.  */
+asm("__memcpy = memcpy; .globl __memcpy");
index 6872c85cb5e54d35125ebb8bc61b47fa26f33785..eb3b6e02242f4b91cffe943b105a04f22f1df249 100644 (file)
@@ -6,7 +6,7 @@
  * This is hand-massaged output from the original memcpy.c.  We defer to
  * memcpy whenever possible; the backwards copy loops are not unrolled.
  */
-#include <asm/export.h>        
+        
        .set noat
        .set noreorder
        .text
@@ -179,4 +179,3 @@ $egress:
        nop
 
        .end memmove
-       EXPORT_SYMBOL(memmove)
index 89a26f5e89de3db904cbfabb1ff735464d6ca3cb..76ccc6d1f364d67ca8c03c859171f113da5e23ce 100644 (file)
@@ -13,7 +13,7 @@
  * The scheduling comments are according to the EV5 documentation (and done by 
  * hand, so they might well be incorrect, please do tell me about it..)
  */
-#include <asm/export.h>
+
        .set noat
        .set noreorder
 .text
@@ -106,8 +106,6 @@ within_one_quad:
 end:
        ret $31,($26),1         /* E1 */
        .end ___memset
-EXPORT_SYMBOL(___memset)
-EXPORT_SYMBOL(__constant_c_memset)
 
        .align 5
        .ent __memsetw
@@ -124,9 +122,6 @@ __memsetw:
        br __constant_c_memset  /* .. E1 */
 
        .end __memsetw
-EXPORT_SYMBOL(__memsetw)
 
 memset = ___memset
 __memset = ___memset
-       EXPORT_SYMBOL(memset)
-       EXPORT_SYMBOL(__memset)
index 249837b03d4b9958d9131ca1cd2a9ab8c02f75a7..393f50384878fd0ed7dc1ef786bb5c1bed612678 100644 (file)
@@ -4,7 +4,6 @@
  *
  * Append a null-terminated string from SRC to DST.
  */
-#include <asm/export.h>
 
        .text
 
@@ -51,4 +50,3 @@ $found:       negq    $2, $3          # clear all but least set bit
        br      __stxcpy
 
        .end strcat
-EXPORT_SYMBOL(strcat);
index 7412a173ea393617f1b65022b06bc8cbfe5b627e..011a175e8329234567c0665ec90de60ed35db88c 100644 (file)
@@ -5,7 +5,7 @@
  * Return the address of a given character within a null-terminated
  * string, or null if it is not found.
  */
-#include <asm/export.h>
+
 #include <asm/regdef.h>
 
        .set noreorder
@@ -68,4 +68,3 @@ $retnull:
        ret                     # .. e1 :
 
        .end strchr
-       EXPORT_SYMBOL(strchr)
index 98deae1e4d085d5dfb54210aeeb854b6328af6a5..e0728e4ad21fda604b166c9435637bd9c5af11fe 100644 (file)
@@ -5,7 +5,7 @@
  * Copy a null-terminated string from SRC to DST.  Return a pointer
  * to the null-terminator in the source.
  */
-#include <asm/export.h>
+
        .text
 
        .align 3
@@ -21,4 +21,3 @@ strcpy:
        br      __stxcpy        # do the copy
 
        .end strcpy
-       EXPORT_SYMBOL(strcpy)
index 79c416f71bacd5704a8d9f6a2841b9cb9566606b..fe63353de152d3bf1d5a24b18b704bde21c161f2 100644 (file)
@@ -11,7 +11,7 @@
  *       do this instead of the 9 instructions that
  *       binary search needs).
  */
-#include <asm/export.h>
+
        .set noreorder
        .set noat
 
@@ -55,4 +55,3 @@ done: subq    $0, $16, $0
        ret     $31, ($26)
 
        .end    strlen
-       EXPORT_SYMBOL(strlen)
index 6c29ea60869ae4c3a3d3c4bff10839b1a764e67d..a8278163c97204d3d5d2e0eb73c956c327bdfbd6 100644 (file)
@@ -9,7 +9,7 @@
  * past count, whereas libc may write to count+1.  This follows the generic
  * implementation in lib/string.c and is, IMHO, more sensible.
  */
-#include <asm/export.h>
+
        .text
 
        .align 3
@@ -82,4 +82,3 @@ $zerocount:
        ret
 
        .end strncat
-       EXPORT_SYMBOL(strncat)
index e102cf1567ddd21314efd9d1fd1f8725cb538410..a46f7f3ad8c731961dd3f24502955ab5953477ca 100644 (file)
@@ -10,7 +10,7 @@
  * version has cropped that bit o' nastiness as well as assuming that
  * __stxncpy is in range of a branch.
  */
-#include <asm/export.h>
+
        .set noat
        .set noreorder
 
@@ -79,4 +79,3 @@ $zerolen:
        ret
 
        .end    strncpy
-       EXPORT_SYMBOL(strncpy)
index 4bc6cb4b9812e1e42a2ac2db7df182cd9810dafb..1970dc07cfd1248147bc17da538196fcb9cd9e84 100644 (file)
@@ -5,7 +5,7 @@
  * Return the address of the last occurrence of a given character
  * within a null-terminated string, or null if it is not found.
  */
-#include <asm/export.h>
+
 #include <asm/regdef.h>
 
        .set noreorder
@@ -85,4 +85,3 @@ $retnull:
        ret                     # .. e1 :
 
        .end strrchr
-       EXPORT_SYMBOL(strrchr)