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 #ifndef RTAS_H 15 #define RTAS_H 16 17 #include "of.h" 18 19 typedef struct dtime { 20 unsigned int year; 21 unsigned int month; 22 unsigned int day; 23 unsigned int hour; 24 unsigned int minute; 25 unsigned int second; 26 unsigned int nano; 27 } dtime; 28 29 typedef void (*thread_t) (int); 30 31 int rtas_token(const char *); 32 int rtas_call(int, int, int, int *, ...); 33 void rtas_init(void); 34 int rtas_pci_config_read (long long, int, int, int, int); 35 int rtas_pci_config_write (long long, int, int, int, int, int); 36 int rtas_set_time_of_day(dtime *); 37 int rtas_get_time_of_day(dtime *); 38 int rtas_ibm_update_flash_64(long long, long long); 39 int rtas_ibm_update_flash_64_and_reboot(long long, long long); 40 int rtas_system_reboot(void); 41 int rtas_start_cpu (int, thread_t, int); 42 int rtas_stop_self (void); 43 int rtas_ibm_manage_flash(int); 44 45 #endif 46