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: <20251124181521.GV233636@ziepe.ca>
Date: Mon, 24 Nov 2025 14:15:21 -0400
From: Jason Gunthorpe <jgg@...pe.ca>
To: ankita@...dia.com
Cc: yishaih@...dia.com, skolothumtho@...dia.com, kevin.tian@...el.com,
	alex@...zbot.org, aniketa@...dia.com, vsethi@...dia.com,
	mochs@...dia.com, Yunxiang.Li@....com, yi.l.liu@...el.com,
	zhangdongdong@...incomputing.com, avihaih@...dia.com,
	bhelgaas@...gle.com, peterx@...hat.com, pstanner@...hat.com,
	apopple@...dia.com, kvm@...r.kernel.org,
	linux-kernel@...r.kernel.org, cjia@...dia.com, kwankhede@...dia.com,
	targupta@...dia.com, zhiw@...dia.com, danw@...dia.com,
	dnigam@...dia.com, kjaju@...dia.com
Subject: Re: [PATCH v5 3/7] vfio/nvgrace-gpu: Add support for huge pfnmap

On Mon, Nov 24, 2025 at 11:59:22AM +0000, ankita@...dia.com wrote:
> +static size_t nvgrace_gpu_aligned_devmem_size(size_t memlength)
> +{
> +#ifdef CONFIG_ARCH_SUPPORTS_PMD_PFNMAP
> +	return ALIGN(memlength, PMD_SIZE);
> +#endif
> +#ifdef CONFIG_ARCH_SUPPORTS_PUD_PFNMAP
> +	return ALIGN(memlength, PUD_SIZE);
> +#endif
> +	return memlength;
> +}

This needs a comment why it is OK to change the size up? Seems really
surprising (and wrong!). The commit message should explain it too.

Jason

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ