lkml.org 
[lkml]   [2012]   [Aug]   [13]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    Patch in this message
    /
    From
    Subject[ 21/82] ARM: 7476/1: vfp: only clear vfp state for current cpu in vfp_pm_suspend
    Date
    From: Greg KH <gregkh@linuxfoundation.org>

    3.5-stable review patch. If anyone has any objections, please let me know.

    ------------------

    From: Colin Cross <ccross@android.com>

    commit a84b895a2348f0dbff31b71ddf954f70a6cde368 upstream.

    vfp_pm_suspend runs on each cpu, only clear the hardware state
    pointer for the current cpu. Prevents a possible crash if one
    cpu clears the hw state pointer when another cpu has already
    checked if it is valid.

    Signed-off-by: Colin Cross <ccross@android.com>
    Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
    Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>

    ---
    arch/arm/vfp/vfpmodule.c | 2 +-
    1 file changed, 1 insertion(+), 1 deletion(-)

    --- a/arch/arm/vfp/vfpmodule.c
    +++ b/arch/arm/vfp/vfpmodule.c
    @@ -460,7 +460,7 @@ static int vfp_pm_suspend(void)
    }

    /* clear any information we had about last context state */
    - memset(vfp_current_hw_state, 0, sizeof(vfp_current_hw_state));
    + vfp_current_hw_state[ti->cpu] = NULL;

    return 0;
    }



    \
     
     \ /
      Last update: 2012-08-14 00:22    [W:4.119 / U:0.300 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site