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: <ZytNkxLzgBnQn_pV@smile.fi.intel.com>
Date: Wed, 6 Nov 2024 13:05:55 +0200
From: Andy Shevchenko <andriy.shevchenko@...ux.intel.com>
To: Philipp Stanner <pstanner@...hat.com>
Cc: Thomas Gleixner <tglx@...utronix.de>, Ingo Molnar <mingo@...hat.com>,
	Borislav Petkov <bp@...en8.de>,
	Dave Hansen <dave.hansen@...ux.intel.com>, x86@...nel.org,
	"H. Peter Anvin" <hpa@...or.com>, linux-kernel@...r.kernel.org
Subject: Re: [PATCH] x86/platform/intel-mid: Replace deprecated PCI functions

On Wed, Nov 06, 2024 at 09:37:51AM +0100, Philipp Stanner wrote:
> On Tue, 2024-11-05 at 16:52 +0200, Andy Shevchenko wrote:
> > On Tue, Nov 05, 2024 at 12:25:22PM +0100, Philipp Stanner wrote:

...

> > > -	ret = pcim_iomap_regions(pdev, 1 << 0, pci_name(pdev));
> > > -	if (ret) {
> > > -		dev_err(&pdev->dev, "I/O memory remapping
> > > failed\n");
> > 
> > Btw, do we have a similar message to be printed inside the new call?
> 
> Hm, no, it seems I forgot. Normally I keep those messages.
> 
> In this particular case we probably want to say "I/O memory request /
> remapping failed\n", though.
> 
> And/or we give back the error code, which would reveal the exact issue
> through -ENOMEM / -EBUSY

I would expect this to behave in a similar way to devm_*ioremap*() which prints
message(s) and returns different error codes depending on the failure.

> > > -		return ret;
> > > -	}

...

> > > +	pwr->regs = pcim_iomap_region(pdev, 0, "intel_mid_pwr");
> > > +	if (IS_ERR(pwr->regs))
> > > +		return PTR_ERR(pwr->regs);

-- 
With Best Regards,
Andy Shevchenko



Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ