HOW DOES THE PROCESSOR TALK TO THE DEVICE? Processor Memory Bus Regular Memory CPU Bus Bus Adaptor Adaptor Device Address+ Controller Other Devices Data Bus Hardware Interrup or Buses Controlle Interfade Controller Interrupt Request read write Addressable 0 CPU interacts with a Controller control Memory Contains a set of registers that status and/or can be read and written Registers Queues 0 May contain memory for request (por叶0x Memory Mapped queues or bit-mapped images Beaian:0x8f008020 o Regardless of the complexity of the connections and buses, processor accesses registers in two ways: I/O instructions:in/out instructions o Example from the Intel architecture:out 0x21,AL Memory mapped I/O:load/store instructions o Registers/memory appear in physical address space o I/O accomplished with load and store instructions
Device Controller read write control status Addressable Memory and/or Registers Queues (port 0x20) Hardware Controller Memory Mapped Region: 0x8f008020 Bus Interface HOW DOES THE PROCESSOR TALK TO THE DEVICE? CPU interacts with a Controller Contains a set of registers that can be read and written May contain memory for request queues or bit-mapped images Regardless of the complexity of the connections and buses, processor accesses registers in two ways: I/O instructions: in/out instructions Example from the Intel architecture: out 0x21,AL Memory mapped I/O: load/store instructions Registers/memory appear in physical address space I/O accomplished with load and store instructions Address+ Data Interrupt Request Processor Memory Bus CPU Regular Memory Interrupt Controller Bus Adaptor Bus Adaptor Other Devices or Buses
MEMORY-MAPPED DISPLAY CONTROLLER EXAMPLE o Memory-Mapped: Hardware maps control registers and display memory to physical address 0x80020000 Graphics space o Addresses set by hardware jumpers or Command programming at boot time Queue Simply writing to display memory (also 0x80010000 called the "frame buffer")changes image Display on screen Memory oAddr:0x8000F000-0x8000FFFF 0x8000F000 Writing graphics description to command-queue area o Say enter a set of triangles that describe 0x0007F004 Command some scene Addr:0x80010000-0x8001FFFF 0x0007F000 Status Writing to the command register may cause on-board graphics hardware to do something o Say render the above scene 。Addr:0x0007F004 Physical Address o Can protect with page tables Space
MEMORY-MAPPED DISPLAY CONTROLLER EXAMPLE Memory-Mapped: Hardware maps control registers and display memory to physical address space Addresses set by hardware jumpers or programming at boot time Simply writing to display memory (also called the “frame buffer”) changes image on screen Addr: 0x8000F000—0x8000FFFF Writing graphics description to command-queue area Say enter a set of triangles that describe some scene Addr: 0x80010000—0x8001FFFF Writing to the command register may cause on-board graphics hardware to do something Say render the above scene Addr: 0x0007F004 Can protect with page tables Display Memory 0x8000F000 0x80010000 Physical Address Space 0x0007F000 Status 0x0007F004 Command Graphics Command Queue 0x80020000