11590Srgrimes/* 21590Srgrimes * Copyright 2018, Data61 31590Srgrimes * Commonwealth Scientific and Industrial Research Organisation (CSIRO) 41590Srgrimes * ABN 41 687 119 230. 51590Srgrimes * 61590Srgrimes * This software may be distributed and modified according to the terms of 71590Srgrimes * the BSD 2-Clause license. Note that NO WARRANTY is provided. 81590Srgrimes * See "LICENSE_BSD2.txt" for details. 91590Srgrimes * 101590Srgrimes * @TAG(DATA61_BSD) 111590Srgrimes */ 121590Srgrimes#pragma once 131590Srgrimes 141590Srgrimes#define HARDWARE_SERIAL_INTERFACES \ 151590Srgrimes uses IOPort serial_port; \ 161590Srgrimes consumes Irq4 serial_irq; 171590Srgrimes 181590Srgrimes#define HARDWARE_SERIAL_ATTRIBUTES 191590Srgrimes 201590Srgrimes#define HARDWARE_SERIAL_COMPOSITION \ 211590Srgrimes component Serial hw_serial; \ 221590Srgrimes connection seL4HardwareIOPort serial_ioport(from serial_port, to hw_serial.serial); \ 231590Srgrimes connection seL4HardwareInterrupt serial_irq(from hw_serial.serial_irq, to serial_irq); \ 241590Srgrimes 251590Srgrimes#define HARDWARE_SERIAL_CONFIG \ 261590Srgrimes hw_serial.serial_attributes <- serial_attributes; \ 271590Srgrimes hw_serial.serial_irq_irq_type <- serial_irq_irq_type; \ 281590Srgrimes hw_serial.serial_irq_irq_ioapic <- serial_irq_irq_ioapic; \ 291590Srgrimes hw_serial.serial_irq_irq_ioapic_pin <- serial_irq_irq_ioapic_pin; \ 301590Srgrimes hw_serial.serial_irq_irq_vector <- serial_irq_irq_vector; 311590Srgrimes