Hi

Just some very basic comments to actually get it compiling, adding Francois 
Romieu to CC because he has been involved with this driver in the past.

On Dienstag, 11. September 2007, Jesse Huang wrote:
> From: Jesse Huang <[EMAIL PROTECTED]>
>
> Change Logs: Add IP1000A Driver to kernel tree.
>
> Signed-off-by: Jesse Huang <[EMAIL PROTECTED]>
> ---
>
> drivers/net/ipg.c | 2331 +++++++++++++++++++++++++++++++++++++++++++++++++++++
> drivers/net/ipg.h |  856 +++++++++++++++++++
>  2 files changed, 3187 insertions(+), 0 deletions(-)
>  create mode 100755 drivers/net/ipg.c
>  create mode 100755 drivers/net/ipg.h

Kconfig/ Makefile adaptions missing (borrowed from 
http://www.fr.zoreil.com/linux/kernel/2.6.x/2.6.19-rc2/ip1000/0001-ipg-new-gigabit-ethernet-device-driver.txt):

diff -Nrup a/drivers/net/Kconfig b/drivers/net/Kconfig
--- a/drivers/net/Kconfig       2007-09-11 12:56:50.000000000 +0200
+++ b/drivers/net/Kconfig       2007-09-11 13:00:52.000000000 +0200
@@ -159,6 +159,15 @@ config NET_SB1000

          If you don't have this card, of course say N.

+config IP1000
+       tristate "IP1000 Gigabit Ethernet support"
+       depends on PCI && EXPERIMENTAL
+       ---help---
+         This driver supports IP1000 gigabit Ethernet cards.
+
+         To compile this driver as a module, choose M here: the module
+         will be called ipg.  This is recommended.
+
 source "drivers/net/arcnet/Kconfig"

 source "drivers/net/phy/Kconfig"
diff -Nrup a/drivers/net/Makefile b/drivers/net/Makefile
--- a/drivers/net/Makefile      2007-09-11 13:17:23.000000000 +0200
+++ b/drivers/net/Makefile      2007-09-11 13:28:00.000000000 +0200
@@ -4,6 +4,7 @@

 obj-$(CONFIG_E1000) += e1000/
 obj-$(CONFIG_IBM_EMAC) += ibm_emac/
+obj-$(CONFIG_IP1000) += ipg.o
 obj-$(CONFIG_IXGB) += ixgb/
 obj-$(CONFIG_CHELSIO_T1) += chelsio/
 obj-$(CONFIG_CHELSIO_T3) += cxgb3/


> e804d1c265bf1d843f845457f925a1728bbfdff7
> diff --git a/drivers/net/ipg.c b/drivers/net/ipg.c
> new file mode 100755
> index 0000000..bdc2b8d
> --- /dev/null
> +++ b/drivers/net/ipg.c
[...]
> +static struct pci_device_id ipg_pci_tbl[] __devinitdata = {
> +     { PCI_DEVICE(PCI_VENDOR_ID_SUNDANCE,    0x1023), 0, 0, 0 },
> +     { PCI_DEVICE(PCI_VENDOR_ID_SUNDANCE,    0x2021), 0, 0, 1 },
> +     { PCI_DEVICE(PCI_VENDOR_ID_SUNDANCE,    0x1021), 0, 0, 2 },
> +     { PCI_DEVICE(PCI_VENDOR_ID_DLINK,       0x9021), 0, 0, 3 },
> +     { PCI_DEVICE(PCI_VENDOR_ID_DLINK,       0x4000), 0, 0, 4 },
> +     { PCI_DEVICE(PCI_VENDOR_ID_DLINK,       0x4020), 0, 0, 5 },
> +     { 0, }
> +};

PCI_VENDOR_ID_SUNDANCE is undefined in kernel 2.6.23-rc6:

diff -Nrup a/include/linux/pci_ids.h b/include/linux/pci_ids.h
--- a/include/linux/pci_ids.h   2007-09-11 13:17:25.000000000 +0200
+++ b/include/linux/pci_ids.h   2007-09-11 13:15:34.000000000 +0200
@@ -1841,6 +1841,8 @@
 #define PCI_VENDOR_ID_ABOCOM           0x13D1
 #define PCI_DEVICE_ID_ABOCOM_2BD1       0x2BD1

+#define PCI_VENDOR_ID_SUNDANCE         0x13F0
+
 #define PCI_VENDOR_ID_CMEDIA           0x13f6
 #define PCI_DEVICE_ID_CMEDIA_CM8338A   0x0100
 #define PCI_DEVICE_ID_CMEDIA_CM8338B   0x0101

After these changes it seems to work in a 100 MBit/s network for me.
00:0a.0 Ethernet controller [0200]: Sundance Technology Inc / IC Plus Corp IC 
Plus IP1000 Family Gigabit Ethernet [13f0:1023] (rev 41)

> --- /dev/null
> +++ b/drivers/net/ipg.h
[...] 
> +
> +/* Miscellaneous Constants. */
> +#define   TRUE  1
> +#define   FALSE 0

Using the generic boolean definitions might be preferred.

Regards
        Stefan Lippers-Hollmann

Attachment: signature.asc
Description: This is a digitally signed message part.

Reply via email to