Re: [PATCH 3/4] Documentation/vm: Remove "Using kmap-atomic" from highmem.rst.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On venerdì 22 aprile 2022 20:38:09 CEST Ira Weiny wrote:
> On Thu, Apr 21, 2022 at 08:01:59PM +0200, Fabio M. De Francesco wrote:
> > The use of kmap_atomic() is deprecated in favor of kmap_local_page().
> 
> I'm not sure deprecated is the right word.

OK, in v2 I won't use "deprecated". Instead I'll say something about a 
strong preference to avoid its use. The reason why developers should avoid 
kmap_atomic() are explained in 4/4 (I've copy-pasted some lines here for 
your convenience):

+  Each call of kmap_atomic() in the kernel creates a non-preemptible 
section
+  and disable pagefaults. This could be a source of unwanted latency, so 
it
+  should be only used if it is absolutely required, otherwise 
kmap_local_page()
+  should be used where it is feasible.

> And I think the fact that this
> documentation is stale is a better reason for the patch as is.
> 
> This series should end up indicating the desire to stop growing kmap() 
and
> kmap_atomic() call sites and that their deprecation is on the horizon.  
I've
> not read the text in patch 4/4 yet.

I'll wait for your review of 4/4 before sending v2.

> 
> > For
> > this reason the "Using kmap_atomic" section in highmem.rst is obsolete 
and
> > unnecessary.
> 
> A lot of the text is obsolete (and redundant) but the example code might 
be
> useful.
> 
> Why not move the example and relevant bits into the kdoc for 
kmap_atomic()
> which is then automatically picked up via patch 2/4.

Yes, I agree with you. I'll take into account your suggestion for v2.

However, as I said above, I'll hold v2 until you have time to review 4/4 
for the purpose to not miss any changes that you might require for that 
patch too.

Furthermore, while working on v2, I think that I'll extend this series with 
one or two patch more, in order to address other issues I noticed. 

Thanks,

Fabio 






[Index of Archives]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Linux FS]     [Yosemite Forum]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]     [Linux Resources]

  Powered by Linux