Received: by 2002:a05:6a10:5bc5:0:0:0:0 with SMTP id os5csp4224176pxb; Thu, 14 Oct 2021 00:38:34 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwNF3Rm0JfJL6SjGNxxIuQmTngkkSJlOhHnnD1nCKx9817bUU+Rff/1WTcACIzw1/UfR3Og X-Received: by 2002:a05:6402:1c94:: with SMTP id cy20mr5207462edb.144.1634197113947; Thu, 14 Oct 2021 00:38:33 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1634197113; cv=none; d=google.com; s=arc-20160816; b=cweb+GuH0b2KuB7CtcRkZAdRxpNCXdhK7bA09pIAa/wn2Phasc8nYHEZoYTX8JXuvZ yME8XJ9CqdMynDVxTBZ0S5IlDs7BlN9Kk6rUTfNrhnetTH7puC9wKfMFTi0a1j1lhneJ lCywgdlVmkQUxatFXnTGfokp2OahedNkva3T5gZoajkbOox0hVORPOYabAEIfufdx7Lg UzMvQBDRqZv4zF0BoQk62+bPamYA8CB+axq3VRyC44p8vqOCmyPXfvfe5CAlOEHTNgMj h5tEHl3LiFZZXbdFtxr6IZvNYFNCXJPZh1x8+gBoEAf9Jhuqb7UpjQdzHfbQzCkwTlny a/5A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:content-language :in-reply-to:mime-version:user-agent:date:message-id:from:references :cc:to:subject:dkim-signature:dkim-signature; bh=vc6k1LW6+P7JIUbPAN5DAvg8nAR+IqMh7t9qU2NYaCY=; b=HYt45/EK47K+HyHnbyJHE4WjZXoh9Yfd/3NYTp66OfI/32UWbn8AeTViQIgyMMekF9 G/hGJxAb165U2f5ZE1tgWKe9jTytJQQY+hdpNTUmXtBQV5aYBYcCAMFz5xJYQGLg4hcn mx17OnE0ZJqr3V4tfQjZP8hmyoNLlLI/Aagd/CMZEXMJTHmTHWqjfZkl73uWv3mbSBzK yiw1cepRLhF6g18Yvi6Rv8uFrlAOZf8ewIGWqOJyYW7LJseq3xg6NCCKa+fGOq7JvJjh mJImbfjpFnndrRnO1S+r+1prkjZhnil5CVuI6IVikc6GRV7ut3fgHC2RlSjaIbuYbPt5 anpw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@suse.de header.s=susede2_rsa header.b="R/c8xngR"; dkim=neutral (no key) header.i=@suse.de header.b="/LpmFZWY"; spf=pass (google.com: domain of linux-nfs-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-nfs-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=suse.de Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id s13si2745631eju.701.2021.10.14.00.38.08; Thu, 14 Oct 2021 00:38:33 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-nfs-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@suse.de header.s=susede2_rsa header.b="R/c8xngR"; dkim=neutral (no key) header.i=@suse.de header.b="/LpmFZWY"; spf=pass (google.com: domain of linux-nfs-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-nfs-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=suse.de Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230007AbhJNHjw (ORCPT + 99 others); Thu, 14 Oct 2021 03:39:52 -0400 Received: from smtp-out2.suse.de ([195.135.220.29]:47362 "EHLO smtp-out2.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229551AbhJNHjv (ORCPT ); Thu, 14 Oct 2021 03:39:51 -0400 Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by smtp-out2.suse.de (Postfix) with ESMTPS id 5F04120286; Thu, 14 Oct 2021 07:37:46 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_rsa; t=1634197066; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=vc6k1LW6+P7JIUbPAN5DAvg8nAR+IqMh7t9qU2NYaCY=; b=R/c8xngRvX6e3D3q3mdt6P9Accv9lrbY/1Vf/cQsDoSgFHFYTHCJbZXMeNL3mZpkWT7iXw ozUNS5HlrZ2nR3WvWvlBKhAZepZfC1LFA43ZtpuE8O1l1nE+v8QtCofYhv0IgnMzaoQZLq JXxaRgmrru57drOof5vL4dppQZODwGg= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_ed25519; t=1634197066; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=vc6k1LW6+P7JIUbPAN5DAvg8nAR+IqMh7t9qU2NYaCY=; b=/LpmFZWYnyN3KLJrI3KqiPijypyFv3X5R0qNMbtAMlr6STQ91p7pbu3M/6W/jUut4TeZvs qiY+cmSc8aiBjFCQ== Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by imap2.suse-dmz.suse.de (Postfix) with ESMTPS id 28B4513D3F; Thu, 14 Oct 2021 07:37:46 +0000 (UTC) Received: from dovecot-director2.suse.de ([192.168.254.65]) by imap2.suse-dmz.suse.de with ESMTPSA id HusJCUreZ2FkIAAAMHmgww (envelope-from ); Thu, 14 Oct 2021 07:37:46 +0000 Subject: Re: [PATCH 5/7] scsi: add a scsi_alloc_request helper To: Christoph Hellwig , Jens Axboe , "Martin K. Petersen" Cc: "J. Bruce Fields" , Chuck Lever , linux-block@vger.kernel.org, linux-scsi@vger.kernel.org, target-devel@vger.kernel.org, linux-nfs@vger.kernel.org References: <20211012120445.861860-1-hch@lst.de> <20211012120445.861860-6-hch@lst.de> From: Hannes Reinecke Message-ID: Date: Thu, 14 Oct 2021 09:37:45 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.12.0 MIME-Version: 1.0 In-Reply-To: <20211012120445.861860-6-hch@lst.de> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-nfs@vger.kernel.org On 10/12/21 2:04 PM, Christoph Hellwig wrote: > Add a new helper that calls blk_get_request and initializes the > scsi_request to avoid the indirect call through ->.initialize_rq_fn. > > Note that this makes the pktcdvd driver depend on the SCSI core, but > given that only SCSI devices support SCSI passthrough requests that > is not a functional change. > > Signed-off-by: Christoph Hellwig > --- > drivers/block/Kconfig | 2 +- > drivers/block/pktcdvd.c | 2 +- > drivers/scsi/scsi_bsg.c | 4 ++-- > drivers/scsi/scsi_error.c | 2 +- > drivers/scsi/scsi_ioctl.c | 4 ++-- > drivers/scsi/scsi_lib.c | 19 +++++++++++++------ > drivers/scsi/sg.c | 4 ++-- > drivers/scsi/sr.c | 2 +- > drivers/scsi/st.c | 2 +- > drivers/target/target_core_pscsi.c | 3 +-- > include/scsi/scsi_cmnd.h | 3 +++ > 11 files changed, 28 insertions(+), 19 deletions(-) > Reviewed-by: Hannes Reinecke Cheers, Hannes -- Dr. Hannes Reinecke Kernel Storage Architect hare@suse.de +49 911 74053 688 SUSE Software Solutions GmbH, Maxfeldstr. 5, 90409 Nürnberg HRB 36809 (AG Nürnberg), Geschäftsführer: Felix Imendörffer