Just because nobody ansered since two days, if you get nothing accurate directly for NASM, there is a Demo, for this, at RosAsm Pages:
<
http://rosasm.org/ >
At the bottom of the [Users Demos] / [Other Demos]
"Ring 0 access".
The zip comes with an explication text inside. For the Demo, the Source is inside the Executable, and can be viewed when loaded with RosAsm.
As this is a very short Demo, i think the port should be trivial...
Betov.