1What:		/sys/class/mic/
2Date:		October 2013
3KernelVersion:	3.13
4Contact:	Sudeep Dutt <sudeep.dutt@intel.com>
5Description:
6		The mic class directory belongs to Intel MIC devices and
7		provides information per MIC device. An Intel MIC device is a
8		PCIe form factor add-in Coprocessor card based on the Intel Many
9		Integrated Core (MIC) architecture that runs a Linux OS.
10
11What:		/sys/class/mic/mic<X>
12Date:		October 2013
13KernelVersion:	3.13
14Contact:	Sudeep Dutt <sudeep.dutt@intel.com>
15Description:
16		The directories /sys/class/mic/mic0, /sys/class/mic/mic1 etc.,
17		represent MIC devices (0,1,..etc). Each directory has
18		information specific to that MIC device.
19
20What:		/sys/class/mic/mic<X>/family
21Date:		October 2013
22KernelVersion:	3.13
23Contact:	Sudeep Dutt <sudeep.dutt@intel.com>
24Description:
25		Provides information about the Coprocessor family for an Intel
26		MIC device. For example - "x100"
27
28What:		/sys/class/mic/mic<X>/stepping
29Date:		October 2013
30KernelVersion:	3.13
31Contact:	Sudeep Dutt <sudeep.dutt@intel.com>
32Description:
33		Provides information about the silicon stepping for an Intel
34		MIC device. For example - "A0" or "B0"
35
36What:		/sys/class/mic/mic<X>/state
37Date:		October 2013
38KernelVersion:	3.13
39Contact:	Sudeep Dutt <sudeep.dutt@intel.com>
40Description:
41		When read, this entry provides the current state of an Intel
42		MIC device in the context of the card OS. Possible values that
43		will be read are:
44
45
46		===============  ===============================================
47		"ready"		 The MIC device is ready to boot the card OS.
48				 On reading this entry after an OSPM resume,
49				 a "boot" has to be written to this entry if
50				 the card was previously shutdown during OSPM
51				 suspend.
52		"booting"	 The MIC device has initiated booting a card OS.
53		"online"	 The MIC device has completed boot and is online
54		"shutting_down"	 The card OS is shutting down.
55		"resetting"	 A reset has been initiated for the MIC device
56		"reset_failed"	 The MIC device has failed to reset.
57		===============  ===============================================
58
59		When written, this sysfs entry triggers different state change
60		operations depending upon the current state of the card OS.
61		Acceptable values are:
62
63
64		==========  ===================================================
65		"boot"      Boot the card OS image specified by the combination
66			    of firmware, ramdisk, cmdline and bootmode
67			    sysfs entries.
68		"reset"     Initiates device reset.
69		"shutdown"  Initiates card OS shutdown.
70		==========  ===================================================
71
72What:		/sys/class/mic/mic<X>/shutdown_status
73Date:		October 2013
74KernelVersion:	3.13
75Contact:	Sudeep Dutt <sudeep.dutt@intel.com>
76Description:
77		An Intel MIC device runs a Linux OS during its operation. This
78		OS can shutdown because of various reasons. When read, this
79		entry provides the status on why the card OS was shutdown.
80		Possible values are:
81
82		==========  ===================================================
83		"nop"       shutdown status is not applicable, when the card OS
84			    is "online"
85		"crashed"   Shutdown because of a HW or SW crash.
86		"halted"    Shutdown because of a halt command.
87		"poweroff"  Shutdown because of a poweroff command.
88		"restart"   Shutdown because of a restart command.
89		==========  ===================================================
90
91What:		/sys/class/mic/mic<X>/cmdline
92Date:		October 2013
93KernelVersion:	3.13
94Contact:	Sudeep Dutt <sudeep.dutt@intel.com>
95Description:
96		An Intel MIC device runs a Linux OS during its operation. Before
97		booting this card OS, it is possible to pass kernel command line
98		options to configure various features in it, similar to
99		self-bootable machines. When read, this entry provides
100		information about the current kernel command line options set to
101		boot the card OS. This entry can be written to change the
102		existing kernel command line options. Typically, the user would
103		want to read the current command line options, append new ones
104		or modify existing ones and then write the whole kernel command
105		line back to this entry.
106
107What:		/sys/class/mic/mic<X>/firmware
108Date:		October 2013
109KernelVersion:	3.13
110Contact:	Sudeep Dutt <sudeep.dutt@intel.com>
111Description:
112		When read, this sysfs entry provides the path name under
113		/lib/firmware/ where the firmware image to be booted on the
114		card can be found. The entry can be written to change the
115		firmware image location under /lib/firmware/.
116
117What:		/sys/class/mic/mic<X>/ramdisk
118Date:		October 2013
119KernelVersion:	3.13
120Contact:	Sudeep Dutt <sudeep.dutt@intel.com>
121Description:
122		When read, this sysfs entry provides the path name under
123		/lib/firmware/ where the ramdisk image to be used during card
124		OS boot can be found. The entry can be written to change
125		the ramdisk image location under /lib/firmware/.
126
127What:		/sys/class/mic/mic<X>/bootmode
128Date:		October 2013
129KernelVersion:	3.13
130Contact:	Sudeep Dutt <sudeep.dutt@intel.com>
131Description:
132		When read, this sysfs entry provides the current bootmode for
133		the card. This sysfs entry can be written with the following
134		valid strings:
135		a) linux - Boot a Linux image.
136		b) flash - Boot an image for flash updates.
137
138What:		/sys/class/mic/mic<X>/log_buf_addr
139Date:		October 2013
140KernelVersion:	3.13
141Contact:	Sudeep Dutt <sudeep.dutt@intel.com>
142Description:
143		An Intel MIC device runs a Linux OS during its operation. For
144		debugging purpose and early kernel boot messages, the user can
145		access the card OS log buffer via debugfs. When read, this entry
146		provides the kernel virtual address of the buffer where the card
147		OS log buffer can be read. This entry is written by the host
148		configuration daemon to set the log buffer address. The correct
149		log buffer address to be written can be found in the System.map
150		file of the card OS.
151
152What:		/sys/class/mic/mic<X>/log_buf_len
153Date:		October 2013
154KernelVersion:	3.13
155Contact:	Sudeep Dutt <sudeep.dutt@intel.com>
156Description:
157		An Intel MIC device runs a Linux OS during its operation. For
158		debugging purpose and early kernel boot messages, the user can
159		access the card OS log buffer via debugfs. When read, this entry
160		provides the kernel virtual address where the card OS log buffer
161		length can be read. This entry is written by host configuration
162		daemon to set the log buffer length address. The correct log
163		buffer length address to be written can be found in the
164		System.map file of the card OS.
165
166What:		/sys/class/mic/mic<X>/heartbeat_enable
167Date:		March 2015
168KernelVersion:	4.4
169Contact:	Ashutosh Dixit <ashutosh.dixit@intel.com>
170Description:
171		The MIC drivers detect and inform user space about card crashes
172		via a heartbeat mechanism (see the description of
173		shutdown_status above). User space can turn off this
174		notification by setting heartbeat_enable to 0 and enable it by
175		setting this entry to 1. If this notification is disabled it is
176		the responsibility of user space to detect card crashes via
177		alternative means such as a network ping. This setting is
178		enabled by default.
179