Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

docs: filesystems: convert spufs/spu_run.txt to ReST

This file is at groff output format. Manually convert it to
ReST format, trying to preserve a similar output after parsed.

Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Link: https://lore.kernel.org/r/7d8ee1edf5ef0137009bc65ff0441826ce555895.1588021877.git.mchehab+huawei@kernel.org
Signed-off-by: Jonathan Corbet <corbet@lwn.net>

authored by

Mauro Carvalho Chehab and committed by
Jonathan Corbet
e2975d7c 299cd274

+43 -25
+1
Documentation/filesystems/spufs/index.rst
··· 10 10 11 11 spufs 12 12 spu_create 13 + spu_run
+42 -25
Documentation/filesystems/spufs/spu_run.txt Documentation/filesystems/spufs/spu_run.rst
··· 1 - SPU_RUN(2) Linux Programmer's Manual SPU_RUN(2) 1 + .. SPDX-License-Identifier: GPL-2.0 2 + 3 + ======= 4 + spu_run 5 + ======= 2 6 3 7 4 - 5 - NAME 8 + Name 9 + ==== 6 10 spu_run - execute an spu context 7 11 8 12 9 - SYNOPSIS 10 - #include <sys/spu.h> 13 + Synopsis 14 + ======== 11 15 12 - int spu_run(int fd, unsigned int *npc, unsigned int *event); 16 + :: 13 17 14 - DESCRIPTION 18 + #include <sys/spu.h> 19 + 20 + int spu_run(int fd, unsigned int *npc, unsigned int *event); 21 + 22 + Description 23 + =========== 15 24 The spu_run system call is used on PowerPC machines that implement the 16 25 Cell Broadband Engine Architecture in order to access Synergistic Pro- 17 26 cessor Units (SPUs). It uses the fd that was returned from spu_cre- ··· 54 45 If NULL is passed as the event argument, these errors will result in a 55 46 signal delivered to the calling process. 56 47 57 - RETURN VALUE 48 + Return Value 49 + ============ 58 50 spu_run returns the value of the spu_status register or -1 to indicate 59 51 an error and set errno to one of the error codes listed below. The 60 52 spu_status register value contains a bit mask of status codes and 61 53 optionally a 14 bit code returned from the stop-and-signal instruction 62 54 on the SPU. The bit masks for the status codes are: 63 55 64 - 0x02 SPU was stopped by stop-and-signal. 56 + 0x02 57 + SPU was stopped by stop-and-signal. 65 58 66 - 0x04 SPU was stopped by halt. 59 + 0x04 60 + SPU was stopped by halt. 67 61 68 - 0x08 SPU is waiting for a channel. 62 + 0x08 63 + SPU is waiting for a channel. 69 64 70 - 0x10 SPU is in single-step mode. 65 + 0x10 66 + SPU is in single-step mode. 71 67 72 - 0x20 SPU has tried to execute an invalid instruction. 68 + 0x20 69 + SPU has tried to execute an invalid instruction. 73 70 74 - 0x40 SPU has tried to access an invalid channel. 71 + 0x40 72 + SPU has tried to access an invalid channel. 75 73 76 74 0x3fff0000 77 75 The bits masked with this value contain the code returned from ··· 87 71 There are always one or more of the lower eight bits set or an error 88 72 code is returned from spu_run. 89 73 90 - ERRORS 74 + Errors 75 + ====== 91 76 EAGAIN or EWOULDBLOCK 92 77 fd is in non-blocking mode and spu_run would block. 93 78 ··· 110 93 not loaded. 111 94 112 95 113 - NOTES 96 + Notes 97 + ===== 114 98 spu_run is meant to be used from libraries that implement a more 115 99 abstract interface to SPUs, not to be used from regular applications. 116 100 See http://www.bsc.es/projects/deepcomputing/linuxoncell/ for the rec- 117 101 ommended libraries. 118 102 119 103 120 - CONFORMING TO 104 + Conforming to 105 + ============= 121 106 This call is Linux specific and only implemented by the ppc64 architec- 122 107 ture. Programs using this system call are not portable. 123 108 124 109 125 - BUGS 110 + Bugs 111 + ==== 126 112 The code does not yet fully implement all features lined out here. 127 113 128 114 129 - AUTHOR 115 + Author 116 + ====== 130 117 Arnd Bergmann <arndb@de.ibm.com> 131 118 132 - SEE ALSO 119 + See Also 120 + ======== 133 121 capabilities(7), close(2), spu_create(2), spufs(7) 134 - 135 - 136 - 137 - 138 - Linux 2005-09-28 SPU_RUN(2)