From: agnel juni <junijoseph@yahoo.co.in>
To: Ameet Patil <ammubhai@gmail.com>
Cc: linuxppc-embedded@ozlabs.org
Subject: Re: System ACE driver - for 2.6 kernel - issue resolved
Date: Tue, 7 Nov 2006 00:30:10 +0530 (IST) [thread overview]
Message-ID: <20061106190010.58059.qmail@web8415.mail.in.yahoo.com> (raw)
[-- Attachment #1: Type: text/plain, Size: 3865 bytes --]
Hi Ameet,
We were able to get over with the unstability in the driver with the following fix in the code
Instead of fixing the number of sectors to be 2 in the loop, we are actually doing a read based on the kernel request like this :
for(i = xsa_cur_req->current_nr_sectors; i > 0; i-=xsa_cur_req->current_nr_sectors ){
xsa_device.req_done = 1;
while ((stat = cur_req(&SysAce, sector,
xsa_cur_req->current_nr_sectors ,
buffer)) == XST_DEVICE_BUSY)
xsa_short_delay();
Now the driver is stable with all the filesystem commands.
Please test this out and if appropriate patch this to the driver code.
Thanks
Junita
----- Original Message ----
From: Ameet Patil <ammubhai@gmail.com>
To: agnel juni <junijoseph@yahoo.co.in>
Cc: linuxppc-embedded@ozlabs.org
Sent: Thursday, 26 October, 2006 1:00:48 AM
Subject: Re: System ACE driver - for 2.6 kernel - need help to understand xsa_thread
Hi Junita,
Its a hack really! When I was developing/porting the SysAce driver
to 2.6 I tried to maintain the code as is from the 2.4 kernel driver. In
doing so I found that there is a slight difference between the two
kernels. i.e. I am not sure why, but the sysace device can only handle
requests for 2 sectors at a time. This was fine in the 2.4 as the kernel
always requested 2 sectors. However, in 2.6 I found that this is
different: the requests are 8 secs. or more. I tried to fix this in vain
by changing several parameters of the driver during initialization.
Anyway, due to several issues I didn't try hard to fix it at that time.
Hence this hack: No matter how many sec. req. I get from the kernel, I
use a loop to req. only 2 secs. at a time. The xsa_device.req_done is
used as a flag and reset in the XSA IRQ IIRC.
If you find a better approach, please do update me. Hope this helps!
cheers,
-Ameet
agnel juni wrote:
>
> Hello all
>
> I am trying to understand the parameters that are sent through "cur_req"
> function used in funtion xsa_thread in System ACE driver.
>
> In xsa_thread function in the System ACE driver ,
>
> In 2.4 kernel:
> --------------------
> while ((stat = cur_req(&SysAce, sector,
> CURRENT->current_nr_sectors,
> CURRENT->buffer)) == XST_DEVICE_BUSY)
> xsa_short_delay();
>
>
> Where as in 2.6 kernel this is changed to
> ---------------------------------------------------------------
>
> for(i = xsa_cur_req->current_nr_sectors; i > 0; i-=2){
> xsa_device.req_done = 1;
> while ((stat = cur_req(&SysAce, sector,
> 2,
> buffer)) == XST_DEVICE_BUSY)
> xsa_short_delay();
> #endif
>
> Ameet , could you help me understand the impact of the parameters,
> especailly the 3rd paramter which is hardcoded in 2.6 kernel.It would be
> great if you could clarify this in regard to 'mount' command.
>
> Thanks in advance
> Junita
>
>
>
> ------------------------------------------------------------------------
> Find out what India is talking about on - Yahoo! Answers India
> <http://us.rd.yahoo.com/mail/in/yanswers/*http://in.answers.yahoo.com/>
> Send FREE SMS to your friend's mobile from Yahoo! Messenger Version 8.
> Get it NOW
> <http://us.rd.yahoo.com/mail/in/messengertagline/*http://in.messenger.yahoo.com>
>
__________________________________________________________
Yahoo! India Answers: Share what you know. Learn something new
http://in.answers.yahoo.com/
[-- Attachment #2: Type: text/html, Size: 7241 bytes --]
reply other threads:[~2006-11-06 19:00 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20061106190010.58059.qmail@web8415.mail.in.yahoo.com \
--to=junijoseph@yahoo.co.in \
--cc=ammubhai@gmail.com \
--cc=linuxppc-embedded@ozlabs.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).