* [PATCH 1/1] input: sentelic: Releasing mutex upon register writing failure
@ 2011-12-16 7:07 Tai-hwa Liang
2011-12-22 17:52 ` Dmitry Torokhov
0 siblings, 1 reply; 3+ messages in thread
From: Tai-hwa Liang @ 2011-12-16 7:07 UTC (permalink / raw)
To: Dmitry Torokhov; +Cc: linux-input, Tai-hwa Liang, Paul Fox
Making sure that mutex is released upon register writing failure.
This fixes boot freezing observed on ARM based OLPC
(http://dev.laptop.org/ticket/11357).
Signed-off-by: Paul Fox <pgf@laptop.org>
Acked-by: Tai-hwa Liang <avatar@sentelic.com>
---
drivers/input/mouse/sentelic.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/input/mouse/sentelic.c b/drivers/input/mouse/sentelic.c
index 5babc47..7e96a5d 100644
--- a/drivers/input/mouse/sentelic.c
+++ b/drivers/input/mouse/sentelic.c
@@ -162,7 +162,7 @@ static int fsp_reg_write(struct psmouse *psmouse, int reg_addr, int reg_val)
ps2_sendbyte(ps2dev, v, FSP_CMD_TIMEOUT2);
if (ps2_sendbyte(ps2dev, 0xf3, FSP_CMD_TIMEOUT) < 0)
- return -1;
+ goto out;
if ((v = fsp_test_invert_cmd(reg_val)) != reg_val) {
/* inversion is required */
@@ -261,7 +261,7 @@ static int fsp_page_reg_write(struct psmouse *psmouse, int reg_val)
ps2_sendbyte(ps2dev, 0x88, FSP_CMD_TIMEOUT2);
if (ps2_sendbyte(ps2dev, 0xf3, FSP_CMD_TIMEOUT) < 0)
- return -1;
+ goto out;
if ((v = fsp_test_invert_cmd(reg_val)) != reg_val) {
ps2_sendbyte(ps2dev, 0x47, FSP_CMD_TIMEOUT2);
--
1.7.7.3
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH 1/1] input: sentelic: Releasing mutex upon register writing failure
2011-12-16 7:07 [PATCH 1/1] input: sentelic: Releasing mutex upon register writing failure Tai-hwa Liang
@ 2011-12-22 17:52 ` Dmitry Torokhov
2011-12-23 1:08 ` Tai-hwa Liang
0 siblings, 1 reply; 3+ messages in thread
From: Dmitry Torokhov @ 2011-12-22 17:52 UTC (permalink / raw)
To: Tai-hwa Liang; +Cc: linux-input, Paul Fox
Hi Tai-hwa,
On Fri, Dec 16, 2011 at 03:07:54PM +0800, Tai-hwa Liang wrote:
> Making sure that mutex is released upon register writing failure.
> This fixes boot freezing observed on ARM based OLPC
> (http://dev.laptop.org/ticket/11357).
>
> Signed-off-by: Paul Fox <pgf@laptop.org>
> Acked-by: Tai-hwa Liang <avatar@sentelic.com>
Since you are actually passing the patch to me there should be your
"Signed-off-by:.. " instead of (or in addtion to) your "Acked-by".
Thanks!
> ---
> drivers/input/mouse/sentelic.c | 4 ++--
> 1 files changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/input/mouse/sentelic.c b/drivers/input/mouse/sentelic.c
> index 5babc47..7e96a5d 100644
> --- a/drivers/input/mouse/sentelic.c
> +++ b/drivers/input/mouse/sentelic.c
> @@ -162,7 +162,7 @@ static int fsp_reg_write(struct psmouse *psmouse, int reg_addr, int reg_val)
> ps2_sendbyte(ps2dev, v, FSP_CMD_TIMEOUT2);
>
> if (ps2_sendbyte(ps2dev, 0xf3, FSP_CMD_TIMEOUT) < 0)
> - return -1;
> + goto out;
>
> if ((v = fsp_test_invert_cmd(reg_val)) != reg_val) {
> /* inversion is required */
> @@ -261,7 +261,7 @@ static int fsp_page_reg_write(struct psmouse *psmouse, int reg_val)
> ps2_sendbyte(ps2dev, 0x88, FSP_CMD_TIMEOUT2);
>
> if (ps2_sendbyte(ps2dev, 0xf3, FSP_CMD_TIMEOUT) < 0)
> - return -1;
> + goto out;
>
> if ((v = fsp_test_invert_cmd(reg_val)) != reg_val) {
> ps2_sendbyte(ps2dev, 0x47, FSP_CMD_TIMEOUT2);
> --
> 1.7.7.3
>
--
Dmitry
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH 1/1] input: sentelic: Releasing mutex upon register writing failure
2011-12-22 17:52 ` Dmitry Torokhov
@ 2011-12-23 1:08 ` Tai-hwa Liang
0 siblings, 0 replies; 3+ messages in thread
From: Tai-hwa Liang @ 2011-12-23 1:08 UTC (permalink / raw)
To: Dmitry Torokhov; +Cc: linux-input, Paul Fox
On Thu, 22 Dec 2011, Dmitry Torokhov wrote:
> Hi Tai-hwa,
>
> On Fri, Dec 16, 2011 at 03:07:54PM +0800, Tai-hwa Liang wrote:
> > Making sure that mutex is released upon register writing failure.
> > This fixes boot freezing observed on ARM based OLPC
> > (http://dev.laptop.org/ticket/11357).
> >
> > Signed-off-by: Paul Fox <pgf@laptop.org>
> > Acked-by: Tai-hwa Liang <avatar@sentelic.com>
>
> Since you are actually passing the patch to me there should be your
> "Signed-off-by:.. " instead of (or in addtion to) your "Acked-by".
>
> Thanks!
Sure. Thank you.
Signed-off-by: Tai-hwa Liang <avatar@sentelic.com>
>
> > ---
> > drivers/input/mouse/sentelic.c | 4 ++--
> > 1 files changed, 2 insertions(+), 2 deletions(-)
> >
> > diff --git a/drivers/input/mouse/sentelic.c b/drivers/input/mouse/sentelic.c
> > index 5babc47..7e96a5d 100644
> > --- a/drivers/input/mouse/sentelic.c
> > +++ b/drivers/input/mouse/sentelic.c
> > @@ -162,7 +162,7 @@ static int fsp_reg_write(struct psmouse *psmouse, int reg_addr, int reg_val)
> > ps2_sendbyte(ps2dev, v, FSP_CMD_TIMEOUT2);
> >
> > if (ps2_sendbyte(ps2dev, 0xf3, FSP_CMD_TIMEOUT) < 0)
> > - return -1;
> > + goto out;
> >
> > if ((v = fsp_test_invert_cmd(reg_val)) != reg_val) {
> > /* inversion is required */
> > @@ -261,7 +261,7 @@ static int fsp_page_reg_write(struct psmouse *psmouse, int reg_val)
> > ps2_sendbyte(ps2dev, 0x88, FSP_CMD_TIMEOUT2);
> >
> > if (ps2_sendbyte(ps2dev, 0xf3, FSP_CMD_TIMEOUT) < 0)
> > - return -1;
> > + goto out;
> >
> > if ((v = fsp_test_invert_cmd(reg_val)) != reg_val) {
> > ps2_sendbyte(ps2dev, 0x47, FSP_CMD_TIMEOUT2);
> > --
> > 1.7.7.3
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2011-12-23 1:08 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-12-16 7:07 [PATCH 1/1] input: sentelic: Releasing mutex upon register writing failure Tai-hwa Liang
2011-12-22 17:52 ` Dmitry Torokhov
2011-12-23 1:08 ` Tai-hwa Liang
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).