Re: tg3 polling extension

2005-07-07 Thread David S. Miller
From: "Qinghua(Kevin) Ye" <[EMAIL PROTECTED]> Date: Thu, 7 Jul 2005 17:43:06 -0600 > So the tg3_tx() and tg3_start_xmit do not include any code of reprogramming > the hardware? Right, they just process the TX ring. > What kinds of code can be classifed to reprogramming the hardware? Should > the

Re: tg3 polling extension

2005-07-07 Thread Qinghua(Kevin) Ye
Thanks, David. Some questions are as following: > It depends, the locking changed significantly in the current > 2.6.13-rcX version of the driver. But before that: > > 1) ->hard_start_xmit() needs to hold the tx_lock with hard IRQs >disabled, as does tg3_tx(). It uses NETIF_F_LLTX locking,

Re: tg3 polling extension

2005-07-07 Thread David S. Miller
From: "Qinghua(Kevin) Ye" <[EMAIL PROTECTED]> Date: Thu, 7 Jul 2005 16:04:40 -0600 > I did some small test showing that polling can improve the packet processing > throughput a bit. I still need to do more tests. Could anyone give me some > information about the lock scheme of RX and TX precedure?

tg3 polling extension

2005-07-07 Thread Qinghua(Kevin) Ye
I did some small test showing that polling can improve the packet processing throughput a bit. I still need to do more tests. Could anyone give me some information about the lock scheme of RX and TX precedure? I would be very appreciate. Thanks. Qinghua - To unsubscribe from this list: send the

Re: help on tg3 polling extension

2005-07-06 Thread Qinghua(Kevin) Ye
> Linux is a general purpose operating system. > > Even as a dedicated router, a router daemon still has to execute > in userspace to do BGP etc. signaling with routing peers. The > administrator also might want to run diagnostic tools to monitor > the network. > > You cannot spin polling on the d

Re: help on tg3 polling extension

2005-07-06 Thread Qinghua(Kevin) Ye
> > > > > In my SMP platform, there is no other processes running. The usage of > CPUs > > > are 100% and 0%. How could I make Nic interrupts not arrive at only one > CPU, > > > or balance the interrupt between two CPUs? > > > > This doesn't work. If you try to split up the work for one network >

Re: help on tg3 polling extension

2005-07-06 Thread Qinghua(Kevin) Ye
> > > In my SMP platform, there is no other processes running. The usage of CPUs > > are 100% and 0%. How could I make Nic interrupts not arrive at only one CPU, > > or balance the interrupt between two CPUs? > > This doesn't work. If you try to split up the work for one network > card amongst mul

Re: help on tg3 polling extension

2005-07-06 Thread David S. Miller
From: "Qinghua(Kevin) Ye" <[EMAIL PROTECTED]> Date: Wed, 6 Jul 2005 15:57:00 -0600 > In my SMP platform, there is no other processes running. The usage of CPUs > are 100% and 0%. How could I make Nic interrupts not arrive at only one CPU, > or balance the interrupt between two CPUs? This doesn't

Re: help on tg3 polling extension

2005-07-06 Thread Qinghua(Kevin) Ye
> It is not Click's right to make this kind of decision, that is what > we have the process scheduler for. > Click's scheduler is aim to make packet processing tasks with highest priority. It's just for the dedicated use. Since Linux is a general OS, and it is free and fatastic, so it is possible

Re: help on tg3 polling extension

2005-07-06 Thread David S. Miller
From: "Qinghua(Kevin) Ye" <[EMAIL PROTECTED]> Date: Wed, 6 Jul 2005 14:12:29 -0600 > Yes, you are right. Click acturally will release the CPU to OS at interval. > Other processes will be responded at this interval. It is not Click's right to make this kind of decision, that is what we have the pr

Re: help on tg3 polling extension

2005-07-06 Thread David S. Miller
From: "Qinghua(Kevin) Ye" <[EMAIL PROTECTED]> Date: Wed, 6 Jul 2005 13:15:40 -0600 > Yes, It wastes CPU cycles if there is other process running. However, as it > being a dedicated router, it should not be a problem. The process of packets > is the only task it is supposed to do. Linux is a gener

Re: help on tg3 polling extension

2005-07-06 Thread David S. Miller
From: "Qinghua(Kevin) Ye" <[EMAIL PROTECTED]> Date: Wed, 6 Jul 2005 11:36:40 -0600 > > > Compared to NAPI, click polling will disable Nic interrupts during its > > > operation, even there is no any packets in the rx buffer. > > > > This destroys latency if you only recheck the RX buffer using > >

Re: help on tg3 polling extension

2005-07-06 Thread Qinghua(Kevin) Ye
Yes, It wastes CPU cycles if there is other process running. However, as it being a dedicated router, it should not be a problem. The process of packets is the only task it is supposed to do. > > > > > Compared to NAPI, click polling will disable Nic interrupts during its > > > > operation, even th

Re: help on tg3 polling extension

2005-07-06 Thread Qinghua(Kevin) Ye
> > Compared to NAPI, click polling will disable Nic interrupts during its > > operation, even there is no any packets in the rx buffer. > > This destroys latency if you only recheck the RX buffer using > timer interrupts. Even with HZ=1000, on gigabit links your packet > latency will be terrible.

Re: help on tg3 polling extension

2005-07-05 Thread David S. Miller
From: "Qinghua(Kevin) Ye" <[EMAIL PROTECTED]> Date: Tue, 5 Jul 2005 16:19:27 -0600 > Compared to NAPI, click polling will disable Nic interrupts during its > operation, even there is no any packets in the rx buffer. This destroys latency if you only recheck the RX buffer using timer interrupts.

Re: help on tg3 polling extension

2005-07-05 Thread Qinghua(Kevin) Ye
ent: Tuesday, July 05, 2005 3:52 PM Subject: Re: help on tg3 polling extension > From: "Qinghua(Kevin) Ye" <[EMAIL PROTECTED]> > Date: Tue, 5 Jul 2005 15:38:57 -0600 > > > I am thinking about extending the tg3 driver to support Click Polling. > > What is Clic

Re: help on tg3 polling extension

2005-07-05 Thread David S. Miller
From: "Qinghua(Kevin) Ye" <[EMAIL PROTECTED]> Date: Tue, 5 Jul 2005 15:38:57 -0600 > I am thinking about extending the tg3 driver to support Click Polling. What is Click Polling, and why would we want it? - To unsubscribe from this list: send the line "unsubscribe netdev" in the body of a message

help on tg3 polling extension

2005-07-05 Thread Qinghua(Kevin) Ye
Hi, all, I am thinking about extending the tg3 driver to support Click Polling. Click has its patch on linux kernel, and adds some callback functions and polling variable to the net_device struct(I did this work on 2.6.11 kernel, and on AMD opteron): netdev->polling = 0; // Check if click p