Subject: [PATCH 2.6.28 1/4] myri10ge: Stop scaring people when DCA is built but absent

From: Brice Goglin <[email-masked]>
Date: Fri, 12 Sep 2008 19:47:26 +0200

Stop scaring people with what looks like a fatal message when DCA support
is compiled into their kernel, but the DCA device is not present.

Signed-off-by: Brice Goglin <[email-masked]>
---
 drivers/net/myri10ge/myri10ge.c |    7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)

Index: linux-2.6.git/drivers/net/myri10ge/myri10ge.c
===================================================================
--- linux-2.6.git.orig/drivers/net/myri10ge/myri10ge.c	2008-08-29 07:29:45.000000000 +0200
+++ linux-2.6.git/drivers/net/myri10ge/myri10ge.c	2008-09-12 19:22:37.000000000 +0200
@@ -1060,8 +1060,9 @@
 	}
 	err = dca_add_requester(&pdev->dev);
 	if (err) {
-		dev_err(&pdev->dev,
-			"dca_add_requester() failed, err=%d\n", err);
+		if (err != -ENODEV)
+			dev_err(&pdev->dev,
+				"dca_add_requester() failed, err=%d\n", err);
 		return;
 	}
 	mgp->dca_enabled = 1;