Zbr's days.
November
Sun Mon Tue Wed Thu Fri Sat
       
9
 
2007
Months
Nov

About :: TODO :: Blog :: RSS :: Old blog :: Projects :: GIT :: Gallery :: Notes

Fri, 09 Nov 2007

New HIFN driver release.

This release forces HIFN driver to invoke crypto callbacks in softirq context instead of hardirq one because of network stack, which performs whole data processing either in process or bottom-half context.

One can find new driver in archive.
It will be included into 2.6.25 kernel tree via cryptodev git tree.

/devel/acrypto/hifn :: Link / Comments (0)


Tasklet vs workqueue. Performance numbers.

Herbert Xu pointed that my HIFN driver performs callback invocation from hardirq context, but many in-kernel users expect it to be from softirq context (bottom halves) - network stack processing happens in that context, so I decided to add some kind of rescheduling of the callback invocation: better would be to call it from process context (workqueue), but tasklet (softirq context) is good too.

So, to find the fastest solution I implemented trivial testing module, which reschedules either tasklet or workqueue until predefined number of executions is reached, and shows time it took.
Here is a result:

workqueue: 10000000 iterations, 4.85 seconds
  tasklet: 10000000 iterations, 0.70 seconds
As you can see, tasklet is about 6.92 times faster.

Test was performed on AMD Athlon64 3500+ (2210 Mhz) with 1 GB of RAM.

One can find testing module in archive.

/devel/other :: Link / Comments (0)