Copyrights @ Journal 2014 - Designed By Templateism - SEO Plugin by MyBloggerLab

Saturday, November 30, 2002

Interrupt Request Level (IRQL)
Every Kernel developer is familiar with IRQL and Matt Wu has written an article to disclose it�s mysterious veil. See these are the definitions from DDK :

The priority ranking of an interrupt. A processor has an IRQL setting that threads can raise or lower. Interrupts that occur at or below the processor's IRQL setting are masked and will not interfere with the current operation. Interrupts that occur above the processor's IRQL setting take precedence over the current operation.

The particular IRQL at which a piece of kernel-mode code executes determines its hardware priority. Kernel-mode code is always interruptible: an interrupt with a higher IRQL value can occur at any time, thereby causing another piece of kernel-mode code with the system-assigned higher IRQL to be run immediately on that processor. In other words, when a piece of code runs at a given IRQL, the Kernel masks off all interrupt vectors with a lesser or equal IRQL value on the microprocessor

Matt does explains the difference between the Thread Priorities and IRQL. Any thread, whatever its priority attribute, is always preemptible by a software or hardware interrupt. Every thread priority falls in to two classes, variable and real-time. These are sub divided in 16 levels 0-15 as variable and 16 to 31 are real time. The preemptive threads get into the Variable threads or I can say all the premptive threads are the variable priority threads. All the threads are preemptible by a software as well as the hardware interrupt.The thread priority only changes the decisions by system scheduler.
On x86 CPU, there are only 4 rings which can be definied by 0,1,2,3 and Windows uses only 0 and 3 (0 is used by Kernel and 3 by the user). IRQL only exists in kernel space. For user space, it�s meaningless. All user threads are running at PASSIVE_LEVEL, though they can result in a task switch to kernel space and change the IRQL. They could not access the IRQL directly. Spin locks are always reliable for getting the control on the driver specific data. Actually they protect the shared data or device registers from simultaneous access by one or more routines running concurrently on a symmetric multiprocessor platform. Because after the SpinLock is acquired , the current IRQL will be DISPATCH_LEVEL and then the NT dispatcher (scheduler) preemption will be disabled. Just FYI and I also donn know much about this, SpinLocks have three types:
1. Standard spin locks
2. ISR synchronization spin locks. Each type has its own IRQL associations
3. Default ISR (Interrupt Service Request) spin locks.


Let me read more on spin licks then will write more.
Refer :
Understanding IRQL
A Catalog of NT Synchronization Mechanisms - OSR 1997.

Friday, November 29, 2002

Windows XP Tip: Device Driver Rollback
I will be starting with Windows Device Drivers again after a long time and posting the my learnings at Windows Device Driver Section. This area of Windows is always been a treasure for me. I could find lot of resources on Windows NT device drivers including books, articles, news groups, postings like
  • Windows NT/2000 Native API Reference by Gary Nebbett, 2000.
  • Undocumented Windows NT by Prasad Dabak, Sandeep Phadke & Milind Borate, 1999.
  • Developing Windows NT Device Drivers: A Programmer's Handbook by Edward N. Dekker & Joseph M. Newcomer, 1999.
  • Programming the Microsoft Windows Driver Model by Walter Oney, 1999.
  • Writing Windows WDM Device Drivers by Chris Cant, 1999.
  • Windows NT Device Driver Development by Peter G. Viscarola & W. Anthony Mason, 1999.
  • Inside Windows NT, 2nd Ed. by Helen Custer & David A. Solomon, 1998.
  • Windows NT File System Internals by Rajeev Nagar, 1997.
  • The Windows NT Device Driver Book (with Disk) by Art Baker, 1997.
        View the Table of Contents
  • Microsoft Windows NT Server Resource Kit by Microsoft Corporation, 1995.
  • Microsoft Windows NT Workstation Resource Kit by Microsoft Corporation, 1995.
  • Advanced Windows (with CD-ROM) by Jeffrey M. Richter, 1996
  • Inside the Windows NT File System by Helen Custer, 1994.
  • Networking Device Drivers by Sanjay Dhawan, 1995.



  • But there are no resources for writing drivers on Windows XP. I will be going through the process lets see what I find here at Windows Device Driver Section. Wish me luck!!!!!!!!!!!!!

    Tuesday, November 26, 2002

    Support is Life
    Software Support is like the nightmare for Software professionals. As I think more on this I feel the difference as they are becoming like the Call center representatives. Working through the same kind of work style and processes people happen to feel corruption of knowledge. In the field like software we should definitely keep ourselves updated but never at the cost of work and also support support the systems but not at the cost of our job satisfaction.
    Here comes the difference between an IT professional and IS professional. Life of IT professional on a single project is only 1-2 years where as an IS professional can work on the same kind of work for years.
    All IT professionals tend to feel the brain drain. They frustrate to the level of resigning. Resignation is not the solution I think.
    When I rethink I get the problem in more detail as there is only support coming up in almost all enterprises. So the thrill remains in these change of employer and salary. It only justifies when you really want to get more benifits.
    So if the settled life is needed stick to the same employer...

    Monday, November 25, 2002

    P's Mentalpiece
    I just wonder and be jealous to write so romantic piece.. but definitely love if somebody like could do it right.
    Pratap says.. Keyboard-portrait of my day, day after day after day (hopefully). I do use my brain occasionally (though friends don't seem to think so), so you'll probably find my thoughts here as well. Lets just say, trespassers will get a piece of my mind ...
    today, i spend most of the time with aakash , his wife sonali and his babygirl reva. it was fun spending time with them. they r happy family and i wish they will remain same or have greater fun in future too. actully he invited me for lunch few days back but i couldn't manage to go on that day, thats why he and his wife was very angry with me. so i decided to spend some time with them. I don't know why but evrybody is complaning now days as i m not spending time with them and i am very busy. i don't know how to explain them that i m managing many friends and even try to find out some time for my improvement like reading, learning violine and developing my own website. i hope i will manage the time well and try to keep evryone happy by spending time with them as much as possible. it is the best lessons i m getting from my schedule for time management and relationship management.

    Thursday, November 21, 2002

    Microsoft plans 'back-up' brains for humans
    'Back-up brains' on digital file and computer-generated beings called 'avataars' were revealed on Thursday as the brave new frontier of software technology, as Britain's leading science magazine catalogued Microsoft corporation's plans to literally put our lives on disk.
    According to the latest issue of the New Scientist magazine,"engineers are working on software to load every photo you take, every letter you write, in fact your every memory and experience - into a surrogate brain that never forgets anything"