CcZeroData and special-case writes

In the docs for CcZeroData you will see the following:

"If Wait is FALSE and if the required pages of the cached file are not
already resident in memory, CcZeroData will refuse to block and will
return FALSE.

Note File systems that call CcZeroData must be prepared to handle a
special form of write call where the memory descriptor list (MDL) is
already supplied. Specifically, if Irp->MdlAddress is not NULL, the file
system must check the low-order bit of Irp->MdlAddress->ByteOffset. If
this bit is set, that means that the IRP was generated in this routine,
and the file system must do the following:

* Decrement Irp->MdlAddress->ByteOffset and Irp->UserBuffer.
* Clear Irp->MdlAddress immediately prior to completing"

Well, I looked through the FastFat source code in the XP kit and
although it uses CcZeroData, it does not check for the special case
where the low-order bit of ->ByteOffset is set in a write. I also
do not see any requests of this kind in my filter, even on writes that
are generated as a result of CcZeroData. So do I have to worry about
this case or not?

- Nicholas Ryan


You are currently subscribed to ntfsd as: $subst(‘Recip.EmailAddr’)
To unsubscribe send a blank email to leave-ntfsd-$subst(‘Recip.MemberIDChar’)@lists.osr.com

I could be mistaken here, but I believe this is an error in the
documentation. Obviously, someone from Microsoft will have to confirm this.

Regards,

Tony

Tony Mason
Consulting Partner
OSR Open Systems Resources, Inc.
http: http://www.osr.com

See the new NTFSD FAQ on the OSR Web Site!
-----Original Message-----
From: Nicholas Ryan [mailto:xxxxx@secretseal.com]
Sent: Friday, January 04, 2002 2:26 PM
To: File Systems Developers
Subject: [ntfsd] CcZeroData and special-case writes

In the docs for CcZeroData you will see the following:

“If Wait is FALSE and if the required pages of the cached file are not
already resident in memory, CcZeroData will refuse to block and will return
FALSE.

Note File systems that call CcZeroData must be prepared to handle a special
form of write call where the memory descriptor list (MDL) is already
supplied. Specifically, if Irp->MdlAddress is not NULL, the file system must
check the low-order bit of Irp->MdlAddress->ByteOffset. If this bit is set,
that means that the IRP was generated in this routine, and the file system
must do the following:

* Decrement Irp->MdlAddress->ByteOffset and Irp->UserBuffer.
* Clear Irp->MdlAddress immediately prior to completing”

Well, I looked through the FastFat source code in the XP kit and although it
uses CcZeroData, it does not check for the special case where the low-order
bit of ->ByteOffset is set in a write. I also do not see any requests
of this kind in my filter, even on writes that are generated as a result of
CcZeroData. So do I have to worry about this case or not?

- Nicholas Ryan

You are currently subscribed to ntfsd as: xxxxx@osr.com
To unsubscribe send a blank email to leave-ntfsd-$subst(‘Recip.MemberIDChar’)@lists.osr.com


You are currently subscribed to ntfsd as: $subst(‘Recip.EmailAddr’)
To unsubscribe send a blank email to leave-ntfsd-$subst(‘Recip.MemberIDChar’)@lists.osr.com</http:>

Thanks for the question and answer. This has been on my “Figure It Out
Someday” list for a long time.
– Demyn

“Tony Mason” wrote in message news:xxxxx@ntfsd…
>
> I could be mistaken here, but I believe this is an error in the
> documentation. Obviously, someone from Microsoft will have to confirm
this.
>
> Regards,
>
> Tony
>
> Tony Mason
> Consulting Partner
> OSR Open Systems Resources, Inc.
> http: http://www.osr.com


You are currently subscribed to ntfsd as: $subst(‘Recip.EmailAddr’)
To unsubscribe send a blank email to leave-ntfsd-$subst(‘Recip.MemberIDChar’)@lists.osr.com</http:>

Sorry about the doc bug! It’s now on my list of things to fix.

–Diane


This posting is provided “AS IS” with no warranties, and confers no
rights. You assume all risk for your use.

-----Original Message-----
From: Demyn Plantenberg [mailto:xxxxx@almaden.ibm.com]
Sent: Wednesday, January 09, 2002 1:55 PM
To: File Systems Developers
Subject: [ntfsd] Re: CcZeroData and special-case writes

Thanks for the question and answer. This has been on my “Figure It Out
Someday” list for a long time.
– Demyn

“Tony Mason” wrote in message news:xxxxx@ntfsd…
>
> I could be mistaken here, but I believe this is an error in the
> documentation. Obviously, someone from Microsoft will have to confirm
this.
>
> Regards,
>
> Tony
>
> Tony Mason
> Consulting Partner
> OSR Open Systems Resources, Inc.
> http: http://www.osr.com


You are currently subscribed to ntfsd as: xxxxx@exchange.microsoft.com
To unsubscribe send a blank email to leave-ntfsd-$subst(‘Recip.MemberIDChar’)@lists.osr.com


You are currently subscribed to ntfsd as: $subst(‘Recip.EmailAddr’)
To unsubscribe send a blank email to leave-ntfsd-$subst(‘Recip.MemberIDChar’)@lists.osr.com</http:>