Lines Matching refs:the
6 spufs - the SPU file system
10 The SPU file system is used on PowerPC machines that implement the Cell
15 message queues. Users that have write permissions on the file system
16 can use spu_create(2) to establish SPU contexts in the spufs root.
19 set of files. These files can be used for manipulating the state of the
26 set the user owning the mount point, the default is 0 (root).
29 set the group owning the mount point, the default is 0 (root).
33 The files in spufs mostly follow the standard behavior for regular sys-
35 the operations supported on regular file systems. This list details the
36 supported operations and the deviations from the behaviour in the
39 All files that support the read(2) operation also support readv(2) and
40 all files that support the write(2) operation also support writev(2).
41 All files support the access(2) and stat(2) family of operations, but
42 only the st_mode, st_nlink, st_uid and st_gid fields of struct stat
45 All files support the chmod(2)/fchmod(2) and chown(2)/fchown(2) opera-
46 tions, but will not be able to grant permissions that contradict the
47 possible operations, e.g. read access on the wbox file.
53 the contents of the local storage memory of the SPU. This can be
55 data in the address space of the SPU. The possible operations on an
59 These operate as documented, with the exception that seek(2),
60 write(2) and pwrite(2) are not supported beyond the end of the
61 file. The file size is the size of the local storage of the SPU,
65 Mapping mem into the process address space gives access to the
66 SPU local storage within the process address space. Only
78 sets errno to EINVAL. If there is no data available in the mail
79 box, the return value is set to -1 and errno becomes EAGAIN.
81 the data buffer and the value four is returned.
86 the first mailbox file, but can be read in blocking I/O mode, and the
92 sets errno to EINVAL. If there is no data available in the mail
93 box and the file descriptor has been opened with O_NONBLOCK, the
96 If there is no data available in the mail box and the file
97 descriptor has been opened without O_NONBLOCK, the call will
98 block until the SPU writes to its interrupt mailbox channel.
100 the data buffer and the value four is returned.
103 Poll on the ibox file returns (POLLIN | POLLRDNORM) whenever
109 in units of 32 bits. If the mailbox is full, write() will block and
113 is no space available in the mail box and the file descriptor has been
114 opened with O_NONBLOCK, the return value is set to -1 and errno becomes
117 If there is no space available in the mail box and the file descriptor
118 has been opened without O_NONBLOCK, the call will block until the SPU
120 fully, four bytes are placed in the data buffer and the value four is
124 Poll on the ibox file returns (POLLOUT | POLLWRNORM) whenever
131 Read-only files that contain the length of the current queue, i.e. how
140 the data buffer, containing the number of elements that can be
142 wbox_stat) the respective mail box without blocking or resulting
152 Internal registers of the SPU. The representation is an ASCII string
153 with the numeric value of the next instruction to be executed. These
177 When the count supplied to the read call is shorter than the
178 required length for the pointer value plus a newline character,
179 subsequent reads from the same file descriptor will result in
180 completing the string, regardless of changes to the register by
183 descriptor needs to be opened to read the value again.
186 A write operation on the file results in setting the register to
187 the value given in the string. The string is parsed from the
188 beginning to the first non-numeric character or the end of the
189 buffer. Subsequent writes to the same file descriptor overwrite
190 the previous setting.
194 This file gives access to the Floating Point Status and Control Regis-
195 ter as a four byte long file. The operations on the fpcr file are:
200 the data buffer, containing the current value of the fpcr regis-
206 from the data buffer, updating the value of the fpcr register.
213 triggers an interrupt on the SPU. The value written to the signal
214 files can be read from the SPU through a channel read or from host user
215 space through the file. After the value has been read by the SPU, it
222 the data buffer, containing the current value of the specified
228 from the data buffer, updating the value of the specified signal
230 either be replaced with the input data or will be updated to the
231 bitwise OR or the old value and the input data, depending on the
232 contents of the signal1_type, or signal2_type respectively,
238 These two files change the behavior of the signal1 and signal2 notifi-
240 either "1" or "0". In mode 0 (overwrite), the hardware replaces the
241 contents of the signal channel with the data that is written to it. in
242 mode 1 (logical OR), the hardware accumulates the bits that are subse-
247 When the count supplied to the read call is shorter than the
248 required length for the digit plus a newline character, subse-
249 quent reads from the same file descriptor will result in com-
250 pleting the string. When a complete string has been read, all
252 descriptor needs to be opened to read the value again.
255 A write operation on the file results in setting the register to
256 the value given in the string. The string is parsed from the
257 beginning to the first non-numeric character or the end of the
258 buffer. Subsequent writes to the same file descriptor overwrite
259 the previous setting.
294 The spu_run system call is used on PowerPC machines that implement the
296 cessor Units (SPUs). It uses the fd that was returned from spu_cre-
297 ate(2) to address a specific SPU context. When the context gets sched-
298 uled to a physical SPU, it starts execution at the instruction pointer
302 not return while the SPU is still running. If there is a need to exe-
303 cute SPU code in parallel with other code on either the main CPU or
305 using the pthread_create(3) call.
307 When spu_run returns, the current value of the SPU instruction pointer
309 the pointers.
312 gets filled when spu_run returns. It can be one of the following con-
324 If NULL is passed as the event argument, these errors will result in a
325 signal delivered to the calling process.
328 spu_run returns the value of the spu_status register or -1 to indicate
329 an error and set errno to one of the error codes listed below. The
331 optionally a 14 bit code returned from the stop-and-signal instruction
332 on the SPU. The bit masks for the status codes are:
347 The bits masked with this value contain the code returned from
350 There are always one or more of the lower eight bits set or an error
363 has been updated to the new program counter value if necessary.
370 ENOSYS the functionality is not provided by the current system, because
371 either the hardware does not provide SPUs or the spufs module is
378 See http://www.bsc.es/projects/deepcomputing/linuxoncell/ for the rec-
383 This call is Linux specific and only implemented by the ppc64 architec-
419 the Cell Broadband Engine Architecture in order to access Synergistic
422 point to a non-existing directory in the mount point of the SPU file
428 ated directory entries in spufs are removed. When the last file handle
429 pointing either inside of the context directory or to this file
430 descriptor is closed, the logical SPU context is destroyed.
432 The parameter flags can be zero or any bitwise or'd combination of the
436 Allow mapping of some of the hardware registers of the SPU into
437 user space. This flag requires the CAP_SYS_RAWIO capability, see
440 The mode parameter specifies the permissions used for creating the new
441 directory in spufs. mode is modified with the user's umask(2) value
442 and then used for both the directory and the files contained in it. The
444 support only read or write access. See stat(2) for a full list of the
450 an error condition and set errno to one of the error codes listed
456 The current user does not have write access on the spufs mount
459 EEXIST An SPU context already exists at the given path name.
461 EFAULT pathname is not a valid string pointer in the current address
464 EINVAL pathname is not a directory in the spufs mount point.
473 ENFILE The system has reached the global open file limit.
480 context or the user specific limit for the number of SPU con-
483 ENOSYS the functionality is not provided by the current system, because
484 either the hardware does not provide SPUs or the spufs module is
495 See http://www.bsc.es/projects/deepcomputing/linuxoncell/ for the rec-
500 pathname must point to a location beneath the mount point of spufs. By
505 This call is Linux specific and only implemented by the ppc64 architec-