Thread (12 messages) flat view 12 messages, 5 authors, 2013-08-23
STALE4733d

Re: [PATCH 2/4] net: ethernet: cpsw: add optional third memory region for CONTROL module

From: Daniel Mack <zonque@gmail.com>
Date: 2013-08-22 18:37:20
Also in: linux-arm-kernel, linux-omap

Hi Sergei,

On 22.08.2013 20:12, Sergei Shtylyov wrote:
quoted
@@ -2012,6 +2013,27 @@ static int cpsw_probe(struct platform_device *pdev)
  		goto clean_runtime_disable_ret;
  	}

+	/* If the control memory region is unspecified, continue without it.
+	 * If it is specified, but we're unable to reserve it, bail. */
    According to Documentation/CodingStyle, the networking code's preferred 
style of multi-line comments is this:

/* Bla
  * bla
  */
Ok, thanks. Will fix.
quoted
+		goto clean_runtime_disable_ret;
+	}
+	priv->gmii_sel_reg = devm_ioremap(&pdev->dev, res->start,
+					  resource_size(res));
+	if (!priv->gmii_sel_reg) {
+		dev_err(priv->dev, "unable to map control i/o region\n");
+		goto clean_runtime_disable_ret;
+	}
    Why not use devm_ioremap_resource() instead of the above sequence?
Right, that's much nicer. I'll also do that for the devm rework patch.


Thank you for your review!


Daniel
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help