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] [day] [month] [year] [list]
Message-ID: <20251206015613.GA3303517@bhelgaas>
Date: Fri, 5 Dec 2025 19:56:13 -0600
From: Bjorn Helgaas <helgaas@...nel.org>
To: dan.j.williams@...el.com
Cc: Terry Bowman <terry.bowman@....com>, dave@...olabs.net,
	jonathan.cameron@...wei.com, dave.jiang@...el.com,
	alison.schofield@...el.com, bhelgaas@...gle.com,
	shiju.jose@...wei.com, ming.li@...omail.com,
	Smita.KoralahalliChannabasappa@....com, rrichter@....com,
	dan.carpenter@...aro.org, PradeepVineshReddy.Kodamati@....com,
	lukas@...ner.de, Benjamin.Cheatham@....com,
	sathyanarayanan.kuppuswamy@...ux.intel.com,
	linux-cxl@...r.kernel.org, alucerop@....com, ira.weiny@...el.com,
	linux-kernel@...r.kernel.org, linux-pci@...r.kernel.org
Subject: Re: [PATCH v13 01/25] CXL/PCI: Move CXL DVSEC definitions into
 uapi/linux/pci_regs.h

On Fri, Dec 05, 2025 at 04:41:40PM -0800, dan.j.williams@...el.com wrote:
> Bjorn Helgaas wrote:
> > On Mon, Nov 03, 2025 at 06:09:37PM -0600, Terry Bowman wrote:
> > > The CXL DVSECs are currently defined in cxl/core/cxlpci.h. These are not
> > > accessible to other subsystems. Move these to uapi/linux/pci_regs.h.

> > > +#define PCI_DVSEC_HEADER1_LENGTH_MASK  __GENMASK(31, 20)
> > 
> > Looks like a functional duplicate of PCI_DVSEC_HEADER1_LEN().
> > 
> > Why __GENMASK() instead of GENMASK()?  I don't know the purpose of
> > __GENMASK(), but I see other include/uapi/ files using GENMASK().
> > Maybe they're wrong?
> > 
> > Same questions for _BITUL() below.
> 
> See this commit:
> 
> 3c7a8e190bc5 uapi: introduce uapi-friendly macros for GENMASK
> 
> GENMASK() for a long time was not available to uapi headers since uapi
> headers can only include other include/uapi/ headers, not
> include/linux/. That commit made some common kernel bitfield helpers
> finally available to the uapi side of the house.

So are the uses I see here wrong?

  git grep "\<GENMASK\|\<BIT\>" include/uapi/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ