Re: IODelay function
Re: IODelay function
- Subject: Re: IODelay function
- From: Dan Markarian <email@hidden>
- Date: Mon, 2 May 2005 17:29:20 -0400
Hi Imran,
IODelay() as a synchronization technique is a bit worrisome. Why not
issue the read to your driver asynchronously, and once it completes
and your callback is called, then issue the write, which is, of
course, asynchronous to begin with?
You can read a bit more about the concept of Completion Chaining in I/
O Kit Fundamentals.
http://developer.apple.com/documentation/DeviceDrivers/Conceptual/
IOKitFundamentals/HandlingEvents/chapter_8_section_3.html#//apple_ref/
doc/uid/TP0000018-DontLinkElementID_180587
Dan
On 2 May 2005, at 10:14 AM, Imran Kazi wrote:
Hi folks,
I had written media filter scheme driver.
I have implemented read/write routine in the driver. I am able to
successfully write on the disk using
this driver.
Actually i have to hold the write routine for a small time interval
say (few
seconds),so that i call the read routine of my driver and read the
data on
the disk and then call the write routine. I am doing this to read
the data
on the disk and copy it to some other disk before my original write
routine
modifies the data on the disk. I am using IODelay routine to delay
my driver
write routine for a few seconds. But because of IODelay function my
read
routine also gets delay as i am specifying IODelay before calling read
routine.
Is it possible to delay only write call and not the read call, so
that I
call my driver read routine to get the data on the disk and then
call write
routine???
Thanks in advance.
Imran
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Darwin-kernel mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden