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]
Date:	Wed, 15 Jan 2014 23:33:53 +0000
From:	Ben Hutchings <bhutchings@...arflare.com>
To:	"Keller, Jacob E" <jacob.e.keller@...el.com>
CC:	Amir Vadai <amirv@...lanox.com>,
	"Kirsher, Jeffrey T" <jeffrey.t.kirsher@...el.com>,
	Bjorn Helgaas <bhelgaas@...gle.com>,
	"David S. Miller" <davem@...emloft.net>,
	"netdev@...r.kernel.org" <netdev@...r.kernel.org>,
	Or Gerlitz <ogerlitz@...lanox.com>,
	Eyal Perry <eyalpe@...lanox.com>,
	"Skidmore, Donald C" <donald.c.skidmore@...el.com>
Subject: Re: [PATCH net-next] net/mlx4_core: Warn if device doesn't have
 enough PCI bandwidth

On Wed, 2014-01-15 at 23:15 +0000, Keller, Jacob E wrote:
> On Mon, 2014-01-06 at 21:15 +0000, Ben Hutchings wrote:
> > On Sat, 2014-01-04 at 21:17 +0200, Amir Vadai wrote:
> > > From: Eyal Perry <eyalpe@...lanox.com>
> > > 
> > > Check if the device get enough bandwidth from the entire PCI chain to satisfy
> > > its capabilities. This patch determines the PCIe device's bandwidth capabilities
> > > by reading its PCIe Link Capabilities registers and then call the
> > > pcie_get_minimum_link function to ensure that the adapter is hooked into a slot
> > > which is capable of providing the necessary bandwidth capabilities.
> > [...]
> > 
> > This is essentially another duplicate of what ixgbe and i40e are
> > doing...  (And the out-of-tree version of sfc does it too, but I never
> > felt that was ready for in-tree.)
> > 
> > We ought to have a generic PCI layer function that warns when a PCIe
> > device is running below maximum link width/speed.  Maybe even run it as
> > soon as the device is enumerated, so that a driver doesn't need to do
> > anything.
> > 
> > Ben.
> > 
> 
> Hi,
> 
> I was thinking about this again, was wondering a few things. Is this
> something you were already investigating?

No, I'm busy with other things.

> On an implementation note, how would this function know how much
> bandwidth a particular device (or function?) would require? I'm thinking
> of something along the lines of a driver essentially saying how much the
> devices it supports require?

I was thinking you could generically compare the link status with link
capabilities of the endpoint, i.e. actual versus maximum possible
bandwidth.

In some cases the link capabilities may be more than you really need.
For example, given a 10/40G controller capable of PCIe gen3 x8, on a
board that only has a single 10G port, you could put the board in a gen1
x8 slot and still have enough PCIe bandwidth to saturate the Ethernet
link.  However it will have higher latency compared to a gen3 x8 slot.
So I think the generic comparison would be OK as long as the log message
and severity is not too alarming.

Ben.

-- 
Ben Hutchings, Staff Engineer, Solarflare
Not speaking for my employer; that's the marketing department's job.
They asked us to note that Solarflare product names are trademarked.

--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ