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 for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20180117034214.4dlns3eojitdsve3@ast-mbp>
Date:   Tue, 16 Jan 2018 19:42:15 -0800
From:   Alexei Starovoitov <alexei.starovoitov@...il.com>
To:     Jakub Kicinski <jakub.kicinski@...ronome.com>
Cc:     daniel@...earbox.net, netdev@...r.kernel.org,
        oss-drivers@...ronome.com, Jiong Wang <jiong.wang@...ronome.com>
Subject: Re: [PATCH bpf-next 3/3] tools: bpftool: improve architecture
 detection by using ifindex

On Tue, Jan 16, 2018 at 04:05:21PM -0800, Jakub Kicinski wrote:
> From: Jiong Wang <jiong.wang@...ronome.com>
> 
> The current architecture detection method in bpftool is designed for host
> case.
> 
> For offload case, we can't use the architecture of "bpftool" itself.
> Instead, we could call the existing "ifindex_to_name_ns" to get DEVNAME,
> then read pci id from /sys/class/dev/DEVNAME/device/vendor, finally we map
> vendor id to bfd arch name which will finally be used to select bfd backend
> for the disassembler.
> 
> Reviewed-by: Jakub Kicinski <jakub.kicinski@...ronome.com>
> Signed-off-by: Jiong Wang <jiong.wang@...ronome.com>

awesome addition!
Acked-by: Alexei Starovoitov <ast@...nel.org>

> +	switch (vendor_id) {
> +	case 0x19ee:
> +		device_id = read_sysfs_netdev_hex_int(devname, "device");
> +		if (device_id != 0x4000 &&
> +		    device_id != 0x6000 &&
> +		    device_id != 0x6003)
> +			p_info("Unknown NFP device ID, assuming it is NFP-6xxx arch");
> +		return "NFP-6xxx";

is this a canonical name that bfd will understand?
a link to bfd patches?

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ