diff options
author | Stefan Richter <stefanr@s5r6.in-berlin.de> | 2010-06-14 20:00:11 -0400 |
---|---|---|
committer | Stefan Richter <stefanr@s5r6.in-berlin.de> | 2010-06-19 07:01:41 -0400 |
commit | 5030c807907ae90ad21e9220c1a9d592558deba2 (patch) | |
tree | 4bb37dffd32a71e9c7712df14938af6bb73656c7 /drivers/ieee1394/dv1394.c | |
parent | 0fcff4e39323f466a47684d7c8ffa77e1be86c8a (diff) |
ieee1394: remove unused variables
which caused gcc 4.6 to warn about
variable 'XYZ' set but not used.
sbp2.c, unit_characteristics:
The underlying problem which was spotted here --- an incomplete
implementation --- is already 50% fixed in drivers/firewire/sbp2.c which
observes mgt_ORB_timeout but not yet ORB_size.
raw1394.c, length_conflict; dv1394.c, ts_off:
Impossible to tell why these variables are there. We can safely remove
them though because we don't need a compiler warning to realize that we
are dealing with (at least stylistically) flawed code here.
dv1394.c, packet_time:
This was used in debug macro that is only compiled in with
DV1394_DEBUG_LEVEL >= 2 defined at compile-time. Just drop it since
nobody debugs dv1394 anymore. Avoids noise in regular kernel builds.
dv1394.c, ohci; eth1394.c, priv:
These variables clearly can go away. Somebody wanted to use them but
then didn't (or not anymore).
Note, all of this code is considered to be at its end of life and is
thus not really meant to receive janitorial updates anymore. But if we
can easily remove noisy warnings from kernel builds, we should.
Reported-by: Justin P. Mattock <justinmattock@gmail.com>
Signed-off-by: Stefan Richter <stefanr@s5r6.in-berlin.de>
Diffstat (limited to 'drivers/ieee1394/dv1394.c')
-rw-r--r-- | drivers/ieee1394/dv1394.c | 14 |
1 files changed, 2 insertions, 12 deletions
diff --git a/drivers/ieee1394/dv1394.c b/drivers/ieee1394/dv1394.c index adaefabc40e9..f8fcbd048447 100644 --- a/drivers/ieee1394/dv1394.c +++ b/drivers/ieee1394/dv1394.c | |||
@@ -610,7 +610,7 @@ static void frame_prepare(struct video_card *video, unsigned int this_frame) | |||
610 | } else { | 610 | } else { |
611 | 611 | ||
612 | u32 transmit_sec, transmit_cyc; | 612 | u32 transmit_sec, transmit_cyc; |
613 | u32 ts_cyc, ts_off; | 613 | u32 ts_cyc; |
614 | 614 | ||
615 | /* DMA is stopped, so this is the very first frame */ | 615 | /* DMA is stopped, so this is the very first frame */ |
616 | video->active_frame = this_frame; | 616 | video->active_frame = this_frame; |
@@ -636,7 +636,6 @@ static void frame_prepare(struct video_card *video, unsigned int this_frame) | |||
636 | transmit_sec += transmit_cyc/8000; | 636 | transmit_sec += transmit_cyc/8000; |
637 | transmit_cyc %= 8000; | 637 | transmit_cyc %= 8000; |
638 | 638 | ||
639 | ts_off = ct_off; | ||
640 | ts_cyc = transmit_cyc + 3; | 639 | ts_cyc = transmit_cyc + 3; |
641 | ts_cyc %= 8000; | 640 | ts_cyc %= 8000; |
642 | 641 | ||
@@ -2004,7 +2003,7 @@ static void ir_tasklet_func(unsigned long data) | |||
2004 | 2003 | ||
2005 | int sof=0; /* start-of-frame flag */ | 2004 | int sof=0; /* start-of-frame flag */ |
2006 | struct frame *f; | 2005 | struct frame *f; |
2007 | u16 packet_length, packet_time; | 2006 | u16 packet_length; |
2008 | int i, dbc=0; | 2007 | int i, dbc=0; |
2009 | struct DMA_descriptor_block *block = NULL; | 2008 | struct DMA_descriptor_block *block = NULL; |
2010 | u16 xferstatus; | 2009 | u16 xferstatus; |
@@ -2024,11 +2023,6 @@ static void ir_tasklet_func(unsigned long data) | |||
2024 | sizeof(struct packet)); | 2023 | sizeof(struct packet)); |
2025 | 2024 | ||
2026 | packet_length = le16_to_cpu(p->data_length); | 2025 | packet_length = le16_to_cpu(p->data_length); |
2027 | packet_time = le16_to_cpu(p->timestamp); | ||
2028 | |||
2029 | irq_printk("received packet %02d, timestamp=%04x, length=%04x, sof=%02x%02x\n", video->current_packet, | ||
2030 | packet_time, packet_length, | ||
2031 | p->data[0], p->data[1]); | ||
2032 | 2026 | ||
2033 | /* get the descriptor based on packet_buffer cursor */ | 2027 | /* get the descriptor based on packet_buffer cursor */ |
2034 | f = video->frames[video->current_packet / MAX_PACKETS]; | 2028 | f = video->frames[video->current_packet / MAX_PACKETS]; |
@@ -2320,7 +2314,6 @@ static void dv1394_add_host(struct hpsb_host *host) | |||
2320 | 2314 | ||
2321 | static void dv1394_host_reset(struct hpsb_host *host) | 2315 | static void dv1394_host_reset(struct hpsb_host *host) |
2322 | { | 2316 | { |
2323 | struct ti_ohci *ohci; | ||
2324 | struct video_card *video = NULL, *tmp_vid; | 2317 | struct video_card *video = NULL, *tmp_vid; |
2325 | unsigned long flags; | 2318 | unsigned long flags; |
2326 | 2319 | ||
@@ -2328,9 +2321,6 @@ static void dv1394_host_reset(struct hpsb_host *host) | |||
2328 | if (strcmp(host->driver->name, OHCI1394_DRIVER_NAME)) | 2321 | if (strcmp(host->driver->name, OHCI1394_DRIVER_NAME)) |
2329 | return; | 2322 | return; |
2330 | 2323 | ||
2331 | ohci = (struct ti_ohci *)host->hostdata; | ||
2332 | |||
2333 | |||
2334 | /* find the corresponding video_cards */ | 2324 | /* find the corresponding video_cards */ |
2335 | spin_lock_irqsave(&dv1394_cards_lock, flags); | 2325 | spin_lock_irqsave(&dv1394_cards_lock, flags); |
2336 | list_for_each_entry(tmp_vid, &dv1394_cards, list) { | 2326 | list_for_each_entry(tmp_vid, &dv1394_cards, list) { |