From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-3.3 required=3.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 2B8D0C433E2 for ; Fri, 28 Aug 2020 13:03:48 +0000 (UTC) Received: from shelob.surriel.com (shelob.surriel.com [96.67.55.147]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id C0F8B20825 for ; Fri, 28 Aug 2020 13:03:47 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=fail reason="signature verification failed" (1024-bit key) header.d=gmx.net header.i=@gmx.net header.b="S+VeJHlH" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org C0F8B20825 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=gmx.net Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=kernelnewbies-bounces@kernelnewbies.org Received: from localhost ([::1] helo=shelob.surriel.com) by shelob.surriel.com with esmtp (Exim 4.94) (envelope-from ) id 1kBe2E-0005zs-Lu; Fri, 28 Aug 2020 09:03:14 -0400 Received: from mout.gmx.net ([212.227.17.20]) by shelob.surriel.com with esmtps (TLS1.2) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94) (envelope-from ) id 1kBe2C-0005zg-JS for kernelnewbies@kernelnewbies.org; Fri, 28 Aug 2020 09:03:12 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.net; s=badeba3b8450; t=1598619783; bh=rSAQrhQrn7x83qal6pEz9/AXXUVXNdnDnZhoJtmX2uA=; h=X-UI-Sender-Class:Date:From:To:Subject:Cc:References:In-Reply-To; b=S+VeJHlHjqZ09/PmLqoTxSluArWgBCIvGIJ2SBv+ylVL2EE1LdxGoQnjvJ5Pd6TTL /Y3IMYakVHEuFlz45zszsaV00uX3jVcdsFCnSLDuJV8GU0NGwmK4IqDnLSnQoxHts6 cPyyS/NR4Zb7i/gJ+yDhW5P7ZYal83pXDMo6N528= X-UI-Sender-Class: 01bb95c1-4bf8-414a-932a-4f6e2808ef9c Received: from scdbackup.webframe.org ([84.179.245.142]) by mail.gmx.com (mrgmx105 [212.227.17.168]) with ESMTPSA (Nemesis) id 1MFbVu-1kOMQL0E4E-00H4bq; Fri, 28 Aug 2020 15:03:03 +0200 Date: Fri, 28 Aug 2020 15:03:26 +0200 From: "Thomas Schmitt" To: kernelnewbies@kernelnewbies.org Subject: Re: Please give advise about my first patch attempt References: In-Reply-To: Message-Id: <8257736897954643869@scdbackup.webframe.org> X-Provags-ID: V03:K1:uc8xqQAQu7MdBrxL4p5S1lPzj97MzvH5JGhgmSVHpgYo7LACZMv cS5KAPhTqwT1O7NGmN0O5e1BYybYUYwqKIB2ueRph4Tt034Vy71y7HAshnRIUJDkZHPepZt jhGojTfxDV/37lb4t8KgClJXwwMGBm8NCEYoDMiTRtXi2heP3DXfr6e+4OOlKse9GFVz4s/ V/WiiXp5atqE2S6+g1tMg== X-UI-Out-Filterresults: notjunk:1;V03:K0:LCLOQMRtAhA=:HU71p5HFJCt0bQ42hXmShd ctnLlHMropQt7zg3Q83ghcQFt7JFXGNvbaiulNCbbpyrPW7xA8kyZrYCeHuULRDuDuz/pJ16m EDoh0ICu3BQr5a70miqSsw0z2RqgIly/1FpiQpjAZJ5V3n2PMA2fASCHN/WhzViXYPUuOU8DX 5nxOmu5UqUBFu9//LQ4DWAfDTV3o9W1EVFTF494U0bpJHcTAPpiofrVehZ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ulwahn@gmail.com, garritfranke@gmail.com, greg@kroah.com X-BeenThere: kernelnewbies@kernelnewbies.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: Learn about the Linux kernel List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Errors-To: kernelnewbies-bounces@kernelnewbies.org Hi, i might get a community problem with the goal of my patch. While googling for hints of acceptance for cdrom on linux-scsi@vger.kernel.org i came to a thread where a much more expensive fix of the problem was obviously rejected by Jens Axboe in november 2019: https://lore.kernel.org/linux-scsi/c6fe572c-530e-93eb-d62a-cb2f89c7b4ec@kernel.dk/ "I think the main complaint with this is that it's kind of a stretch to add core functionality for a device type that's barely being manufactured anymore and is mostly used in a virtualized fashion. I think it you could fix this without 10 patches of churn and without adding a new ->open() addition to fops, then people would be a lot more receptive to the idea of improving cdrom auto-close." Well, 10 patches. Each about the code size of my single one. But also a negative opinion towards the device class by the maintainer. That proposal fixes tray loading for audio, too. I did not care because i cannot test realistically. Then there are patches 04/10 and 08/10 which shall avoid blocking other processes from inquiring the drive while it is loading its tray because of the automatic load feature in open_for_data(). Mine has a 40 seconds timeout instead, blocking CDROM ioctls and sr_bdops.open() == sr_block_open() to that particular drive. Would it be wise to mention from the beginning that i studied that proposal ? My opinion is now that if concurrent access from multiple threads to a drive is more important than a working automatic tray load on open(2), then automatic tray loading should be disabled at all. If concurrent drive inspection by multiple threads at any time is not a main goal, then i would still advertise my patch. Should i mention this opinion from the beginning ? I have a few other cdrom+sr fixes in my local 4.19 kernel. I don't want to spoil their chances by starting with a non-starter. Any strategic proposals to not appear clueless in front of Jens Axboe would be welcome. Due to real life issues i will probably until mid of next week not be able to post a patch on linux-scsi and to then react swiftly on demanding requests. ----------------------------------------------------------------------- Lukas Bulwahn wrote: > Archives at https://lore.kernel.org/ can give you the raw text and that > archive is tested among kernel maintainers for picking patches. > You can prepare your patch and send it to kernelnewbies. > Then, pick it from https://lore.kernel.org/kernelnewbies/ and try to apply > your own patch with git am. If that works, it is probably fine. Pawan Gupta wrote: > $ ./scripts/checkpatch.pl --strict --codespell -g > $ make CFLAGS_KERNEL+=-Werror ... I surely learn a lot here. Already lagging behind now ... :) Have a nice day :) Thomas _______________________________________________ Kernelnewbies mailing list Kernelnewbies@kernelnewbies.org https://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies