Changeset 31c14d9 in rtems for c/src/libchip/rtc


Ignore:
Timestamp:
Sep 22, 2008, 11:45:25 AM (11 years ago)
Author:
Thomas Doerfler <Thomas.Doerfler@…>
Branches:
4.10, 4.11, master
Children:
e97e0e0
Parents:
8efda6a
Message:

Include required header files. Some internal functions have now static linkage type. Added constant qualifier to operations table and read-only function parameters.

Location:
c/src/libchip/rtc
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • c/src/libchip/rtc/icm7170.c

    r8efda6a r31c14d9  
    3838 */
    3939
    40 void icm7170_initialize(
     40static void icm7170_initialize(
    4141  int minor
    4242)
     
    6161 */
    6262
    63 int icm7170_get_time(
     63static int icm7170_get_time(
    6464  int                minor,
    6565  rtems_time_of_day *time
     
    114114 */
    115115
    116 int icm7170_set_time(
     116static int icm7170_set_time(
    117117  int                minor,
    118   rtems_time_of_day *time
     118  const rtems_time_of_day *time
    119119)
    120120{
  • c/src/libchip/rtc/m48t08.c

    r8efda6a r31c14d9  
    4040 */
    4141
    42 void m48t08_initialize(
     42static void m48t08_initialize(
    4343  int minor
    4444)
     
    5353#define To_BCD( _x )   ((((_x) / 10) << 4) + ((_x) % 10))
    5454
    55 int m48t08_get_time(
     55static int m48t08_get_time(
    5656  int                minor,
    5757  rtems_time_of_day *time
     
    113113 */
    114114
    115 int m48t08_set_time(
     115static int m48t08_set_time(
    116116  int                minor,
    117   rtems_time_of_day *time
     117  const rtems_time_of_day *time
    118118)
    119119{
  • c/src/libchip/rtc/rtc.h

    r8efda6a r31c14d9  
    1616#define __LIBCHIP_RTC_h
    1717
     18#include <stdbool.h>
     19#include <stdint.h>
     20
     21#include <rtems.h>
     22
    1823/*
    1924 *  Types for get and set register routines
     
    2732  void    (*deviceInitialize)(int minor);
    2833  int     (*deviceGetTime)(int minor, rtems_time_of_day *time);
    29   int     (*deviceSetTime)(int minor, rtems_time_of_day *time);
     34  int     (*deviceSetTime)(int minor, const rtems_time_of_day *time);
    3035} rtc_fns;
    3136
     
    5156 * ulCtrlPort1  This is the primary control port number for the device.
    5257 *
    53  * ulCtrlPort2  This is the secondary control port number.
    54  *
    5558 * ulDataPort   This is the port number for the data port of the device
    5659 *
     
    6164
    6265typedef struct _rtc_tbl {
    63   char          *sDeviceName;
     66  const char    *sDeviceName;
    6467  rtc_devs       deviceType;
    65   rtc_fns      *pDeviceFns;
     68  const rtc_fns *pDeviceFns;
    6669  bool           (*deviceProbe)(int minor);
    6770  void          *pDeviceParams;
Note: See TracChangeset for help on using the changeset viewer.