Re: Re: [patch] net/tulip: LAN driver for ULI M5261/M5263

From: Peer . Chen
Date: Tue Aug 16 2005 - 04:59:40 EST



Jeff:
The attached file is the incremental patch to the original uli526x.c I send
you first time,
I modify the source according to your advice, thanks.

Signed-off-by: Peer Chen <Peer.Chen@xxxxxxxxxx>
(See attached file: patch_uli526x_inc)

Best Regards
Peer


|---------+--------------------------->
| | Jeff Garzik |
| | <jgarzik@xxxxxxx|
| | om> |
| | |
| | 2005-08-12 03:15|
| | |
|---------+--------------------------->
>------------------------------------------------------------------------------------------------------------------------------|
| |
| 收件人: Peer.Chen@xxxxxxxxxx |
| 抄送: Alexey Dobriyan <adobriyan@xxxxxxxxx>, Alan Cox <alan@xxxxxxxxxx>, Clear.Zhang@xxxxxxxxxx, |
| netdev@xxxxxxxxxxxxxxx, Emily.Jiang@xxxxxxxxxx |
| 主题: Re: [patch] net/tulip: LAN driver for ULI M5261/M5263 |
>------------------------------------------------------------------------------------------------------------------------------|



Peer.Chen@xxxxxxxxxx wrote:
> Jeff:
> I have removed the uli526x support from tulip core driver,check the patch
> file for detail,thanks.

Patch applied, thanks!


> Alexey:
> Here the new patch,please check it, thanks.
> (See attached file: patchuli526x)

Please submit a patch -incremental- to the original uli526x.c that you
sent.

I have already applied your original patch, so I am unable to apply this
new patch.

Also:

1) Obtain PCI vendor, device IDs from pdev->vendor and pdev->device, not
by reading PCI config registers directly:

//add by clearzhang 2004/7/8
pci_read_config_dword(pdev,0x0,&configval);
m526x_id = configval;
if(configval == 0x526310b9)
{
//printk("is m5263\n");
pci_read_config_dword(pdev,0x0c,&configval);
configval = ((configval & 0xffff00ff) | 0x8000);
pci_write_config_dword(pdev,0x0c,configval);
}


2) Check return value of pci_alloc_consistent() for failure, and handle
cleanup:

> db->desc_pool_ptr = pci_alloc_consistent(pdev, sizeof(struct
tx_desc) *
> DESC_ALL_CNT + 0x20, &db->desc_pool_dma_ptr);
> db->buf_pool_ptr = pci_alloc_consistent(pdev, TX_BUF_ALLOC *
TX_DESC_CNT
> + 4, &db->buf_pool_dma_ptr);


3) uli526x_remove_one() should call pci_disable_device()




Attachment: patch_uli526x_inc
Description: Binary data