summaryrefslogtreecommitdiff
path: root/linux/drivers
diff options
context:
space:
mode:
authorDevin Heitmueller <dheitmueller@kernellabs.com>2009-04-02 21:24:38 -0400
committerDevin Heitmueller <dheitmueller@kernellabs.com>2009-04-02 21:24:38 -0400
commit56b45a9ffa2227538376556bb0536b1ef932ab33 (patch)
tree6e69948df2c09c5b7ccf0d90f821edf96f43336e /linux/drivers
parent88c300ff3c421a23a0c8e72a0c768f58e74f9221 (diff)
downloadmediapointer-dvb-s2-56b45a9ffa2227538376556bb0536b1ef932ab33.tar.gz
mediapointer-dvb-s2-56b45a9ffa2227538376556bb0536b1ef932ab33.tar.bz2
xc5000: add build version to debug info
From: Devin Heitmueller <dheitmueller@kernellabs.com> Expose the firmware build number along with the other version info Priority: normal Signed-off-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Diffstat (limited to 'linux/drivers')
-rw-r--r--linux/drivers/media/common/tuners/xc5000.c12
1 files changed, 10 insertions, 2 deletions
diff --git a/linux/drivers/media/common/tuners/xc5000.c b/linux/drivers/media/common/tuners/xc5000.c
index 2ca2cba6d..e35d4d888 100644
--- a/linux/drivers/media/common/tuners/xc5000.c
+++ b/linux/drivers/media/common/tuners/xc5000.c
@@ -100,6 +100,7 @@ struct xc5000_priv {
#define XREG_VERSION 0x07
#define XREG_PRODUCT_ID 0x08
#define XREG_BUSY 0x09
+#define XREG_BUILD 0x0D
/*
Basic firmware description. This will remain with
@@ -471,6 +472,11 @@ static int xc_get_version(struct xc5000_priv *priv,
return 0;
}
+static int xc_get_buildversion(struct xc5000_priv *priv, u16 *buildrev)
+{
+ return xc5000_readreg(priv, XREG_BUILD, buildrev);
+}
+
static int xc_get_hsync_freq(struct xc5000_priv *priv, u32 *hsync_freq_hz)
{
u16 regData;
@@ -593,6 +599,7 @@ static void xc_debug_dump(struct xc5000_priv *priv)
u16 quality;
u8 hw_majorversion = 0, hw_minorversion = 0;
u8 fw_majorversion = 0, fw_minorversion = 0;
+ u16 fw_buildversion = 0;
/* Wait for stats to stabilize.
* Frame Lines needs two frame times after initial lock
@@ -612,9 +619,10 @@ static void xc_debug_dump(struct xc5000_priv *priv)
xc_get_version(priv, &hw_majorversion, &hw_minorversion,
&fw_majorversion, &fw_minorversion);
- dprintk(1, "*** HW: V%02x.%02x, FW: V%02x.%02x\n",
+ xc_get_buildversion(priv, &fw_buildversion);
+ dprintk(1, "*** HW: V%02x.%02x, FW: V%02x.%02x.%04x\n",
hw_majorversion, hw_minorversion,
- fw_majorversion, fw_minorversion);
+ fw_majorversion, fw_minorversion, fw_buildversion);
xc_get_hsync_freq(priv, &hsync_freq_hz);
dprintk(1, "*** Horizontal sync frequency = %d Hz\n", hsync_freq_hz);