All of lore.kernel.org
 help / color / mirror / Atom feed
From: syzbot <syzbot+e7d46eb426883fb97efd@syzkaller.appspotmail.com>
To: stern@rowland.harvard.edu
Cc: christophe.jaillet@wanadoo.fr, linux-usb@vger.kernel.org,
	stern@rowland.harvard.edu, syzkaller-bugs@googlegroups.com
Subject: Re: KMSAN: uninit-value in alauda_check_media
Date: Wed, 02 Aug 2023 09:05:05 -0700	[thread overview]
Message-ID: <000000000000b2c2d50601f2d36b@google.com> (raw)
In-Reply-To: <497564c2-632f-472a-914e-5e19488824ae@rowland.harvard.edu>

> This thread has been dormant for over a year and a half.  Let's revive 
> it and try to close out the issue.
>
> Alan Stern
>
> #syz test: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/ v6.5-rc3

Your commands are accepted, but please keep syzkaller-bugs@googlegroups.com mailing list in CC next time. It serves as a history of what happened with each bug report. Thank you.

>
> Index: usb-devel/drivers/usb/storage/alauda.c
> ===================================================================
> --- usb-devel.orig/drivers/usb/storage/alauda.c
> +++ usb-devel/drivers/usb/storage/alauda.c
> @@ -318,7 +318,8 @@ static int alauda_get_media_status(struc
>  	rc = usb_stor_ctrl_transfer(us, us->recv_ctrl_pipe,
>  		command, 0xc0, 0, 1, data, 2);
>  
> -	usb_stor_dbg(us, "Media status %02X %02X\n", data[0], data[1]);
> +	if (rc == USB_STOR_XFER_GOOD)
> +		usb_stor_dbg(us, "Media status %02X %02X\n", data[0], data[1]);
>  
>  	return rc;
>  }
> @@ -454,9 +455,14 @@ static int alauda_init_media(struct us_d
>  static int alauda_check_media(struct us_data *us)
>  {
>  	struct alauda_info *info = (struct alauda_info *) us->extra;
> -	unsigned char status[2];
> +	unsigned char *status = us->iobuf;
> +	int rc;
>  
> -	alauda_get_media_status(us, status);
> +	rc = alauda_get_media_status(us, status);
> +	if (rc != USB_STOR_XFER_GOOD) {
> +		status[0] = 0xF0;	/* Pretend there's no media */
> +		status[1] = 0;
> +	}
>  
>  	/* Check for no media or door open */
>  	if ((status[0] & 0x80) || ((status[0] & 0x1F) == 0x10)

  reply	other threads:[~2023-08-02 16:05 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-08-02 16:05 KMSAN: uninit-value in alauda_check_media Alan Stern
2023-08-02 16:05 ` syzbot [this message]
2023-08-02 16:35   ` Alan Stern
2023-08-02 17:01 ` [syzbot] [usb?] [usb-storage?] " syzbot
2023-08-02 17:49   ` [PATCH] usb-storage: alauda: Fix uninit-value in alauda_check_media() Alan Stern
     [not found] <cca3b7b4-d9cf-a275-ec0a-c99720a94049@wanadoo.fr>
2021-12-28  7:52 ` KMSAN: uninit-value in alauda_check_media syzbot
  -- strict thread matches above, loose matches on Subject: below --
2019-10-11 11:17 Jas K
2019-10-07 19:39 syzbot
2019-10-11 11:23 ` Jaskaran Singh
2019-10-11 11:51   ` Alexander Potapenko
2019-10-11 15:42     ` syzbot
2019-10-11 14:08   ` Alan Stern
2019-10-11 14:18     ` Andrey Konovalov
2019-10-11 14:53       ` Alan Stern
2019-10-11 15:06         ` Greg Kroah-Hartman
2019-10-14 12:56           ` Andrey Konovalov
2019-10-11 15:24   ` syzbot
2021-12-28  7:47 ` Christophe JAILLET
2021-12-28  7:47   ` syzbot
2021-12-28 22:49   ` Alan Stern
2021-12-29  9:16     ` Christophe JAILLET
2021-12-29 16:45       ` Alan Stern
2021-12-28  8:01 ` Christophe JAILLET

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=000000000000b2c2d50601f2d36b@google.com \
    --to=syzbot+e7d46eb426883fb97efd@syzkaller.appspotmail.com \
    --cc=christophe.jaillet@wanadoo.fr \
    --cc=linux-usb@vger.kernel.org \
    --cc=stern@rowland.harvard.edu \
    --cc=syzkaller-bugs@googlegroups.com \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.