Mailing List archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[linux-dvb] [patch] av7110 - verbose firmware not found



Hi!

Here is a patch for av7110.c that is verbose if the firmware file is just not 
found, displaying a message on where it usually is and where to get it.

Kenneth
Index: av7110.c
===================================================================
RCS file: /cvs/linuxtv/dvb-kernel/linux/drivers/media/dvb/ttpci/av7110.c,v
retrieving revision 1.125
diff -u -r1.125 av7110.c
--- av7110.c	13 Jun 2004 16:40:17 -0000	1.125
+++ av7110.c	21 Jun 2004 12:34:45 -0000
@@ -1309,7 +1309,17 @@
 	/* request the av7110 firmware, this will block until someone uploads it */
 	ret = request_firmware(&fw, "dvb-ttpci-01.fw", &av7110->dev->pci->dev);
 	if (ret) {
-		printk("dvb-ttpci: cannot request firmware!\n");
+		if (ret == -ENOENT) {
+			printk(KERN_ERR "dvb-ttpci: could not load firmware,"
+					" file not found: dvb-ttpci-01.fw\n");
+			printk(KERN_INFO "dvb-ttpci: usually this should be in"
+					 " /usr/lib/hotplug/firmware\n");
+			printk(KERN_INFO "dvb-ttpci: and can be downloaded here"
+				" http://www.linuxtv.org/download/dvb/firmware/\n";);
+		} else {
+			printk(KERN_ERR "dvb-ttpci: cannot request firmware"
+					" (errno:%i)!\n", ret);
+		}
 		return -EINVAL;
 	}
 	if (fw->size <= 200000) {

Home | Main Index | Thread Index