ATM Switch WUGS - PowerPoint PPT Presentation

1 / 36
About This Presentation
Title:

ATM Switch WUGS

Description:

PIC. RTC' BIOS ROM. UART1 Interface. UART2 Interface. UART1 ... Programmable Interrupt Controller (PIC) Four Interrupts supported and statically assigned: ... – PowerPoint PPT presentation

Number of Views:275
Avg rating:3.0/5.0
Slides: 37
Provided by: myweb1
Category:
Tags: atm | wugs | pic | switch

less

Transcript and Presenter's Notes

Title: ATM Switch WUGS


1
ATM Switch WUGS
  • Darron Yi Zhang

2
Topics of Discussion
  • Overview of WUGS
  • SPC Hardware
  • SPC Software
  • SPC Utility

3
Motivation
  • Active Networking
  • Network Probe
  • High performance router
  • PC as router is VERY limited
  • (Gigabit/s Processing) on each port

4
WUGS-20 Packaging
5
Overview of WUGS
6
Overview of WUGS(continued)
7
  • Smart Port Card
  • Hardware

8
The Smart Port Card
  • Hardware
  • SPC as a PC
  • How do they each boot?
  • SPC Hardware Components
  • What roles do they play?

9
Typical Pentium PC
CPU/Memory Bus
Addr/Data
Ctrl
Ctrl
CPU
North- Bridge
Cache
DRAM
Addr/Data/Ctrl
PCI Bus
Intr
NMI
INIT
SouthBridge (PIIX3) (PIC, PIT, )
PCI Devices
ISA Bus
ISA Devices
BIOS
Super-IO
BIOS
RTC Uarts Kbd/Mse Floppy Parallel ...
10
How NetBSD Boots on a PC
  • Components
  • Pentium
  • Boot ROM (replaced by BIOS in modern systems)
  • BIOS
  • Bootloader
  • Kernel

11
What SPC Needs
CPU/Memory Bus
12
SPC Architecture
Addr/Data
Ctrl
Ctrl
CPU
North- Bridge
Cache
DRAM
Addr/Data/Ctrl
PCI Bus
NMI
INIT
Intr
APIC
PIT
PIC
RTC
UART1 Interface
BIOS ROM
Link Interface
UART2 Interface
Switch Interface
13
SPC Photo
Switch Interface
DRAM
Link Interface
CPU Module
APIC
PCI Bus
System FPGA
Serial Ports
14
SPC Components
  • APIC
  • PCI Bus Master
  • Pentium Embedded Module
  • 166 MHz MMX Pentium Processor
  • L1 Cache 16KB Data, 16KB Code
  • L2 cache 512 KB
  • NorthBridge - 33 MHz, 32 bit PCI Bus
  • PCI Bus Master
  • System FPGA
  • PCI Bus Slave
  • Xilinx XC4020XLA-1 FPGA
  • 20K Equivalent Gates
  • 75 used

15
SPC Components (continued)
  • Memory
  • EDO DRAM
  • 64MB (Max for current design)
  • Switch Interface - 1 Gb Utopia
  • Link Interface - 1 Gb Utopia
  • UART
  • Two Serial Ports
  • NetBSD system console
  • TTY port

16
System FPGA
  • Coded in VHDL
  • PCI slave device
  • Replaces some of the PIIX3 (south bridge)
  • Replaces some of the BIOS
  • Replaces some of the Super IO Chip
  • Provides reset capability

17
System FPGA PIIX3 Functionality
  • Programmable Interrupt Controller (PIC)
  • Four Interrupts supported and statically
    assigned
  • PIT (IRQ 0)
  • APIC (IRQ 5)
  • COM1 (IRQ 4)
  • COM2 (IRQ 3)
  • Static fully-nested interrupt priority structure.
  • Specific End of Interrupt is the only EOI mode
    supported
  • Programmable Interval Timer (PIT)
  • generates a clock interrupt for NetBSD every
    10ms
  • Reset - covered in a later slide

18
System FPGA BIOS Functionality
  • Interrupt functionality replaced by static values
  • Simple 16 word by 32-bit ROM
  • implements loop waiting for location 0xFFE00 to
    change value
  • then jumps to boot loader code

19
System FPGA Super IO Chip Functionality
  • UART Interface
  • Two Serial lines supported
  • Fixed IRQs
  • Real Time Clock
  • only the register accesses of the RTC are
    supported
  • no interrupts supported

20
System FPGA Reset
  • SPC needs a reset before every download
  • switch reset
  • causes SPC to be reset
  • causes all connections in switch to be lost
  • System FPGA reset
  • causes SPC to be reset
  • has no effect on the switch
  • Normal SouthBridge reset
  • I/O Register 0xCF9
  • Hard Reset assert CPURST, PCIRST, and RSTDRV
  • write 0xCF9 0x02 (00000010b)
  • write 0xCF9 0x06 (00000110b)
  • Soft Reset assert INIT
  • write 0xCF9 0x00 (00000000b)
  • write 0xCF9 0x04 (00000100b)

21
System FPGA Reset
  • SPC Reset
  • a sequence of two writes to memory addresses
  • APIC Control cells can write to
  • memory addresses
  • configuration registers
  • NOT I/O Registers! Argh...
  • To mimic the reset structure of the SB we use
  • 0xFFFFFFF0
  • 0xFFFFFFF4
  • Hard Reset (all we really care about)
  • write 0xFFFFFFF0 0x02 (00000010b)
  • write 0xFFFFFFF4 0x06 (00000110b)

bits
22
  • Smart Port Card
  • Software

23
Software Overview
  • SPC Specific Kernel Modifications
  • Building a Kernel
  • config
  • compile
  • Loading Kernel onto SPC to execute it
  • download via APIC
  • Initiating Kernel execution
  • boot loader
  • Configuring Devices
  • APIC

24
The Download Process
0x0
Bootloader
RESET
0x03FC
0 0 0 0 0 0 0 0
0 0 0 0 0 0 0 1
Download Program
0x0FFE00
0 0 0 0 0 0 0 0
0 0 0 0 0 0 0 1
0x0100000
Kernel
0xFFFFFFF0
Boot ROM
25
  • SPC Utilities

26
Utilities - Overview
  • Purpose of SPC Utilities
  • glue between various software components
  • simplify other parts of the system
  • solve miscellaneous problems encountered
  • Utilities that are still useful
  • mkimg - make image
  • mknl - make namelist

27
mkimg - overview
  • Creates a kernel image suitable for downloading
    to the SPC
  • Removes some of the burden from the bootloader

28
Kernel Image
On Disk
  • This is what the NetBSD kernel in a.out format
    looks like on the disk
  • e.g. the file /netbsd on most systems

29
Kernel Image
  • This is what the kernel image looks like when
    loaded into memory.
  • Whats different?
  • BSS segment has been inserted in the middle.

In Memory (as loaded by bootloader)
On Disk (e.g. the file /netbsd)
30
mkimg - summary
  • Kernel requires BSS segment for execution.
  • Normal PC done at boot time (by the bootloader)
  • SPC done by mkimg, after kernel build
  • mkimg creates a copy of the kernel file with the
    BSS segment included.
  • mkimg is invoked by make from the mk.3 script

31
mknl - purpose
  • Certain system tools need a kernel namelist
  • ps, netstat, top, uptime, etc.
  • Normally, this is read from kernel file (/netbsd)
  • Problem kernel too large to fit on filesystem
  • Solution
  • create a file that we can put on the filesystem,
    to hold the namelist information
  • file should look as much like the real kernel as
    possible

32
Kernel Image
On Disk (e.g. the file /netbsd)
  • mknl utility
  • input kernel in a.out format
  • output the symbols only file
  • approach
  • open input and output files
  • copy exec header
  • lseek past text and data segments
  • copy symbol table and string table
  • close files

33
a file with a hole
  • mknl creates a file with a hole
  • unneeded blocks are not allocated
  • Example of a file with a hole

block array for the file
disk block
disk block
null
null
null
null
disk block
disk block
. . .
34
output from mknl
Output file from mknl
exec header
hole (used to be text segment)
  • This is what the symbols-only netbsd file looks
    like
  • This is what we put into our filesystem as
    /netbsd
  • Doesnt require much space
  • typically around 150kB
  • Example from a 24MB kernel

hole (used to be initialized data)
symbol table
string table
152 -rw-r--r-- 1 root wheel 24624114 /netbsd
35
mknl - implications
  • Implication of a files with holes
  • Copying can produce undesirable results holes
    look like blocks full of zeroes...
  • new file will be as large as the original kernel
  • defeats purpose of mknl
  • Need to mknl directly into the filesystem.
  • Need to mknl after any changes are made to the
    kernel.

36
  • Thank you!!!
Write a Comment
User Comments (0)
About PowerShow.com