(Msg. 1) Posted: Wed Aug 13, 2008 3:38 pm
Post subject: 64 bit structure alignment? Archived from groups: microsoft>public>windowsxp>device_driver>dev (more info?)
I've just started working on a port of a driver from 32 bit to 64 bit XP and
I think I'm having trouble with alignment in my structures. For example, a
UNICODE_STRING is two shorts and 32 bit pointer. Using WinDbg, I can see
that a pointer to a UNICODE_STRING being supplied by the system to a call
back in my code is using two shorts, four padding bytes and then an 8 byte
pointer to a wide character buffer. My code is not reading this structure
correctly. What settings should I be using at compile time to get my code to
properly interpret structures?
--
Rick
(Msg. 2) Posted: Mon May 25, 2009 2:19 am
Post subject: Re: 64 bit structure alignment? [Login to view extended thread Info.] Archived from groups: per prev. post (more info?)
On Wed, 13 Aug 2008 15:38:09 -0400, "Richard Lewis Haggard"
<haggard.DeleteThis@msn.com> spake thusly:
>I've just started working on a port of a driver from 32 bit to 64 bit XP and
>I think I'm having trouble with alignment in my structures. For example, a
>UNICODE_STRING is two shorts and 32 bit pointer. Using WinDbg, I can see
>that a pointer to a UNICODE_STRING being supplied by the system to a call
>back in my code is using two shorts, four padding bytes and then an 8 byte
>pointer to a wide character buffer. My code is not reading this structure
>correctly. What settings should I be using at compile time to get my code to
>properly interpret structures?
Is there any way you could do another one?
Please see the new thread, "ACPI Driver".
I have both the XP 32 bit & Vista 64 bit drivers
already, but neither will work in XP 64 bit.
Thanks for taking the time to read, if you do!!!
--
Pastor Dave
"The difference between stupidity and genius is that
genius has its limits." - Albert Einstein
All times are: Eastern Time (US & Canada) (change)
Page 1 of 1
You can post new topics in this forum You can reply to topics in this forum You can edit your posts in this forum You can delete your posts in this forum You can vote in polls in this forum