~pmdj/ubuntu/trusty/qemu/2.9+applesmc+fadtv3

« back to all changes in this revision

Viewing changes to roms/SLOF/clients/net-snk/libc/time/ftime.c

  • Committer: Phil Dennis-Jordan
  • Date: 2017-07-21 08:03:43 UTC
  • mfrom: (1.1.1)
  • Revision ID: phil@philjordan.eu-20170721080343-2yr2vdj7713czahv
New upstream release 2.9.0.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/******************************************************************************
 
2
 * Copyright (c) 2004, 2008 IBM Corporation
 
3
 * All rights reserved.
 
4
 * This program and the accompanying materials
 
5
 * are made available under the terms of the BSD License
 
6
 * which accompanies this distribution, and is available at
 
7
 * http://www.opensource.org/licenses/bsd-license.php
 
8
 *
 
9
 * Contributors:
 
10
 *     IBM Corporation - initial implementation
 
11
 *****************************************************************************/
 
12
 
 
13
 
 
14
#include <time.h>
 
15
#include <rtas.h>
 
16
#include <stdio.h>
 
17
 
 
18
time_t
 
19
time(time_t *tod)
 
20
{
 
21
        dtime ts;
 
22
 
 
23
        rtas_get_time_of_day(&ts);
 
24
        printf("debug!!\n");
 
25
        
 
26
        printf("year  : %d\n", ts.year);
 
27
        printf("month : %d\n", ts.month);
 
28
        printf("day   : %d\n", ts.day);
 
29
        printf("hour  : %d\n", ts.hour);
 
30
        printf("minute: %d\n", ts.minute);
 
31
        printf("second: %d\n", ts.second);
 
32
        printf("nano  : %d\n", ts.nano);
 
33
        printf("debug ende\n");
 
34
 
 
35
//      if(tod)
 
36
//              *tod = t;
 
37
        return 0;
 
38
}