summaryrefslogtreecommitdiffstats
path: root/sys/i386/include/bus.h
Commit message (Collapse)AuthorAgeFilesLines
* Revert r243960 based on feedback regarding keeping x86 headers unifiedjimharris2012-12-131-22/+0
| | | | | | (mdf@, tijl@) and use of KASSERT/systm.h in bus.h (zeising@, bde@). Alternate implementation will be made in a separate commit.
* Add amd64 implementations for 8-byte bus_space routines.jimharris2012-12-061-0/+22
| | | | | | | Submitted by: Carl Delsey <carl.r.delsey@intel.com> Discussed with: jhb, rwatson Reviewed by: jimharris MFC after: 1 week
* Merge amd64 and i386 bus.h and move the resulting header to x86. Replacetijl2010-12-201-1161/+3
| | | | | | | | | the original amd64 and i386 headers with stubs. Rename (AMD64|I386)_BUS_SPACE_* to X86_BUS_SPACE_* everywhere. Reviewed by: imp (previous version), jhb Approved by: kib (mentor)
* Revert r216134. This checkin broke platforms where bus_space are macros:brucec2010-12-031-24/+12
| | | | | they need to be a single statement, and do { } while (0) doesn't work in this situation so revert until a solution can be devised.
* Disallow passing in a count of zero bytes to the bus_space(9) functions.brucec2010-12-021-12/+24
| | | | | | | | | Passing a count of zero on i386 and amd64 for [I386|AMD64]_BUS_SPACE_MEM causes a crash/hang since the 'loop' instruction decrements the counter before checking if it's zero. PR: kern/80980 Discussed with: jhb
* Fix -Wundef warnings found when compiling i386 LINT, GENERIC andru2005-12-051-1/+1
| | | | custom kernels.
* Remove bus_{mem,p}io.h and related code for a micro-optimization on i386nyan2005-05-291-280/+42
| | | | | | and amd64. The optimization is a trivial on recent machines. Reviewed by: -arch (imp, marcel, dfr)
* Break out the definition of bus_space_{tag,handle}_t and a few other typesimp2005-04-181-16/+1
| | | | | | | | | | into _bus.h to help with name space polution from including all of bus.h. In a few days, I'll commit changes to the MI code to take advantage of thse sepration (after I've made sure that these changes don't break anything in the main tree, I've tested in my trees, but you never know...). Suggested by: bde (in 2002 or 2003 I think) Reviewed in principle by: jhb
* With pc98/include, we can have pc98 and i386 specific bus spaceimp2005-04-031-5/+1312
| | | | | implementations in their own files named $MACHINE/include/bus.h. Copy the contents appropriately.
* Add the following functions/macros to support byte order conversions andtmm2002-02-271-0/+64
| | | | | | | | | | | | | | | | | | | | | | | | device drivers for bus system with other endinesses than the CPU (using interfaces compatible to NetBSD): - bwap16() and bswap32(). These have optimized implementations on some architectures; for those that don't, there exist generic implementations. - macros to convert from a certain byte order to host byte order and vice versa, using a naming scheme like le16toh(), htole16(). These are implemented using the bswap functions. - stream bus space access functions, which do not perform a byte order conversion (while the normal access functions would if the bus endianess differs from the CPU endianess). htons(), htonl(), ntohs() and ntohl() are implemented using the new functions above for kernel usage. None of the above interfaces is currently exported to user land. Make use of the new functions in a few places where local implementations of the same functionality existed. Reviewed by: mike, bde Tested on alpha by: mike
* - Moved the bus_dma declarations from bus_{at386,pc98}.h into bus_dma.h.nyan2001-10-061-0/+1
| | | | | (bus_dma.h is repo-copied from bus_at386.h) - Added '#include <machine/bus_dma.h>' into bus.h for backward compatibility.
* Added indirect pio into the bus space stuff for the NEC PC-98. bus.hkato2000-03-291-1263/+17
| | | | | | | | | | | includes one of bus_at386.h and bus_pc98.h. Becuase only bus_pc98.h supports indirect pio and bus_at386.h is identical to old bus.h, there is no functional change in PC-AT's kernels. That is, it cannot cause performance loss. Submitted by: nyan Reviewed by: imp bde and luoqi provided useful comments for earlier version.
* Fix clobbers so that GENERIC may compile with GCC 2.95.2.obrien1999-11-141-83/+84
| | | | | | | | | | | | | | | | | | | | Historically, the documentation of extended asm was lacking, namely you should NOT specify the same register as an input, and a clobber. If the register is clobbered, it should be specified as an output as well, e.g., by linking input and output through the "number" notation. (Beware of lvalues, some local variables needed...) URL:http://egcs.cygnus.com/faq.html In versions up to egcs-1.1.1, the compiler did not even warn about it, but it was liable to output bad code. Newer egcs are pickier and simply refuse to swallow such code. Note, since *addr changes, it needs to be an output operand. We might be excessive in saying that all memory has changed. Obtained from: OpenBSD w/extra thanks to Marc Espie <Marc.Espie@liafa.jussieu.fr>
* $Id$ -> $FreeBSD$peter1999-08-281-1/+1
|
* Improve compatibility with other systems by changing the defaultimp1999-07-031-1/+10
| | | | | | | | | | | | | | | | | | | | | behavior slightly. If machine/bus.h is included, but neither bus_memio.h nor bus_pio.h are included, then behave as if both were included. This won't change existing drivers, all of which include one or more of bus_{p,mem}io.h, but will allow drivers from other systems to come over with fewer changes. I freely admit that this might not be optimal for some drivers, but those drivers can be optimized for FreeBSD after the initial bringup happens. Without the change, there is a bug that preclude drivers from compiling with strange warning/errors. I've been running this here for a while now w/o ill effects. Reviewed by: gibbs Not objected to by: bde, arch@ list.
* Don't pretend to support ix86's with 16-bit ints by using longs justbde1998-09-291-4/+4
| | | | to ensure 32-bit variables. Doing so broke ix86's with 64-bit longs.
* Implement bus_dmamem_* functions and correct a few nits reported by Peter Wemm.gibbs1998-05-061-10/+27
|
* Support compiling with `gcc-pedantic' (don't use hard newlines inbde1998-04-191-74/+74
| | | | (asm) string constants or trailing commas in enum declarations).
* Implementation of Bus Space for FreeBSD-x86.gibbs1998-01-151-0/+1264
Obtained From: NetBSD
OpenPOWER on IntegriCloud