linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "Martin K. Petersen" <martin.petersen@oracle.com>
To: Johannes Thumshirn <jthumshirn@suse.de>
Cc: "Martin K . Petersen" <martin.petersen@oracle.com>,
	Linux Kernel Mailinglist <linux-kernel@vger.kernel.org>,
	Linux SCSI Mailinglist <linux-scsi@vger.kernel.org>,
	Hannes Reinecke <hare@suse.de>,
	Bart Van Assche <bvanassche@acm.org>,
	Christoph Hellwig <hch@lst.de>
Subject: Re: [PATCH v2] scsi: sd: don't crash the host on invalid commands
Date: Tue, 25 Sep 2018 20:52:58 -0400	[thread overview]
Message-ID: <yq1tvmdgjv9.fsf@oracle.com> (raw)
In-Reply-To: <20180921070101.9260-1-jthumshirn@suse.de> (Johannes Thumshirn's message of "Fri, 21 Sep 2018 09:01:01 +0200")


Johannes,

> When sd_init_command() get's a with a unknown req_op() it crashes the
> system via BUG().
>
> This makes debugging the actual reason for the broken request
> cmd_flags pretty hard as the system is down before it's able to write
> out debugging data on the serial console or the trace buffer.
>
> Change the BUG() to a WARN_ON() and return BLKPREP_KILL to fail
> gracefully and return an I/O error to the producer of the request.

Looks like a bunch of my merge mails didn't make it out last week.

For the record, I did merge this into 4.19/scsi-fixes and it has made
its way upstream.

-- 
Martin K. Petersen	Oracle Linux Engineering

  parent reply	other threads:[~2018-09-26  0:53 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-09-21  7:01 [PATCH v2] scsi: sd: don't crash the host on invalid commands Johannes Thumshirn
2018-09-21 13:52 ` Bart Van Assche
2018-09-26  0:52 ` Martin K. Petersen [this message]
2018-09-26  6:51   ` Johannes Thumshirn

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=yq1tvmdgjv9.fsf@oracle.com \
    --to=martin.petersen@oracle.com \
    --cc=bvanassche@acm.org \
    --cc=hare@suse.de \
    --cc=hch@lst.de \
    --cc=jthumshirn@suse.de \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-scsi@vger.kernel.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).