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=-2.5 required=3.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,USER_AGENT_SANE_1 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 4CA83C433E5 for ; Mon, 29 Jun 2020 18:36:51 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 2D61F22281 for ; Mon, 29 Jun 2020 18:36:51 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727011AbgF2Sgm (ORCPT ); Mon, 29 Jun 2020 14:36:42 -0400 Received: from verein.lst.de ([213.95.11.211]:58732 "EHLO verein.lst.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726996AbgF2Sgl (ORCPT ); Mon, 29 Jun 2020 14:36:41 -0400 Received: by verein.lst.de (Postfix, from userid 2407) id 425DD68CEE; Mon, 29 Jun 2020 20:36:37 +0200 (CEST) Date: Mon, 29 Jun 2020 20:36:36 +0200 From: Christoph Hellwig To: Linus Torvalds Cc: Christoph Hellwig , David Laight , Al Viro , Luis Chamberlain , Kees Cook , Iurii Zaikin , Linux Kernel Mailing List , linux-fsdevel Subject: Re: [PATCH 03/11] fs: add new read_uptr and write_uptr file operations Message-ID: <20200629183636.GA6539@lst.de> References: <20200624162901.1814136-4-hch@lst.de> <20200624175548.GA25939@lst.de> <20200629152912.GA26172@lst.de> <20200629180730.GA4600@lst.de> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: User-Agent: Mutt/1.5.17 (2007-11-01) Sender: linux-fsdevel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-fsdevel@vger.kernel.org On Mon, Jun 29, 2020 at 11:29:22AM -0700, Linus Torvalds wrote: > I didn't look at the compat cases, but if anything I'd expect those to > become simpler by having kernel pointers. And there doesn't actually > seem to be that many of them (possibly because the "int" case si so > common that it all ends up being the same?) Having resurrect my work there really are tons of int cases. Which makes me thing that splitting out a setsockopt_int method which gets passed value instead of a pointer, then converting all the simple cases to that first and then doing the real shit later sounds like a promÑ–sing idea. Let me think a bit more about that. And yes, a lot of the common methods have tons of cases and sub-dispatchers and everything else you'd expect from an ioctl-like interface..