misc: Small cleanup
authorMichel Pollet <buserror@gmail.com>
Wed, 6 Jan 2010 22:37:50 +0000 (22:37 +0000)
committerMichel Pollet <buserror@gmail.com>
Wed, 6 Jan 2010 22:47:18 +0000 (22:47 +0000)
Removed mutiple defined constants etc

Signed-off-by: Michel Pollet <buserror@gmail.com>
simavr/sim/avr_flash.c
simavr/sim/avr_uart.c
simavr/sim/avr_uart.h

index 05f3e87..fd0609a 100644 (file)
@@ -92,7 +92,7 @@ static        avr_io_t        _io = {
 void avr_flash_init(avr_t * avr, avr_flash_t * p)
 {
        p->io = _io;
-       printf("%s init SPM %04x\n", __FUNCTION__, p->r_spm);
+//     printf("%s init SPM %04x\n", __FUNCTION__, p->r_spm);
 
        avr_register_io(avr, &p->io);
        avr_register_vector(avr, &p->flash);
index 7fdb353..ee306da 100644 (file)
@@ -34,7 +34,7 @@ static avr_cycle_count_t avr_uart_txc_raise(struct avr_t * avr, avr_cycle_count_
 {
        avr_uart_t * p = (avr_uart_t *)param;
        if (avr_regbit_get(avr, p->txen)) {
-               // if the interrupts are not used, still raised the UDRE and TXC flaga
+               // if the interrupts are not used, still raised the UDRE and TXC flag
                avr_raise_interrupt(avr, &p->udrc);
                avr_raise_interrupt(avr, &p->txc);
        }
@@ -190,9 +190,6 @@ void avr_uart_reset(struct avr_io_t *io)
 
 }
 
-#define AVR_IOCTL_UART_SET_FLAGS(_name)        AVR_IOCTL_DEF('u','a','s',(_name))
-#define AVR_IOCTL_UART_GET_FLAGS(_name)        AVR_IOCTL_DEF('u','a','g',(_name))
-
 static int avr_uart_ioctl(struct avr_io_t * port, uint32_t ctl, void * io_param)
 {
        avr_uart_t * p = (avr_uart_t *)port;
@@ -213,7 +210,6 @@ static int avr_uart_ioctl(struct avr_io_t * port, uint32_t ctl, void * io_param)
        return res;
 }
 
-
 static avr_io_t        _io = {
        .kind = "uart",
        .reset = avr_uart_reset,
index 283f7e0..1d8c725 100644 (file)
@@ -38,7 +38,7 @@ DECLARE_FIFO(uint8_t, uart_fifo, 64);
  * you to "pause" sending it bytes when it's own input buffer is full.
  * So, the UART will send XON to you when it's fifo is empty, XON means you can
  * send as many bytes as you have until XOFF is send. Note that these are two
- * IRQs because you /will/ be caused with XOFF when sending a byte in INPUT...
+ * IRQs because you /will/ be called with XOFF when sending a byte in INPUT...
  * So it's a reentrant process.
  *
  * When XOFF has been called, do not send any new bytes, they would be dropped.