Ignore:
Timestamp:
2021-10-24T08:28:43Z (2 years ago)
Author:
GitHub <noreply@…>
Children:
fcb4e15
Parents:
2ce943a (diff), cd981f2a (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the (diff) links above to see all the changes relative to each parent.
git-author:
Erik Kučák <35500848+Riko196@…> (2021-10-24 08:28:43)
git-committer:
GitHub <noreply@…> (2021-10-24 08:28:43)
Message:

Merge branch 'HelenOS:master' into master

File:
1 edited

Legend:

Unmodified
Added
Removed
  • kernel/genarch/include/genarch/drivers/ns16550/ns16550.h

    r2ce943a r8a9a41e  
    4343#include <console/chardev.h>
    4444
    45 #define IER_ERBFI  0x01  /** Enable Receive Buffer Full Interrupt. */
     45#define NS156440_CLOCK    115200 /** Internal clock speed, max. baud rate. */
    4646
    47 #define LCR_DLAB   0x80  /** Divisor Latch Access bit. */
     47#define IER_ERBFI         0x01   /** Enable Receive Buffer Full Interrupt. */
     48#define MCR_OUT2          0x08   /** OUT2. */
    4849
    49 #define MCR_OUT2   0x08  /** OUT2. */
     50#define LCR_DLAB          0x80   /** Divisor Latch Access bit. */
     51#define LCR_SBE           0x40   /** RS-232 Break Signal bit. */
     52
     53#define LCR_PARITY_NONE   0x00   /** No parity bit. */
     54#define LCR_PARITY_ODD    0x08   /** Odd parity. */
     55#define LCR_PARITY_EVEN   0x18   /** Even parity. */
     56#define LCR_PARITY_MARK   0x28   /** Parity bit always one. */
     57#define LCR_PARITY_SPACE  0x38   /** Parity bit always zero. */
     58
     59#define LCR_STOP_BIT_ONE  0x00   /** One stop bit. */
     60#define LCR_STOP_BIT_TWO  0x04   /** Two stop bits. */
     61
     62#define LCR_WORD_LEN_5    0x00   /** 5-bit word length. */
     63#define LCR_WORD_LEN_6    0x01   /** 6-bit word length. */
     64#define LCR_WORD_LEN_7    0x02   /** 7-bit word length. */
     65#define LCR_WORD_LEN_8    0x03   /** 8-bit word length. */
    5066
    5167/** NS16550 registers. */
     
    5369        NS16550_REG_RBR = 0,  /**< Receiver Buffer Register (read). */
    5470        NS16550_REG_THR = 0,  /**< Transmitter Holder Register (write). */
     71        NS16550_REG_DLL = 0,  /**< Baud rate divisor latch low byte (write). */
    5572        NS16550_REG_IER = 1,  /**< Interrupt Enable Register. */
     73        NS16550_REG_DLH = 1,  /**< Baud rate divisor latch high byte (write). */
    5674        NS16550_REG_IIR = 2,  /**< Interrupt Ident Register (read). */
    5775        NS16550_REG_FCR = 2,  /**< FIFO control register (write). */
     
    7391extern ns16550_instance_t *ns16550_init(ioport8_t *, unsigned, inr_t, cir_t,
    7492    void *, outdev_t **);
     93extern void ns16550_format_set(ns16550_instance_t *, unsigned, uint8_t);
    7594extern void ns16550_wire(ns16550_instance_t *, indev_t *);
    7695
Note: See TracChangeset for help on using the changeset viewer.