Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 18 Feb 1999 16:03:14 -0600 (CST)
From:      Kevin Day <toasty@home.dragondata.com>
To:        beko@max.sknet.sk (Pavol Beko)
Cc:        freebsd-hardware@FreeBSD.ORG
Subject:   Re: Accessing I/O ports
Message-ID:  <199902182203.QAA07420@home.dragondata.com>
In-Reply-To: <01BE5B8E.8CA28F60@Dialup24.sknet.sk> from Pavol Beko at "Feb 18, 1999 10:31:44 pm"

next in thread | previous in thread | raw e-mail | index | archive | help
> Hi,
> I'm new in programing under FreeBSD. I tried to write a simple program which will
> shut down my hard drive, but program ended up with signal 10 (SIGBUS).
> Shuting down the first IDE hard drive is accomplished by sending to I/O port 0x1f7
> value 0x99 trough outb() (from /machine/cpufunc.h) function. The same situation is
> when I try to access CMOS trough 0x70 and 0x71 I/O ports. There was no problem 
> with this under 'other' OS.
> What went wrong? Is there some part of kernel (some syscall) which is responsible 
> for handling  these low level operation?
> (machine is 486, EIDE HDs, FreeBSD 2.2.8)
> Thanks
> 
> 		Pavol
> 
> 
> 
> To Unsubscribe: send mail to majordomo@FreeBSD.org
> with "unsubscribe freebsd-hardware" in the body of the message
> 

Try opening /dev/io first, then see if you have better luck.


Kevin


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-hardware" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199902182203.QAA07420>