Intrigued by the word (finally) of integration of driver development with
Visual Studio I …
Installed VS-2012 RC …
Installed WDK-8 …
Made new driver project -> KmdfHelloWorld
Open Driver.c …
Clicked on WdfDeviceCreate ( ) …
Hit the F1 key …
Zip, zilch, nada! Gee, I sure wanted to see help on the WdfDeviceCreate et
al function(s) - why oh why doesn’t this work!!
Bill Casey
== VirDISR & VirtualSCSIT Target Mode Solutions ==
Advanced Storage Concepts, Inc. (409) 762-0604
2200 Market Street, Suite 810 mailto:xxxxx
xxxxx@virtualscsi.com
Galveston, TX USA 77550-1532 http:</http:>
www.virtualscsi.com
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of Monisha Barooah
Sent: Wednesday, July 25, 2012 12:14 PM
To: Windows System Software Devs Interest List
Subject: RE: [ntdev] Issues with using ExSetFirmwareEnvironmentVariable to
set/create UEFI variables?
I was trying to pass 1 byte of data to set the UEFI variable data and so
passed onto it a pointer to a local variable.
Should I try the buffer with a NonPaged Memory allocated dynamically?
Thanks
Monisha
> From: xxxxx@windows.microsoft.com
> Subject: Re:[ntdev] Issues with using ExSetFirmwareEnvironmentVariable to
set/create UEFI variables?
> Date: Tue, 24 Jul 2012 18:12:25 -0700
> To: xxxxx@lists.osr.com
>
> Your post made me curious, so I went and read the code. The code locks the
> buffer you pass in with MmProbeAndLockPages. What is your buffer backed
by?
> It sounds like this corrupted the PFN list.
>
> Jake Oshins
> Windows Kernel Team
>
> The message offers no warranties and confers no rights.
> -----------------------------------------------------------------
> “Monisha Barooah” wrote in message
> news:xxxxx@ntdev…
> Hello Everyone,
> I have been struggling for a while with using the Win8
> ‘ExSetFirmwareEnvironmentVariable’ API to set/create UEFI variables.
>
> 1) On using the ‘ExGetFirmwareEnvironmentVariable’ API to read the values
of
> an existing UEFI variable, the operation is successful when we tried
reading
> a UEFI variable of size 1 bytes and by providing the ‘Attributes’ of
> EFI_VARIABLE_RUNTIME_ACCESS and EFI_VARIABLE_NON_VOLATILE as input to the
> API.
>
> 2) But when we try to use the same set of Attributes
> EFI_VARIABLE_RUNTIME_ACCESS and EFI_VARIABLE_NON_VOLATILE as input to the
> Win8 API ‘ExSetFirmwareEnvironmentVariable’ while trying to set a new
value
> to the UEFI variable mentioned in (1), the Win8 system experiences a BSOD
> and the bugcheck error shows the error code as ‘Bug Check 0x4E:
> PFN_LIST_CORRUPT’.
>
> On analyzing the Win8 system, looks like the Administrator account for
that
> system had been configured to ‘SE_SYSTEM_ENVIRONMENT_PRIVILEGE’ (Modify
> firmware environment variables) and our driver code is getting executed in
> Administrator account. As such, there should be no issues with the
privilege
> while using the Set API in Win8.
>
> The UEFI Specification Section 7.2 mentions that for creating UEFI
variables
> the Storage Attribute needs to be mentioned as an Attribute while using
the
> Win8 API ‘ExSetFirmwareEnvironmentVariable’? Could anyone let know which
of
> the attributes other than EFI_VARIABLE_RUNTIME_ACCESS and
> EFI_VARIABLE_NON_VOLATILE need to be included for creating a new UEFI
> variable?
>
> The UEFI Specification does not mention usage of any Storage Attribute
while
> trying to modify an existing UEFI variable. But when we tried Setting a
new
> value to an existing UEFI variable using the Win8 API
> ‘ExSetFirmwareEnvironmentVariable’ with Attributes
> EFI_VARIABLE_RUNTIME_ACCESS and EFI_VARIABLE_NON_VOLATILE, even in that
case
> we experienced a BSOD of ‘Bug Check 0x4E: PFN_LIST_CORRUPT’.
>
> Does the Win8 API ‘ExSetFirmwareEnvironmentVariable’ support the Set
feature
> appropriately? or are there some known issues with this API?
> Anyone will be able to let know about the same?
>
> Thanks
> Monisha
>
>
>
>
>
> —
> NTDEV is sponsored by OSR
>
> For our schedule of WDF, WDM, debugging and other seminars visit:
> http://www.osr.com/seminars
>
> To unsubscribe, visit the List Server section of OSR Online at
http://www.osronline.com/page.cfm?name=ListServer
—
NTDEV is sponsored by OSR
For our schedule of WDF, WDM, debugging and other seminars visit:
http://www.osr.com/seminars
To unsubscribe, visit the List Server section of OSR Online at
http://www.osronline.com/page.cfm?name=ListServer</mailto:xxxxx>
We are aware of the issue we are working on fixing msdn to make this work.
d
From: xxxxx@lists.osr.com [mailto:xxxxx@lists.osr.com] On Behalf Of Bill Casey
Sent: Wednesday, July 25, 2012 10:41 AM
To: Windows System Software Devs Interest List
Subject: [ntdev] F1 - where is my F1 key?
Intrigued by the word (finally) of integration of driver development with Visual Studio I …
Installed VS-2012 RC …
Installed WDK-8 …
Made new driver project -> KmdfHelloWorld
Open Driver.c …
Clicked on WdfDeviceCreate ( ) …
Hit the F1 key …
Zip, zilch, nada! Gee, I sure wanted to see help on the WdfDeviceCreate et al function(s) - why oh why doesn’t this work!!
Bill Casey
== VirDIS(r) & VirtualSCSI™ Target Mode Solutions ==
Advanced Storage Concepts, Inc. (409) 762-0604
2200 Market Street, Suite 810 xxxxx@virtualscsi.commailto:xxxxx
Galveston, TX USA 77550-1532 www.virtualscsi.comhttp:</http:>
From: xxxxx@lists.osr.commailto:xxxxx [mailto:xxxxx@lists.osr.com]mailto: On Behalf Of Monisha Barooah
Sent: Wednesday, July 25, 2012 12:14 PM
To: Windows System Software Devs Interest List
Subject: RE: [ntdev] Issues with using ExSetFirmwareEnvironmentVariable to set/create UEFI variables?
I was trying to pass 1 byte of data to set the UEFI variable data and so passed onto it a pointer to a local variable.
Should I try the buffer with a NonPaged Memory allocated dynamically?
Thanks
Monisha
> From: xxxxx@windows.microsoft.commailto:xxxxx
> Subject: Re:[ntdev] Issues with using ExSetFirmwareEnvironmentVariable to set/create UEFI variables?
> Date: Tue, 24 Jul 2012 18:12:25 -0700
> To: xxxxx@lists.osr.commailto:xxxxx
>
> Your post made me curious, so I went and read the code. The code locks the
> buffer you pass in with MmProbeAndLockPages. What is your buffer backed by?
> It sounds like this corrupted the PFN list.
>
> Jake Oshins
> Windows Kernel Team
>
> The message offers no warranties and confers no rights.
> -----------------------------------------------------------------
> “Monisha Barooah” > wrote in message
> news:xxxxx@ntdev…
> Hello Everyone,
> I have been struggling for a while with using the Win8
> ‘ExSetFirmwareEnvironmentVariable’ API to set/create UEFI variables.
>
> 1) On using the ‘ExGetFirmwareEnvironmentVariable’ API to read the values of
> an existing UEFI variable, the operation is successful when we tried reading
> a UEFI variable of size 1 bytes and by providing the ‘Attributes’ of
> EFI_VARIABLE_RUNTIME_ACCESS and EFI_VARIABLE_NON_VOLATILE as input to the
> API.
>
> 2) But when we try to use the same set of Attributes
> EFI_VARIABLE_RUNTIME_ACCESS and EFI_VARIABLE_NON_VOLATILE as input to the
> Win8 API ‘ExSetFirmwareEnvironmentVariable’ while trying to set a new value
> to the UEFI variable mentioned in (1), the Win8 system experiences a BSOD
> and the bugcheck error shows the error code as ‘Bug Check 0x4E:
> PFN_LIST_CORRUPT’.
>
> On analyzing the Win8 system, looks like the Administrator account for that
> system had been configured to ‘SE_SYSTEM_ENVIRONMENT_PRIVILEGE’ (Modify
> firmware environment variables) and our driver code is getting executed in
> Administrator account. As such, there should be no issues with the privilege
> while using the Set API in Win8.
>
> The UEFI Specification Section 7.2 mentions that for creating UEFI variables
> the Storage Attribute needs to be mentioned as an Attribute while using the
> Win8 API ‘ExSetFirmwareEnvironmentVariable’? Could anyone let know which of
> the attributes other than EFI_VARIABLE_RUNTIME_ACCESS and
> EFI_VARIABLE_NON_VOLATILE need to be included for creating a new UEFI
> variable?
>
> The UEFI Specification does not mention usage of any Storage Attribute while
> trying to modify an existing UEFI variable. But when we tried Setting a new
> value to an existing UEFI variable using the Win8 API
> ‘ExSetFirmwareEnvironmentVariable’ with Attributes
> EFI_VARIABLE_RUNTIME_ACCESS and EFI_VARIABLE_NON_VOLATILE, even in that case
> we experienced a BSOD of ‘Bug Check 0x4E: PFN_LIST_CORRUPT’.
>
> Does the Win8 API ‘ExSetFirmwareEnvironmentVariable’ support the Set feature
> appropriately? or are there some known issues with this API?
> Anyone will be able to let know about the same?
>
> Thanks
> Monisha
>
>
>
>
>
> —
> NTDEV is sponsored by OSR
>
> For our schedule of WDF, WDM, debugging and other seminars visit:
> http://www.osr.com/seminars
>
> To unsubscribe, visit the List Server section of OSR Online at http://www.osronline.com/page.cfm?name=ListServer
—
NTDEV is sponsored by OSR
For our schedule of WDF, WDM, debugging and other seminars visit:
http://www.osr.com/seminars
To unsubscribe, visit the List Server section of OSR Online at http://www.osronline.com/page.cfm?name=ListServer
—
NTDEV is sponsored by OSR
For our schedule of WDF, WDM, debugging and other seminars visit:
http://www.osr.com/seminars
To unsubscribe, visit the List Server section of OSR Online at http://www.osronline.com/page.cfm?name=ListServer</mailto:xxxxx></mailto:xxxxx></mailto:></mailto:xxxxx></mailto:xxxxx>