Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

mfd: handle legacy m10bmc #1

Open
wants to merge 54 commits into
base: fpga-ofs-dev
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
54 commits
Select commit Hold shift + click to select a range
7f031a6
fpga: dfl: support multiple opens on feature device node.
yilunxu1984 Nov 18, 2019
d24d498
fpga: dfl: pci: fix return value of cci_pci_sriov_configure
yilunxu1984 Feb 25, 2020
4f6918c
Documentation: fpga: dfl: add description for performance reporting s…
yilunxu1984 Apr 14, 2020
c844778
fpga: dfl: fme: add performance reporting support
WuHao270 Apr 14, 2020
69633d2
fpga: dfl: parse interrupt info for feature devices on enumeration
yilunxu1984 Apr 7, 2020
6ed13c6
fpga: dfl: pci: add irq info for feature devices enumeration
yilunxu1984 Apr 7, 2020
7703cf1
fpga: dfl: introduce interrupt trigger setting API
yilunxu1984 Apr 7, 2020
13a8d7f
fpga: dfl: afu: add interrupt support for port error reporting
yilunxu1984 Apr 7, 2020
3c1f142
fpga: dfl: fme: add interrupt support for global error reporting
yilunxu1984 Apr 7, 2020
e047130
fpga: dfl: afu: add AFU interrupt support
yilunxu1984 Apr 7, 2020
d95a8df
Documentation: fpga: dfl: add descriptions for interrupt related inte…
yilunxu1984 Apr 7, 2020
d4ff3d9
fpga: dfl: fme: support 512bit data width PR
WuHao270 Jul 5, 2019
9738c3b
fpga: dfl: map feature mmio resources in their own feature drivers
yilunxu1984 Dec 31, 2019
7a2476a
fpga: dfl: create a dfl bus type to support DFL devices
yilunxu1984 Jan 3, 2020
b4afcf8
dfl: move dfl_device_id to mod_devicetable.h
yilunxu1984 Mar 12, 2020
c985de9
dfl: add dfl bus support to MODULE_DEVICE_TABLE()
yilunxu1984 Mar 12, 2020
b550d6e
fpga: dfl: pci: add device id for Intel FPGA PAC N3000
yilunxu1984 Jan 7, 2020
082f565
spi: altera: add 32bit data width transfer support.
yilunxu1984 Jan 7, 2020
7ec26ee
spi: altera: add SPI core parameters support via platform data.
yilunxu1984 Jan 7, 2020
27487bf
spi: altera: add platform data for slave information.
yilunxu1984 Jan 10, 2020
18f4c77
spi: altera: use regmap instead of direct mmio register access
yilunxu1984 Jan 8, 2020
d5d990a
spi: altera: move driver name string to header file
yilunxu1984 Jan 10, 2020
95f6516
fpga: dfl: move dfl-bus related APIs to include/linux/fpga/dfl-bus.h
yilunxu1984 Apr 21, 2020
c166df2
fpga: dfl: add support for N3000 nios private feature
yilunxu1984 Jan 3, 2020
de84bb0
mfd: intel-m10-bmc: add Max10 BMC chip support for Intel FPGA PAC
yilunxu1984 Jan 13, 2020
1f87030
spi: altera: fix size mismatch on 64 bit processors
matthew-gerlach Apr 24, 2020
1a262f2
fpga: dfl: pci: reduce the scope of variable 'ret'
yilunxu1984 Apr 16, 2020
6761dc5
fpga: dfl: fix bug in port reset handshake
matthew-gerlach Apr 16, 2020
0729322
mfd: intel-m10-bmc: add hwmon support for MAX10 BMC chip
yilunxu1984 Feb 24, 2020
b51af43
mfd: intel-m10-bmc: expose mac address and count
May 26, 2020
7a0b634
mfd: intel-m10-bmc: declare static for some functions and variables
yilunxu1984 May 28, 2020
df55b0e
hwmon: intel-m10-bmc: declare static for some functions and variables
yilunxu1984 May 28, 2020
795cce9
fpga: dfl: fme: use hlist_entry() in fme_perf_offline_cpu()
yilunxu1984 May 9, 2020
8078c30
fpga: dfl: pci: add DID for D5005 PAC cards
Mar 10, 2020
cd6ae57
fpga: dfl: Add DFL bus driver for Altera SPI Master
matthew-gerlach Apr 15, 2020
d0dc3e5
hwmon: intel-m10-bmc-hwmon: add sensor support of Intel D5005 card
matthew-gerlach Apr 4, 2020
19a1c58
net: ethernet: intel: template network driver for 10G MAC
matthew-gerlach Apr 21, 2020
b897a4a
net: phy: intel: driver for stratix10 phy
Apr 23, 2020
6f0f7b0
fpga: dfl: hssi driver
Apr 22, 2020
f12f94b
fpga: dfl: fme: fpga security manager class driver
Mar 5, 2020
ac2ceb9
mfd: intel-m10-bmc: create max10 bcm security engine
May 4, 2020
237fd18
mfd: intel-m10-bmc: expose flash count in sysfs
Apr 11, 2020
6bc5c84
mfd: intel-m10-bmc: expose canceled keys in sysfs
May 5, 2020
7c17e93
fpga: dfl: fme: enable secure updates
Apr 13, 2020
767060a
mfd: intel-m10-bmc: add secure update functions
May 5, 2020
9b83177
fpga: dfl: fme: expose sec-mgr update status
Apr 14, 2020
d60157b
fpga: dfl: fme: expose sec-mgr update errors
Apr 15, 2020
ebb3338
fpga: dfl: fme: expose sec-mgr update size
Apr 15, 2020
1d99f2d
fpga: dfl: fme: enable sec-mgr update cancel
Apr 15, 2020
685d608
fpga: dfl: fme: expose hardware error info in sysfs
May 13, 2020
3e356d7
mfd: intel-m10-bmc: add sec_mgr get_hw_errinfo func
May 13, 2020
5729b58
mfd: intel-m10-bmc: add bmc secure device for d5005
May 5, 2020
c5fa2c3
dfl: add config fragment and readme
matthew-gerlach May 4, 2020
5a365e7
mfd: handle legacy m10bmc
Jun 19, 2020
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 15 additions & 0 deletions Documentation/ABI/testing/sysfs-bus-dfl
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
What: /sys/bus/dfl/devices/.../type
Date: March 2020
KernelVersion: 5.7
Contact: Xu Yilun <[email protected]>
Description: Read-only. It returns type of DFL FIU of the device. Now DFL
supports 2 FIU types, 0 for FME, 1 for PORT.
Format: 0x%x

What: /sys/bus/dfl/devices/.../feature_id
Date: March 2020
KernelVersion: 5.7
Contact: Xu Yilun <[email protected]>
Description: Read-only. It returns feature identifier local to its DFL FIU
type.
Format: 0x%llx
16 changes: 16 additions & 0 deletions Documentation/ABI/testing/sysfs-bus-dfl-devices-n3000-nios
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
What: /sys/bus/dfl/devices/dfl-fme.X.X/fec_mode
Date: March 2020
KernelVersion: 5.8
Contact: Xu Yilun <[email protected]>
Description: Read-only. It returns the FEC mode of the ethernet retimer
configured by NIOS firmware. "rs" for RS FEC mode, "kr" for
KR FEC mode, "no" FOR NO FEC mode.
Format: string

What: /sys/bus/dfl/devices/dfl-fme.X.X/nios_fw_version
Date: March 2020
KernelVersion: 5.8
Contact: Xu Yilun <[email protected]>
Description: Read-only. It returns the NIOS firmware version in FPGA. Its
format is "major.minor.patch".
Format: %x.%x.%x
104 changes: 104 additions & 0 deletions Documentation/ABI/testing/sysfs-bus-event_source-devices-dfl_fme
Original file line number Diff line number Diff line change
@@ -0,0 +1,104 @@
What: /sys/bus/event_source/devices/dfl_fmeX/format
Date: April 2020
KernelVersion: 5.8
Contact: Wu Hao <[email protected]>
Description: Read-only. Attribute group to describe the magic bits
that go into perf_event_attr.config for a particular pmu.
(See ABI/testing/sysfs-bus-event_source-devices-format).

Each attribute under this group defines a bit range of the
perf_event_attr.config. All supported attributes are listed
below.

event = "config:0-11" - event ID
evtype = "config:12-15" - event type
portid = "config:16-23" - event source

For example,

fab_mmio_read = "event=0x06,evtype=0x02,portid=0xff"

It shows this fab_mmio_read is a fabric type (0x02) event with
0x06 local event id for overall monitoring (portid=0xff).

What: /sys/bus/event_source/devices/dfl_fmeX/cpumask
Date: April 2020
KernelVersion: 5.8
Contact: Wu Hao <[email protected]>
Description: Read-only. This file always returns cpu which the PMU is bound
for access to all fme pmu performance monitoring events.

What: /sys/bus/event_source/devices/dfl_fmeX/events
Date: April 2020
KernelVersion: 5.8
Contact: Wu Hao <[email protected]>
Description: Read-only. Attribute group to describe performance monitoring
events specific to fme. Each attribute in this group describes
a single performance monitoring event supported by this fme pmu.
The name of the file is the name of the event.
(See ABI/testing/sysfs-bus-event_source-devices-events).

All supported performance monitoring events are listed below.

Basic events (evtype=0x00)

clock = "event=0x00,evtype=0x00,portid=0xff"

Cache events (evtype=0x01)

cache_read_hit = "event=0x00,evtype=0x01,portid=0xff"
cache_read_miss = "event=0x01,evtype=0x01,portid=0xff"
cache_write_hit = "event=0x02,evtype=0x01,portid=0xff"
cache_write_miss = "event=0x03,evtype=0x01,portid=0xff"
cache_hold_request = "event=0x05,evtype=0x01,portid=0xff"
cache_data_write_port_contention =
"event=0x06,evtype=0x01,portid=0xff"
cache_tag_write_port_contention =
"event=0x07,evtype=0x01,portid=0xff"
cache_tx_req_stall = "event=0x08,evtype=0x01,portid=0xff"
cache_rx_req_stall = "event=0x09,evtype=0x01,portid=0xff"
cache_eviction = "event=0x0a,evtype=0x01,portid=0xff"

Fabric events (evtype=0x02)

fab_pcie0_read = "event=0x00,evtype=0x02,portid=0xff"
fab_pcie0_write = "event=0x01,evtype=0x02,portid=0xff"
fab_pcie1_read = "event=0x02,evtype=0x02,portid=0xff"
fab_pcie1_write = "event=0x03,evtype=0x02,portid=0xff"
fab_upi_read = "event=0x04,evtype=0x02,portid=0xff"
fab_upi_write = "event=0x05,evtype=0x02,portid=0xff"
fab_mmio_read = "event=0x06,evtype=0x02,portid=0xff"
fab_mmio_write = "event=0x07,evtype=0x02,portid=0xff"
fab_port_pcie0_read = "event=0x00,evtype=0x02,portid=?"
fab_port_pcie0_write = "event=0x01,evtype=0x02,portid=?"
fab_port_pcie1_read = "event=0x02,evtype=0x02,portid=?"
fab_port_pcie1_write = "event=0x03,evtype=0x02,portid=?"
fab_port_upi_read = "event=0x04,evtype=0x02,portid=?"
fab_port_upi_write = "event=0x05,evtype=0x02,portid=?"
fab_port_mmio_read = "event=0x06,evtype=0x02,portid=?"
fab_port_mmio_write = "event=0x07,evtype=0x02,portid=?"

VTD events (evtype=0x03)

vtd_port_read_transaction = "event=0x00,evtype=0x03,portid=?"
vtd_port_write_transaction = "event=0x01,evtype=0x03,portid=?"
vtd_port_devtlb_read_hit = "event=0x02,evtype=0x03,portid=?"
vtd_port_devtlb_write_hit = "event=0x03,evtype=0x03,portid=?"
vtd_port_devtlb_4k_fill = "event=0x04,evtype=0x03,portid=?"
vtd_port_devtlb_2m_fill = "event=0x05,evtype=0x03,portid=?"
vtd_port_devtlb_1g_fill = "event=0x06,evtype=0x03,portid=?"

VTD SIP events (evtype=0x04)

vtd_sip_iotlb_4k_hit = "event=0x00,evtype=0x04,portid=0xff"
vtd_sip_iotlb_2m_hit = "event=0x01,evtype=0x04,portid=0xff"
vtd_sip_iotlb_1g_hit = "event=0x02,evtype=0x04,portid=0xff"
vtd_sip_slpwc_l3_hit = "event=0x03,evtype=0x04,portid=0xff"
vtd_sip_slpwc_l4_hit = "event=0x04,evtype=0x04,portid=0xff"
vtd_sip_rcc_hit = "event=0x05,evtype=0x04,portid=0xff"
vtd_sip_iotlb_4k_miss = "event=0x06,evtype=0x04,portid=0xff"
vtd_sip_iotlb_2m_miss = "event=0x07,evtype=0x04,portid=0xff"
vtd_sip_iotlb_1g_miss = "event=0x08,evtype=0x04,portid=0xff"
vtd_sip_slpwc_l3_miss = "event=0x09,evtype=0x04,portid=0xff"
vtd_sip_slpwc_l4_miss = "event=0x0a,evtype=0x04,portid=0xff"
vtd_sip_rcc_miss = "event=0x0b,evtype=0x04,portid=0xff"
131 changes: 131 additions & 0 deletions Documentation/ABI/testing/sysfs-class-ifpga-sec-mgr
Original file line number Diff line number Diff line change
@@ -0,0 +1,131 @@
What: /sys/class/ifpga_sec_mgr/ifpga_secX/security/sr_root_entry_hash
Date: June 2020
KernelVersion: 5.8
Contact: Russ Weight <[email protected]>
Description: Read only. Returns the root entry hash for the static
region if one is programmed, else it returns the
string: "hash not programmed". This file is only
visible if the underlying device supports it.
Format: "0x%x".

What: /sys/class/ifpga_sec_mgr/ifpga_secX/security/pr_root_entry_hash
Date: June 2020
KernelVersion: 5.8
Contact: Russ Weight <[email protected]>
Description: Read only. Returns the root entry hash for the partial
reconfiguration region if one is programmed, else it
returns the string: "hash not programmed". This file
is only visible if the underlying device supports it.
Format: "0x%x".

What: /sys/class/ifpga_sec_mgr/ifpga_secX/security/bmc_root_entry_hash
Date: June 2020
KernelVersion: 5.8
Contact: Russ Weight <[email protected]>
Description: Read only. Returns the root entry hash for the BMC image
if one is programmed, else it returns the string:
"hash not programmed". This file is only visible if the
underlying device supports it.
Format: "0x%x".

What: /sys/class/ifpga_sec_mgr/ifpga_secX/security/sr_canceled_csks
Date: June 2020
KernelVersion: 5.8
Contact: Russ Weight <[email protected]>
Description: Read only. Returns a list of indices for canceled code
signing keys for the static region. The standard bitmap
list format is used (e.g. "1,2-6,9").

What: /sys/class/ifpga_sec_mgr/ifpga_secX/security/pr_canceled_csks
Date: June 2020
KernelVersion: 5.8
Contact: Russ Weight <[email protected]>
Description: Read only. Returns a list of indices for canceled code
signing keys for the partial reconfiguration region. The
standard bitmap list format is used (e.g. "1,2-6,9").

What: /sys/class/ifpga_sec_mgr/ifpga_secX/security/bmc_canceled_csks
Date: June 2020
KernelVersion: 5.8
Contact: Russ Weight <[email protected]>
Description: Read only. Returns a list of indices for canceled code
signing keys for the BMC. The standard bitmap list format
is used (e.g. "1,2-6,9").

What: /sys/class/ifpga_sec_mgr/ifpga_secX/security/user_flash_count
Date: June 2020
KernelVersion: 5.8
Contact: Russ Weight <[email protected]>
Description: Read only. Returns number of times the user image for the
static region has been flashed.
Format: "%d".

What: /sys/class/ifpga_sec_mgr/ifpga_secX/security/bmc_flash_count
Date: June 2020
KernelVersion: 5.8
Contact: Russ Weight <[email protected]>
Description: Read only. Returns number of times the BMC image has been
flashed.
Format: "%d".

What: /sys/class/ifpga_sec_mgr/ifpga_secX/update/filename
Date: June 2020
KernelVersion: 5.8
Contact: Russ Weight <[email protected]>
Description: Write only. Write the filename of an Intel image
file to this sysfs file to initiate a secure
update. The file must have an appropriate header
which, among other things, identifies the target
for the update. This mechanism is used to update
BMC images, BMC firmware, Static Region images,
and Root Entry Hashes, and to cancel Code Signing
Keys (CSK).

What: /sys/class/ifpga_sec_mgr/ifpga_secX/update/cancel
Date: June 2020
KernelVersion: 5.8
Contact: Russ Weight <[email protected]>
Description: Write-only. Write a "1" to this file to request
that a current update be canceled. This request
will be rejected (EBUSY) if the programming phase
has already started.

What: /sys/class/ifpga_sec_mgr/ifpga_secX/update/status
Date: June 2020
KernelVersion: 5.8
Contact: Russ Weight <[email protected]>
Description: Read-only. Returns a string describing the current
status of an update. The string will be one of the
following: idle, preparing, writing, programming.

What: /sys/class/ifpga_sec_mgr/ifpga_secX/update/remaining_size
Date: June 2020
KernelVersion: 5.8
Contact: Russ Weight <[email protected]>
Description: Read-only. Returns the size of data that remains to
be written to the secure update engine. The size
value is initialized to the full size of the file
image and the value is updated periodically during
the "writing" phase of the update.
Format: "%u".

What: /sys/class/ifpga_sec_mgr/ifpga_secX/update/error
Date: June 2020
KernelVersion: 5.8
Contact: Russ Weight <[email protected]>
Description: Read-only. Returns an error string describing the
failure of a secure update. This string will be one
of the following: operation-error, crc-error,
auth-error, timeout-error, user-abort, device-busy,
invalid_size.

What: /sys/class/ifpga_sec_mgr/ifpga_secX/update/hw_errinfo
Date: June 2020
KernelVersion: 5.8
Contact: Russ Weight <[email protected]>
Description: Read-only. Returns a 64 bit error value providing
hardware specific information that may be useful in
debugging errors that occur during FPGA image updates.
This file is only visible if the underlying device
supports it.
Format: "0x%llx".
19 changes: 19 additions & 0 deletions Documentation/ABI/testing/sysfs-driver-intel-m10-bmc
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
What: /sys/bus/spi/devices/.../mac_address
Date: June 2020
KernelVersion: 5.8
Contact: Russ Weight <[email protected]>
Description: Read only. Returns the base mac address assigned to
the board managed by the Intel MAX10 BMC. It is
stored in flash and is mirrored in the MAX10 BMC
register space.
Format: "%02x:%02x:%02x:%02x:%02x:%02x".

What: /sys/bus/spi/devices/.../mac_count
Date: June 2020
KernelVersion: 5.8
Contact: Russ Weight <[email protected]>
Description: Read only. Returns the number of mac addresses
assigned to the board managed by the Intel MAX10
BMC. This value is stored in flash and is mirrored
in the MAX10 BMC register space.
Format: "%u".
Loading