Re: [PATCH -mm -V3 03/21] mm, THP, swap: Support PMD swap mapping in swap_duplicate()

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

 



On Tue, Jun 12, 2018 at 09:23:19AM +0800, Huang, Ying wrote:
> Daniel Jordan <daniel.m.jordan@xxxxxxxxxx> writes:
> >> +#else
> >> +static inline int __swap_duplicate_cluster(swp_entry_t *entry,
> >
> > This doesn't need inline.
> 
> Why not?  This is just a one line stub.

Forgot to respond to this.  The compiler will likely choose to optimize out
calls to an empty function like this.  Checking, this is indeed what it does in
this case on my machine, with or without inline.


By the way, when building without CONFIG_THP_SWAP, we get

  linux/mm/swapfile.c:933:13: warning: ‘__swap_free_cluster’ defined but not used [-Wunused-function]
   static void __swap_free_cluster(struct swap_info_struct *si, unsigned long idx)
               ^~~~~~~~~~~~~~~~~~~




[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Bugtraq]     [Linux OMAP]     [Linux MIPS]     [eCos]     [Asterisk Internet PBX]     [Linux API]

  Powered by Linux