32 bit process & 64 bit driver, 32/64 bit pointer?

32 bit process & 64 bit driver, 32/64 bit pointer?

Post by S290Y » Fri, 12 Feb 2010 23:23:01


Hi,

I am using MmMapLockedPagesSpecifyCache function to map my device memory RAM
to user area. It is not a security conernt to me to do by this method.

I want to support this for a 32 bit application, calls 64 bit driver(64 bit
system), I am taking care of 32 bit process detection, In this case, if i
uses above function, it returns a PVOID, I am not sure, will get a 32/64 bit
pointer, but PVOID is 64 bit in 64 bit system?

Is there any way to request only 32 bit User pointer from this API?
Any coversion of mapping 64 bit userarea pointer to 32 bit different user
area pointer?

Any other ways to support this in 32 bit process in a 64 bit driver, for
getting a 32 bit User address pointer?

I have tested once, I received a 32 bit pointer, but i doubt, this will not
be a case always.

Thanks,
kota
 
 
 

32 bit process & 64 bit driver, 32/64 bit pointer?

Post by Scott Noon » Fri, 12 Feb 2010 23:27:05

> Is there any way to request only 32 bit User pointer from this API?

If the user application is 32bit you'll get a 32bit pointer.

See:

http://www.yqcomputer.com/

-scott

--
Scott Noone
Consulting Associate
OSR Open Systems Resources, Inc.
http://www.yqcomputer.com/

 
 
 

32 bit process & 64 bit driver, 32/64 bit pointer?

Post by Maxim S. S » Sat, 13 Feb 2010 03:05:57

> Any other ways to support this in 32 bit process in a 64 bit driver, for

Return the 64bit pointer to user mode, and, in 32bit app, just truncate the upper 32 bits.

--
Maxim S. Shatskih
Windows DDK MVP
XXXX@XXXXX.COM
http://www.yqcomputer.com/