firmware: convert av7110 driver to request_firmware()
PATCH 1/1 firmware: convert av7110 driver to request_firmware()
--
drivers/media/dvb/ttpci/Kconfig | 7 +++++++ drivers/media/dvb/ttpci/av7110_hw.c | 35 ++++++++++++----------------------- drivers/media/dvb/ttpci/av7110_hw.h | 3 ++- firmware/Makefile | 1 + firmware/WHENCE | 10 ++++++++++ firmware/av7110/bootcode.bin.ihex | 15 +++++++++++++++ 6 files changed, 47 insertions(+), 24 deletions(-)
create mode 100644 firmware/av7110/bootcode.bin.ihex
drivers/media/dvb/ttpci/Kconfig +7 -0
@@ -32,6 +32,13 @@ config DVB_AV7110 Say Y if you own such a card and want to use it. +config DVB_AV7110_BOOTCODE + bool "Compile AV7110 bootcode into the driver" + depends on DVB_AV7110 + help + This includes firmware for AV7110 bootcode + Say 'N' and let it get loaded from userspace on demand + config DVB_AV7110_FIRMWARE bool "Compile AV7110 firmware into the driver" depends on DVB_AV7110 && !STANDALONE
drivers/media/dvb/ttpci/av7110_hw.c +12 -23
@@ -198,29 +198,10 @@ static int load_dram(struct av7110 *av7110, u32 *data, int len)/* we cannot write av7110 DRAM directly, so load a bootloader into * the DPRAM which implements a simple boot protocol */ -static u8 bootcode[] = { -0xea ,0x00 ,0x00 ,0x0e ,0xe1 ,0xb0 ,0xf0 ,0x0e ,0xe2 ,0x5e ,0xf0 ,0x04 , -0xe2 ,0x5e ,0xf0 ,0x04 ,0xe2 ,0x5e ,0xf0 ,0x08 ,0xe2 ,0x5e ,0xf0 ,0x04 , -0xe2 ,0x5e ,0xf0 ,0x04 ,0xe2 ,0x5e ,0xf0 ,0x04 ,0x2c ,0x00 ,0x00 ,0x24 , -0x00 ,0x00 ,0x00 ,0x0c ,0x00 ,0x00 ,0x00 ,0x00 ,0x2c ,0x00 ,0x00 ,0x34 , -0x00 ,0x00 ,0x00 ,0x00 ,0xa5 ,0xa5 ,0x5a ,0x5a ,0x00 ,0x1f ,0x15 ,0x55 , -0x00 ,0x00 ,0x00 ,0x09 ,0xe5 ,0x9f ,0xd0 ,0x7c ,0xe5 ,0x9f ,0x40 ,0x74 , -0xe3 ,0xa0 ,0x00 ,0x00 ,0xe5 ,0x84 ,0x00 ,0x00 ,0xe5 ,0x84 ,0x00 ,0x04 , -0xe5 ,0x9f ,0x10 ,0x70 ,0xe5 ,0x9f ,0x20 ,0x70 ,0xe5 ,0x9f ,0x30 ,0x64 , -0xe8 ,0xb1 ,0x1f ,0xe0 ,0xe8 ,0xa3 ,0x1f ,0xe0 ,0xe1 ,0x51 ,0x00 ,0x02 , -0xda ,0xff ,0xff ,0xfb ,0xe5 ,0x9f ,0xf0 ,0x50 ,0xe1 ,0xd4 ,0x10 ,0xb0 , -0xe3 ,0x51 ,0x00 ,0x00 ,0x0a ,0xff ,0xff ,0xfc ,0xe1 ,0xa0 ,0x10 ,0x0d , -0xe5 ,0x94 ,0x30 ,0x04 ,0xe1 ,0xd4 ,0x20 ,0xb2 ,0xe2 ,0x82 ,0x20 ,0x3f , -0xe1 ,0xb0 ,0x23 ,0x22 ,0x03 ,0xa0 ,0x00 ,0x02 ,0xe1 ,0xc4 ,0x00 ,0xb0 , -0x0a ,0xff ,0xff ,0xf4 ,0xe8 ,0xb1 ,0x1f ,0xe0 ,0xe8 ,0xa3 ,0x1f ,0xe0 , -0xe8 ,0xb1 ,0x1f ,0xe0 ,0xe8 ,0xa3 ,0x1f ,0xe0 ,0xe2 ,0x52 ,0x20 ,0x01 , -0x1a ,0xff ,0xff ,0xf9 ,0xe2 ,0x2d ,0xdb ,0x05 ,0xea ,0xff ,0xff ,0xec , -0x2c ,0x00 ,0x03 ,0xf8 ,0x2c ,0x00 ,0x04 ,0x00 ,0x9e ,0x00 ,0x08 ,0x00 , -0x2c ,0x00 ,0x00 ,0x74 ,0x2c ,0x00 ,0x00 ,0xc0 -}; -int av7110_bootarm (struct av7110 *av7110) { +const struct firmware *fw; +const char *fw_name ="av7110/bootcode.bin" ;struct saa7146_dev *dev = av7110->dev;u32 ret;int i;
@@ -261,7 +242,15 @@ int av7110_bootarm(struct av7110 *av7110)//saa7146_setgpio(dev, DEBI_DONE_LINE, SAA7146_GPIO_INPUT); //saa7146_setgpio(dev, 3, SAA7146_GPIO_INPUT); -mwdebi (av7110,DEBISWAB ,DPRAM_BASE , bootcode,sizeof (bootcode)); + ret =request_firmware (&fw, fw_name, &dev->pci->dev); +if (ret) { +printk (KERN_ERR "dvb-ttpci: Failed to load firmware \"%s\"\n" , + fw_name); +return ret; + } + +mwdebi (av7110,DEBISWAB ,DPRAM_BASE , fw->data, fw->size); +release_firmware (fw);iwdebi (av7110,DEBINOSWAP ,AV7110_BOOT_STATE ,BOOTSTATE_BUFFER_FULL ,2 );if (saa7146_wait_for_debi_done (av7110->dev,1 )) {
@@ -302,7 +291,7 @@ int av7110_bootarm(struct av7110 *av7110) av7110->arm_ready =1 ;return 0 ; } - +MODULE_FIRMWARE ("av7110/bootcode.bin" );/**************************************************************************** * DEBI command polling
drivers/media/dvb/ttpci/av7110_hw.h +2 -1
@@ -393,7 +393,8 @@ static inline void iwdebi(struct av7110 *av7110, u32 config, int addr, u32 val, }/* buffer writes */ -static inline void mwdebi (struct av7110 *av7110,u32 config,int addr,u8 *val,int count) +static inline void mwdebi (struct av7110 *av7110,u32 config,int addr, +const u8 *val,int count) {memcpy (av7110->debi_virt, val, count);av7110_debiwrite (av7110, config, addr,0 , count);
firmware/Makefile +1 -0
@@ -18,6 +18,7 @@ fw-shipped-$(CONFIG_USB_KAWETH_FIRMWARE) += kaweth/new_code.bin \ kaweth/new_code_fix.bin kaweth/trigger_code.bin \ kaweth/trigger_code_fix.bin fw-shipped-$(CONFIG_DVB_TTUSB_BUDGET_FIRMWARE) += ttusb-budget/dspbootcode.bin +fw-shipped-$(CONFIG_DVB_AV7110_BOOTCODE) += av7110/bootcode.bin fw-shipped-$(CONFIG_E100_FIRMWARE) += e100/d101m_ucode.bin \ e100/d101s_ucode.bin e100/d102e_ucode.bin fw-shipped-$(CONFIG_ACENIC_TG1_FIRMWARE) += acenic/tg1.bin
firmware/WHENCE +10 -0
@@ -279,3 +279,13 @@ Licence: Found in hex form in kernel source. -------------------------------------------------------------------------- + +Driver: DVB AV7110 -- AV7110 cards + +File: av7110/bootcode.bin + +Licence: GPLv2 or later + +ARM assembly source code available at http://www.linuxtv.org/downloads/firmware/Boot.S + +--------------------------------------------------------------------------
firmware/av7110/bootcode.bin.ihex new file +15 -0
@@ -0,0 +1,15 @@ +:10000000EA00000EE1B0F00EE25EF004E25EF00401 +:10001000E25EF008E25EF004E25EF004E25EF0040C +:100020002C0000240000000C000000002C00003414 +:1000300000000000A5A55A5A001F15550000000930 +:10004000E59FD07CE59F4074E3A00000E5840000BC +:10005000E5840004E59F1070E59F2070E59F306403 +:10006000E8B11FE0E8A31FE0E1510002DAFFFFFB67 +:10007000E59FF050E1D410B0E35100000AFFFFFC0F +:10008000E1A0100DE5943004E1D420B2E282203FDB +:10009000E1B0232203A00002E1C400B00AFFFFF494 +:1000A000E8B11FE0E8A31FE0E8B11FE0E8A31FE00C +:1000B000E25220011AFFFFF9E22DDB05EAFFFFEC17 +:1000C0002C0003F82C0004009E0008002C00007493 +:0400D0002C0000C040 +:00000001FF
_______________________________________________
linux-dvb mailing list
[email protected]
http://www.linuxtv.org/cgi-bin/mailman/listinfo/linux-dvb
Hi,
Quoted 146 lines · Jaswinder Singh
Signed-off-by Jaswinder Singh <[email protected]>--
drivers/media/dvb/ttpci/Kconfig | 7 +++++++ drivers/media/dvb/ttpci/av7110_hw.c | 35 ++++++++++++----------------------- drivers/media/dvb/ttpci/av7110_hw.h | 3 ++- firmware/Makefile | 1 + firmware/WHENCE | 10 ++++++++++ firmware/av7110/bootcode.bin.ihex | 15 +++++++++++++++ 6 files changed, 47 insertions(+), 24 deletions(-)create mode 100644
firmware/av7110/bootcode.bin.ihexdrivers/media/dvb/ttpci/Kconfig +7
-0@@ -32,6 +32,13 @@ config DVB_AV7110 Say Y if you own such a card and want to use it. +config DVB_AV7110_BOOTCODE + bool "Compile AV7110 bootcode into the driver" + depends on DVB_AV7110 + help + This includes firmware for AV7110 bootcode + Say 'N' and let it get loaded from userspace on demand + config DVB_AV7110_FIRMWARE bool "Compile AV7110 firmware into the driver" depends on DVB_AV7110 && !STANDALONEdrivers/media/dvb/ttpci/av7110_hw.c +12
-23@@ -198,29 +198,10 @@ static int load_dram(struct av7110 *av7110, u32 *data, int len)/* we cannot write av7110 DRAM directly, so load a bootloader into * the DPRAM which implements a simple boot protocol */ -static u8 bootcode[] = { -0xea ,0x00 ,0x00 ,0x0e ,0xe1 ,0xb0 ,0xf0 ,0x0e ,0xe2 ,0x5e ,0xf0 ,0x04 , -0xe2 ,0x5e ,0xf0 ,0x04 ,0xe2 ,0x5e ,0xf0 ,0x08 ,0xe2 ,0x5e ,0xf0 ,0x04 , -0xe2 ,0x5e ,0xf0 ,0x04 ,0xe2 ,0x5e ,0xf0 ,0x04 ,0x2c ,0x00 ,0x00 ,0x24 , -0x00 ,0x00 ,0x00 ,0x0c ,0x00 ,0x00 ,0x00 ,0x00 ,0x2c ,0x00 ,0x00 ,0x34 , -0x00 ,0x00 ,0x00 ,0x00 ,0xa5 ,0xa5 ,0x5a ,0x5a ,0x00 ,0x1f ,0x15 ,0x55 , -0x00 ,0x00 ,0x00 ,0x09 ,0xe5 ,0x9f ,0xd0 ,0x7c ,0xe5 ,0x9f ,0x40 ,0x74 , -0xe3 ,0xa0 ,0x00 ,0x00 ,0xe5 ,0x84 ,0x00 ,0x00 ,0xe5 ,0x84 ,0x00 ,0x04 , -0xe5 ,0x9f ,0x10 ,0x70 ,0xe5 ,0x9f ,0x20 ,0x70 ,0xe5 ,0x9f ,0x30 ,0x64 , -0xe8 ,0xb1 ,0x1f ,0xe0 ,0xe8 ,0xa3 ,0x1f ,0xe0 ,0xe1 ,0x51 ,0x00 ,0x02 , -0xda ,0xff ,0xff ,0xfb ,0xe5 ,0x9f ,0xf0 ,0x50 ,0xe1 ,0xd4 ,0x10 ,0xb0 , -0xe3 ,0x51 ,0x00 ,0x00 ,0x0a ,0xff ,0xff ,0xfc ,0xe1 ,0xa0 ,0x10 ,0x0d , -0xe5 ,0x94 ,0x30 ,0x04 ,0xe1 ,0xd4 ,0x20 ,0xb2 ,0xe2 ,0x82 ,0x20 ,0x3f , -0xe1 ,0xb0 ,0x23 ,0x22 ,0x03 ,0xa0 ,0x00 ,0x02 ,0xe1 ,0xc4 ,0x00 ,0xb0 , -0x0a ,0xff ,0xff ,0xf4 ,0xe8 ,0xb1 ,0x1f ,0xe0 ,0xe8 ,0xa3 ,0x1f ,0xe0 , -0xe8 ,0xb1 ,0x1f ,0xe0 ,0xe8 ,0xa3 ,0x1f ,0xe0 ,0xe2 ,0x52 ,0x20 ,0x01 , -0x1a ,0xff ,0xff ,0xf9 ,0xe2 ,0x2d ,0xdb ,0x05 ,0xea ,0xff ,0xff ,0xec , -0x2c ,0x00 ,0x03 ,0xf8 ,0x2c ,0x00 ,0x04 ,0x00 ,0x9e ,0x00 ,0x08 ,0x00 , -0x2c ,0x00 ,0x00 ,0x74 ,0x2c ,0x00 ,0x00 ,0xc0 -}; -int av7110_bootarm (struct av7110 *av7110) { +const struct firmware *fw; +const char *fw_name ="av7110/bootcode.bin" ;struct saa7146_dev *dev = av7110->dev;u32 ret;int i;@@ -261,7 +242,15 @@ int av7110_bootarm(struct av7110 *av7110)//saa7146_setgpio(dev, DEBI_DONE_LINE, SAA7146_GPIO_INPUT); //saa7146_setgpio(dev, 3, SAA7146_GPIO_INPUT); -mwdebi (av7110,DEBISWAB ,DPRAM_BASE , bootcode,sizeof (bootcode)); + ret =request_firmware (&fw, fw_name, &dev->pci->dev); +if (ret) { +printk (KERN_ERR "dvb-ttpci: Failed to load firmware \"%s\"\n" , + fw_name); +return ret; + } + +mwdebi (av7110,DEBISWAB ,DPRAM_BASE , fw->data, fw->size); +release_firmware (fw);iwdebi (av7110,DEBINOSWAP ,AV7110_BOOT_STATE ,BOOTSTATE_BUFFER_FULL ,2 );if (saa7146_wait_for_debi_done (av7110->dev,1 )) {@@ -302,7 +291,7 @@ int av7110_bootarm(struct av7110 *av7110) av7110->arm_ready =1 ;return 0 ; } - +MODULE_FIRMWARE ("av7110/bootcode.bin" );/**************************************************************************** * DEBI command polling drivers/media/dvb/ttpci/av7110_hw.h +2
-1@@ -393,7 +393,8 @@ static inline void iwdebi(struct av7110 *av7110, u32 config, int addr, u32 val, }/* buffer writes */ -static inline void mwdebi (struct av7110 *av7110,u32 config,int addr,u8 *val,int count) +static inline void mwdebi (struct av7110 *av7110,u32 config,int addr, +const u8 *val,int count) {memcpy (av7110->debi_virt, val, count);av7110_debiwrite (av7110, config, addr,0 , count);firmware/Makefile +1
-0@@ -18,6 +18,7 @@ fw-shipped-$(CONFIG_USB_KAWETH_FIRMWARE) += kaweth/new_code.bin \ kaweth/new_code_fix.bin kaweth/trigger_code.bin \ kaweth/trigger_code_fix.bin fw-shipped-$(CONFIG_DVB_TTUSB_BUDGET_FIRMWARE) += ttusb-budget/dspbootcode.bin +fw-shipped-$(CONFIG_DVB_AV7110_BOOTCODE) += av7110/bootcode.bin fw-shipped-$(CONFIG_E100_FIRMWARE) += e100/d101m_ucode.bin \ e100/d101s_ucode.bin e100/d102e_ucode.bin fw-shipped-$(CONFIG_ACENIC_TG1_FIRMWARE) += acenic/tg1.binfirmware/WHENCE +10
-0@@ -279,3 +279,13 @@ Licence: Found in hex form in kernel source. -------------------------------------------------------------------------- + +Driver: DVB AV7110 -- AV7110 cards + +File: av7110/bootcode.bin + +Licence: GPLv2 or later + +ARM assembly source code available at http://www.linuxtv.org/downloads/firmware/Boot.S + +--------------------------------------------------------------------------firmware/av7110/bootcode.bin.ihex new file +5
-0@@ -0,0 +1,15 @@ +:10000000EA00000EE1B0F00EE25EF004E25EF00401 +:10001000E25EF008E25EF004E25EF004E25EF0040C +:100020002C0000240000000C000000002C00003414 +:1000300000000000A5A55A5A001F15550000000930 +:10004000E59FD07CE59F4074E3A00000E5840000BC
firmware/av7110/bootcode.bin.ihex line 15
Quoted 10 lines
firmware/av7110/bootcode.bin.ihex new file +10
-0+:10005000E5840004E59F1070E59F2070E59F306403 +:10006000E8B11FE0E8A31FE0E1510002DAFFFFFB67 +:10007000E59FF050E1D410B0E35100000AFFFFFC0F +:10008000E1A0100DE5943004E1D420B2E282203FDB +:10009000E1B0232203A00002E1C400B00AFFFFF494 +:1000A000E8B11FE0E8A31FE0E8B11FE0E8A31FE00C +:1000B000E25220011AFFFFF9E22DDB05EAFFFFEC17 +:1000C0002C0003F82C0004009E0008002C00007493 +:0400D0002C0000C040 +:00000001FF
the patch seems to be ok, please be aware that request_firmware is not waterproof though (eg. name collisions, like the comment in the request firmware module says).
Markus
_______________________________________________
linux-dvb mailing list
[email protected]
http://www.linuxtv.org/cgi-bin/mailman/listinfo/linux-dvb
Hi,
drivers/media/dvb/ttpci/Kconfig config DVB_AV7110 · line 40
Quoted 6 lines · Jaswinder Singh
drivers/media/dvb/ttpci/Kconfig +6
-0+config DVB_AV7110_BOOTCODE + bool "Compile AV7110 bootcode into the driver" + depends on DVB_AV7110 + help + This includes firmware for AV7110 bootcode + Say 'N' and let it get loaded from userspace on demand
This option does not make any sense.
Nobody needs to replace the bootloader.
Furthermore, if you load the boot code from userspace, you must provide some means to ensure data integrity (file header, crc protection). It is a very bad idea to load garbage into the ARM processor...
CU
Oliver
Signature · 8 lines
---------------------------------------------------------------- VDR Remote Plugin 0.4.0: http://www.escape-edv.de/endriss/vdr/ ---------------------------------------------------------------- _______________________________________________ linux-dvb mailing list [email protected] http://www.linuxtv.org/cgi-bin/mailman/listinfo/linux-dvb
What is the purpose of this patch? How does the driver benefit? I ran into a problem today where I was getting a 'dvb-ttpci: Failed to load firmware "av7110/bootcode.bin"' error. This happened after I downloaded a fresh copy of v4l and compiled the drivers for my nexus. After looking into this problem I've found that a lot of users have experienced this error and from what I've read most have just reverted to an older v4l tree.
Btw, the only "bootcode.bin" I see is at v4l-dvb/linux/firmware/av7110/bootcode.bin.ihex and as per a warning, I don't dare rename that file and try to copy av7110/bootcode.bin somewhere and cross my fingers.
Maybe I'm ignorant of it's true purpose but the only thing this bootcode patch seems to do is cause problems and frustrate users. Please resolve this!
Thanks.
_______________________________________________
linux-dvb users mailing list
For V4L/DVB development, please use instead [email protected] [email protected]
http://www.linuxtv.org/cgi-bin/mailman/listinfo/linux-dvb
Quoted 8 lines · VDR User
What is the purpose of this patch? How does the driver benefit? I ran into a problem today where I was getting a 'dvb-ttpci: Failed to load firmware "av7110/bootcode.bin"' error. This happened after I downloaded a fresh copy of v4l and compiled the drivers for my nexus. After looking into this problem I've found that a lot of users have experienced this error and from what I've read most have just reverted to an older v4l tree.
Quoted 8 lines
Btw, the only "bootcode.bin" I see is at v4l-dvb/linux/firmware/av7110/bootcode.bin.ihex and as per a warning, I don't dare rename that file and try to copy av7110/bootcode.bin somewhere and cross my fingers.
Maybe I'm ignorant of it's true purpose but the only thing this bootcode patch seems to do is cause problems and frustrate users. Please resolve this!
Since the fix is so obvious, and you don't want to post using your real name, I'm going to assume that you're just trolling and not actually attempt to answer you directly.
Signature · 8 lines
dwmw2 _______________________________________________ linux-dvb users mailing list For V4L/DVB development, please use instead [email protected] [email protected] http://www.linuxtv.org/cgi-bin/mailman/listinfo/linux-dvb
Quoted 3 lines · David Woodhouse
Since the fix is so obvious, and you don't want to post using your real name, I'm going to assume that you're just trolling and not actually attempt to answer you directly.
Maybe the fix is obvious to you but it clearly isn't to a lot of other people. As far as your assumption I'm here "trolling", you may want to rethink that. How you could even interpret my post as trolling in the first place is laughable but I'm neither a stranger to this mailing list, nor am I new here. A simple search would tell you that but making bad assumptions seems to be your preference. You would also discover my name is Derek. And now knowing it, do you feel better? There are far more worthy things to concern yourself with but that's merely my opinion.
I'll ignore the fact that your reply offered absolutely no value to the thread and issue at hand but for future reference, please leave such useless comments to direct email and off of the mailing list.
Furthermore, since you're unwilling to help with your "obvious fix", my recommendation to the many others having this problems is what was suggested to me... Revert to an older v4l or use the tree located at:
http://linuxtv.org/hg/~endriss/v4l-dvb/
Thanks only to those with something useless or constructive to say.
_______________________________________________
linux-dvb users mailing list
For V4L/DVB development, please use instead [email protected] [email protected]
http://www.linuxtv.org/cgi-bin/mailman/listinfo/linux-dvb
Quoted 1 line · VDR User
Thanks only to those with something useless or constructive to say.
s/useless/usefull of course.
_______________________________________________
linux-dvb users mailing list
For V4L/DVB development, please use instead [email protected] [email protected]
http://www.linuxtv.org/cgi-bin/mailman/listinfo/linux-dvb
Quoted 2 lines · VDR User
Maybe the fix is obvious to you but it clearly isn't to a lot of other people.
OK then. For reference, for those of you who have slept through the last few years of Linux development...
When the kernel complains that it cannot find a certain item of firmware that is required for a driver to work, you need to place that firmware into the /lib/firmware directory, so that it can be found on demand.
A recent development is that we're starting to collect those firmware images into a central repository, so that you don't have to go hunting all over the place for them. That repository is at
git://git.kernel.org/pub/scm/linux/kernel/git/dwmw2/linux-firmware.git
We've also started to fix up some of the older drivers which used to have firmware built directly into the kernel instead of using the request_firmware() API to fetch it only when it's needed. Firmware for _those_ drivers, which includes av7110, is actually included directly in the kernel source tree for now, but cleanly separated from the drivers. It can be included in the kernel if you build the driver in and set the CONFIG_FIRMWARE_IN_KERNEL option, or otherwise it'll be automatically installed for you when you run 'make modules_install', if you build the driver as a module.
The major distributions are now shipping 'kernel-firmware' packages which contain the firmware extracted from these older kernel drivers, and are in the process of switching to the linux-firmware.git tree instead, to include more firmware images.
If you were using a normal kernel tree, this would all 'just work'. I believe the main problem, other than the fact that you don't _want_ to see the obvious answer, is that you're using a tree which has a lot of the normal kernel bits stripped out, so the automatic installation of the firmware doesn't work?
I _would_ look at fixing that, but life's too short to learn to use everyone's weird version control system du jour; if it isn't in git, I have better things to do. When I encounter a project which doesn't use git, I usually figure they just don't _want_ me to contribute, and find something more productive to do.
As it is, you just need to copy one file. It's _really_ simple. Which is why I assumed (and still assume) that you're just trolling.
Signature · 8 lines
dwmw2 _______________________________________________ linux-dvb users mailing list For V4L/DVB development, please use instead [email protected] [email protected] http://www.linuxtv.org/cgi-bin/mailman/listinfo/linux-dvb
Quoted 3 lines · David Woodhouse
When the kernel complains that it cannot find a certain item of firmware that is required for a driver to work, you need to place that firmware into the
/lib/firmwaredirectory, so that it can be found on demand.
So the files expected location is /lib/firmware/av7110/bootcode.bin then. Fair enough, however you might want to consider that many users aren't familiar with what the kernel expects and have installed their Linux dvb system according to howto's. Unfortunately, I guess, those likely aren't updated in sync with the most recent changes. This is usually not a problem, although clearly is in this case.
Quoted 4 lines
A recent development is that we're starting to collect those firmware images into a central repository, so that you don't have to go hunting all over the place for them. That repository is at
git://git.kernel.org/pub/scm/linux/kernel/git/dwmw2/linux-firmware.git
I guess that's a good thing. I've never had to use git so I'm not familiar with it but hopefully users won't have to download the entire repository and then delete everything they don't need. I only need firmware for use with my nexus-s dvb card, it would be nice to be able to download only that -- only what I actually need.
Quoted 9 lines
We've also started to fix up some of the older drivers which used to have firmware built directly into the kernel instead of using the
request_firmware()API to fetch it only when it's needed. Firmware for _those_ drivers, which includes av7110, is actually included directly in the kernel source tree for now, but cleanly separated from the drivers. It can be included in the kernel if you build the driver in and set theCONFIG_FIRMWARE_IN_KERNELoption, or otherwise it'll be automatically installed for you when you run 'makemodules_install', if you build the driver as a module.
I, like many others, don't build the dvb drivers in/from the kernel at all. I download the v4l tree from http://linuxtv.org/hg/v4l-dvb and select my drivers using menuconfig. Which by the way, didn't present me with an option to compile this av7110 bootcode into the driver.
Quoted 1 line
From my perspective I used the same method I have been for a very long
time except now I get an error saying av7110/bootcode.bin wasn't found both by 'apt-file search bootcode.bin' or 'find -H / |grep bootcode.bin'.. However, there is v4l-dvb/linux/firmware/av7110/bootcode.bin.ihex so is that the file users are supposed to use? If so, it's poor form that a user should have to rename files.
Quoted 5 lines
If you were using a normal kernel tree, this would all 'just work'. I believe the main problem, other than the fact that you don't _want_ to see the obvious answer, is that you're using a tree which has a lot of the normal kernel bits stripped out, so the automatic installation of the firmware doesn't work?
I'm using kernel 2.6.29.1, however as previously mentioned, I use v4l-dvb, not kernel dvb drivers.
Quoted 2 lines
As it is, you just need to copy one file. It's _really_ simple. Which is why I assumed (and still assume) that you're just trolling.
While I agree copying a single file is simple, it's not so smart to assume everyone knows how to resolve the problem. As I've pointed out there are loads of users who are only as familiar with Linux as the installation howto's they used taught them to be. There's nothing wrong with using howtos, and not knowing everything about Linux behavior and the kernel. Additionally, the only "av7110/bootcode.bin" I found was actually "v4l-dvb/linux/firmware/av7110/bootcode.bin.ihex". The safe/smart thing to do is to ask rather then assuming you should (right?) rename & relocate that file. If this is in fact the necessary action to take, it should be mentioned somewhere people can search and find it (this thread possibly).
As far as the "trolling" nonsense.. You can continue to think whatever you want, no matter how ridiculous. I, and others I know who are reading this thread but haven't participated in it, are just glad you actually replied with useful information this time. Thank you for that.
To be absolutely clear; users compiling dvb drivers outside of the kernel should copy v4l-dvb/linux/firmware/av7110/bootcode.bin.ihex to /lib/firmware/av7110/bootcode.bin correct?
Thanks for your help.
_______________________________________________
linux-dvb users mailing list
For V4L/DVB development, please use instead [email protected] [email protected]
http://www.linuxtv.org/cgi-bin/mailman/listinfo/linux-dvb
Quoted 4 lines · VDR User
To be absolutely clear; users compiling dvb drivers outside of the kernel should copy v4l-dvb/linux/firmware/av7110/bootcode.bin.ihex to
/lib/firmware/av7110/bootcode.bincorrect?
Run 'objcopy -Iihex -Obinary bootcode.bin.ihex bootcode.bin' first, then copy the resulting bootcode.bin file to /lib/firmware/av7110/
We didn't want to put raw binary files into the kernel source tree so we converted them to a simple hex form instead.
As I said, the makefiles in the kernel tree get this right, and convert them to binary for you and automatically install them. It shouldn't be hard to fix the v4l tree to do it too, but as I also said, I'm not particularly interested in doing that myself.
Signature · 8 lines
dwmw2 _______________________________________________ linux-dvb users mailing list For V4L/DVB development, please use instead [email protected] [email protected] http://www.linuxtv.org/cgi-bin/mailman/listinfo/linux-dvb
2009/4/19 David Woodhouse <[email protected]>:
Quoted 9 lines · VDR User
Quoted 4 lines
To be absolutely clear; users compiling dvb drivers outside of the kernel should copy v4l-dvb/linux/firmware/av7110/bootcode.bin.ihex to
/lib/firmware/av7110/bootcode.bincorrect?Run 'objcopy -Iihex -Obinary bootcode.bin.ihex bootcode.bin' first, then copy the resulting bootcode.bin file to
/lib/firmware/av7110/
That doesn't seem very *obvious* to me, actually.
After ten year of using gnu/linux, I don't consider myself a newbie, but I didn't know what was the purpose of that command (if I ever knew it existed). Maybe it's just I never had the need for such a tool.
Quoted 3 lines
We didn't want to put raw binary files into the kernel source tree so we converted them to a simple hex form instead.
IMHO that's the right direction.
Quoted 8 lines
As I said, the makefiles in the kernel tree get this right, and convert them to binary for you and automatically install them. It shouldn't be hard to fix the v4l tree to do it too, but as I also said, I'm not particularly interested in doing that myself.
--
dwmw2
Well, VDR *just wanted it fixed*: that's what he asked for in its first message on this thread.
At least, David, you gave some useful information; but I found your attitude -and please note I don't want to offend you personally- more or less annoying. I don't understand why you said so lightly he was trolling, specially when he is a somewhat active participant on this list, I know you didn't either, but if I had to say someone was trolling in here, you'll be my first candidate. Derek simply pointed out a problem on the v4l-dvb tree. I think the most of us don't have much time to spend on this kind of volunteer projects, so we should avoid wasting it on sterile arguments.
Once again, excuse me if I did offend you. That was not my intention.
Regards,
--
Román
_______________________________________________
linux-dvb users mailing list
For V4L/DVB development, please use instead [email protected] [email protected]
http://www.linuxtv.org/cgi-bin/mailman/listinfo/linux-dvb
Hi,
Am Sonntag, den 19.04.2009, 23:41 +0200 schrieb Román:
Quoted 44 lines
2009/4/19 David Woodhouse <[email protected]>:
Quoted 9 lines · VDR User
Quoted 4 lines
To be absolutely clear; users compiling dvb drivers outside of the kernel should copy v4l-dvb/linux/firmware/av7110/bootcode.bin.ihex to
/lib/firmware/av7110/bootcode.bincorrect?Run 'objcopy -Iihex -Obinary bootcode.bin.ihex bootcode.bin' first, then copy the resulting bootcode.bin file to
/lib/firmware/av7110/That doesn't seem very *obvious* to me, actually.
After ten year of using gnu/linux, I don't consider myself a newbie, but I didn't know what was the purpose of that command (if I ever knew it existed). Maybe it's just I never had the need for such a tool.Quoted 3 lines
We didn't want to put raw binary files into the kernel source tree so we converted them to a simple hex form instead.
IMHO that's the right direction.
Quoted 8 lines
As I said, the makefiles in the kernel tree get this right, and convert them to binary for you and automatically install them. It shouldn't be hard to fix the v4l tree to do it too, but as I also said, I'm not particularly interested in doing that myself.
--
dwmw2Well, VDR *just wanted it fixed*: that's what he asked for in its first message on this thread.
At least, David, you gave some useful information; but I found your attitude -and please note I don't want to offend you personally- more or less annoying. I don't understand why you said so lightly he was trolling, specially when he is a somewhat active participant on this list, I know you didn't either, but if I had to say someone was trolling in here, you'll be my first candidate. Derek simply pointed out a problem on the v4l-dvb tree. I think the most of us don't have much time to spend on this kind of volunteer projects, so we should avoid wasting it on sterile arguments.
Quoted 7 lines
Once again, excuse me if I did offend you. That was not my intention.
Regards,
--
Román
giving seemingly the troll then, but asking just some simple questions, likely already answered over all this years ...
The firmware download for the tda10046 was broken for months, likely half a year.
Technotrend changed the URL and LifeView disappeared somehow.
Now we have a "fix", Douglas had the fun to promote it.
The firmware versions still differ between revision 20 and 29.
Some OEMs, as far as i can tell, controlled on that other OS, that firmware updates should only be made on such revisions of the chips really in need and later ones should not be touched.
This could mean that the flashing itself inherits some known risks only.
For what I have seen so far, it also could be the other way round sometimes, let the old chips with the old firmware and don't touch them.
How do you know about this?
Related, they get a substantial load on their servers to serve also cards not even produced by them. Who did ask them to still tolerate this and how sure you know they deliver the correct stuff, given that revision 20 and 29 are around for free choice ?
Have there been any tries to ask Philips/NXP what to use on what and can we be confident that the latest version is always suitable for all stuff around? I just don't know and have some doubts.
Cheers,
Hermann
Quoted 7 lines · On Sun, 19 Apr 2009 23:41:58 +0200 Román <[email protected]> wrote:
2009/4/19 David Woodhouse <[email protected]>:
Quoted 6 lines · VDR User
Quoted 4 lines
To be absolutely clear; users compiling dvb drivers outside of the kernel should copy v4l-dvb/linux/firmware/av7110/bootcode.bin.ihex to
/lib/firmware/av7110/bootcode.bincorrect?
Quoted 5 lines
Quoted 3 lines
Run 'objcopy -Iihex -Obinary bootcode.bin.ihex bootcode.bin' first, then copy the resulting bootcode.bin file to
/lib/firmware/av7110/That doesn't seem very *obvious* to me, actually.
If you see INSTALL file at v4l-dvb tree, you'll see:
...
Firmware rules:
firmware - Create the firmware files that are enclosed at the
tree.
Notice: Only a very few firmwares are currently here
firmware_install- Install firmware files under /lib/firmware
...
So, all you would need to do to install firmwares with -hg is to run:
make firmware_install
Anyway, since firmware install is very fast, and in order to avoid such issues, I've just committed a patch that will run firmware_install when you do a "make install".
Cheers,
Mauro
2009/4/20 Mauro Carvalho Chehab <[email protected]>:
Quoted 31 lines
Quoted 7 lines · On Sun, 19 Apr 2009 23:41:58 +0200 Román <[email protected]> wrote:
2009/4/19 David Woodhouse <[email protected]>:
Quoted 6 lines · VDR User
Quoted 4 lines
To be absolutely clear; users compiling dvb drivers outside of the kernel should copy v4l-dvb/linux/firmware/av7110/bootcode.bin.ihex to
/lib/firmware/av7110/bootcode.bincorrect?Quoted 5 lines
Quoted 3 lines
Run 'objcopy -Iihex -Obinary bootcode.bin.ihex bootcode.bin' first, then copy the resulting bootcode.bin file to
/lib/firmware/av7110/That doesn't seem very *obvious* to me, actually.
If you see INSTALL file at v4l-dvb tree, you'll see:
...
Firmware rules:firmware - Create the firmware files that are enclosed at the tree.
Notice: Only a very few firmwares are currently herefirmware_install- Install firmware files under
/lib/firmware
...So, all you would need to do to install firmwares with -hg is to run:
makefirmware_install
Quoted 9 lines
Anyway, since firmware install is very fast, and in order to avoid such issues, I've just committed a patch that will run
firmware_installwhen you do a "make install".Cheers,
Mauro
I'm sorry, my fault. As I said, I never had the necessity to install any firmware.
The patch sounds good, I don't need it myself, but thank you anyway.
Regards,
Román