[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <92423340-311b-0799-7a23-2a89201700ed@oracle.com>
Date: Thu, 21 Oct 2021 18:19:04 +0000
From: Jane Chu <jane.chu@...cle.com>
To: Christoph Hellwig <hch@...radead.org>
CC: "david@...morbit.com" <david@...morbit.com>,
"djwong@...nel.org" <djwong@...nel.org>,
"dan.j.williams@...el.com" <dan.j.williams@...el.com>,
"vishal.l.verma@...el.com" <vishal.l.verma@...el.com>,
"dave.jiang@...el.com" <dave.jiang@...el.com>,
"agk@...hat.com" <agk@...hat.com>,
"snitzer@...hat.com" <snitzer@...hat.com>,
"dm-devel@...hat.com" <dm-devel@...hat.com>,
"ira.weiny@...el.com" <ira.weiny@...el.com>,
"willy@...radead.org" <willy@...radead.org>,
"vgoyal@...hat.com" <vgoyal@...hat.com>,
"linux-fsdevel@...r.kernel.org" <linux-fsdevel@...r.kernel.org>,
"nvdimm@...ts.linux.dev" <nvdimm@...ts.linux.dev>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
"linux-xfs@...r.kernel.org" <linux-xfs@...r.kernel.org>
Subject: Re: [PATCH 2/6] dax: prepare dax_direct_access() API with
DAXDEV_F_RECOVERY flag
On 10/21/2021 4:20 AM, Christoph Hellwig wrote:
> On Wed, Oct 20, 2021 at 06:10:55PM -0600, Jane Chu wrote:
>> @@ -156,8 +156,8 @@ bool generic_fsdax_supported(struct dax_device *dax_dev,
>> }
>>
>> id = dax_read_lock();
>> - len = dax_direct_access(dax_dev, pgoff, 1, &kaddr, &pfn);
>> - len2 = dax_direct_access(dax_dev, pgoff_end, 1, &end_kaddr, &end_pfn);
>> + len = dax_direct_access(dax_dev, pgoff, 1, &kaddr, &pfn, 0);
>> + len2 = dax_direct_access(dax_dev, pgoff_end, 1, &end_kaddr, &end_pfn, 0);
>
> FYI, I have a series killing this code. But either way please avoid
> these overly long lines.
>
>> long dax_direct_access(struct dax_device *dax_dev, pgoff_t pgoff, long nr_pages,
>> - void **kaddr, pfn_t *pfn)
>> + void **kaddr, pfn_t *pfn, unsigned long flags)
>
> API design: I'd usually expect flags before output paramters.
>
Thanks for the heads up.
Sure, will break long lines and move 'flags' ahead of output parameters.
thanks,
jane
Powered by blists - more mailing lists