Dave Hansen writes:
>> Yes. Boolean parameter isn't good at most times. Matthew Wilcox
>> suggested to use
>>
>> swap_duplicate(&entry, HPAGE_PMD_NR);
>>
>> vs.
>>
>> swap_duplicate(&entry, 1);
>>
>> He thinks this makes the interface more flexible to support other swap
>> e
> Yes. Boolean parameter isn't good at most times. Matthew Wilcox
> suggested to use
>
> swap_duplicate(&entry, HPAGE_PMD_NR);
>
> vs.
>
> swap_duplicate(&entry, 1);
>
> He thinks this makes the interface more flexible to support other swap
> entry size in the future. What do
Dave Hansen writes:
>> +static inline bool thp_swap_supported(void)
>> +{
>> +return IS_ENABLED(CONFIG_THP_SWAP);
>> +}
>
> This seems like rather useless abstraction. Why do we need it?
I just want to make it shorter, 19 vs 27 characters. But if you think
IS_ENABLED(CONFIG_THP_SWAP) is mu
> +static inline bool thp_swap_supported(void)
> +{
> + return IS_ENABLED(CONFIG_THP_SWAP);
> +}
This seems like rather useless abstraction. Why do we need it?
...
> -static inline int swap_duplicate(swp_entry_t swp)
> +static inline int swap_duplicate(swp_entry_t *swp, bool cluster)
> {
>
Dan Williams writes:
> On Thu, Jun 21, 2018 at 8:55 PM Huang, Ying wrote:
>>
>> From: Huang Ying
>>
>> To support to swapin the THP as a whole, we need to create PMD swap
>> mapping during swapout, and maintain PMD swap mapping count. This
>> patch implements the support to increase the PMD sw
On Thu, Jun 21, 2018 at 8:55 PM Huang, Ying wrote:
>
> From: Huang Ying
>
> To support to swapin the THP as a whole, we need to create PMD swap
> mapping during swapout, and maintain PMD swap mapping count. This
> patch implements the support to increase the PMD swap mapping
> count (for swapout
Matthew Wilcox writes:
> On Fri, Jun 22, 2018 at 11:51:33AM +0800, Huang, Ying wrote:
>> +++ b/mm/swap_state.c
>> @@ -433,7 +433,7 @@ struct page *__read_swap_cache_async(swp_entry_t entry,
>> gfp_t gfp_mask,
>> /*
>> * Swap entry may have been freed since our caller o
On Fri, Jun 22, 2018 at 11:51:33AM +0800, Huang, Ying wrote:
> +++ b/mm/swap_state.c
> @@ -433,7 +433,7 @@ struct page *__read_swap_cache_async(swp_entry_t entry,
> gfp_t gfp_mask,
> /*
>* Swap entry may have been freed since our caller observed it.
>*
From: Huang Ying
To support to swapin the THP as a whole, we need to create PMD swap
mapping during swapout, and maintain PMD swap mapping count. This
patch implements the support to increase the PMD swap mapping
count (for swapout, fork, etc.) and set SWAP_HAS_CACHE flag (for
swapin, etc.) for
9 matches
Mail list logo