Linux-USB Archive on lore.kernel.org
 help / color / Atom feed
From: Phong Tran <tranmanphong@gmail.com>
To: David Miller <davem@davemloft.net>
Cc: tranmanphong@gmail.com,
	syzbot+7dc7c28d4577bbe55b10@syzkaller.appspotmail.com,
	gregkh@linuxfoundation.org, glider@google.com,
	hslester96@gmail.com, kstewart@linuxfoundation.org,
	linux-kernel@vger.kernel.org, linux-usb@vger.kernel.org,
	netdev@vger.kernel.org, syzkaller-bugs@googlegroups.com,
	tglx@linutronix.de,
	linux-kernel-mentees@lists.linuxfoundation.org
Subject: Re: Re: [PATCH] usb: asix: Fix uninit-value in asix_mdio_write
Date: Sun, 10 Nov 2019 21:11:11 +0700
Message-ID: <5679efce-797a-ea2c-f7fb-882ac450e9d2@gmail.com> (raw)
In-Reply-To: <20191107.152118.922830217121663373.davem@davemloft.net>



On 11/8/19 6:21 AM, David Miller wrote:
> From: Phong Tran <tranmanphong@gmail.com>
> Date: Thu,  7 Nov 2019 07:44:04 +0700
> 
>> The local variables use without initilization value.
>> This fixes the syzbot report.
>>
>> Reported-by: syzbot+7dc7c28d4577bbe55b10@syzkaller.appspotmail.com
>>
>> Test result:
>>
>> https://groups.google.com/d/msg/syzkaller-bugs/3H_n05x_sPU/sUoHhxgAAgAJ
>>
>> Signed-off-by: Phong Tran <tranmanphong@gmail.com>
> 
> There are several more situations in this file where the data blob passed
> to asix_read_cmd() is read without pre-initialization not checking the
> return value from asix_read_cmd().
> 
> So, syzbot can see some of them but not all of them, yet all of them
> are buggy and should be fixed.
> 
> These kinds of patches drive me absolutely crazy :-)
> 
> Really, one of two things needs to happen, either asix_read_cmd() clears
> the incoming buffer unconditionally, 

thank you for your suggestion.
Sent Patch v2 reply-to this mail thread.

regards,
Phong.

      parent reply index

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-10-15 21:22 KMSAN: " syzbot
2019-11-07  0:44 ` [PATCH] usb: asix: Fix " Phong Tran
2019-11-07 23:21   ` David Miller
2019-11-10 14:07     ` [[Patch V2]] usb: asix: cleanup the buffer in asix_read_cmd Phong Tran
2019-11-10 14:11     ` Phong Tran [this message]

Reply instructions:

You may reply publically 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=5679efce-797a-ea2c-f7fb-882ac450e9d2@gmail.com \
    --to=tranmanphong@gmail.com \
    --cc=davem@davemloft.net \
    --cc=glider@google.com \
    --cc=gregkh@linuxfoundation.org \
    --cc=hslester96@gmail.com \
    --cc=kstewart@linuxfoundation.org \
    --cc=linux-kernel-mentees@lists.linuxfoundation.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-usb@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=syzbot+7dc7c28d4577bbe55b10@syzkaller.appspotmail.com \
    --cc=syzkaller-bugs@googlegroups.com \
    --cc=tglx@linutronix.de \
    /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

Linux-USB Archive on lore.kernel.org

Archives are clonable:
	git clone --mirror https://lore.kernel.org/linux-usb/0 linux-usb/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 linux-usb linux-usb/ https://lore.kernel.org/linux-usb \
		linux-usb@vger.kernel.org
	public-inbox-index linux-usb

Example config snippet for mirrors

Newsgroup available over NNTP:
	nntp://nntp.lore.kernel.org/org.kernel.vger.linux-usb


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git