Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp893407rwd; Tue, 13 Jun 2023 01:39:16 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ4Ox6+tUZHGVOOpUbclhgUn5g+6aCHVmBnqSO9P6qNSRWaoJbPh8Z5u1Kq/16xpDicbpKfc X-Received: by 2002:a17:907:9714:b0:980:5b89:bba3 with SMTP id jg20-20020a170907971400b009805b89bba3mr6875504ejc.54.1686645555890; Tue, 13 Jun 2023 01:39:15 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1686645555; cv=none; d=google.com; s=arc-20160816; b=nYwx6FhACcJZeajZ5XiQUXaW4aJqwXUFLSNAxcCjoeM+gEsnJyUERoXkH2jx3T3557 +m3TRzZy9JPRlERMSVdJ7ECaBYRkGNL5r2K+lhR5PfRE4b6fTn3bTVXCFYwuOOwtv0Uq w+zWeushcBebIDFH6BqmSoyNhLfsKInVNgOuexGfXre+cfOyXTe90nk+4eOdoJZ44L0g Qe5ILpRQ+sVcOlbxAw8hxaLmcwA6qYEE3fLlS0d6OtDfJX717OdEu3nSGMg+N/UZ9s50 xiyEocEEifjkxuzRoSVqkC90hnNG5NAhrrKE8djohhfzRn/mYAEntspGe4oEtuAOS8x8 Z/1w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:subject:cc:to:from:message-id:date :dkim-signature; bh=fAWSkGYmCWKL5bXYvk6CuiJFkQfPXw1vMINiicyg49U=; b=ocA80bMl+mWZXzO+lM9hDOWwEPmuCnegYvD4l+KtsRjXQWYLPlkbN8MukhuMyEdCno XycQtO/aTUIFM5jvV59NPFK5DwdJQvqnCUo562xAWUPpAnS/8i74zLDNi5g8/TBfxBTY fdY3WLkO0The+9OeUp8cPro8My2+3iu1TAt0XHbzF+MtvLPv1ea/J3qwm4dxC4hB1vqN 4lK3tdjLQ1ujJvXLwazsq1oIlslHhw2mawzqF1XYdN4/CEHMK2K3kZGmlE8dIpbOc6sW gqCsSyW9LRWtXKS/zKuT3GKH5OCs658/yuoDt+Zyi6MxuTs7duqFWC8apZ87KRAqHThW fPLQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20221208 header.b=L3JDIHCQ; spf=pass (google.com: domain of linux-ext4-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-ext4-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id ko17-20020a170907987100b0096acf19c1b8si6213659ejc.28.2023.06.13.01.38.49; Tue, 13 Jun 2023 01:39:15 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-ext4-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20221208 header.b=L3JDIHCQ; spf=pass (google.com: domain of linux-ext4-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-ext4-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S241234AbjFMIcH (ORCPT + 99 others); Tue, 13 Jun 2023 04:32:07 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:42814 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S241263AbjFMIcG (ORCPT ); Tue, 13 Jun 2023 04:32:06 -0400 Received: from mail-pl1-x629.google.com (mail-pl1-x629.google.com [IPv6:2607:f8b0:4864:20::629]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 7082E188 for ; Tue, 13 Jun 2023 01:31:59 -0700 (PDT) Received: by mail-pl1-x629.google.com with SMTP id d9443c01a7336-1b3c0c476d1so19990985ad.1 for ; Tue, 13 Jun 2023 01:31:59 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1686645118; x=1689237118; h=in-reply-to:subject:cc:to:from:message-id:date:from:to:cc:subject :date:message-id:reply-to; bh=fAWSkGYmCWKL5bXYvk6CuiJFkQfPXw1vMINiicyg49U=; b=L3JDIHCQLc/kKPQ7RVpu8TO+yLZtzIb+z4Lsb/I1AMVjDhghGweWBGqEyf4rENg0iN nMun24JAlxBaDIJmkyOoIvBpDQUgUWSF/kD/D6SQrkLn23tALsz/SOZJBRmeZ1qFGfjc xODY3EsrD3BavVKhTODyXuoQYwqUNYnjACl07UcSnVJoInE4lTMSlhQP6xVQoaW/qEpm QQQeg24YsBFXKWy8emfuIdsV+9tzl95SIqJDeiZUtae3AWWi6Z3JHOxN0yCm/s+jUW+X Jb5fACuGXHJg0cp0KOF3n0b7JJHR4y9NkYp/bvMNcqsKS5+b+C2KYgAd6gxxTIF/VXOf aMjQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1686645118; x=1689237118; h=in-reply-to:subject:cc:to:from:message-id:date:x-gm-message-state :from:to:cc:subject:date:message-id:reply-to; bh=fAWSkGYmCWKL5bXYvk6CuiJFkQfPXw1vMINiicyg49U=; b=Jw4qgvy4Moa09W1IRcc/KKsqhP4bw67mUVmOw0EVXTrgQ8qqFl7fVlSeDrc/CZYjVC +Z1tGHf+zv5s+B6RRF0TeTYpVq55zRpMVUU1NKo8xB9T2g2SwxA7aZ9gFJVdDqU3qqa/ xV+mLbJY0v7iMAdP07FMiTt/dDIecuTKEmu6U2wsGSqEXTn2fHtin6pWhbtfkuVPgmvR inb/8oWLYAYoux3ZC69r+1ZQZrgkuv0UdCbfvW5Eirs7Oa5Wv3a+Qf7N0vG/BWsQBGpb nyseUWuf4DspnDsSdXKkXbY2a5OyeRQLgi+ygWJen74n24JnD+KMaNa+tmtOOV1AaaTe ivIQ== X-Gm-Message-State: AC+VfDzMAdJnXZt3dPNupuSaL/yNSMLy6cJN1wHJqt6+I2jULkMEfWVF hvK9fS8jBgxUKTJnLn3GtHHCfnSe/YI= X-Received: by 2002:a17:902:8544:b0:1b3:7def:3754 with SMTP id d4-20020a170902854400b001b37def3754mr8645186plo.28.1686645118473; Tue, 13 Jun 2023 01:31:58 -0700 (PDT) Received: from dw-tp ([129.41.58.19]) by smtp.gmail.com with ESMTPSA id j3-20020a170902da8300b001ab01598f40sm9589295plx.173.2023.06.13.01.31.56 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 13 Jun 2023 01:31:57 -0700 (PDT) Date: Tue, 13 Jun 2023 19:27:23 +0530 Message-Id: <87ttvb5ut8.fsf@doe.com> From: Ritesh Harjani (IBM) To: Christoph Hellwig Cc: Christoph Hellwig , tytso@mit.edu, linux-ext4@vger.kernel.org Subject: Re: [PATCH] ext4: set FMODE_CAN_ODIRECT instead of a dummy direct_IO method In-Reply-To: <20230613054700.GA14648@lst.de> X-Spam-Status: No, score=0.9 required=5.0 tests=BAYES_00,DATE_IN_FUTURE_03_06, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM, RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS,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-ext4@vger.kernel.org Christoph Hellwig writes: > On Tue, Jun 13, 2023 at 11:00:19AM +0530, Ritesh Harjani wrote: >> why do we require .direct_IO function op for any of the dax_aops? >> IIUC, any inode if it supports DAX i.e. IS_DAX(inode), then it takes the >> separate path in file read/write iter path. >> >> so it should never do ->direct_IO on an inode which supports DAX right? > > do_dentry_open rejects opens with O_DIRECT if FMODE_CAN_ODIRECT is > not set. So we either needs to set that manually or because there is a > ->direct_IO if we want to keep supporting O_DIRECT opens for DAX > files, which we've traditionally supported. Ok, so for DAX it was mainly to support file opens with O_DIRECT semantics. Thanks -ritesh