Subject: port-i386/1085: minor bug in disklabel code.
To: None <gnats-admin@sun-lamp.cs.berkeley.edu>
From: James Jegers <jimj@enigma.cs.uwm.edu>
List: netbsd-bugs
Date: 05/29/1995 23:50:05
>Number:         1085
>Category:       port-i386
>Synopsis:       disklabel code looks at bad args.
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    gnats-admin (GNATS administrator)
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Mon May 29 23:50:03 1995
>Originator:     James Jegers
>Organization:
	
>Release:        5/25/95<NetBSD-current source date>
>Environment:
	
System: NetBSD enigma.cs.uwm.edu 1.0A NetBSD 1.0A (ENIGMA) #0: Wed Apr 19 22:19:50 CDT 1995 jimj@enigma.cs.uwm.edu:/usr/src/sys/arch/i386/compile/ENIGMA i386


>Description:
	

  There looks like there is a bug in the floppy/disklabel code.

  In fd.c in the ioctl routine it calls  readdisklabel and writedisklabel
  with the fourth arguement being a NULL.  In the actuall readdisklabel
  code it uses the fourth arguement as..

  readdisklabel(a, b, c, d)
  {
  	something = d->dospart;
  	if (something)

  Assumeing page 0 contains all zero's this shouldn't be a problem.
  Does NetBSD/i386 unmap page 0 in the kernel space to cause page
  faults if someone is accessing it, like in userland?

>How-To-Repeat:
	
>Fix:
	
>Audit-Trail:
>Unformatted: