target-ppc: disable unsupported modes for SPR_CTRL/SPR_UCTRL
authorAlexey Kardashevskiy <aik@ozlabs.ru>
Mon, 23 Dec 2013 02:42:22 +0000 (13:42 +1100)
committerAlexander Graf <agraf@suse.de>
Wed, 5 Mar 2014 02:06:27 +0000 (03:06 +0100)
commit4e38181979ec4bc80c75f0c181f9df2d4e933c13
tree491983494d31c609dfc6b9ce79cddb3996a058b1
parent3052f0d59426a1f8120ffbf66fd438973bfd2912
target-ppc: disable unsupported modes for SPR_CTRL/SPR_UCTRL

The Figure 17 "SPR encodings" of the PowerISA 2.07 describes CTRL SPR as:

                       priviledged
#   spr5-9 spr0-4 name mtspr mfspr len cat
136 00100  01000  CTRL   -    no    32  S
152 00100  11000  CTRL  yes    -    32  S

According to this chart, the hypervisor's CTRL (#152) does not support
reading, the user-space's CTRL (UCTRL, #136) does not support writing.

This replaces unsupported operations with the default SPR_NOACCESS hook.

Signed-off-by: Alexey Kardashevskiy <aik@ozlabs.ru>
Signed-off-by: Alexander Graf <agraf@suse.de>
target-ppc/translate_init.c