Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 29 Jun 1998 14:42:25 -0400 (EDT)
From:      zhihuizhang <bf20761@binghamton.edu>
To:        hackers <freebsd-hackers@FreeBSD.ORG>
Subject:   Interrupt Handling and inline assembly
Message-ID:  <Pine.SOL.L3.93.980629141418.18359A-100000@bingsun2>

next in thread | raw e-mail | index | archive | help

I got two questions:

(1) I read in the MailingList Archive that the interrupt blocking in
FreeBSD is software-based, we do not communicate with 8259 (which I think
is slower)  What is the advantage of doing this besides being faster?  If
we mask interrupts off (by cli or setting the IMR register in 8259), will
interrupts be simply discarded (the device has to request interrupt
again) or postponed by 8259?

(2) I am reading the source code in cpufunc.h:

	static __inline void
	setbits(volatile unsigned * addr, u_int bits)
	{
		__asm __volatile("orl %1, %0" : "=m" (*addr): "ir"(bits));
	} 

I have read a text on inline assembly at: 

	http://www.rt66.com/~brennan/djgpp/djgpp_asm.html

But I still do not understand the meaining of "m" and "ir". 

Thanks a lot.

-------------------------------------------------

Zhihui Zhang

Department of Computer Science
State University of New York at Binghamton

Web Site: http://cs.binghamton.edu/~zzhang

-------------------------------------------------




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



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.SOL.L3.93.980629141418.18359A-100000>