lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <Y+EoTPqkSOrOZlyq@casper.infradead.org>
Date:   Mon, 6 Feb 2023 16:18:20 +0000
From:   Matthew Wilcox <willy@...radead.org>
To:     Charan Teja Kalla <quic_charante@...cinc.com>
Cc:     akpm@...ux-foundation.org, hughd@...gle.com,
        markhemm@...glemail.com, rientjes@...gle.com, surenb@...gle.com,
        shakeelb@...gle.com, mhocko@...e.com, vbabka@...e.cz,
        quic_pkondeti@...cinc.com, linux-mm@...ck.org,
        linux-kernel@...r.kernel.org
Subject: Re: [PATCH V6 2/2] mm: shmem: implement POSIX_FADV_[WILL|DONT]NEED
 for shmem

On Mon, Feb 06, 2023 at 07:51:33PM +0530, Charan Teja Kalla wrote:
> +static int shmem_fadvise_willneed(struct address_space *mapping,
> +				 pgoff_t start, pgoff_t long end)
> +{
> +	struct page *page;
> +	pgoff_t index;
> +
> +	xa_for_each_range(&mapping->i_pages, index, page, start, end) {
> +		if (!xa_is_value(page))
> +			continue;
> +		page = shmem_read_mapping_page(mapping, index);
> +		if (!IS_ERR(page))
> +			put_page(page);
> +	}
> +
> +	return 0;
> +}

Hm, that's a gap in the shmem folio API.  Patches imminent.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ