mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: "Nicholas A. Bellinger" <nab@linux-iscsi.org>
To: Stefan Hajnoczi <stefanha@linux.vnet.ibm.com>
Cc: target-devel@vger.kernel.org, linux-scsi@vger.kernel.org,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH] target: Handle GET_EVENT_STATUS_NOTIFICATION passthrough
Date: Thu, 03 May 2012 18:24:06 -0700	[thread overview]
Message-ID: <1336094646.22393.102.camel@haakon2.linux-iscsi.org> (raw)
In-Reply-To: <1335800113-28075-1-git-send-email-stefanha@linux.vnet.ibm.com>

On Mon, 2012-04-30 at 16:35 +0100, Stefan Hajnoczi wrote:
> The SCSI MMC GET_EVENT_STATUS_NOTIFICATION command can be used to find
> out about media change, among other things.  This patch adds it to the
> command sequencer so that PSCSI CD-ROM passthrough works with modern
> Linux guests that issue this command.
> 
> Tested-by: Cong Meng <mengcong@cn.ibm.com>
> Signed-off-by: Stefan Hajnoczi <stefanha@linux.vnet.ibm.com>
> ---
>  drivers/target/target_core_transport.c |    4 ++++
>  1 file changed, 4 insertions(+)
> 
> diff --git a/drivers/target/target_core_transport.c b/drivers/target/target_core_transport.c
> index a953ca0..5b83fd2 100644
> --- a/drivers/target/target_core_transport.c
> +++ b/drivers/target/target_core_transport.c
> @@ -3146,6 +3146,10 @@ static int transport_generic_cmd_sequencer(
>  			cmd->sam_task_attr = MSG_HEAD_TAG;
>  		cmd->se_cmd_flags |= SCF_SCSI_CONTROL_SG_IO_CDB;
>  		break;
> +	case GET_EVENT_STATUS_NOTIFICATION:
> +		size = (cdb[7] << 8) | cdb[8];
> +		cmd->se_cmd_flags |= SCF_SCSI_CONTROL_SG_IO_CDB;
> +		break;
>  	default:
>  		pr_warn("TARGET_CORE[%s]: Unsupported SCSI Opcode"
>  			" 0x%02x, sending CHECK_CONDITION.\n",

Applied to lio-core, and will get this added into for-next for 3.5-rc1

Thanks Cong + Stefan!

--nab


      reply	other threads:[~2012-05-04  1:24 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-04-30 15:35 Stefan Hajnoczi
2012-05-04  1:24 ` Nicholas A. Bellinger [this message]

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=1336094646.22393.102.camel@haakon2.linux-iscsi.org \
    --to=nab@linux-iscsi.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-scsi@vger.kernel.org \
    --cc=stefanha@linux.vnet.ibm.com \
    --cc=target-devel@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

all inboxes | Powered by JetHome®