Subscribe to our RSS news feed
AAPL 199.94 (-1.25)

PCGenRTL8139Ethernet v1.1.0 (8.4.1) & v1.2.0 (8.8.1) released, Adds support for on-board RTL 8139/810x Family
****
  • Group: Members
  • Posts: 179
  • Joined: 2-September 06
  • Member No.: 54,047
/****************************** INFO BAR ************************************

Edit: Last Modified: 31/12/07, Leo Link Added.

FOR LEOPARD:
---------------------------------
Thanks to John Stormdrake, a driver for Leopard is now available here.

Files
----------------------------------
1. Darwin 8.8.1 - PCGenRTL8139Ethernet-1.2.0.zip
MD5 (PCGenRTL8139Ethernet-1.2.0.zip) = c2e4ac081c855e95ee4a3af52c2df63c
2. Darwin 8.4.1 - PCGenRTL8139Ethernet-1.1.0.zip
MD5 (PCGenRTL8139Ethernet-1.1.0.zip) = a7cec7c9ec113c41126de8ba877715b8


Compatibility Guidelines
----------------------------------
(10.4.9) = Reported to work with Tubgirl's AMD release - pls. see this thread.

For Kernel 8.8.1

(10.4.8) + IONetworkingFamily (1.5.1)

For Kernel 8.4.1

(10.4.6) + IONetworkingFamily (1.5.0)
(10.4.7) + IONetworkingFamily (1.5.0)
(10.4.8) + IONetworkingFamily (1.5.0)

Other configurations may work, but these are the ones I have tested.

******************************************************************************/

DISCUSSION THREAD STARTS BELOW:

Hi all,

I am pleased to announce the release of PCGenRTLEthernet8139.kext - another addition to the 'Generic PC drivers' project for Darwin.

This driver is based on the AppleRTL8139Ethernet-3 and AppleRTL8139Ethernet-4 sources and extends functionality to include ON-BOARD RTL 8139/810x Fast Ethernet Family devices, which were previously unworkable. The driver will continue to work for add-on devices. It should be backwards compatible with the Apple versions.

CHANGES
---------------------------------------------------------

10/01/07
* Changes on x86 based systems:
(+) Added MMIO access mode (adds support for on-board RTL8139/810x family devices)
(+) To override PIO mode, added ForceMMIOAccess (true/false) key to Info.plist, default false.
(+) Added hard chip reset if soft reset fails logic.


CREDITS
---------------------------------------------------------

- Thanks to Owen Wei for the original Apple Realtek code. This was invaluable.
- Thanks to cremes' OSX tulip driver.
- Thanks to Linux. In my case. Gentoo 2.6.17.



discussion

Problem: On-board RTL8139/810x devices are not detected by the AppleRTL8139Ethernet driver.

Cause: The Apple driver only used PIO access to speak to the RTL chip. But PIO access fails to initialize for on-board devices.

Solution: Using MMIO acces mode works for on-board devices.

Implementation Options Considered:

0. Make 2 versions of the kext using a compiler directive selecting PIO/MMIO at compile time (e.g. Linux).
Advantages: Simple to do.
Disadvantages: Two kext versions, user specifies which one.

1. Make 1 version of the kext using MMIO only.
Advantages: Simple to do, tested and works.
Disadvantages: Breaks compatibility with existing code base.

2. Make 1 version of the kext with run-time PIO/MMIO allocation.
Advantages: Single kext, retains backwards compatibility.
Disadvantages: Need to create fast coding model.


We could have done something like:
CODE
inline UInt32 csrRead32( UInt16 offset )
    {
      if (ioAccessMode == kIOAccessModeIsPIO) return pciNub->ioRead32(offset, csrMap);
      else return OSReadLittleInt32( ( void * ) csrBase, offset );
     }


But this is not true run-time allocation. Instead, this is a good case for using the features of C++ - in particular, the ability the cast a derived class to a base class. For interested parties, the details are in the code, but the final implementation is class based:
CODE
class ioAccessor : public OSObject
{

    OSDeclareAbstractStructors ( ioAccessor )
    
    public:
    
    virtual void                csrWrite32 ( UInt16 offset, UInt32 value ) = 0;
       virtual void                csrWrite16 ( UInt16 offset, UInt16 value ) = 0;
       virtual void                csrWrite8 (  UInt16 offset, UInt8 value ) = 0;
    virtual void                csrWrite32Slow ( UInt16 offset, UInt32 value ) = 0;
       virtual void                csrWrite16Slow ( UInt16 offset, UInt16 value ) = 0;
       virtual void                csrWrite8Slow (  UInt16 offset, UInt8 value ) = 0;
       virtual UInt32                csrRead32 ( UInt16 offset ) = 0;
       virtual UInt16                csrRead16 ( UInt16 offset ) = 0;
       virtual UInt8                csrRead8 (  UInt16 offset ) = 0;
    
    protected:
    virtual bool                init ( );

};

as the abstract base class, then

  class ioAccessorPIO : public ioAccessor
{

...
    
};

  class ioAccessorMMIO : public ioAccessor
{

...

  };

which implement the appropriate access methods and variables.


Best
PM Profile Card
Go to the top of the page
+ Quote Post

Posts in this topic
- orByte   PCGenRTL8139Ethernet v1.1.0 (8.4.1) & v1.2.0 (8.8.1) released   Jan 10 2007, 12:32 PM
- - onelove   Thanks orByte for this new release driver it actua...   Jan 10 2007, 04:26 PM
- - donh   Thanks works on my compaq V5000 laptop. wireless a...   Jan 11 2007, 01:11 AM
- - orByte   Cheers guys!   Jan 11 2007, 07:35 AM
- - Boooooommm   I do get that posted, but for some reason it hangs...   Jan 16 2007, 09:25 AM
|- - donh   QUOTE (Boooooommm @ Jan 16 2007, 02:25 AM...   Jan 16 2007, 04:44 PM
- - envisioneer   Thanks, very much appreciated dmesg: com_orByt...   Jan 16 2007, 08:28 PM
|- - dab   QUOTE (envisioneer @ Jan 16 2007, 08:28 P...   Oct 2 2007, 03:28 PM
- - errandwolfe   For the people who are hanging where the login scr...   Jan 16 2007, 09:03 PM
- - Boooooommm   Nope. I'm making sure they're erased. I ev...   Jan 17 2007, 02:16 PM
|- - orByte   QUOTE (Boooooommm @ Jan 17 2007, 02:16 PM...   Jan 18 2007, 01:38 PM
- - jester1o1   Thanks for these drivers - I am using your AppleRT...   Jan 24 2007, 12:53 AM
- - pablovbas   Thanks Brother!!! pabs   Jan 26 2007, 12:29 AM
- - Tibian Ass Monkey   Hi I have an Asus Salmon K8S-LA board (pain in the...   Feb 4 2007, 02:08 AM
|- - orByte   QUOTE (Tibian Ass Monkey @ Feb 4 2007, 02...   Feb 5 2007, 01:52 PM
- - gio on the mic   You guy really rock! This is totally AWESOME...   Feb 6 2007, 11:25 AM
|- - orByte   QUOTE (gio on the mic @ Feb 6 2007, 11:25...   Feb 7 2007, 02:03 PM
- - squimmy   I have the same problems as Boooooommm. My system ...   Feb 18 2007, 06:55 PM
|- - orByte   QUOTE (squimmy @ Feb 18 2007, 06:55 PM) I...   Feb 19 2007, 05:17 PM
- - kfriis   Hi I hope you can help me as well - I'm kinda...   Feb 24 2007, 04:34 AM
|- - orByte   QUOTE (kfriis @ Feb 24 2007, 04:34 AM) Hi...   Feb 26 2007, 12:09 PM
- - envying   I have a Dlink DFE 538TX Card, it is said with a R...   Feb 26 2007, 03:47 PM
|- - orByte   QUOTE (envying @ Feb 26 2007, 03:47 PM) I...   Feb 27 2007, 02:22 PM
|- - envying   QUOTE (orByte @ Feb 27 2007, 07:22 AM) Se...   Feb 27 2007, 03:05 PM
- - jester1o1   check your dmesg (type sudo dmesg in terminal). l...   Feb 28 2007, 01:29 AM
|- - envying   QUOTE (jester1o1 @ Feb 27 2007, 06:29 PM)...   Feb 28 2007, 04:06 PM
|- - orByte   QUOTE (envying @ Feb 28 2007, 04:06 PM) T...   Mar 1 2007, 10:23 AM
- - envying   Thanks orByte, I will give it a try tonight again....   Mar 1 2007, 02:40 PM
- - envying   QUOTE ethernet: family specific matching fails ...   Mar 2 2007, 03:27 AM
|- - orByte   QUOTE (envying @ Mar 2 2007, 03:27 AM) Fi...   Mar 3 2007, 04:15 PM
|- - envying   QUOTE (orByte @ Mar 3 2007, 09:15 AM) It ...   Mar 3 2007, 07:18 PM
- - envying   Waiting for an answer!   Mar 3 2007, 12:55 AM
- - ACFan   Going to try this one now -- system detects the NI...   Mar 3 2007, 07:10 PM
- - envying   Thank god! I finally got my internet working ...   Mar 4 2007, 03:24 AM
|- - envying   QUOTE (envying @ Mar 3 2007, 08:24 PM) Th...   Mar 4 2007, 09:49 PM
- - pabloide86   hello i'm pablo from argentina(sorry, my engli...   Mar 20 2007, 08:16 PM
|- - orByte   QUOTE (pabloide86 @ Mar 20 2007, 08:16 PM...   Mar 24 2007, 10:00 AM
|- - pabloide86   QUOTE (orByte @ Mar 24 2007, 07:00 AM) Wh...   Mar 25 2007, 04:08 AM
- - Thang Bo   (use PCGenRTL8139Ethernet-1.2.0) I have the proble...   Mar 30 2007, 05:53 AM
- - Thang Bo   My god, I have solved the problem . The problem i...   Mar 30 2007, 10:35 AM
- - anurup   Hi, Have been following this thread closely for s...   Apr 9 2007, 05:11 PM
|- - anurup   Help!   Apr 11 2007, 06:41 PM
- - Lakriz   Wow! This is amazing! It worked out so eas...   Apr 18 2007, 01:20 AM
|- - anurup   Hey orByte, It works. I was doing something inane...   Apr 18 2007, 10:12 PM
|- - orByte   QUOTE (anurup @ Apr 18 2007, 11:12 PM) He...   Apr 19 2007, 01:03 PM
- - sam9879   Typing sudo dmseg in the Terminal gives me followi...   Apr 19 2007, 05:26 AM
- - sam9879   i have only one PCGenRTL8139Ethernet.kext in the /...   Apr 19 2007, 04:25 PM
- - sam9879   Waiting...   Apr 20 2007, 05:43 PM
- - orByte   orByte releases RTL8139 modified source code ...   Apr 22 2007, 05:04 PM
- - sam9879   No, it doesn't. after restart System Preferenc...   Apr 23 2007, 04:21 AM
|- - orByte   QUOTE (sam9879 @ Apr 23 2007, 05:21 AM) N...   Apr 24 2007, 12:59 PM
- - sam9879   1) If PCGenRTL8139Ethernet.kext is at the both loc...   Apr 24 2007, 07:15 PM
|- - orByte   QUOTE (sam9879 @ Apr 24 2007, 08:15 PM) 1...   Apr 25 2007, 01:29 PM
- - sam9879   Solved...! I just tried anathor LAN card fro...   May 19 2007, 01:32 PM
- - zenchess   Thankyou. Thankyou. Thankyou. I installed mac ...   May 22 2007, 07:12 AM
- - kronwied   Okay... When I type in "dmesg" I get: d...   May 29 2007, 06:19 PM
- - Pijo   Can smb upload PCGenRTL8139Ethernet-1.2.0.zip file...   Jun 3 2007, 07:39 PM
- - edstace   Works like a charm with uphuck's 10.4.9. v1.2 ...   Jun 4 2007, 02:56 AM
- - Pijo   Problemo. The network card is present , but I can...   Jun 4 2007, 05:09 PM
- - Fretless   Thanks, this worked like a charm on my HP a1130n w...   Jun 20 2007, 08:49 PM
- - zozett   Hi guys! I have a Fujitsu-Siemens Amilo Pa151...   Aug 1 2007, 06:05 PM
- - z3r01   sweeeeeeeeeeeeeeeeeeeeeeeeet!!!!...   Aug 7 2007, 04:07 PM
- - Lumrian   QUOTE (Pijo @ Jun 4 2007, 07:09 PM) Probl...   Aug 16 2007, 09:30 PM
- - jchaapel   I had the DHCP issue getting an address. Deleted ...   Sep 1 2007, 02:52 PM
- - hoarkis   I patch it on my laptop Compaq Presario C500 (xXx ...   Oct 4 2007, 04:26 AM
- - Yaniv Ragasaydiv   Hi, Thanks it works on my mobo. however just a sm...   Oct 9 2007, 08:57 AM
|- - donh   Thanks Worked perfectly on my compaq v500 laptop...   Oct 13 2007, 07:27 PM
- - h von h   hi, If I'm right, I can get my onboard RTL813...   Oct 29 2007, 12:26 PM
- - monsoft   In installation information file there is a path t...   Oct 31 2007, 05:17 AM
- - DriveTheOne   Hi, i've a PC on VMware... i've tried to r...   Nov 6 2007, 12:01 AM
|- - tokyovigilante   Thanks, this works well on Leopard.   Nov 9 2007, 09:15 AM
- - markpenn   Hi Envying, I have a dfe-538tx card..ver:f2. (whi...   Nov 14 2007, 04:22 AM
|- - envying   QUOTE (markpenn @ Nov 13 2007, 10:19 PM) ...   Dec 30 2007, 02:42 AM
- - bubugugu   My onboard 8139 is very slow with the leopard stoc...   Nov 18 2007, 07:46 PM
- - jimmyfoz   Hi, I have tried the driverr but i fails... any id...   Dec 30 2007, 01:52 AM
|- - orByte   QUOTE (jimmyfoz @ Dec 30 2007, 02:49 AM) ...   Dec 31 2007, 11:46 AM
- - harry.haller   I use leopard baut the driver by john don't wo...   Jan 1 2008, 04:49 PM
- - harry.haller   it's no rtl card:( netgeasr say it'S ...   Jan 1 2008, 06:13 PM
- - openxs   I have an external (PCI) DLink DFE 520TX (RTL 8139...   Jan 1 2008, 06:24 PM
- - openxs   Okay, I just bought a PCI LAN with Realtek 8139D c...   Jan 2 2008, 06:56 AM
- - richardyates   Well I'd would really appreciate some help.I...   Jan 2 2008, 09:38 PM
- - John stormdrake   richardyates i think the problem is because you ca...   Jan 5 2008, 10:23 PM
- - sue0110   Hi all, I have a Realtek 8139d based card install...   Jan 7 2008, 04:31 AM
- - geez   Hey all. Just wondering if I could take this oppor...   Jan 11 2008, 02:10 PM
|- - orByte   QUOTE (geez @ Jan 11 2008, 02:10 PM) Hey ...   Jan 12 2008, 06:16 PM
- - geez   I think I've tried adding the device ID number...   Jan 13 2008, 12:56 AM
- - bugsyman   On my computer with Kalyway 10.5.1, RTL8139C is wo...   Jan 15 2008, 10:41 AM
- - sue0110   I have been trying to fix my rtl8139d card for mor...   Jan 16 2008, 07:20 AM
- - xblahallo   RTL-8139/8139C/8139C+ (rev 10), Posted Today, 01:1...   Feb 8 2008, 02:17 PM
- - Mysticus   Hi orByte, Your driver works on Leopard releases,...   Feb 22 2008, 04:59 PM
|- - orByte   QUOTE (Mysticus @ Feb 22 2008...   Feb 24 2008, 05:03 PM
- - DvP   I've got a 8139D and a 8139C card. The C card ...   Mar 12 2008, 04:00 PM
- - anurup   Hi John/orByte, Running Xephyroth Leopard 10.5.2 ...   Mar 30 2008, 08:26 AM
- - TNW   Hello , I added my IOPCIMatch for the SiS900 (0x0...   Apr 2 2008, 11:12 PM
|- - orByte   QUOTE (TNW @ Apr 2 2008, 11:12 PM) Hello ...   Apr 4 2008, 06:54 PM
- - locomacg6   Does anybody knows if it works with the Dlink DFE ...   Apr 18 2008, 07:48 PM
- - godzilla00   I have tried this on my CompaQ Presaro R3000 (R323...   Apr 26 2008, 08:40 AM
- - Bomans   Kalyway 10.5.2 runs without problems on my packard...   Apr 29 2008, 10:53 PM
- - Bomans   If someone wants more info. It's this computer...   Apr 30 2008, 10:55 AM
- - NSCXP2005   does anybody know how to get the Realtek 8139 on -...   Jun 5 2008, 06:22 AM
2 Pages V   1 2 >

Reply to this topic Start new topic

1 User(s) are reading this topic (1 Guests and 0 Anonymous Users)
0 Members:

 

RSS Lo-Fi Version Time is now: 21st November 2009 - 12:22 PM