Received: by 2002:a05:6512:3d0e:0:0:0:0 with SMTP id d14csp52661lfv; Tue, 12 Apr 2022 16:59:51 -0700 (PDT) X-Google-Smtp-Source: ABdhPJx9sCNQLgxCQQF5C/azJ+VlDjE+4+lWjmpZBmHCPFgK7qhfNxecq5WzwZzdNYwuKW0ihakH X-Received: by 2002:a17:902:8644:b0:153:9f01:2090 with SMTP id y4-20020a170902864400b001539f012090mr39122963plt.101.1649807990795; Tue, 12 Apr 2022 16:59:50 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1649807990; cv=none; d=google.com; s=arc-20160816; b=Pldo+d6BSL4+ftZIHDrNhSnLWaFCK3tF7tG8ha4j2VYmD1l5opRqJCsz7mVTAw7PrK xoPIdF4igggsVdOXiXzOlOEQhvDHu45dd91OSmYrPQ77nlCFPN7SAJJopjBy/LmmjNr1 7H8pRI6OuojUznNDe6BJpVDGHC7E3TTv+eyCUXPqXj3Ieipc+0xm9y95jxiC3G3/K60v byiPz3S7LNDMeGdF6RJnwqciGTsja10TdCkURHSLrWiSXLzg/Hry707sVt2jCFJnJa3W WZk2JK5N9BxL462rVtcle0VlGtRAKeJnCcrXzeRJ5sDh3pHoWzs6IRZO4RlGBSfJc7SF cZLQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version:dkim-signature; bh=SAV9zD/9i3JbiiASrVcLIQyrbdWy7ico6dvybKeWvXs=; b=zk4L7DgoLxzVQTV+jrgKeKR2ZCdFfDFZO9e40l++4cg1seUS314NFRhzMFYQg95ajf k71kUD49BSAfrMVMZgtUREvRrWcK2oPI2XXgrx9YpWcUkW4FvN9+k9KH90Gc9mvhYt2L rLeV4qiYgBJ/PkNJx7/uPFWZWRMNw2vKuc0ErGvdyY91zbNTFgTLMMgoxu5ErkTeOrWE 08kt5ymp5S+klY0FICPU5Yrr07EgT5AH81wqUEexQ5MoC3cAJThCR+TY8RVW2/Nq3TaY JxaavcR+9o34u7Ey1+EO+lyKKMcmYilvuyTvrnORY6HSNdFgQEJcUJySWAMCx1PdbT1c QJ0A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linux-foundation.org header.s=google header.b="M/AHANmK"; spf=softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from lindbergh.monkeyblade.net (lindbergh.monkeyblade.net. [23.128.96.19]) by mx.google.com with ESMTPS id x6-20020a170902ec8600b00153b32082afsi14998806plg.266.2022.04.12.16.59.50 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 12 Apr 2022 16:59:50 -0700 (PDT) Received-SPF: softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) client-ip=23.128.96.19; Authentication-Results: mx.google.com; dkim=pass header.i=@linux-foundation.org header.s=google header.b="M/AHANmK"; spf=softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 26DAE20C2ED; Tue, 12 Apr 2022 14:56:03 -0700 (PDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1352485AbiDLHYH (ORCPT + 99 others); Tue, 12 Apr 2022 03:24:07 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:57086 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1343548AbiDLHJI (ORCPT ); Tue, 12 Apr 2022 03:09:08 -0400 Received: from mail-lf1-x12e.google.com (mail-lf1-x12e.google.com [IPv6:2a00:1450:4864:20::12e]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 6207E49F31 for ; Mon, 11 Apr 2022 23:49:32 -0700 (PDT) Received: by mail-lf1-x12e.google.com with SMTP id p10so30455263lfa.12 for ; Mon, 11 Apr 2022 23:49:32 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux-foundation.org; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=SAV9zD/9i3JbiiASrVcLIQyrbdWy7ico6dvybKeWvXs=; b=M/AHANmKGN/x+pUfTld06wGLxBZO8idhvqokFKh3BT7GGmJsUzvYs7TnI5abkdSjIW PMSxmtD12lJgdcdZ2OqdkCSLdMxu98RMRLkVkArQbM54XQ1sY2yeEjL+w00BVnLPR1SX sv1fHZETALyHeOuUK7+l+iTeLbFoU0iMZrz7U= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=SAV9zD/9i3JbiiASrVcLIQyrbdWy7ico6dvybKeWvXs=; b=fF02Mk7zV2mAAi1c6CR6gttAfsfNRXnKork0eWfrdUdrQ8AzpO5Hr+W0a0RzGjgQb4 N5sW55eUCQrnkrqi92WSz/jAPx/PpJBUZo6fmmrT7YVJCGOSb2uy/Oxpw4SgHzkkExhP UrC3CjMi/7y+XMq3yRD+fvAHRmrznpkceU4ChwbHd7kLOOWtUSwpd/mWAaS+KMukBZG2 zBK82h4GfHWeMMbcbv0gXZsWkC6I3vOji6Fz0BAscRZEHqiZ9YdCZXcOHON7x7RjuL6P y0ws4QVc1oOpPrXd9cYJKFvw4fJcokCBtc3CpEDBxUNS+RTSv3SiJNx8lYdLGu3w7f0U ZDmA== X-Gm-Message-State: AOAM5334QU/morHIWbboU1GXACKqiYRKHaPi2oY+a0HwaWIthz29Lw3r 1nCeKzKSEeFlMUMfjIJuZDtawPl9Q4j05JOH X-Received: by 2002:a05:6512:b06:b0:44a:f7bf:a425 with SMTP id w6-20020a0565120b0600b0044af7bfa425mr24423404lfu.445.1649746170480; Mon, 11 Apr 2022 23:49:30 -0700 (PDT) Received: from mail-lj1-f175.google.com (mail-lj1-f175.google.com. [209.85.208.175]) by smtp.gmail.com with ESMTPSA id bq1-20020a056512150100b004481de98e5bsm3545389lfb.305.2022.04.11.23.49.29 for (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Mon, 11 Apr 2022 23:49:29 -0700 (PDT) Received: by mail-lj1-f175.google.com with SMTP id r18so7210386ljp.0 for ; Mon, 11 Apr 2022 23:49:29 -0700 (PDT) X-Received: by 2002:a2e:a549:0:b0:249:9ec3:f2b with SMTP id e9-20020a2ea549000000b002499ec30f2bmr22850127ljn.358.1649746169549; Mon, 11 Apr 2022 23:49:29 -0700 (PDT) MIME-Version: 1.0 References: In-Reply-To: From: Linus Torvalds Date: Mon, 11 Apr 2022 20:49:13 -1000 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [PATCH] stat: don't fail if the major number is >= 256 To: Mikulas Patocka Cc: Alexander Viro , linux-fsdevel , Linux Kernel Mailing List , Matthew Wilcox Content-Type: text/plain; charset="UTF-8" X-Spam-Status: No, score=-2.0 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,RDNS_NONE,SPF_HELO_NONE,T_SCC_BODY_TEXT_LINE autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Apr 11, 2022 at 7:37 PM Linus Torvalds wrote: > > Correct. It's literally the compat structure that has no basis in reality. > > Or it might be some truly ancient thing, but I really don't think so. I was intrigued, so I went back and checked. unsigned short st_dev; unsigned short __pad1; is in fact historical. But it was changed to unsigned long st_dev; (for i386, so this is a 32-bit 'unsigned long') on April 2, 2003. From the BK tree conversion: https://git.kernel.org/pub/scm/linux/kernel/git/tglx/history.git/commit/?id=e95b2065677fe32512a597a79db94b77b90c968d so I think we should just make sure that the 64-bit compat system call is compatible with that 2003+ state, not with some truly ancient state. Linus