Received: by 2002:a05:7412:2a8c:b0:e2:908c:2ebd with SMTP id u12csp2500984rdh; Wed, 27 Sep 2023 04:49:31 -0700 (PDT) X-Google-Smtp-Source: AGHT+IE4N/KqzVMbW3vKgds7aKu9fxMVXQsODtJfdlvmprksg4WA62bcxD0Mg0QOXcWgD1axAM1w X-Received: by 2002:a17:902:ea10:b0:1c4:2271:55c3 with SMTP id s16-20020a170902ea1000b001c4227155c3mr1516105plg.38.1695815370809; Wed, 27 Sep 2023 04:49:30 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1695815370; cv=none; d=google.com; s=arc-20160816; b=yAI2dvEfLIV7ZZHlbFB6w+M5qIlMBXjVPr9wrWYOVhsZ0DqvclubkKT+7+Xw//Yemv KIve5WhNqP+iEJF5paF95cCdFOafjddZgqMMiOu/e2+4OgDpQEh10tc3kb7qGJPOWouq UVdfaChXpuPMXfpNHnG0rmXvTLE0GaunhMN+cT00AP7/14Yt/jEABsfmc4ev6Nd5WdEZ 8y0QAFx9e5m/2FTfjYHxX+GHcJ7jyGr9At0EeEW29+vedec0Hv2ZH9jSc9rKwjiIOP5K 5yhHSnWdG9I3F/6LFmmCPi2edppPUfRs1rakT+AlaLRpl3bai+6y5iN27s+o/pghJIOQ dm8w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to:from :references:cc:to:content-language:subject:user-agent:mime-version :date:message-id:dkim-signature:dkim-signature; bh=iMMMAkXIfCJBA1fnhBXlrKaQDS1jkKA6gpwpqc4OApU=; fh=SIFTRxdxx1z7UNwQF+Dg1sWUaEy+Bc5/TO8FwTvBp0E=; b=w1ElfrxSFs75xpvOe+lRrl0eS1QCps9URc9lLiI5Gpbj54wwqLdL2B8V3wV3ZkM7ck rmApB/VFfDxOcVLXdnD5GOBsJhgqo5x8hz11BO/lebv5iVT7BtJ0Wd1mH+T1BBBTRM+G UAdLmig9Oqn7a23Bi58/RBQP4jz0/qVaApx5A8cEtCHV3IlDWlxpa7UYYxHMn/+AtoDT PnsaOSczCy7J8w4I+JFbctkkljv3i95RC8TXMB26Heg12b0IxJ8ND1U1pxL7ScLiXYBO vLt/7FRJfMPUe9pXHP9S+Q9OSUkSdv3b867+QpFSd+/jF/tJaW5wcPF/qEq2zWTR64jy tG/w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@suse.de header.s=susede2_rsa header.b=ktWgBJDU; dkim=neutral (no key) header.i=@suse.de; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:2 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=suse.de Return-Path: Received: from agentk.vger.email (agentk.vger.email. [2620:137:e000::3:2]) by mx.google.com with ESMTPS id n12-20020a170902d2cc00b001b69ede5b79si4296497plc.470.2023.09.27.04.49.30 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 27 Sep 2023 04:49:30 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:2 as permitted sender) client-ip=2620:137:e000::3:2; Authentication-Results: mx.google.com; dkim=pass header.i=@suse.de header.s=susede2_rsa header.b=ktWgBJDU; dkim=neutral (no key) header.i=@suse.de; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:2 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=suse.de Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by agentk.vger.email (Postfix) with ESMTP id C6ADF80947FA; Tue, 26 Sep 2023 23:26:25 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at agentk.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229616AbjI0G0U (ORCPT + 99 others); Wed, 27 Sep 2023 02:26:20 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:40898 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229846AbjI0G0J (ORCPT ); Wed, 27 Sep 2023 02:26:09 -0400 Received: from smtp-out1.suse.de (smtp-out1.suse.de [195.135.220.28]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 2330D1A8; Tue, 26 Sep 2023 23:26:08 -0700 (PDT) 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-out1.suse.de (Postfix) with ESMTPS id B655921873; Wed, 27 Sep 2023 06:26:06 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_rsa; t=1695795966; 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=iMMMAkXIfCJBA1fnhBXlrKaQDS1jkKA6gpwpqc4OApU=; b=ktWgBJDUGFFX22xHnBuwDLIabwT1AksbzWTA7mv7gKbegGZMI0DqlqBKjZF1a8F0FnFEkZ +/gmw3ZKTYYD6cIztyrG1Tqqa1IA+N1m+gwm9AcnG5JhmsnC+J6Fd7Pd27wQGLx92/C2IY E4hGHgb3EfWuoebiy454mRdL9jQsVrE= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_ed25519; t=1695795966; 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=iMMMAkXIfCJBA1fnhBXlrKaQDS1jkKA6gpwpqc4OApU=; b=itz5ji7XRrmNIUxMaFZVmHJkUG0I1y0AmNVOaciU2yssUCqPtPXOyoDmUykHdoB9R1uGzO SfA0yR1+Pec/jdDg== 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 C355113479; Wed, 27 Sep 2023 06:26:05 +0000 (UTC) Received: from dovecot-director2.suse.de ([192.168.254.65]) by imap2.suse-dmz.suse.de with ESMTPSA id Vqo9Kv3KE2VMIwAAMHmgww (envelope-from ); Wed, 27 Sep 2023 06:26:05 +0000 Message-ID: Date: Wed, 27 Sep 2023 08:26:05 +0200 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [RFC PATCH v2 00/18] scsi: scsi_error: Introduce new error handle mechanism Content-Language: en-US To: Christoph Hellwig , Mike Christie Cc: Wenchao Hao , "James E . J . Bottomley" , "Martin K . Petersen" , linux-scsi@vger.kernel.org, linux-kernel@vger.kernel.org, louhongxiang@huawei.com, lixiaokeng@huawei.com References: <20230901094127.2010873-1-haowenchao2@huawei.com> <47bed3cb-f307-ec55-5c28-051687dab1ea@huawei.com> From: Hannes Reinecke In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-0.9 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on agentk.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (agentk.vger.email [0.0.0.0]); Tue, 26 Sep 2023 23:26:26 -0700 (PDT) On 9/26/23 09:26, Christoph Hellwig wrote: > On Mon, Sep 25, 2023 at 12:54:48PM -0500, Mike Christie wrote: >> I think we want to figure out Hannes's patches first. > > Yes. > >> For a new EH design we will want to be able to do multiple TMFs in parallel >> on the same host/target right? >> >> The problem is that we need to be able to make forward progress in the EH >> path and not fail just because we can't allocate memory for a TMF related >> struct. To accomplish this now, drivers will use mempools, preallocate TMF >> related structs/mem/tags with their scsi_cmnd related structs, preallocate >> per host/target/device related structs or ignore what I wrote above and just >> fail. >> >> Hannes's patches fix up the eh callouts so they don't pass in a scsi_cmnd >> when it's not needed. That seems nice because after that, then for your new >> EH we can begin to standardize on how to handle preallocation of drivers >> resources needed to perform TMFs for your new EH. It could be a per >> device/target/host callout to allow drivers to preallocate, then scsi-ml calls >> into the drivers with that data. It doesn't have to be exactly like that or >> anything close. It would be nice for drivers to not have to think about this >> type of thing and scsi-ml just to handle the resource management for us when >> there are multiple TMFs in progress. > > Exactly! Yeah, thanks for the vote of support. Last time I tried the attempt got shot down, as it had been using the 'wrong' interface. But seeing that there's renewed interest I'll be reposting them. 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: Ivo Totev, Andrew Myers, Andrew McDonald, Martje Boudien Moerman