• Alexey Kardashevskiy's avatar
    powerpc: Per process DSCR + some fixes (try#4) · efcac658
    Alexey Kardashevskiy authored
    The DSCR (aka Data Stream Control Register) is supported on some
    server PowerPC chips and allow some control over the prefetch
    of data streams.
    
    This patch allows the value to be specified per thread by emulating
    the corresponding mfspr and mtspr instructions. Children of such
    threads inherit the value. Other threads use a default value that
    can be specified in sysfs - /sys/devices/system/cpu/dscr_default.
    
    If a thread starts with non default value in the sysfs entry,
    all children threads inherit this non default value even if
    the sysfs value is changed later.
    Signed-off-by: default avatarAlexey Kardashevskiy <aik@au1.ibm.com>
    Signed-off-by: default avatarBenjamin Herrenschmidt <benh@kernel.crashing.org>
    efcac658
sysfs.c 16.6 KB