home *** CD-ROM | disk | FTP | other *** search
/ The World of Computer Software / World_Of_Computer_Software-02-387-Vol-3of3.iso / p / parity.tec < prev    next >
Text File  |  1993-03-21  |  6KB  |  105 lines

  1. ID:PE Parity Errors
  2. Quarterdeck Technical Note #128
  3. by Bryan Scott
  4. Last revision: 13 January 1993
  5.  
  6.  
  7.      * Since I installed QEMM on my system I have been getting "parity
  8.        errors".  What are parity errors and why are they occurring?
  9.  
  10. A parity error is a Non-Maskable Interrupt error.  The memory controller chip
  11. reports a parity error when it reads a byte of data and the 9 bits it used to
  12. encode the byte do not add up to 1 (odd parity).  Parity errors are always
  13. hardware-related.  Software applications cannot cause parity errors (though an
  14. application may cause one to be detected).
  15.  
  16. The error may appear since you've installed QEMM-386 because QEMM-386 uses
  17. memory that has probably never been used before, and could be marginally bad
  18. to begin with.  However, before we explain why parity errors are always an
  19. indication of hardware problems, let's discuss what a parity error is.
  20.  
  21. In the digital world, all information is represented by the binary numbers 0
  22. and 1.  The binary digit, or bit, is the fundamental building block of digital
  23. information in a computer, and it stores information in two states:  off or on
  24. (0 or 1, respectively).  One bit can make a big difference.  Here's why:
  25.  
  26.      The binary number for the letter U is:
  27.  
  28.      01010101
  29.  
  30.      If you change just the fourth bit over from the left, from one state to
  31.      the other, the binary number becomes the letter E.
  32.  
  33.      01000101
  34.  
  35. Now while there are 8 bits in a byte, your memory controller handles
  36. information 9 bits at a time.  This extra bit is called a "parity bit",
  37. and is the computer's way to verify the integrity of your data. Whenever
  38. you write data to memory, the memory controller adds up the number of 1's
  39. in each byte of information then sets the ninth bit to make the sum of
  40. all nine bytes odd.  IBM could have chosen to make the sum of the nine
  41. bytes be even (even parity), but they chose to store data in memory with
  42. odd parity and every other PC manufacturer followed suit.
  43.  
  44. In the example above, the letter U has the binary value of 01010101, which has
  45. 4 1s in it, and the letter E is 01000101, which has 3 1s in it.  When your PC
  46. reads each byte of data, it sums the 9 bits to make sure the number of 1s in
  47. the byte is still odd.  If the state of a single bit gets changed from 1 to 0,
  48. or 0 to 1, the parity of the nine bits becomes even and the memory controller
  49. asserts the NMI (Non-Maskable Interrupt).  This signal is put directly on a
  50. pin of the CPU, then the code Interrupt 2 points at posts a Parity Error
  51. message, which warns you that there is a problem with your RAM.
  52.  
  53. Please note that all of these operations are performed directly by your
  54. computer's hardware, regardless of which operating system (DOS, OS/2,
  55. UNIX) you use, and regardless of which utility programs or application
  56. software you are running.  One exception is Macintosh computers, which
  57. use the 8 bit SIMM chips that do not have parity.  When errors occur
  58. the system just malfunctions from the invalid data.  Also remember that
  59. parity checking will only detect if one bit in a byte gets changed.  If
  60. two bits in the same byte get changed it will accurately reflect that
  61. the sum is still odd and errors will not be detected.
  62.  
  63.  
  64.      * OK, so it is a hardware problem.  Which hardware and how can I find it?
  65.  
  66. Obviously, the first thing to check is the RAM in your system.  An easy test
  67. is to disable everything that uses EMS and XMS memory so you can create a
  68. RAMDRIVE the size of all your system memory.  Then:
  69.  
  70.      a) Run CHKDSK on the RAMDRIVE, or
  71.      b) Copy files to the RAMDRIVE until it is full.
  72.  
  73. Either way, eventually you will get a parity error or a General Drive Failure
  74. on the RAMDRIVE.  The first thing you can do to try to remedy this problem is
  75. to make sure that the RAM chips are seated properly in their sockets.  If they
  76. are DRAMs or SIPPs make sure the pins aren't broken off or bent.  If they are
  77. SIMMs or the memory is on a card, you may just need to clean the contacts.  If
  78. the chips physically check out ok, the chip speeds could be mis-matched with
  79. memory that is too slow for the cpu/memory bus, or a controller chip could be
  80. bad.  At this point the only sure way to test this is to swap out the chips
  81. for ones that you know are good.
  82.  
  83. Parity errors may also be caused by the presence of an autoswitching video
  84. card or one that is using 16-bit ROM access.  Your motherboard could be
  85. assigning parity to the address space where your EMS page frame is located.
  86. Also there may be some special features of the computer in the CMOS Setup that
  87. could be causing problems.  Try disabling the computer's shadowing of BIOS or
  88. video ROM or turning off memory caching or other features to see if one of
  89. them is involved.  This may allow you to pinpoint the cause of the problem.
  90. In all these cases you should refer to the documentation that came with your
  91. hardware product to disable a particular feature.
  92.  
  93. While there are several diagnostic programs on the market that will test your
  94. memory for errors, they may not duplicate conditions that would cause marginal
  95. memory to fail, and most are not even designed to be run with a memory
  96. manager.  When parity errors are encountered, it is time to have the hardware
  97. components of the machine examined.
  98.  
  99.   ************************************************************************
  100.   *          Trademarks are property of their respective owners.         *
  101.   *This technical note may be copied and distributed freely as long as it*
  102.   *is distributed in its entirety and it is not distributed for profit.  *
  103.   *          Copyright (C) 1993 by Quarterdeck Office Systems            *
  104.   ************************ E N D   O F   F I L E *************************
  105.