diff options
| author | Jiri Kosina <jkosina@suse.cz> | 2012-10-28 19:28:52 +0100 |
|---|---|---|
| committer | Jiri Kosina <jkosina@suse.cz> | 2012-10-28 19:29:19 +0100 |
| commit | 3bd7bf1f0fe14f591c089ae61bbfa9bd356f178a (patch) | |
| tree | 0058693cc9e70b7461dae551f8a19aff2efd13ca /arch/powerpc/platforms/ps3/setup.c | |
| parent | f16f84937d769c893492160b1a8c3672e3992beb (diff) | |
| parent | e657e078d3dfa9f96976db7a2b5fd7d7c9f1f1a6 (diff) | |
Merge branch 'master' into for-next
Sync up with Linus' tree to be able to apply Cesar's patch
against newer version of the code.
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
Diffstat (limited to 'arch/powerpc/platforms/ps3/setup.c')
| -rw-r--r-- | arch/powerpc/platforms/ps3/setup.c | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/arch/powerpc/platforms/ps3/setup.c b/arch/powerpc/platforms/ps3/setup.c index 2d664c5a83b..3f509f86432 100644 --- a/arch/powerpc/platforms/ps3/setup.c +++ b/arch/powerpc/platforms/ps3/setup.c @@ -184,11 +184,15 @@ early_param("ps3flash", early_parse_ps3flash); #define prealloc_ps3flash_bounce_buffer() do { } while (0) #endif -static int ps3_set_dabr(unsigned long dabr) +static int ps3_set_dabr(unsigned long dabr, unsigned long dabrx) { - enum {DABR_USER = 1, DABR_KERNEL = 2,}; + /* Have to set at least one bit in the DABRX */ + if (dabrx == 0 && dabr == 0) + dabrx = DABRX_USER; + /* hypervisor only allows us to set BTI, Kernel and user */ + dabrx &= DABRX_BTI | DABRX_KERNEL | DABRX_USER; - return lv1_set_dabr(dabr, DABR_KERNEL | DABR_USER) ? -1 : 0; + return lv1_set_dabr(dabr, dabrx) ? -1 : 0; } static void __init ps3_setup_arch(void) |
