mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Stewart Smith <stewartsmith@mac.com>
To: Linus Torvalds <torvalds@transmeta.com>
Cc: linux-kernel@vger.kernel.org,
	David Woodhouse <dwmw2@infradead.org>,
	Stewart Smith <stewart@linux.org.au>
Subject: [PATCH] fixed: CRC32=y && 8193TOO=m unresolved symbols
Date: Wed, 4 Jun 2003 15:56:09 +1000	[thread overview]
Message-ID: <3D3CD66D-9651-11D7-A060-00039346F142@mac.com> (raw)
In-Reply-To: <1054646171.17921.64.camel@passion.cambridge.redhat.com>

Linus,
please apply - this fixes unresolved symbols when CONFIG_CRC32=y and 
CONFIG_8139TOO=m (it also appeared on some other ethernet device 
drivers). I think this is the right way to fix this problem. It at 
least now builds, links and boots (and hey, even my ethernet works so 
it can't all be bad :)

patches cleanly against 2.5.70 and 2.5.70-bk8

--- linux-2.5.70-orig/include/linux/crc32.h	2003-05-05 
09:53:08.000000000 +1000
+++ linux-2.5.70-stew3/include/linux/crc32.h	2003-06-04 
15:27:34.000000000 +1000
@@ -6,6 +6,7 @@
  #define _LINUX_CRC32_H

  #include <linux/types.h>
+#include <linux/module.h>

  extern u32  crc32_le(u32 crc, unsigned char const *p, size_t len);
  extern u32  crc32_be(u32 crc, unsigned char const *p, size_t len);
@@ -21,7 +22,16 @@
   * is in bit nr 0], thus it must be reversed before use. Except for
   * nics that bit swap the result internally...
   */
-#define ether_crc(length, data)    bitreverse(crc32_le(~0, data, 
length))
-#define ether_crc_le(length, data) crc32_le(~0, data, length)
+static inline u32 ether_crc(size_t length, unsigned char const *data)
+{
+  return bitreverse(crc32_le(~0, data, length));
+}
+EXPORT_SYMBOL(ether_crc);
+
+static inline u32 ether_crc_le(size_t length, unsigned char const 
*data)
+{
+  return crc32_le(~0, data, length);
+}
+EXPORT_SYMBOL(ether_crc_le);

  #endif /* _LINUX_CRC32_H */
--- linux-2.5.70-orig/kernel/ksyms.c	2003-06-02 23:28:32.000000000 +1000
+++ linux-2.5.70-stew3/kernel/ksyms.c	2003-06-04 15:11:37.000000000 
+1000
@@ -58,6 +58,7 @@
  #include <linux/time.h>
  #include <linux/backing-dev.h>
  #include <linux/percpu_counter.h>
+#include <linux/crc32.h>
  #include <asm/checksum.h>

  #if defined(CONFIG_PROC_FS)


------------
Stewart Smith
Vice President, Linux Australia
stewart@linux.org.au
http://www.linux.org.au


  reply	other threads:[~2003-06-04  5:43 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-06-03  1:13 Stewart Smith
2003-06-03 13:16 ` David Woodhouse
2003-06-04  5:56   ` Stewart Smith [this message]
2003-06-04 15:28     ` [PATCH] fixed: " Jeff Garzik
2003-06-04 15:30       ` David Woodhouse
2003-06-04 15:32         ` Jeff Garzik
2003-06-04 15:41           ` Linus Torvalds
2003-06-07  7:33             ` [EVIL-PATCH] getting rid of lib/lib.a and breaking many archs in the processes (was Re: [PATCH] fixed: CRC32=y && 8193TOO=m unresolved symbols) Stewart Smith
2003-06-07  7:39               ` Christoph Hellwig
2003-06-07 17:34               ` Linus Torvalds
2003-06-07 19:02                 ` Sam Ravnborg

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=3D3CD66D-9651-11D7-A060-00039346F142@mac.com \
    --to=stewartsmith@mac.com \
    --cc=dwmw2@infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=stewart@linux.org.au \
    --cc=torvalds@transmeta.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®