Skip to contentSkip to conversation

staging: media: Remove unnecessary function and its call

PATCH In review simran singhal 3 participants 3 messages Mar 5, 2017

Subsystems (4)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 staging: media: Remove unnecessary function and its call

The function atomisp_set_stop_timeout on being called, simply returns back. The function hasn't been mentioned in the TODO and doesn't have FIXME code around. Hence, atomisp_set_stop_timeout and its calls have been removed.

---
 drivers/staging/media/atomisp/pci/atomisp2/atomisp_cmd.c          | 1 -
 drivers/staging/media/atomisp/pci/atomisp2/atomisp_compat.h       | 1 -
 drivers/staging/media/atomisp/pci/atomisp2/atomisp_compat_css20.c | 5 -----
 3 files changed, 7 deletions(-)
drivers/staging/media/atomisp/pci/atomisp2/atomisp_cmd.c +0 -1
index e99f7b8..66299dd 100644
@@ -1700,7 +1700,6 @@ void atomisp_wdt_work(struct work_struct *work)
 		}
 	}
 #endif
-	atomisp_set_stop_timeout(ATOMISP_CSS_STOP_TIMEOUT_US);
 	dev_err(isp->dev, "timeout recovery handling done\n");
 	atomic_set(&isp->wdt_work_queued, 0);
 
drivers/staging/media/atomisp/pci/atomisp2/atomisp_compat.h +0 -1
index 5a404e4..0b9ced5 100644
@@ -660,7 +660,6 @@ int atomisp_css_set_acc_parameters(struct atomisp_acc_fw *acc_fw);
 int atomisp_css_isr_thread(struct atomisp_device *isp,
 			   bool *frame_done_found,
 			   bool *css_pipe_done);
-void atomisp_set_stop_timeout(unsigned int timeout);
 
 bool atomisp_css_valid_sof(struct atomisp_device *isp);
 
drivers/staging/media/atomisp/pci/atomisp2/atomisp_compat_css20.c +0 -5
index 6697d72..cfa0ad4 100644
@@ -4699,11 +4699,6 @@ int atomisp_css_isr_thread(struct atomisp_device *isp,
 	return 0;
 }
 
-void atomisp_set_stop_timeout(unsigned int timeout)
-{
-	return;
-}
-
 bool atomisp_css_valid_sof(struct atomisp_device *isp)
 {
 	unsigned int i, j;
Signature · 1 line
2.7.4
#1 lore raw
Quoted 7 lines · simran singhal

The function atomisp_set_stop_timeout on being called, simply returns back. The function hasn't been mentioned in the TODO and doesn't have FIXME code around. Hence, atomisp_set_stop_timeout and its calls have been removed.

---

Hi Simran,

It's helpful to state right in the subject line what you removed. ie. remove unused function atomisp_set_stop_timeout()

If you do that, scan's or grep'ing the git log pretty oneline's can easily see this without having to dig into the log.

(gitpretty='git log --pretty=oneline --abbrev-commit')

Can you share to Outreachy group how you found this? By inspection or otherwise??

Thanks,
alisons

alisons

Quoted 54 lines
 drivers/staging/media/atomisp/pci/atomisp2/atomisp_cmd.c          | 1 -
 drivers/staging/media/atomisp/pci/atomisp2/atomisp_compat.h       | 1 -
 drivers/staging/media/atomisp/pci/atomisp2/atomisp_compat_css20.c | 5 -----
 3 files changed, 7 deletions(-)
drivers/staging/media/atomisp/pci/atomisp2/atomisp_cmd.c +0 -1
index e99f7b8..66299dd 100644
@@ -1700,7 +1700,6 @@ void atomisp_wdt_work(struct work_struct *work)
 		}
 	}
 #endif
-	atomisp_set_stop_timeout(ATOMISP_CSS_STOP_TIMEOUT_US);
 	dev_err(isp->dev, "timeout recovery handling done\n");
 	atomic_set(&isp->wdt_work_queued, 0);
 
drivers/staging/media/atomisp/pci/atomisp2/atomisp_compat.h +0 -1
index 5a404e4..0b9ced5 100644
@@ -660,7 +660,6 @@ int atomisp_css_set_acc_parameters(struct atomisp_acc_fw *acc_fw);
 int atomisp_css_isr_thread(struct atomisp_device *isp,
 			   bool *frame_done_found,
 			   bool *css_pipe_done);
-void atomisp_set_stop_timeout(unsigned int timeout);
 
 bool atomisp_css_valid_sof(struct atomisp_device *isp);
 
drivers/staging/media/atomisp/pci/atomisp2/atomisp_compat_css20.c +0 -5
index 6697d72..cfa0ad4 100644
@@ -4699,11 +4699,6 @@ int atomisp_css_isr_thread(struct atomisp_device *isp,
 	return 0;
 }
 
-void atomisp_set_stop_timeout(unsigned int timeout)
-{
-	return;
-}
-
 bool atomisp_css_valid_sof(struct atomisp_device *isp)
 {
 	unsigned int i, j;
Signature · 8 lines
2.7.4

-- 
You received this message because you are subscribed to the Google Groups "outreachy-kernel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit https://groups.google.com/d/msgid/outreachy-kernel/20170305064721.GA22548%40singhal-Inspiron-5558.
For more options, visit https://groups.google.com/d/optout.
#2 lore raw
Quoted 14 lines · Alison Schofield
Quoted 7 lines · simran singhal

The function atomisp_set_stop_timeout on being called, simply returns back. The function hasn't been mentioned in the TODO and doesn't have FIXME code around. Hence, atomisp_set_stop_timeout and its calls have been removed.

---

Hi Simran,

It's helpful to state right in the subject line what you removed. ie. remove unused function atomisp_set_stop_timeout()

Quoted 7 lines

If you do that, scan's or grep'ing the git log pretty oneline's can easily see this without having to dig into the log.

(gitpretty='git log --pretty=oneline --abbrev-commit')

Can you share to Outreachy group how you found this? By inspection or otherwise??

At least for the rtl8192u patch submitted:

It's also helpful to read the comment you remove and determine if what you are doing is the correct thing to do and explain why it's OK in the commit message. (fractured english below notwithstanding)

/* These function were added to load crypte module autoly */
- ieee80211_tkip_null();