Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754011AbcDUSPh (ORCPT ); Thu, 21 Apr 2016 14:15:37 -0400 Received: from mail-bn1on0135.outbound.protection.outlook.com ([157.56.110.135]:62336 "EHLO na01-bn1-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1752149AbcDUSPf (ORCPT ); Thu, 21 Apr 2016 14:15:35 -0400 Authentication-Results: infradead.org; dkim=none (message not signed) header.d=none;infradead.org; dmarc=none action=none header.from=hpe.com; Message-ID: <571918BC.2060007@hpe.com> Date: Thu, 21 Apr 2016 14:15:24 -0400 From: Waiman Long User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:10.0.12) Gecko/20130109 Thunderbird/10.0.12 MIME-Version: 1.0 To: Christoph Hellwig CC: "Theodore Ts'o" , Andreas Dilger , , , Tejun Heo , Christoph Lameter , Scott J Norton , Douglas Hatch , Toshimitsu Kani Subject: Re: [PATCH v3 1/2] ext4: Pass in DIO_SKIP_DIO_COUNT flag if inode_dio_begin() called References: <1460484775-33359-1-git-send-email-Waiman.Long@hpe.com> <1460484775-33359-2-git-send-email-Waiman.Long@hpe.com> <20160420205801.GA24609@infradead.org> In-Reply-To: <20160420205801.GA24609@infradead.org> Content-Type: text/plain; charset="ISO-8859-1"; format=flowed Content-Transfer-Encoding: 7bit X-Originating-IP: [72.71.243.35] X-ClientProxiedBy: BY2PR04CA043.namprd04.prod.outlook.com (10.141.249.161) To CS1PR84MB0312.NAMPRD84.PROD.OUTLOOK.COM (10.162.190.30) X-MS-Office365-Filtering-Correlation-Id: 6fbc0ed0-2ccf-469f-299b-08d36a10ed72 X-Microsoft-Exchange-Diagnostics: 1;CS1PR84MB0312;2:pyW7HKFDWPSX5OgMNS+/U1KLmB6ip3v5xTew82+xVzEP1xK5SJ+qUvMVE90glKw+gNQ6BfyWAwliEnGC56WFPZXBbh+kbiuhhg6Z0yhOsqIROWjoJ7fjpREAJ9G2Eq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nqQHhoJUlviX7CsAUfEW1zpVkSwzQU0cof4zN8xUvG0Iyze+6ndVO51pFI4FyuTDaXLuWD2uIVN6gyxwHIe+xHuZxboEBfU86eynBjos6e+KT90ik4KMn+R1IfeEV8PSS5h6XA2CSaT5PxImDAbwLpZqy8RWeYzWX7I3qICwF0xaSJDeAHExHvUslxeXZSu+cKy4euq0UnN0fqAHy95aWYKbP2kVciLlYD2LxCzyFQvaUHukQi8mUdEQJh3zbUXWmP2Qj0OKoGyXtjCB6lDnRg2t6F5VYdz1/HwgRyPlBbohw8qfMmFgleq9cdEwAfZDx1q45qGqRmD1El1eMbIewi1yOlEpxcXWVxQ44rOCp80mpJ9xpkSoKklbADA= X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:; X-Exchange-Antispam-Report-CFA-Test: BCL:0;PCL:0;RULEID:(9101521026)(601004)(2401047)(5005006)(8121501046)(3002001)(10201501046)(6055026);SRVR:CS1PR84MB0312;BCL:0;PCL:0;RULEID:;SRVR:CS1PR84MB0312; X-Forefront-PRVS: 091949432C X-Forefront-Antispam-Report: SFV:NSPM;SFS:(10019020)(4630300001)(6049001)(6009001)(377454003)(24454002)(2950100001)(42186005)(65956001)(33656002)(66066001)(77096005)(81166005)(117156001)(23756003)(76176999)(189998001)(54356999)(87266999)(65816999)(5008740100001)(50986999)(1096002)(64126003)(99136001)(47776003)(230700001)(6116002)(83506001)(5004730100002)(92566002)(2906002)(4001350100001)(86362001)(4326007)(36756003)(50466002)(586003)(3846002);DIR:OUT;SFP:1102;SCL:1;SRVR:CS1PR84MB0312;H:[192.168.142.160];FPR:;SPF:None;MLV:sfv;LANG:en; X-Microsoft-Exchange-Diagnostics: =?iso-8859-1?Q?1;CS1PR84MB0312;23:3OAtnL23iTO+xZ0gkNOeCi8+j6RKFtSsop/Oj8L?= =?iso-8859-1?Q?zw4CjYWMg2s3fpsp1LzatwBMrY8tp9X2orZOxRWODaUK1RLtkMzCyAbDdi?= =?iso-8859-1?Q?78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GUkpRYSrN?= =?iso-8859-1?Q?7FmJtvs+cQkFhCyJlPraKwTjgsBC1tUn+QrreAMZRox8q0X3I2221vZz6?= X-Microsoft-Exchange-Diagnostics: 1;CS1PR84MB0312;5:vc4OL9aEaD1KInC7Qt7wD0MQtRR2M8kll5yLqm1bZ+dBEpIXCqk0MWWsxkvmPrfFLLMHunOlf6JK1og/RjFW/CMIvrqII149cL+ORmp3ASziFUDaLtWMGI84Adnj+cWE9xto1TIUAsvXylVlg4V1Ge1VL0vjPCJ9IyzuqUPtKnGtMA/zu6gD8GXMMkkn86KU;24:HxcGc1ZlKZKXwOs2gk8Ycw6a+ZrD3Y8EWzdB8YHCyXskg9FCJ9Y9dbKzCMOsyi8tfdLX3vD82RWhWa+LeaaJ+Ssx6gx1Vb9vWF6bECpyoS8=;7:4K7L3jugBIULpTXA8X3xU/I59O8cqpMjrZz9dd+ulJZFQ9F5EiylYrF9hreo3s99IAqq+5U5Nq6sEspbpfZgxJ9DON61I2NejXThW6J43bH8li6P0K7ehy+nU/GJWV9M4+SK1rAhEPZEN3i3RxHeBa+Zffo9kqqkjZzERPe3TYk9H3J25XEIpg0M/L6nW1r6wqmKfwyqLvVza7FiF+9s1r63JHJIHsMpgqRYIm9y7/E= SpamDiagnosticOutput: 1:23 SpamDiagnosticMetadata: NSPM X-OriginatorOrg: hpe.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 21 Apr 2016 18:15:30.9761 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-Transport-CrossTenantHeadersStamped: CS1PR84MB0312 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 487 Lines: 12 On 04/20/2016 04:58 PM, Christoph Hellwig wrote: > FYI, none of the Dax code even needs to ever touch the dio_count, > as dax I/O can't be asynchronous, and we thus don't need it to protect > against truncate. I'd suggest to remove it and then end_io callback > from the DAX code entirely as a start and then move from there. Yes, it seems like we may not need to change the dio_count in dax_do_io() after all. BTW, what do mean by using end_io callback as a start? Cheers, Longman