diff options
Diffstat (limited to 'drivers/media/dvb/firewire/firedtv-1394.c')
-rw-r--r-- | drivers/media/dvb/firewire/firedtv-1394.c | 19 |
1 files changed, 12 insertions, 7 deletions
diff --git a/drivers/media/dvb/firewire/firedtv-1394.c b/drivers/media/dvb/firewire/firedtv-1394.c index 7c5459c27b75..c3e0ec2dcfca 100644 --- a/drivers/media/dvb/firewire/firedtv-1394.c +++ b/drivers/media/dvb/firewire/firedtv-1394.c | |||
@@ -90,13 +90,14 @@ static inline struct node_entry *node_of(struct firedtv *fdtv) | |||
90 | return container_of(fdtv->device, struct unit_directory, device)->ne; | 90 | return container_of(fdtv->device, struct unit_directory, device)->ne; |
91 | } | 91 | } |
92 | 92 | ||
93 | static int node_lock(struct firedtv *fdtv, u64 addr, __be32 data[]) | 93 | static int node_lock(struct firedtv *fdtv, u64 addr, void *data) |
94 | { | 94 | { |
95 | quadlet_t *d = data; | ||
95 | int ret; | 96 | int ret; |
96 | 97 | ||
97 | ret = hpsb_node_lock(node_of(fdtv), addr, EXTCODE_COMPARE_SWAP, | 98 | ret = hpsb_node_lock(node_of(fdtv), addr, |
98 | (__force quadlet_t *)&data[1], (__force quadlet_t)data[0]); | 99 | EXTCODE_COMPARE_SWAP, &d[1], d[0]); |
99 | data[0] = data[1]; | 100 | d[0] = d[1]; |
100 | 101 | ||
101 | return ret; | 102 | return ret; |
102 | } | 103 | } |
@@ -192,9 +193,13 @@ static int node_probe(struct device *dev) | |||
192 | int kv_len, err; | 193 | int kv_len, err; |
193 | void *kv_str; | 194 | void *kv_str; |
194 | 195 | ||
195 | kv_len = (ud->model_name_kv->value.leaf.len - 2) * sizeof(quadlet_t); | 196 | if (ud->model_name_kv) { |
196 | kv_str = CSR1212_TEXTUAL_DESCRIPTOR_LEAF_DATA(ud->model_name_kv); | 197 | kv_len = (ud->model_name_kv->value.leaf.len - 2) * 4; |
197 | 198 | kv_str = CSR1212_TEXTUAL_DESCRIPTOR_LEAF_DATA(ud->model_name_kv); | |
199 | } else { | ||
200 | kv_len = 0; | ||
201 | kv_str = NULL; | ||
202 | } | ||
198 | fdtv = fdtv_alloc(dev, &fdtv_1394_backend, kv_str, kv_len); | 203 | fdtv = fdtv_alloc(dev, &fdtv_1394_backend, kv_str, kv_len); |
199 | if (!fdtv) | 204 | if (!fdtv) |
200 | return -ENOMEM; | 205 | return -ENOMEM; |