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=-4.0 required=3.0 tests=BAYES_00, 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 0D585C433E9 for ; Thu, 3 Sep 2020 17:35:16 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id D9584206C0 for ; Thu, 3 Sep 2020 17:35:15 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728422AbgICRfM (ORCPT ); Thu, 3 Sep 2020 13:35:12 -0400 Received: from albireo.enyo.de ([37.24.231.21]:40558 "EHLO albireo.enyo.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726025AbgICRfJ (ORCPT ); Thu, 3 Sep 2020 13:35:09 -0400 Received: from [172.17.203.2] (helo=deneb.enyo.de) by albireo.enyo.de with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) id 1kDt8U-0004Wm-Jl; Thu, 03 Sep 2020 17:34:58 +0000 Received: from fw by deneb.enyo.de with local (Exim 4.92) (envelope-from ) id 1kDt8U-00087R-Fu; Thu, 03 Sep 2020 19:34:58 +0200 From: Florian Weimer To: Minchan Kim Cc: Andrew Morton , LKML , Christian Brauner , linux-mm , linux-api@vger.kernel.org, oleksandr@redhat.com, Suren Baghdasaryan , Tim Murray , Sandeep Patil , Sonny Rao , Brian Geffon , Michal Hocko , Johannes Weiner , Shakeel Butt , John Dias , Joel Fernandes , Jann Horn , alexander.h.duyck@linux.intel.com, sj38.park@gmail.com, David Rientjes , Arjun Roy , Linus Torvalds , Vlastimil Babka , Christian Brauner , Daniel Colascione , Jens Axboe , Kirill Tkhai , SeongJae Park , linux-man@vger.kernel.org Subject: Re: [PATCH v9 3/3] mm/madvise: introduce process_madvise() syscall: an external memory hinting API References: <20200901000633.1920247-1-minchan@kernel.org> <20200901000633.1920247-4-minchan@kernel.org> <87blippc7p.fsf@mid.deneb.enyo.de> <20200903172618.GB1959033@google.com> Date: Thu, 03 Sep 2020 19:34:58 +0200 In-Reply-To: <20200903172618.GB1959033@google.com> (Minchan Kim's message of "Thu, 3 Sep 2020 10:26:18 -0700") Message-ID: <87pn72lq65.fsf@mid.deneb.enyo.de> MIME-Version: 1.0 Content-Type: text/plain Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org * Minchan Kim: > On Tue, Sep 01, 2020 at 08:46:02PM +0200, Florian Weimer wrote: >> * Minchan Kim: >> >> > ssize_t process_madvise(int pidfd, const struct iovec *iovec, >> > unsigned long vlen, int advice, unsigned int flags); >> >> size_t for vlen provides a clearer hint regarding the type of special >> treatment needed for ILP32 here (zero extension, not changing the type >> to long long). >> > > All existing system calls using iove in Linux uses unsigned long so > I want to be consistent with them unless process_madvise need something > speicial. Userspace uses int, following POSIX (where applicable). There is no consistency to be had here. 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=-4.0 required=3.0 tests=BAYES_00, 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 4EFC2C433E9 for ; Thu, 3 Sep 2020 17:35:13 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id 1380A206C0 for ; Thu, 3 Sep 2020 17:35:13 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 1380A206C0 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=deneb.enyo.de Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=owner-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix) id A6F276B005A; Thu, 3 Sep 2020 13:35:12 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 9F8C56B005D; Thu, 3 Sep 2020 13:35:12 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 898ED6B0071; Thu, 3 Sep 2020 13:35:12 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0224.hostedemail.com [216.40.44.224]) by kanga.kvack.org (Postfix) with ESMTP id 7064B6B005A for ; Thu, 3 Sep 2020 13:35:12 -0400 (EDT) Received: from smtpin18.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay05.hostedemail.com (Postfix) with ESMTP id 28143181AC9C6 for ; Thu, 3 Sep 2020 17:35:12 +0000 (UTC) X-FDA: 77222451264.18.anger47_6002a60270ab Received: from filter.hostedemail.com (10.5.16.251.rfc1918.com [10.5.16.251]) by smtpin18.hostedemail.com (Postfix) with ESMTP id 00EFB100ED9CD for ; Thu, 3 Sep 2020 17:35:11 +0000 (UTC) X-HE-Tag: anger47_6002a60270ab X-Filterd-Recvd-Size: 2910 Received: from albireo.enyo.de (albireo.enyo.de [37.24.231.21]) by imf06.hostedemail.com (Postfix) with ESMTP for ; Thu, 3 Sep 2020 17:35:11 +0000 (UTC) Received: from [172.17.203.2] (helo=deneb.enyo.de) by albireo.enyo.de with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) id 1kDt8U-0004Wm-Jl; Thu, 03 Sep 2020 17:34:58 +0000 Received: from fw by deneb.enyo.de with local (Exim 4.92) (envelope-from ) id 1kDt8U-00087R-Fu; Thu, 03 Sep 2020 19:34:58 +0200 From: Florian Weimer To: Minchan Kim Cc: Andrew Morton , LKML , Christian Brauner , linux-mm , linux-api@vger.kernel.org, oleksandr@redhat.com, Suren Baghdasaryan , Tim Murray , Sandeep Patil , Sonny Rao , Brian Geffon , Michal Hocko , Johannes Weiner , Shakeel Butt , John Dias , Joel Fernandes , Jann Horn , alexander.h.duyck@linux.intel.com, sj38.park@gmail.com, David Rientjes , Arjun Roy , Linus Torvalds , Vlastimil Babka , Christian Brauner , Daniel Colascione , Jens Axboe , Kirill Tkhai , SeongJae Park , linux-man@vger.kernel.org Subject: Re: [PATCH v9 3/3] mm/madvise: introduce process_madvise() syscall: an external memory hinting API References: <20200901000633.1920247-1-minchan@kernel.org> <20200901000633.1920247-4-minchan@kernel.org> <87blippc7p.fsf@mid.deneb.enyo.de> <20200903172618.GB1959033@google.com> Date: Thu, 03 Sep 2020 19:34:58 +0200 In-Reply-To: <20200903172618.GB1959033@google.com> (Minchan Kim's message of "Thu, 3 Sep 2020 10:26:18 -0700") Message-ID: <87pn72lq65.fsf@mid.deneb.enyo.de> MIME-Version: 1.0 Content-Type: text/plain X-Rspamd-Queue-Id: 00EFB100ED9CD X-Spamd-Result: default: False [0.00 / 100.00] X-Rspamd-Server: rspam02 X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: * Minchan Kim: > On Tue, Sep 01, 2020 at 08:46:02PM +0200, Florian Weimer wrote: >> * Minchan Kim: >> >> > ssize_t process_madvise(int pidfd, const struct iovec *iovec, >> > unsigned long vlen, int advice, unsigned int flags); >> >> size_t for vlen provides a clearer hint regarding the type of special >> treatment needed for ILP32 here (zero extension, not changing the type >> to long long). >> > > All existing system calls using iove in Linux uses unsigned long so > I want to be consistent with them unless process_madvise need something > speicial. Userspace uses int, following POSIX (where applicable). There is no consistency to be had here.