Changeset f3a66a3 in rtems


Ignore:
Timestamp:
Oct 16, 2014, 8:12:34 PM (5 years ago)
Author:
Joel Sherrill <joel.sherrill@…>
Branches:
4.11, master
Children:
2681fc4
Parents:
0b51575
git-author:
Joel Sherrill <joel.sherrill@…> (10/16/14 20:12:34)
git-committer:
Joel Sherrill <joel.sherrill@…> (10/19/14 22:00:56)
Message:

mips/hurricane: Fix warnings

Location:
c/src/lib/libbsp/mips/hurricane
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • c/src/lib/libbsp/mips/hurricane/console/console.c

    r0b51575 rf3a66a3  
    11/*
    22 *  This file contains the IDT 4650 console IO package.
    3  *
     3 */
     4
     5/*
    46 *  Author:     Craig Lebakken <craigl@transition.com>
    57 *
     
    3234
    3335/* PMON entry points */
    34 int mon_read(int fd, char *buf, int cnt);               /* stdin is fd=0 */
    35 int mon_write(int fd, char *buf, int cnt);              /* stdout is fd=1 */
     36int mon_read(int fd, char *buf, int cnt);    /* stdin is fd=0 */
     37int mon_write(int fd, char *buf, int cnt);    /* stdout is fd=1 */
    3638
    3739/*  console_initialize
     
    4547 *  Return values:
    4648 */
    47 
    4849rtems_device_driver console_initialize(
    4950  rtems_device_major_number  major,
     
    6667}
    6768
    68 
    69 /*  is_character_ready
    70  *
    71  *  This routine returns TRUE if a character is available.
    72  *
    73  *  Input parameters: NONE
    74  *
    75  *  Output parameters:  NONE
    76  *
    77  *  Return values:
    78  */
    79 
    80 bool is_character_ready(
    81   char *ch
    82 )
    83 {
    84   *ch = '\0';   /* return NULL for no particular reason */
    85   return true;
    86 }
    87 
    8869/*  inbyte
    8970 *
    9071 *  This routine reads a character from the SOURCE.
    91  *
    92  *  Input parameters: NONE
    93  *
    94  *  Output parameters:  NONE
    95  *
    96  *  Return values:
    97  *    character read from SOURCE
    98  */
    99 
    100 char inbyte( void )
    101 {
    102         char buf[10];
     72 */
     73static char inbyte( void )
     74{
     75  char buf[10];
     76
    10377  /*
    10478   *  If polling, wait until a character is available.
    10579   */
    106 
    107         mon_read(0, buf, 1);            /* stdin is fd=0, read 1 byte */
    108 
    109         return (buf[0]);
     80  mon_read(0, buf, 1);    /* stdin is fd=0, read 1 byte */
     81
     82  return (buf[0]);
    11083}
    11184
     
    11487 *  This routine transmits a character out the SOURCE.  It may support
    11588 *  XON/XOFF flow control.
    116  *
    117  *  Input parameters:
    118  *    ch  - character to be transmitted
    119  *
    120  *  Output parameters:  NONE
    121  */
    122 
    123 void outbyte(
     89 */
     90static void outbyte(
    12491  char ch
    12592)
    12693{
    127         char buf[10];
     94  char buf[10];
    12895  /*
    12996   *  If polling, wait for the transmitter to be ready.
     
    13198   *  Then output the character.
    13299   */
    133         buf[0] = ch;
    134 
    135         mon_write( 1, buf, 1 );         /* stdout is fd=1, write 1 byte */
    136 }
    137 
    138 
    139 #if 0
    140 static int console_fd = -1;
    141 #endif
     100  buf[0] = ch;
     101
     102  mon_write( 1, buf, 1 );    /* stdout is fd=1, write 1 byte */
     103}
    142104
    143105/*
     
    151113)
    152114{
    153 #if 0
    154   int console_fd = open("tty0", 2); /* open for read/write */
    155 #endif
    156115  return RTEMS_SUCCESSFUL;
    157116}
     
    167126)
    168127{
    169 #if 0
    170   if ( console_fd )
    171     close( console_fd );
    172 #endif
    173128  return RTEMS_SUCCESSFUL;
    174129}
     
    177132 * read bytes from the serial port. We only have stdin.
    178133 */
    179 
    180134rtems_device_driver console_read(
    181135  rtems_device_major_number major,
     
    209163 * write bytes to the serial port. Stdout and stderr are the same.
    210164 */
    211 
    212165rtems_device_driver console_write(
    213166  rtems_device_major_number major,
     
    240193 *  IO Control entry point
    241194 */
    242 
    243195rtems_device_driver console_control(
    244196  rtems_device_major_number major,
     
    252204#include <rtems/bspIo.h>
    253205
    254 void hurricane_output_char(char c) { outbyte( c ); }
     206static void hurricane_output_char(char c) { outbyte( c ); }
    255207
    256208BSP_output_char_function_type           BSP_output_char = hurricane_output_char;
  • c/src/lib/libbsp/mips/hurricane/include/bsp.h

    r0b51575 rf3a66a3  
    11/**
    22 *  @file
    3  * 
    43 */
    54
     
    1514#ifndef _BSP_H
    1615#define _BSP_H
     16
     17#ifndef ASM
    1718
    1819#ifdef __cplusplus
     
    6768#define RAM_END   0x100000
    6869
     70/*
     71 * Prototypes for methods called from .S for dependency tracking
     72 */
     73void init_tlb(void);
     74void resettlb(int i);
     75
    6976#ifdef __cplusplus
    7077}
    7178#endif
    7279
     80#endif /* !ASM */
     81
    7382#endif  /* __HURRICANE_BSP_h */
  • c/src/lib/libbsp/mips/hurricane/start/start.S

    r0b51575 rf3a66a3  
    3434#include <rtems/asm.h>
    3535
     36#include <bsp.h>
    3637
    3738#if 0
  • c/src/lib/libbsp/mips/hurricane/startup/inittlb.c

    r0b51575 rf3a66a3  
     1#include <bsp.h>
    12#include <rtems/mips/idtcpu.h>
    2 
    3 extern void resettlb( int i );
    43
    54void init_tlb(void)
Note: See TracChangeset for help on using the changeset viewer.