Skip to content

Commit

Permalink
[PATCH] s390: 31 bit memory size limit
Browse files Browse the repository at this point in the history
Limit reported memory size to 2GB if running in 31 bit mode.

Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
  • Loading branch information
heicarst authored and Linus Torvalds committed Jul 27, 2005
1 parent 4111796 commit f878e43
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion arch/s390/kernel/head.S
Original file line number Diff line number Diff line change
Expand Up @@ -535,8 +535,13 @@ startup:basr %r13,0 # get base
lhi %r1,0
icm %r1,3,.Lscpincr1-PARMAREA(%r4) # use this one if != 0
jnz .Lscnd
l %r1,.Lscpincr2-PARMAREA+4(%r4) # otherwise use this one
lhi %r1,0x800 # otherwise report 2GB
.Lscnd:
lhi %r3,0x800 # limit reported memory size to 2GB
cr %r1,%r3
jl .Lno2gb
lr %r1,%r3
.Lno2gb:
xr %r3,%r3 # same logic
ic %r3,.Lscpa1-PARMAREA(%r4)
chi %r3,0x00
Expand Down

0 comments on commit f878e43

Please sign in to comment.