linux-input.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Pan Zhang <zhangpan26@huawei.com>
To: <zhangpan26@huawei.com>, <hushiyuan@huawei.com>,
	<jikos@kernel.org>, <benjamin.tissoires@redhat.com>,
	<rydberg@bitmath.org>
Cc: <linux-input@vger.kernel.org>, <linux-kernel@vger.kernel.org>
Subject: Re: Re: [PATCH v2] drivers/hid/hid-multitouch.c: fix a possible null pointer access.
Date: Tue, 17 Dec 2019 20:28:07 +0800	[thread overview]
Message-ID: <1576585687-10426-1-git-send-email-zhangpan26@huawei.com> (raw)
In-Reply-To: <CAO-hwJ+5Ch02fPQ+XF=A4iEcH81V5PrCdV2qGQDZ8HxnQAoEog@mail.gmail.com>

On Tue, Dec 17, 2019 at 18:50 PM Benjamin Tissoires <benjamin.tissoires@redhat.com> wrote:

>Can you add at the beginning of your commit message:
>From: Pan Zhang <zhangpan26@huawei.com>
>
>This way we have the commit author that matches the signature, which is a requirement for the kernel.

Firstly, thanks for your reviewing very much. I would fix my signature.

>>  drivers/hid/hid-multitouch.c | 2 +-
>>  1 file changed, 1 insertion(+), 1 deletion(-)
>>
>> diff --git a/drivers/hid/hid-multitouch.c 
>> b/drivers/hid/hid-multitouch.c index 3cfeb16..368de81 100644
>> --- a/drivers/hid/hid-multitouch.c
>> +++ b/drivers/hid/hid-multitouch.c
>> @@ -1019,7 +1019,7 @@ static int mt_process_slot(struct mt_device *td, struct input_dev *input,
>>                 tool = MT_TOOL_DIAL;
>>         else if (unlikely(!confidence_state)) {
>>                 tool = MT_TOOL_PALM;
>> -               if (!active &&
>> +               if (!active && mt

>Ack on the principle, but this doesn't even compile. You are missing a `&&` at the end of the line.
>
>Can you send a v2 with the comments above? And we will queue the v2 for 5.5 I think.

Sorry about that. I made a stupid mistake. This patch fixed it.

Signed-off-by: Pan Zhang <zhangpan26@huawei.com>
---
 drivers/hid/hid-multitouch.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/hid/hid-multitouch.c b/drivers/hid/hid-multitouch.c
index 3cfeb16..368de81 100644
--- a/drivers/hid/hid-multitouch.c
+++ b/drivers/hid/hid-multitouch.c
@@ -1019,7 +1019,7 @@ static int mt_process_slot(struct mt_device *td, struct input_dev *input,
 		tool = MT_TOOL_DIAL;
 	else if (unlikely(!confidence_state)) {
 		tool = MT_TOOL_PALM;
-		if (!active &&
+		if (!active && mt &&
 		    input_mt_is_active(&mt->slots[slotnum])) {
 			/*
 			 * The non-confidence was reported for
-- 
2.7.4


  reply	other threads:[~2019-12-17 12:28 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-12-17  3:02 [PATCH] drivers/hid/hid-multitouch.c: fix a possible null pointer access z00417012
2019-12-17 10:49 ` Benjamin Tissoires
2019-12-17 12:28   ` Pan Zhang [this message]
2019-12-18 14:05     ` Re: [PATCH v2] " Benjamin Tissoires

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1576585687-10426-1-git-send-email-zhangpan26@huawei.com \
    --to=zhangpan26@huawei.com \
    --cc=benjamin.tissoires@redhat.com \
    --cc=hushiyuan@huawei.com \
    --cc=jikos@kernel.org \
    --cc=linux-input@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=rydberg@bitmath.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).