Received: by 2002:a05:6358:d09b:b0:dc:cd0c:909e with SMTP id jc27csp3071220rwb; Mon, 7 Nov 2022 23:34:09 -0800 (PST) X-Google-Smtp-Source: AA0mqf4T9ltpHWg8eVisIs75E2LH57idnSiH/djo3Il0zeuVhrNB1j/4SG+xMELtRtsouptFARdU X-Received: by 2002:a17:907:2e0b:b0:7a7:d37e:4650 with SMTP id ig11-20020a1709072e0b00b007a7d37e4650mr10631734ejc.261.1667892848934; Mon, 07 Nov 2022 23:34:08 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1667892848; cv=none; d=google.com; s=arc-20160816; b=HZx/VDscvXrWFMh+swV+Argw2oWlAn5hwRBKqFu3hQwLyDE6YqqmQMT3+vIKobHoKu jWdPiBwPRceREsTGbnMJ6RnVnWkNj7/d/F6/DIoVkJlkc20hb2gItZJFWtjLYRnhuPF2 ds2NgolXtAOixFIQrfDp1AHdhfCinPVFs8XlZ6k8GK2xe/g03+1jx/EgnJgbzW8Jl8P7 sLc2Lhs35knlefPGApLMG8AabA33Rl9JcDTO94rLA5c5oLpixTTd2bzc3AZmp7Cr51uD Z7pTmM0HCHl/1U6wnMHtMh/CUR6XR22WWAjPuvmuRBP+UPL7ZOIDri3a1uu5rtRHb64V Audw== 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=9HsuM9y0VlNY6STi9GVfvRAUeLwjjk0OZ0q1YrHxZxA=; b=dv8l2w28px5cMmIqV7xkBCZgX55mTaD7gHA+dNVrsJ0V8TU3K9iHWF8+Df2ThHX2iZ 4qT6qMvw/wCHDMBNpCIeFwhjyc6pcO1n7BfcsRfQt4ho+vmFgza8wjNgNn/anBREJZyk Kli4wu9JK6jeOJNUtCt8GJYY8QLgK/740hwk1b58Puv2o7e0vwKIkYMbESMmMF6BW1nx jZOERmpnpEQiTSLLFhf5tLuBLH9JVdyQ1/ZWnzoIfdV9NqOzuxSJlfxlwI5D1qMMFtMK +wioSuSZIzYjy88D9seMxgwN/FDitn64fFK1rl6cRbj/D7GKmhmIVvwnc6l7BENS9BIB E8wA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@suse.de header.s=susede2_rsa header.b=PQlOorVS; dkim=neutral (no key) header.i=@suse.de header.s=susede2_ed25519 header.b=Wz2Raops; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 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 out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id nd32-20020a17090762a000b007a1e33462c1si11100149ejc.268.2022.11.07.23.33.47; Mon, 07 Nov 2022 23:34:08 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@suse.de header.s=susede2_rsa header.b=PQlOorVS; dkim=neutral (no key) header.i=@suse.de header.s=susede2_ed25519 header.b=Wz2Raops; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-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 S233412AbiKHG5M (ORCPT + 90 others); Tue, 8 Nov 2022 01:57:12 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:52036 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232641AbiKHG5K (ORCPT ); Tue, 8 Nov 2022 01:57:10 -0500 Received: from smtp-out2.suse.de (smtp-out2.suse.de [195.135.220.29]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 074941FCD3; Mon, 7 Nov 2022 22:57:09 -0800 (PST) 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 7F4021F899; Tue, 8 Nov 2022 06:57:08 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_rsa; t=1667890628; 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=9HsuM9y0VlNY6STi9GVfvRAUeLwjjk0OZ0q1YrHxZxA=; b=PQlOorVSacK9kBqqDTVufL791tp1f97C0geHzbp95MGeTsZrL1SptB3ufb5MIGOH3E0VS5 SgA1P81wR6/yW64dw1I5HhiMvWcSkEnAPdk93oIE35HbD0DuKzNIG7KtE+5LU5u0OtM7I0 0cnYUrxTZTQEfIn2X4QIp0V7K/MsUkQ= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_ed25519; t=1667890628; 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=9HsuM9y0VlNY6STi9GVfvRAUeLwjjk0OZ0q1YrHxZxA=; b=Wz2Raops3HzN72/wiUuvca6T64lLPFg4WcdKN/30PzSOnpqusLRxF3vKEsWuQwrvWe7ViB iRiZO1hdcKaXyuAw== 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 57ABE139F1; Tue, 8 Nov 2022 06:57:08 +0000 (UTC) Received: from dovecot-director2.suse.de ([192.168.254.65]) by imap2.suse-dmz.suse.de with ESMTPSA id 4e3RFMT9aWMzIQAAMHmgww (envelope-from ); Tue, 08 Nov 2022 06:57:08 +0000 Message-ID: <6349abb3-9fb5-8bd1-7d71-e8a1435b0cef@suse.de> Date: Tue, 8 Nov 2022 07:57:09 +0100 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.2.2 Subject: Re: [PATCH] scsi: core: Add BLIST_NO_ASK_VPD_SIZE for some VDASD Content-Language: en-US To: "Martin K. Petersen" Cc: Bart Van Assche , Lee Duncan , "James E.J. Bottomley" , linux-scsi@vger.kernel.org, linux-kernel@vger.kernel.org, Lee Duncan , Martin Wilck References: <20220928181350.9948-1-leeman.duncan@gmail.com> <11a582f0-723c-95e1-0e44-0a19e1a8a9a8@acm.org> <4a1da181-8a54-d2f8-6d19-d9c1982ab044@suse.de> From: Hannes Reinecke In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-4.4 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,NICE_REPLY_A,RCVD_IN_DNSWL_MED, SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 11/8/22 03:50, Martin K. Petersen wrote: > > Hannes, > > I have been contemplating this for a bit. > >>> Has it been considered instead of introducing a blacklist flag to not >>> use the reported VPD page size if the device reports that the VPD >>> page size is zero? I am not aware of any VPD pages for which zero is >>> a valid size. > > That would also be my preferred approach, I think. I haven't received > any bug reports about devices returning short VPD pages since this > change was introduced. So I think I'd prefer falling back to a > (hopefully small) default if a device returns a 0 page length. > > Now, my question is which VPD pages are actually supported by this > device and how large are they? > >> But pre-SPC drives will ignore the VPD bit in the inquiry size. And >> these devices do not set an additional length in the inquiry data > > Can you elaborate a bit on your experience with older devices? I checked > SCSI-2 (1991) and don't see any indication this would be valid behavior > even back then. > This is primarily crappy USB devices, which implement only the absolute minimum to get SCSI rolling. In particular, if devices do _not_ check the VPD bit in the inquiry command they will continue to return the standard inquiry data. And if the additional length is zero we have exactly the scenario above. However, we _could_ turn things around, and use the BLIST_NO_VPD flag for these cases; so I'd be fine with having a default length for the VPD page and delegate any fallout from the to use the BLIST_NO_VPD flags. 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