diff options
author | Patrick Boettcher <devnull@localhost> | 2005-04-19 22:02:58 +0000 |
---|---|---|
committer | Patrick Boettcher <devnull@localhost> | 2005-04-19 22:02:58 +0000 |
commit | fff9d155d7a3fbe4903f6a037a6218aeae9e55aa (patch) | |
tree | c8cbee0056243ef63d8e252f5d03f7ce4fc0b6f7 /linux | |
parent | ad0bfa666521692284a7e8cc3b7aa69b59274731 (diff) | |
download | mediapointer-dvb-s2-fff9d155d7a3fbe4903f6a037a6218aeae9e55aa.tar.gz mediapointer-dvb-s2-fff9d155d7a3fbe4903f6a037a6218aeae9e55aa.tar.bz2 |
firmware load fixed for big-endian (thanks to Martin Loschwitz (madkiss))
Diffstat (limited to 'linux')
-rw-r--r-- | linux/drivers/media/dvb/dvb-usb/dvb-usb-common.h | 1 | ||||
-rw-r--r-- | linux/drivers/media/dvb/dvb-usb/dvb-usb-firmware.c | 4 | ||||
-rw-r--r-- | linux/drivers/media/dvb/dvb-usb/dvb-usb-init.c | 2 |
3 files changed, 5 insertions, 2 deletions
diff --git a/linux/drivers/media/dvb/dvb-usb/dvb-usb-common.h b/linux/drivers/media/dvb/dvb-usb/dvb-usb-common.h index 2ea1f6ef7..c617287df 100644 --- a/linux/drivers/media/dvb/dvb-usb/dvb-usb-common.h +++ b/linux/drivers/media/dvb/dvb-usb/dvb-usb-common.h @@ -19,6 +19,7 @@ extern int dvb_usb_debug; #define deb_ts(args...) dprintk(dvb_usb_debug,0x08,args) #define deb_err(args...) dprintk(dvb_usb_debug,0x10,args) #define deb_rc(args...) dprintk(dvb_usb_debug,0x20,args) +#define deb_fw(args...) dprintk(dvb_usb_debug,0x40,args) /* commonly used methods */ extern int usb_cypress_load_firmware(struct usb_device *, const char *, int); diff --git a/linux/drivers/media/dvb/dvb-usb/dvb-usb-firmware.c b/linux/drivers/media/dvb/dvb-usb/dvb-usb-firmware.c index 6d5abc3e7..5244e3977 100644 --- a/linux/drivers/media/dvb/dvb-usb/dvb-usb-firmware.c +++ b/linux/drivers/media/dvb/dvb-usb/dvb-usb-firmware.c @@ -65,7 +65,9 @@ int usb_cypress_load_firmware(struct usb_device *udev, const char *filename, int err("could not stop the USB controller CPU."); for(i = 0; p[i+3] == 0 && i < fw->size; ) { b = (u8 *) &p[i]; - addr = *((u16 *) &b[1]); + addr = cpu_to_le16( *((u16 *) &b[1]) ); + + deb_fw("writing to address 0x%04x (buffer: 0x%02x%02x)\n",addr,b[1],b[2]); ret = usb_cypress_writemem(udev,addr,&b[4],b[0]); diff --git a/linux/drivers/media/dvb/dvb-usb/dvb-usb-init.c b/linux/drivers/media/dvb/dvb-usb/dvb-usb-init.c index 63f6242cf..beced1bd5 100644 --- a/linux/drivers/media/dvb/dvb-usb/dvb-usb-init.c +++ b/linux/drivers/media/dvb/dvb-usb/dvb-usb-init.c @@ -16,7 +16,7 @@ /* debug */ int dvb_usb_debug; module_param_named(debug,dvb_usb_debug, int, 0644); -MODULE_PARM_DESC(debug, "set debugging level (1=info,xfer=2,alot=4,ts=8,err=16,rc=32 (or-able))." DVB_USB_DEBUG_STATUS); +MODULE_PARM_DESC(debug, "set debugging level (1=info,xfer=2,alot=4,ts=8,err=16,rc=32,fw=64 (or-able))." DVB_USB_DEBUG_STATUS); /* general initialization functions */ int dvb_usb_exit(struct dvb_usb_device *d) |