Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1500864
| From | SF Markus Elfring <elfring@users.sourceforge.net> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | [PATCH 3/5] [media] winbond-cir: Move assignments for three variables in wbcir_shutdown() |
| Date | 2016-10-14 13:50 +0200 |
| Message-ID | <ss99V-JJ-65@gated-at.bofh.it> (permalink) |
| References | <qEuGl-43C-5@gated-at.bofh.it> <ss99T-JJ-1@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
From: Markus Elfring <elfring@users.sourceforge.net>
Date: Fri, 14 Oct 2016 10:40:12 +0200
Move the setting for the local variables "mask", "match" and "rc6_csl"
behind the source code for a condition check by this function
at the beginning.
Signed-off-by: Markus Elfring <elfring@users.sourceforge.net>
---
drivers/media/rc/winbond-cir.c | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/drivers/media/rc/winbond-cir.c b/drivers/media/rc/winbond-cir.c
index fd997f0..9d05e17 100644
--- a/drivers/media/rc/winbond-cir.c
+++ b/drivers/media/rc/winbond-cir.c
@@ -702,17 +702,17 @@ wbcir_shutdown(struct pnp_dev *device)
bool do_wake = true;
u8 match[11];
u8 mask[11];
- u8 rc6_csl = 0;
+ u8 rc6_csl;
int i;
- memset(match, 0, sizeof(match));
- memset(mask, 0, sizeof(mask));
-
if (wake_sc == INVALID_SCANCODE || !device_may_wakeup(dev)) {
do_wake = false;
goto finish;
}
+ rc6_csl = 0;
+ memset(match, 0, sizeof(match));
+ memset(mask, 0, sizeof(mask));
switch (protocol) {
case IR_PROTOCOL_RC5:
if (wake_sc > 0xFFF) {
--
2.10.1
Back to linux.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
[PATCH 0/5] [media] winbond-cir: Fine-tuning for four function implementations SF Markus Elfring <elfring@users.sourceforge.net> - 2016-10-14 13:50 +0200
[PATCH 2/5] [media] winbond-cir: Move a variable assignment in wbcir_tx() SF Markus Elfring <elfring@users.sourceforge.net> - 2016-10-14 13:50 +0200
Re: [PATCH 2/5] [media] winbond-cir: Move a variable assignment in wbcir_tx() "David Härdeman" <david@hardeman.nu> - 2016-10-19 17:40 +0200
Re: [media] winbond-cir: Move a variable assignment in wbcir_tx() SF Markus Elfring <elfring@users.sourceforge.net> - 2016-10-19 18:30 +0200
[PATCH 5/5] [media] winbond-cir: Move a variable assignment in two functions SF Markus Elfring <elfring@users.sourceforge.net> - 2016-10-14 13:50 +0200
Re: [PATCH 5/5] [media] winbond-cir: Move a variable assignment in two functions "David Härdeman" <david@hardeman.nu> - 2016-10-19 16:30 +0200
[PATCH 4/5] [media] winbond-cir: One variable and its check less in wbcir_shutdown() after error detection SF Markus Elfring <elfring@users.sourceforge.net> - 2016-10-14 13:50 +0200
Re: [PATCH 4/5] [media] winbond-cir: One variable and its check less in wbcir_shutdown() after error detection Sean Young <sean@mess.org> - 2016-10-15 15:40 +0200
Re: [PATCH 4/5] [media] winbond-cir: One variable and its check less in wbcir_shutdown() after error detection SF Markus Elfring <elfring@users.sourceforge.net> - 2016-10-15 18:50 +0200
Re: [PATCH 4/5] [media] winbond-cir: One variable and its check less in wbcir_shutdown() after error detection "David Härdeman" <david@hardeman.nu> - 2016-10-19 16:30 +0200
Re: [PATCH 4/5] [media] winbond-cir: One variable and its check less in wbcir_shutdown() after error detection SF Markus Elfring <elfring@users.sourceforge.net> - 2016-10-19 18:30 +0200
Re: [PATCH 4/5] [media] winbond-cir: One variable and its check less in wbcir_shutdown() after error detection "David Härdeman" <david@hardeman.nu> - 2016-10-19 16:30 +0200
[PATCH 1/5] [media] winbond-cir: Use kmalloc_array() in wbcir_tx() SF Markus Elfring <elfring@users.sourceforge.net> - 2016-10-14 13:50 +0200
Re: [PATCH 1/5] [media] winbond-cir: Use kmalloc_array() in wbcir_tx() "David Härdeman" <david@hardeman.nu> - 2016-10-19 17:40 +0200
[PATCH 3/5] [media] winbond-cir: Move assignments for three variables in wbcir_shutdown() SF Markus Elfring <elfring@users.sourceforge.net> - 2016-10-14 13:50 +0200
Re: [PATCH 3/5] [media] winbond-cir: Move assignments for three variables in wbcir_shutdown() "David Härdeman" <david@hardeman.nu> - 2016-10-19 16:30 +0200
Re: [media] winbond-cir: Move assignments for three variables in wbcir_shutdown() SF Markus Elfring <elfring@users.sourceforge.net> - 2016-10-19 16:30 +0200
Re: [media] winbond-cir: Move assignments for three variables in wbcir_shutdown() "David Härdeman" <david@hardeman.nu> - 2016-10-19 17:50 +0200
Re: [media] winbond-cir: Move a variable assignment in two functions SF Markus Elfring <elfring@users.sourceforge.net> - 2016-10-19 16:20 +0200
Re: [media] winbond-cir: Move a variable assignment in wbcir_tx() SF Markus Elfring <elfring@users.sourceforge.net> - 2016-10-19 16:20 +0200
Re: [media] winbond-cir: Move assignments for three variables in wbcir_shutdown() SF Markus Elfring <elfring@users.sourceforge.net> - 2016-10-19 16:20 +0200
Re: [media] winbond-cir: Move a variable assignment in wbcir_tx() "David Härdeman" <david@hardeman.nu> - 2016-10-19 16:30 +0200
csiph-web