Received: by 2002:ac0:950c:0:0:0:0:0 with SMTP id f12csp3891319imc; Thu, 14 Mar 2019 07:35:10 -0700 (PDT) X-Google-Smtp-Source: APXvYqy4mm0PJcxeE+jDvZWaQFleccRg9/45pGcLOEZ0lweuqZBFMcl3UqhEnIy8aE6kx1OMeWSj X-Received: by 2002:a65:63cd:: with SMTP id n13mr34475526pgv.193.1552574110583; Thu, 14 Mar 2019 07:35:10 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1552574110; cv=none; d=google.com; s=arc-20160816; b=lLEaDrsnQWFFJOUcWG9lF6P310+iQQ3nCvkzzM9NHMXpxV4DSnpjppXh3Z/xRJD2KI sVmOnALWwNxiXoFHYJL5GRI012nXekWyrszCpE5eDajkHnogeDBtNvJbtWGwXzoCii+e Ni9T75hq17eHVR0UXvMs0bjSPPyky7sx4U/wg30nn6Z8iJElRjYHMxX7XyAtJISinVcn l9gZjbh+v895VOWjoBf/pWs/pej8mb7j/Tli/fLWLWwWeeD6hWJXgHct63czxlXdAr0T r8oPYDETJqJHEnQ7myHPUXjsZ1Gh9NNvLfQpl/FiWs52kjA0nJT7dM/xNXJN67NQD1sf iljQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date; bh=oEok4qZhQS1Wmilrm/1RgFAoC4bmXHCZK/T3gwlQU7k=; b=Q3i+c5PQjaSFXpTk7xtfZKklImbxcK6XBIDFMPb8NaKh6Jr/FOFJYSrrxCu7JeiDjV TAW+5tQjq89fF/5n/ZQC1EwlmlbNc4BPocPznPr1vOg+rL9StG2NEJKFp2ExI77CkM6H jCP2boAFkdx3rBikNVhwvP+2brRspPzKH0SNtbYUE7URgAPBCxsVeZQrQprygcYt2HuU hfcu9/5zV2FO3av6jiUOBmfvhPjI2XnZlfFxcxOvIWPqubkct9ESINC3pyEUcYRg9kBO 7Grwby+GgXuPcOVJ8YyklmEWKXx1gtQk/qBAclBO40NSuGpyHOmm2lCB5fVugVOhqNt+ ouqg== ARC-Authentication-Results: i=1; mx.google.com; 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 h21si12905674pgl.346.2019.03.14.07.34.54; Thu, 14 Mar 2019 07:35:10 -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; 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 S1727705AbfCNOeJ (ORCPT + 99 others); Thu, 14 Mar 2019 10:34:09 -0400 Received: from eddie.linux-mips.org ([148.251.95.138]:59682 "EHLO cvs.linux-mips.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727159AbfCNOeJ (ORCPT ); Thu, 14 Mar 2019 10:34:09 -0400 Received: from localhost.localdomain ([127.0.0.1]:57138 "EHLO linux-mips.org" rhost-flags-OK-OK-OK-FAIL) by eddie.linux-mips.org with ESMTP id S23992786AbfCNOeGqbyS4 (ORCPT + 1 other); Thu, 14 Mar 2019 15:34:06 +0100 Received: from h7.dl5rb.org.uk (localhost [127.0.0.1]) by h7.dl5rb.org.uk (8.15.2/8.15.2) with ESMTP id x2EEVxlr003253; Thu, 14 Mar 2019 15:31:59 +0100 Received: (from ralf@localhost) by h7.dl5rb.org.uk (8.15.2/8.15.2/Submit) id x2EEVwVc003252; Thu, 14 Mar 2019 15:31:58 +0100 Date: Thu, 14 Mar 2019 15:31:58 +0100 From: Ralf Baechle To: Jan Kara Cc: Amir Goldstein , kbuild-all@01.org, linux-kernel , linux-mips@vger.kernel.org, Paul Burton , James Hogan Subject: Re: fs/notify/fanotify/fanotify.c:198:2: note: in expansion of macro 'pr_warn_ratelimited' Message-ID: <20190314143158.GC27249@linux-mips.org> References: <201903140234.4FpTWdW3%lkp@intel.com> <20190314083758.GA16658@quack2.suse.cz> <20190314123811.GH16658@quack2.suse.cz> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20190314123811.GH16658@quack2.suse.cz> User-Agent: Mutt/1.11.3 (2019-02-01) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Mar 14, 2019 at 01:38:11PM +0100, Jan Kara wrote: > On Thu 14-03-19 14:01:18, Amir Goldstein wrote: > > On Thu, Mar 14, 2019 at 10:37 AM Jan Kara wrote: > > > > > > AFAICS this is the known problem with weird mips definitions of > > > __kernel_fsid_t which uses long whereas all other architectures use int, > > > right? Seeing that mips can actually have 8-byte longs, I guess this > > > bogosity is just wired in the kernel API and we cannot easily fix it in > > > mips (mips guys, correct me if I'm wrong). So what if we just > > > unconditionally typed printed values to unsigned int to silence the > > > warning? > > > > I don't understand why. To me that sounds like papering over a bug. > > > > See this reply from mips developer Paul Burton: > > https://marc.info/?l=linux-fsdevel&m=154783680019904&w=2 > > mips developers have not replied to the question why __kernel_fsid_t > > should use long. > > Ah, right. I've missed that mips defines __kernel_fsid_t only if > sizeof(long) == 4. OK, than fixing MIPS headers is definitely what we ought > to do. Mips guys, any reason why the patch from Ralf didn't get merged yet? Paul's patch :-) As for the reason why the definition is as it is - 32-bit MIPS was born using long, then in 2000 64-bit MIPS started off as arch/mips64 using int. Eventually the two ports were combined using: ypedef struct { #if (_MIPS_SZLONG == 32) long val[2]; #endif #if (_MIPS_SZLONG == 64) int val[2]; #endif } __kernel_fsid_t; A desparate attempt to use asm-generic where ever possible then resulted in the confusing definition we'e having today. Normally APIs are cast into stone not to be changed. But fsid is used in struct statfs and the man page states "Nobody knows what f_fsid is supposed to contain (but see below)." and f_fsid is supposed to be opaque anyway so I'm wondering if something could break at all. Researching that. Ralf