[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [microblaze-uclinux] FSL Driver Overhead
Thanks guys!
I've recorded the number of times the fsl is full (or empty) and come up with a bunch of zeros. I'll need to double check my implementation, but this seems likely because of the new fifo depth of 64 words.
I'm going to test my implementation by writing a test app that purposely tries to read and write to an empty/full fifo.
-----------------
Jonathan Jung
jwjung@xxxxxxxxxxxxx
Sent via Chattermail - push Email for the treo
-----Original Message-----
From: Claudio Lanconelli <lanconelli.claudio@xxxxxxxxx>
Date: Wednesday, Jan 4, 2006 6:18 am
Subject: Re: [microblaze-uclinux] FSL Driver Overhead
Hi Jonathan,
Inside kernel you can't use printf, but you can use printk() that is printf() with some limitations.
Howerver to print integer variables you can consider exactly like printf()
For example:
printk("Write full count: %d, Read empty count: %d\n", write_full_counter, read_empty_counter);
Cheers,
Claudio Lanconelli
Jonathan Jung wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
> Hi Claudio,
> One question regarding the counter:
> I'm not really familiar with Linux driver development, but is there an
easy way to gain access to printf from inside the driver (fslfifo.c)?
Including uClib's stdio.h leads to a large mess of files that would
have to be copied/symlinked to different locations.
> Should I be reading the value of the counters a different way?
> Thanks,
> Jonathan
>
On Jan 3, 2006, at 2:55 AM, Claudio Lanconelli wrote:
>> Jonathan Jung wrote:
>
>> As you can see, software version consumes 1m 33 s of CPU time >> running the openssl code. The hardware/software combo takes only 10 >> seconds of time executing the openssl code, but requires 1 minute >> and 56 seconds of overhead in unrelated system calls, I'm sure is >> because of the reading and writing to the FSL.
>
>
> Reading/writing to FSL takes time only when the FSL FIFO if full on > writing or empty on reading.
> Be sure your FSL FIFO is depth enough. Then you can count how many > times the driver wait on the
> fifo by adding a couple of counters like this:
>
> write_tasklet_func:
>
> fsl_nput(fsl_fifo->id, value, fsl_status);
> if(fsl_nodata(fsl_status))
> {
> write_full_counter++;
> do_reschedule++;
> break;
> }
>
> read_tasklet_func:
>
> fsl_nget(fsl_fifo->id, val, fsl_status);
> if(fsl_nodata(fsl_status))
> {
> read_empty_counter++;
> break;
> }
>
> Try it and report the counters value
>
> Happy new year,
> Claudio Lanconelli
> ___________________________
> microblaze-uclinux mailing list
> microblaze-uclinux@xxxxxxxxxxxxxx
> Project Home Page : http://www.itee.uq.edu.au/~jwilliams/mblaze- uclinux
> Mailing List Archive : http://www.itee.uq.edu.au/~listarch/ > microblaze-uclinux/
>
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.1 (Darwin)
> iD8DBQFDu4Dd4kOt3FHegqgRAtgzAJwP8BfAWhlyphrZJiRKQg1BqMKD1ACglH9O
k9Ejyjeb+M5qmJnm5sTHtFo=
=Jo9p
-----END PGP SIGNATURE-----
__________________________
___________________________
microblaze-uclinux mailing list
microblaze-uclinux@xxxxxxxxxxxxxx
Project Home Page : http://www.itee.uq.edu.au/~jwilliams/mblaze-uclinux
Mailing List Archive : http://www.itee.uq.edu.au/~listarch/microblaze-uclinux/