linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [2.5] Update sk98lin driver
@ 2003-05-04 18:44 Martin Schlemmer
  2003-05-04 18:54 ` Christoph Hellwig
                   ` (2 more replies)
  0 siblings, 3 replies; 6+ messages in thread
From: Martin Schlemmer @ 2003-05-04 18:44 UTC (permalink / raw)
  To: KML

[-- Attachment #1: Type: text/plain, Size: 867 bytes --]

Hi

I have a 3Com 3c940 gigabit LOM, that is basically a
SysKonnect chipset card.  Here are later drivers that
do support it:

  ftp://ftp.asus.com.tw/pub/ASUS/lan/3com/3c940/041_Linux.zip

The current one in the 2.5 tree was last updated for newer
chipsets in 2001, while the new was updated February this
year.

Anyhow, I got the new to compile, and fixed the few irqreturn_t
calls, and some other 2.5 changes I knew about.

Now the problem is that if I try to load it, I get this:

-----------------------------------------
sk98lin: Unknown symbol __udivdi3
-----------------------------------------

Meaning it linked with libgcc_s.so.  Any ideas why ?

If you need the diff from above source, let me know.  Else
if somebody more experienced is interested in porting it,
I will gladly test.


Thanks,

-- 

Martin Schlemmer




[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 189 bytes --]

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [2.5] Update sk98lin driver
  2003-05-04 18:44 [2.5] Update sk98lin driver Martin Schlemmer
@ 2003-05-04 18:54 ` Christoph Hellwig
  2003-05-04 18:57 ` Matti Aarnio
  2003-05-04 21:50 ` Andrew Morton
  2 siblings, 0 replies; 6+ messages in thread
From: Christoph Hellwig @ 2003-05-04 18:54 UTC (permalink / raw)
  To: Martin Schlemmer; +Cc: KML

On Sun, May 04, 2003 at 08:44:07PM +0200, Martin Schlemmer wrote:
> Anyhow, I got the new to compile, and fixed the few irqreturn_t
> calls, and some other 2.5 changes I knew about.
> 
> Now the problem is that if I try to load it, I get this:
> 
> -----------------------------------------
> sk98lin: Unknown symbol __udivdi3
> -----------------------------------------
> 
> Meaning it linked with libgcc_s.so.  Any ideas why ?

Get rid of division on 64bit types in the driver.


^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [2.5] Update sk98lin driver
  2003-05-04 18:44 [2.5] Update sk98lin driver Martin Schlemmer
  2003-05-04 18:54 ` Christoph Hellwig
@ 2003-05-04 18:57 ` Matti Aarnio
  2003-05-04 19:35   ` Martin Schlemmer
  2003-05-04 21:50 ` Andrew Morton
  2 siblings, 1 reply; 6+ messages in thread
From: Matti Aarnio @ 2003-05-04 18:57 UTC (permalink / raw)
  To: Martin Schlemmer; +Cc: KML

On Sun, May 04, 2003 at 08:44:07PM +0200, Martin Schlemmer wrote:
> Hi
> 
> I have a 3Com 3c940 gigabit LOM, that is basically a
> SysKonnect chipset card.  Here are later drivers that
> do support it:
>   ftp://ftp.asus.com.tw/pub/ASUS/lan/3com/3c940/041_Linux.zip
...> 
> Now the problem is that if I try to load it, I get this:
> -----------------------------------------
> sk98lin: Unknown symbol __udivdi3
> -----------------------------------------
> Meaning it linked with libgcc_s.so.  Any ideas why ?

  It wanted to.    That is signature of  64 bit value
  being divided by an abitrary non-power-of-two divider.

  If there is a non-fast-path use for the division,
  using   do_div()  macro.   Originally for   lib/vsprintf.c
  from which you can deduce the usage.

  If it is in fast-path,   then the code needs serious
  re-thought.

> If you need the diff from above source, let me know.  Else
> if somebody more experienced is interested in porting it,
> I will gladly test.
> Thanks,
> -- 
> Martin Schlemmer

/Matti Aarnio

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [2.5] Update sk98lin driver
  2003-05-04 18:57 ` Matti Aarnio
@ 2003-05-04 19:35   ` Martin Schlemmer
  0 siblings, 0 replies; 6+ messages in thread
From: Martin Schlemmer @ 2003-05-04 19:35 UTC (permalink / raw)
  To: Matti Aarnio; +Cc: KML

[-- Attachment #1: Type: text/plain, Size: 851 bytes --]

On Sun, 2003-05-04 at 20:57, Matti Aarnio wrote:

> > Now the problem is that if I try to load it, I get this:
> > -----------------------------------------
> > sk98lin: Unknown symbol __udivdi3
> > -----------------------------------------
> > Meaning it linked with libgcc_s.so.  Any ideas why ?
> 
>   It wanted to.    That is signature of  64 bit value
>   being divided by an abitrary non-power-of-two divider.
> 
>   If there is a non-fast-path use for the division,
>   using   do_div()  macro.   Originally for   lib/vsprintf.c
>   from which you can deduce the usage.
> 
>   If it is in fast-path,   then the code needs serious
>   re-thought.
> 

Bleh, never easy hey =)

And I am guessing just adding a __udivdi3 implementation like
some of the other archs is out of the question ?


-- 

Martin Schlemmer




[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 189 bytes --]

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [2.5] Update sk98lin driver
  2003-05-04 18:44 [2.5] Update sk98lin driver Martin Schlemmer
  2003-05-04 18:54 ` Christoph Hellwig
  2003-05-04 18:57 ` Matti Aarnio
@ 2003-05-04 21:50 ` Andrew Morton
  2003-05-04 23:29   ` Martin Schlemmer
  2 siblings, 1 reply; 6+ messages in thread
From: Andrew Morton @ 2003-05-04 21:50 UTC (permalink / raw)
  To: azarah; +Cc: linux-kernel

Martin Schlemmer <azarah@gentoo.org> wrote:
>
> Hi
> 
> I have a 3Com 3c940 gigabit LOM, that is basically a
> SysKonnect chipset card.  Here are later drivers that
> do support it:
> 
>   ftp://ftp.asus.com.tw/pub/ASUS/lan/3com/3c940/041_Linux.zip
> 
> The current one in the 2.5 tree was last updated for newer
> chipsets in 2001, while the new was updated February this
> year.
> 
> Anyhow, I got the new to compile, and fixed the few irqreturn_t
> calls, and some other 2.5 changes I knew about.
> 
> Now the problem is that if I try to load it, I get this:
> 
> -----------------------------------------
> sk98lin: Unknown symbol __udivdi3
> -----------------------------------------
> 
> Meaning it linked with libgcc_s.so.  Any ideas why ?
> 

This was the fix for the in-kernel driver, so it'll presumably
fix the updated driver.


diff -puN drivers/net/sk98lin/h/skgepnm2.h~sk98-build-fix drivers/net/sk98lin/h/skgepnm2.h
--- 25/drivers/net/sk98lin/h/skgepnm2.h~sk98-build-fix	Thu Mar  6 16:18:07 2003
+++ 25-akpm/drivers/net/sk98lin/h/skgepnm2.h	Thu Mar  6 16:18:07 2003
@@ -341,7 +341,7 @@ typedef struct s_PnmiStatAddr {
 #if SK_TICKS_PER_SEC == 100
 #define SK_PNMI_HUNDREDS_SEC(t)	(t)
 #else
-#define SK_PNMI_HUNDREDS_SEC(t)	(((t) * 100) / (SK_TICKS_PER_SEC))
+#define SK_PNMI_HUNDREDS_SEC(t)	((((long)t) * 100) / (SK_TICKS_PER_SEC))
 #endif
 
 /*

_


^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [2.5] Update sk98lin driver
  2003-05-04 21:50 ` Andrew Morton
@ 2003-05-04 23:29   ` Martin Schlemmer
  0 siblings, 0 replies; 6+ messages in thread
From: Martin Schlemmer @ 2003-05-04 23:29 UTC (permalink / raw)
  To: Andrew Morton; +Cc: KML

[-- Attachment #1: Type: text/plain, Size: 1050 bytes --]

On Sun, 2003-05-04 at 23:50, Andrew Morton wrote:

> > Now the problem is that if I try to load it, I get this:
> > 
> > -----------------------------------------
> > sk98lin: Unknown symbol __udivdi3
> > -----------------------------------------
> > 
> > Meaning it linked with libgcc_s.so.  Any ideas why ?
> > 
> 
> This was the fix for the in-kernel driver, so it'll presumably
> fix the updated driver.
> 
> 
> diff -puN drivers/net/sk98lin/h/skgepnm2.h~sk98-build-fix drivers/net/sk98lin/h/skgepnm2.h
> --- 25/drivers/net/sk98lin/h/skgepnm2.h~sk98-build-fix	Thu Mar  6 16:18:07 2003
> +++ 25-akpm/drivers/net/sk98lin/h/skgepnm2.h	Thu Mar  6 16:18:07 2003
> @@ -341,7 +341,7 @@ typedef struct s_PnmiStatAddr {
>  #if SK_TICKS_PER_SEC == 100
>  #define SK_PNMI_HUNDREDS_SEC(t)	(t)
>  #else
> -#define SK_PNMI_HUNDREDS_SEC(t)	(((t) * 100) / (SK_TICKS_PER_SEC))
> +#define SK_PNMI_HUNDREDS_SEC(t)	((((long)t) * 100) / (SK_TICKS_PER_SEC))
>  #endif
>  
>  /*

Thanks, that fixed it =)


-- 

Martin Schlemmer




[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 189 bytes --]

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2003-05-04 23:18 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-05-04 18:44 [2.5] Update sk98lin driver Martin Schlemmer
2003-05-04 18:54 ` Christoph Hellwig
2003-05-04 18:57 ` Matti Aarnio
2003-05-04 19:35   ` Martin Schlemmer
2003-05-04 21:50 ` Andrew Morton
2003-05-04 23:29   ` Martin Schlemmer

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).