[Skiboot] [PATCH] V2 mambo: Advertise available RADIX page sizes

Balbir Singh bsingharora at gmail.com
Wed Sep 28 08:41:16 AEST 2016



On 23/09/16 14:07, Chris Smart wrote:
> This adds a device tree entry which advertises additional support for 2M
> and 1G pages in a PAPR compliant manner. Without this, the kernel will
> default to only 4K and 64K page sizes.
> 
> With this patch, 1G (0x40000000) pages for linear mapping will be used.
> This can be seen by when checking the output of "Mapping range" in the
> kernel log:
> 
> # dmesg |grep "Mapping range"
> Mapping range 0x0 - 0x100000000 with 0x40000000
> 
> Without this patch, the kernel will use 64K (0x10000) instead:
> 
> # dmesg |grep "Mapping range"
> Mapping range 0x0 - 0x100000000 with 0x10000
> ---
> 
> Changes since V1:
>     move comments out onto their own line to avoid warnings
> 
> external/mambo/skiboot.tcl | 18 ++++++++++++++++--
> 1 file changed, 16 insertions(+), 2 deletions(-)
> 
> diff --git a/external/mambo/skiboot.tcl b/external/mambo/skiboot.tcl
> index e9aea028edcc..f9d92f626c9d 100644
> --- a/external/mambo/skiboot.tcl
> +++ b/external/mambo/skiboot.tcl
> @@ -205,8 +205,20 @@ for { set c 0 } { $c < $mconf(cpus) } { incr c } {
>     lappend reg 0x22 0x120 1 0x22 0x0003 ;# 16G seg 16G pages
>     mysim of addprop $cpu_node array "ibm,segment-page-sizes" reg
> 
> -    set reg {}
>     if { $default_config == "P9" } {
> +        # Set actual page size encodings
> +        set reg {}
> +        # 4K pages
> +        lappend reg 0x0000000c
> +        # 64K pages
> +        lappend reg 0xa0000010
> +        # 2M pages
> +        lappend reg 0x20000015
> +        # 1G pages
> +        lappend reg 0x4000001e
> +        mysim of addprop $cpu_node array "ibm,processor-radix-AP-encodings" reg
> +

Don't we need the top 3 bits of the __lower order byte__ to contain the AP encoding, I'd expect
0x0000000c, 0x000000b0, 0x00000035, 0x0000005e.

Balbir Singh


More information about the Skiboot mailing list