Received: by 2002:ac0:a582:0:0:0:0:0 with SMTP id m2-v6csp615567imm; Wed, 3 Oct 2018 23:59:26 -0700 (PDT) X-Google-Smtp-Source: ACcGV63vHEl6o86RqQ5PpHZ1Prtls74lpyDTu9l/DC4n6EeVS7DY0sqNkOQgEIiDq8h0t8HS2Weu X-Received: by 2002:a17:902:788e:: with SMTP id q14-v6mr5287920pll.49.1538636366460; Wed, 03 Oct 2018 23:59:26 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1538636366; cv=none; d=google.com; s=arc-20160816; b=rH1puaykvTml/L53Vc8JB4QJnV/sHYhwey2B6ZHrcaiAXDrjUSneuDFU+a7FsXlwzF rpcJJisfsF45Zj3Y8s1Thk6eLCWYHpBgsSQfSyPpzAFlxh9YQAPO+9AkGqHnwJjOBWD2 OXVmCto5nz3Mo5nEw2c/rx0iHQAcqBPnMoq6YhttHfMn3mOcUrOgrX+VQAx9dGvtgpmZ dOZnHspaFVF0kwLtw2BL/na+p3A++RnWXJ65mW+eGwV88u+K5zJsSNoVLyH/tQmm/jAa sP4Lk19Hvuj4L0+QrCK3Tk3+p04MQbejI3tsf6wiSQaNURvv0ahgVn0GtTBtD0a+33HH N8mQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=ILgMXlBvUEo+sZHLx50+QCGySzxBjzwtiFLrday+WkA=; b=uc5NxbUzWyl0xr5/x6nI6E6EbSQ2s/f1AP1/5C/1RKWrYEdN/+K8yQwJ5B8YIBh3Lx h+43CLA9fl5Mow4/hcAy37hhV/SslYbAxS2e+SsgxEDqWbMeDhBd/AwcvWR3QbPmkGKC BJP5q1H0gMm88sj5I5RaxySb+Fs50HfwExfR3IBYfHdKUS2BxWjMH4LelyUGPKICn5Y9 PkY7yqmhXDUixJRjYBRYA0vBCCDESXMg1XSfEPHFKNsfstGNhnKwpzQqIi+qV5Aphz1l mQYhh7+7MdqFIe/eFrrntMgYBpd9hUIz/KiZbdac8VjxQmzEAvbu4m1uiBWs5f5cnNP5 yGSg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@infinidat-com.20150623.gappssmtp.com header.s=20150623 header.b=Z9Dr9OQZ; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id u22-v6si3654819pfn.111.2018.10.03.23.59.10; Wed, 03 Oct 2018 23:59:26 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@infinidat-com.20150623.gappssmtp.com header.s=20150623 header.b=Z9Dr9OQZ; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727467AbeJDNuj (ORCPT + 99 others); Thu, 4 Oct 2018 09:50:39 -0400 Received: from mail-ot1-f65.google.com ([209.85.210.65]:34414 "EHLO mail-ot1-f65.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727293AbeJDNug (ORCPT ); Thu, 4 Oct 2018 09:50:36 -0400 Received: by mail-ot1-f65.google.com with SMTP id i12-v6so8171918otl.1 for ; Wed, 03 Oct 2018 23:58:49 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=infinidat-com.20150623.gappssmtp.com; s=20150623; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=ILgMXlBvUEo+sZHLx50+QCGySzxBjzwtiFLrday+WkA=; b=Z9Dr9OQZk5sasDJozWyp9Acgu+ATjRQo4NOdWhIALWMgdSO5NF5jFsnvIm7muKaog+ zmwsTgvfMqbrfW7+Lme5fT+MR938Q+TVBvvmqJE1pf2Kw334DHVndww7s995ywIrVsTx GYLeDngGS3R6vZhq+JnySDgyTK7BqrI4IgRzamVyj2+qVW2Pw/g1CrcAgEQ+rstKnola NKxQhH4ZQLlkEiZkow/wRIWwoWafQWe7WRDT7A8g0ZbQ5jdu03h/ZbNRTf/fPSJQcIad fb3lh6sXgMLIJzcHH+A3ASNVFpgK6f1adBMvsxZ3NNNLMsZP5XbKN9e7bzyjHBSAegOY hVpg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=ILgMXlBvUEo+sZHLx50+QCGySzxBjzwtiFLrday+WkA=; b=TMSgWjbHQIEPzo+rFG81vFsnQzhY38U599AhXrZmeYPxbDOMBFN2H+94/Yurxd3R52 0T6fcJ+RpArk3TrqzRA3LR/1KgP4rSXhQVdMcWzjHSwF64Io/KpY8rGtNjDXbCRpljro pqutpxvurjxR+HyLyEpafhdPWD+4vH42FKQoDvODBxyqjmT+rO0YoQVjdxrMmi1wCrdz C52D33K3KO01j4ORVxElVLmKgD/tfyeHhb/+YnR9m7CNp1Z5c5XwFuN87x7nRxPYVj1s Dj4Yp14pr0QSCLZrDIoJxHcG03i4m8pwKQxe3kpDk+QVZfh1rBABo/rkzvISExK+Vjwf avcg== X-Gm-Message-State: ABuFfoguXmNtKqxJb96D9yQ7nhCj+yxztMSNxliY9x8fEplmIbDIvUVE 4y/i+EIaSgpt+2bVWVknXqIUpnWfaa5icDoFyYMP X-Received: by 2002:a9d:3c9:: with SMTP id f67-v6mr2986177otf.208.1538636329410; Wed, 03 Oct 2018 23:58:49 -0700 (PDT) MIME-Version: 1.0 References: In-Reply-To: From: Dror Levin Date: Thu, 4 Oct 2018 09:58:37 +0300 Message-ID: Subject: Re: Recent removal of bsg read/write support To: torvalds@linux-foundation.org Cc: Richard Weinberger , linux-kernel@vger.kernel.org, linux-block@vger.kernel.org, linux-scsi@vger.kernel.org, hch@infradead.org, axboe@kernel.dk, gregkh@linuxfoundation.org Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org CC'ing Greg. On Mon, Sep 3, 2018 at 11:34 AM Dror Levin wrote: > > On Sun, Sep 2, 2018 at 8:55 PM Linus Torvalds > wrote: > > > > On Sun, Sep 2, 2018 at 4:44 AM Richard Weinberger > > wrote: > > > > > > CC'ing relevant people. Otherwise your mail might get lost. > > > > Indeed. > > Sorry for that. > > > > On Sun, Sep 2, 2018 at 1:37 PM Dror Levin wrote: > > > > > > > > We have an internal tool that uses the bsg read/write interface to > > > > issue SCSI commands as part of a test suite for a storage device. > > > > > > > > After recently reading on LWN that this interface is to be removed we > > > > tried porting our code to use sg instead. However, that raises new > > > > issues - mainly getting ENOMEM over iSCSI for unknown reasons. > > > > Is there any chance that you can make more data available? > > Sure, I can try. > > We use writev() to send up to SG_MAX_QUEUE tasks at a time. Occasionally not > all tasks are written at which point we wait for tasks to return before > sending more, but then writev() fails with ENOMEM and we see this in the syslog: > > Sep 1 20:58:14 gdc-qa-io-017 kernel: sd 441:0:0:5: [sg73] > sg_common_write: start_req err=-12 > > Failing tasks are reads of 128KiB. > > > I'd rather fix the sg interface (which while also broken garbage, we > > can't get rid of) than re-surrect the bsg interface. Discussion seems to have died down but release of 4.19 is drawing near. Is there still any chance removal of bsg can be reconsidered? Maybe postponed to the next version to allow more time to adjust? I'm especially concerned about the possibility of this being backported to stable kernels which might leave us very little time to fix our code. Thanks, Dror