powerpc/pseries: Add null property check to pseries_discover_pic()

Michael Ellerman mpe at ellerman.id.au
Thu May 5 08:40:25 AEST 2016


On Thu, 2016-28-04 at 05:53:45 UTC, Suraj Jitindar Singh wrote:
> The return value of of_get_property() isn't checked before it is passed
> to the strstr() function, if it happens that the return value is null
> then this will result in a null pointer being dereferenced.
> 
> Add a check to see if the return value of of_get_property() is null and
> if it is continue straight on to the next node.
> 
> Signed-off-by: Suraj Jitindar Singh <sjitindarsingh at gmail.com>
> Reviewed-by: Chris Smart <chris at distroguy.com>

Applied to powerpc next, thanks.

https://git.kernel.org/powerpc/c/9ed3f7bcab00c9477e382e6589

cheers


More information about the Linuxppc-dev mailing list