lkml.org 
[lkml]   [2013]   [Nov]   [23]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH 1/2] New Driver for IOSF-SB MBI access on Intel SOCs
On Thu, 21 Nov 2013 22:05:56 -0800
"David E. Box" <david.e.box@linux.intel.com> wrote:

> +static int iosf_mbi_probe(struct platform_device *pdev)
> +{
> + struct resource *mem;
> +
> + /* Get and map MBI address space */
> + mem = platform_get_resource(pdev, IORESOURCE_MEM, 0);
> + iosf_mbi_data.addr = devm_ioremap_resource(&pdev->dev, mem);

Purely "defensive driv(er)ing" but platform_get_resource can return NULL

Alan


\
 
 \ /
  Last update: 2013-11-24 02:21    [W:2.910 / U:0.036 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site