summaryrefslogtreecommitdiffstats
path: root/qemu/roms/SLOF/slof/fs/rtas
diff options
context:
space:
mode:
authorRajithaY <rajithax.yerrumsetty@intel.com>2017-04-25 03:31:15 -0700
committerRajitha Yerrumchetty <rajithax.yerrumsetty@intel.com>2017-05-22 06:48:08 +0000
commitbb756eebdac6fd24e8919e2c43f7d2c8c4091f59 (patch)
treeca11e03542edf2d8f631efeca5e1626d211107e3 /qemu/roms/SLOF/slof/fs/rtas
parenta14b48d18a9ed03ec191cf16b162206998a895ce (diff)
Adding qemu as a submodule of KVMFORNFV
This Patch includes the changes to add qemu as a submodule to kvmfornfv repo and make use of the updated latest qemu for the execution of all testcase Change-Id: I1280af507a857675c7f81d30c95255635667bdd7 Signed-off-by:RajithaY<rajithax.yerrumsetty@intel.com>
Diffstat (limited to 'qemu/roms/SLOF/slof/fs/rtas')
-rw-r--r--qemu/roms/SLOF/slof/fs/rtas/rtas-cpu.fs23
-rw-r--r--qemu/roms/SLOF/slof/fs/rtas/rtas-flash.fs46
-rw-r--r--qemu/roms/SLOF/slof/fs/rtas/rtas-init.fs121
-rw-r--r--qemu/roms/SLOF/slof/fs/rtas/rtas-reboot.fs33
-rw-r--r--qemu/roms/SLOF/slof/fs/rtas/rtas-vpd.fs33
5 files changed, 0 insertions, 256 deletions
diff --git a/qemu/roms/SLOF/slof/fs/rtas/rtas-cpu.fs b/qemu/roms/SLOF/slof/fs/rtas/rtas-cpu.fs
deleted file mode 100644
index c133abc40..000000000
--- a/qemu/roms/SLOF/slof/fs/rtas/rtas-cpu.fs
+++ /dev/null
@@ -1,23 +0,0 @@
-\ *****************************************************************************
-\ * Copyright (c) 2004, 2008 IBM Corporation
-\ * All rights reserved.
-\ * This program and the accompanying materials
-\ * are made available under the terms of the BSD License
-\ * which accompanies this distribution, and is available at
-\ * http://www.opensource.org/licenses/bsd-license.php
-\ *
-\ * Contributors:
-\ * IBM Corporation - initial implementation
-\ ****************************************************************************/
-
-: rtas-start-cpu ( pid loc r3 -- status )
- [ s" start-cpu" rtas-get-token ] LITERAL rtas-cb rtas>token l!
- 3 rtas-cb rtas>nargs l!
- 1 rtas-cb rtas>nret l!
- rtas-cb rtas>args2 l!
- rtas-cb rtas>args1 l!
- rtas-cb rtas>args0 l!
- 0 rtas-cb rtas>args3 l!
- enter-rtas
- rtas-cb rtas>args3 l@
-;
diff --git a/qemu/roms/SLOF/slof/fs/rtas/rtas-flash.fs b/qemu/roms/SLOF/slof/fs/rtas/rtas-flash.fs
deleted file mode 100644
index f8abeaaf0..000000000
--- a/qemu/roms/SLOF/slof/fs/rtas/rtas-flash.fs
+++ /dev/null
@@ -1,46 +0,0 @@
-\ *****************************************************************************
-\ * Copyright (c) 2004, 2008 IBM Corporation
-\ * All rights reserved.
-\ * This program and the accompanying materials
-\ * are made available under the terms of the BSD License
-\ * which accompanies this distribution, and is available at
-\ * http://www.opensource.org/licenses/bsd-license.php
-\ *
-\ * Contributors:
-\ * IBM Corporation - initial implementation
-\ ****************************************************************************/
-
-: rtas-ibm-update-flash-64-and-reboot ( block-list -- status )
- [ s" ibm,update-flash-64-and-reboot" rtas-get-token ] LITERAL rtas-cb rtas>token l!
- 1 rtas-cb rtas>nargs l!
- 1 rtas-cb rtas>nret l!
- rtas-cb rtas>args0 l!
- enter-rtas
- rtas-cb rtas>args1 l@
-;
-
-: rtas-ibm-manage-flash-image ( image-to-commit -- status )
- [ s" ibm,manage-flash-image" rtas-get-token ] LITERAL rtas-cb rtas>token l!
- 1 rtas-cb rtas>nargs l!
- 1 rtas-cb rtas>nret l!
- rtas-cb rtas>args0 l!
- enter-rtas
- rtas-cb rtas>args1 l@
-;
-
-: rtas-set-flashside ( flashside -- status )
- [ s" rtas-set-flashside" rtas-get-token ] LITERAL rtas-cb rtas>token l!
- 1 rtas-cb rtas>nargs l!
- 1 rtas-cb rtas>nret l!
- rtas-cb rtas>args0 l!
- enter-rtas
- rtas-cb rtas>args1 l@
-;
-
-: rtas-get-flashside ( -- status )
- [ s" rtas-get-flashside" rtas-get-token ] LITERAL rtas-cb rtas>token l!
- 0 rtas-cb rtas>nargs l!
- 1 rtas-cb rtas>nret l!
- enter-rtas
- rtas-cb rtas>args0 l@
-;
diff --git a/qemu/roms/SLOF/slof/fs/rtas/rtas-init.fs b/qemu/roms/SLOF/slof/fs/rtas/rtas-init.fs
deleted file mode 100644
index 8451cfde7..000000000
--- a/qemu/roms/SLOF/slof/fs/rtas/rtas-init.fs
+++ /dev/null
@@ -1,121 +0,0 @@
-\ *****************************************************************************
-\ * Copyright (c) 2004, 2008 IBM Corporation
-\ * All rights reserved.
-\ * This program and the accompanying materials
-\ * are made available under the terms of the BSD License
-\ * which accompanies this distribution, and is available at
-\ * http://www.opensource.org/licenses/bsd-license.php
-\ *
-\ * Contributors:
-\ * IBM Corporation - initial implementation
-\ ****************************************************************************/
-
-\ (rtas-size) determines the size required for RTAS.
-\ It looks at the rtas binary in the flash and reads the rtas-size from
-\ its header at offset 8.
-: (rtas-size) ( -- rtas-size )
- s" rtas" romfs-lookup dup 0=
- ABORT" romfs-lookup for rtas failed"
- drop 8 + @
-;
-
-(rtas-size) CONSTANT rtas-size
-
-: instantiate-rtas ( adr -- entry )
- dup rtas-size erase
- s" rtas" romfs-lookup 0=
- ABORT" romfs-lookup for rtas failed"
- rtas-config swap start-rtas ;
-
-here fff + fffffffffffff000 and here - allot
-here rtas-size allot CONSTANT rtas-start-addr
-
-rtas-start-addr instantiate-rtas CONSTANT rtas-entry-point
-
-: drone-rtas
- rtas-start-addr
- dup rtas-size erase
- 2000000 start-rtas to rtas-entry-point
-;
-
-
-\ ffffffffffffffff CONSTANT rtas-entry-point
-
-\ rtas control block
-
-STRUCT
- /l field rtas>token
- /l field rtas>nargs
- /l field rtas>nret
- /l field rtas>args0
- /l field rtas>args1
- /l field rtas>args2
- /l field rtas>args3
- /l field rtas>args4
- /l field rtas>args5
- /l field rtas>args6
- /l field rtas>args7
- /l C * field rtas>args
- /l field rtas>bla
-
-CONSTANT /rtas-control-block
-
-CREATE rtas-cb /rtas-control-block allot
-rtas-cb /rtas-control-block erase
-
-\ call-c ( p0 p1 p2 entry -- ret )
-
-: enter-rtas ( -- )
- rtas-cb rtas-start-addr 0 rtas-entry-point call-c drop ;
-
-
-\ This is the structure of the RTAS function jump table in the C code:
-STRUCT
- cell FIELD rtasfunctab>name
- cell FIELD rtasfunctab>func
- cell FIELD rtasfunctab>flags
-CONSTANT rtasfunctab-size
-
-\ Create RTAS token properties by analyzing the jump table in the C code:
-: rtas-create-token-properties ( -- )
- rtas-start-addr 10 + @ rtas-start-addr + \ Get pointer to jump table
- rtas-start-addr 18 + @ rtas-start-addr + l@ \ Get the number of entries
- 0 DO
- dup rtasfunctab>func @ 0<> \ function pointer must not be NULL
- over rtasfunctab>flags @ 1 and 0= \ Check the only-internal flag
- and
- IF
- i 1+ encode-int \ Create the token value
- 2 pick rtasfunctab>name @ zcount \ Create the token name string
- property \ Create the property
- THEN
- rtasfunctab-size + \ Proceed to the next entry
- LOOP
- drop
-;
-
-\ Get the RTAS token that corresponds to an RTAS property name:
-: rtas-get-token ( str len -- token|0 )
- rtas-start-addr 10 + @ rtas-start-addr + \ Get pointer to jump table
- rtas-start-addr 18 + @ rtas-start-addr + l@ \ Get the number of entries
- 0 DO
- dup rtasfunctab>name @ \ Get pointer to function name
- dup 0<> \ function name must not be NULL
- over zcount 5 pick = nip and \ Check if both strings have same length
- IF
- 3 pick 3 pick \ Make a copy of the token name string
- comp 0=
- IF
- drop 2drop
- i 1+ \ If the name matched, return the token
- UNLOOP EXIT
- THEN
- ELSE
- drop
- THEN
- rtasfunctab-size + \ Proceed to the next entry
- LOOP
- drop
- ." RTAS token not found: " type cr
- 0
-;
diff --git a/qemu/roms/SLOF/slof/fs/rtas/rtas-reboot.fs b/qemu/roms/SLOF/slof/fs/rtas/rtas-reboot.fs
deleted file mode 100644
index a9539ecc1..000000000
--- a/qemu/roms/SLOF/slof/fs/rtas/rtas-reboot.fs
+++ /dev/null
@@ -1,33 +0,0 @@
-\ *****************************************************************************
-\ * Copyright (c) 2004, 2008 IBM Corporation
-\ * All rights reserved.
-\ * This program and the accompanying materials
-\ * are made available under the terms of the BSD License
-\ * which accompanies this distribution, and is available at
-\ * http://www.opensource.org/licenses/bsd-license.php
-\ *
-\ * Contributors:
-\ * IBM Corporation - initial implementation
-\ ****************************************************************************/
-
-: rtas-power-off ( x y -- status )
- [ s" power-off" rtas-get-token ] LITERAL rtas-cb rtas>token l!
- 2 rtas-cb rtas>nargs l!
- 1 rtas-cb rtas>nret l!
- rtas-cb rtas>args0 l!
- rtas-cb rtas>args1 l!
- enter-rtas
- rtas-cb rtas>args2 l@
-;
-
-: power-off ( -- ) 0 0 rtas-power-off ;
-
-
-: rtas-system-reboot ( -- status )
- [ s" system-reboot" rtas-get-token ] LITERAL rtas-cb rtas>token l!
- 0 rtas-cb rtas>nargs l!
- 1 rtas-cb rtas>nret l!
- rtas-cb rtas>args0 l!
- enter-rtas
- rtas-cb rtas>args1 l@
-;
diff --git a/qemu/roms/SLOF/slof/fs/rtas/rtas-vpd.fs b/qemu/roms/SLOF/slof/fs/rtas/rtas-vpd.fs
deleted file mode 100644
index 7fb4b547d..000000000
--- a/qemu/roms/SLOF/slof/fs/rtas/rtas-vpd.fs
+++ /dev/null
@@ -1,33 +0,0 @@
-\ *****************************************************************************
-\ * Copyright (c) 2004, 2008 IBM Corporation
-\ * All rights reserved.
-\ * This program and the accompanying materials
-\ * are made available under the terms of the BSD License
-\ * which accompanies this distribution, and is available at
-\ * http://www.opensource.org/licenses/bsd-license.php
-\ *
-\ * Contributors:
-\ * IBM Corporation - initial implementation
-\ ****************************************************************************/
-
-: rtas-read-vpd ( offset length data -- status )
- [ s" msg-read-vpd" rtas-get-token ] LITERAL rtas-cb rtas>token l!
- 3 rtas-cb rtas>nargs l!
- 1 rtas-cb rtas>nret l!
- rtas-cb rtas>args2 l!
- rtas-cb rtas>args1 l!
- rtas-cb rtas>args0 l!
- enter-rtas
- rtas-cb rtas>args3 l@
-;
-
-: rtas-write-vpd ( offset length data -- status )
- [ s" msg-write-vpd" rtas-get-token ] LITERAL rtas-cb rtas>token l!
- 3 rtas-cb rtas>nargs l!
- 1 rtas-cb rtas>nret l!
- rtas-cb rtas>args2 l!
- rtas-cb rtas>args1 l!
- rtas-cb rtas>args0 l!
- enter-rtas
- rtas-cb rtas>args3 l@
-;